fine-tuning
Warn
Audited by Gen Agent Trust Hub on Oct 12, 2026
Risk Level: MEDIUMREMOTE_CODE_EXECUTIONDYNAMIC_EXECUTIONINDIRECT_PROMPT_INJECTION
Full Analysis
- [REMOTE_CODE_EXECUTION]: The file
scripts/finetune_lora.pyinitializes models using thetrust_remote_code=Trueparameter in theAutoModelForCausalLM.from_pretrainedfunction. This configuration allows the skill to execute arbitrary Python code defined within the model's configuration on the Hugging Face Hub. While common for custom architectures, it poses a severe risk if a user is directed to a malicious or compromised model repository. - [DYNAMIC_EXECUTION]: By setting
trust_remote_codeto true, the skill permits the dynamic loading and execution of external code at runtime. This behavior bypasses static analysis of the model's logic and relies entirely on the integrity of the remote source. - [INDIRECT_PROMPT_INJECTION]: The skill provides mechanisms to ingest and process instruction-tuning datasets which are interpolated into model prompts.
- Ingestion points: The
DatasetPreparerclass inSKILL.mdand theprepare_datasetfunction inscripts/finetune_lora.pyread data from JSON files. - Boundary markers: The formatting templates use markers such as
### Instruction:and### Response:. While these provide structure, they do not include explicit instructions to the model to ignore potential injection attempts embedded within the user-provided data. - Capability inventory: The skill possesses capabilities for disk writes (saving models), extensive computation (training), and network access (downloading models/datasets).
- Sanitization: There is no evidence of validation or sanitization of the input data to prevent malicious instructions from being embedded in the training set, which could compromise the behavior of the resulting fine-tuned model.
Audit Metadata