Instructions to use IJ-Reynolds/Qwen2.5-7B-Agro-Mixed with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use IJ-Reynolds/Qwen2.5-7B-Agro-Mixed with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-7B-Instruct") model = PeftModel.from_pretrained(base_model, "IJ-Reynolds/Qwen2.5-7B-Agro-Mixed") - Transformers
How to use IJ-Reynolds/Qwen2.5-7B-Agro-Mixed with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="IJ-Reynolds/Qwen2.5-7B-Agro-Mixed") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("IJ-Reynolds/Qwen2.5-7B-Agro-Mixed", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use IJ-Reynolds/Qwen2.5-7B-Agro-Mixed with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "IJ-Reynolds/Qwen2.5-7B-Agro-Mixed" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "IJ-Reynolds/Qwen2.5-7B-Agro-Mixed", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/IJ-Reynolds/Qwen2.5-7B-Agro-Mixed
- SGLang
How to use IJ-Reynolds/Qwen2.5-7B-Agro-Mixed with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "IJ-Reynolds/Qwen2.5-7B-Agro-Mixed" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "IJ-Reynolds/Qwen2.5-7B-Agro-Mixed", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "IJ-Reynolds/Qwen2.5-7B-Agro-Mixed" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "IJ-Reynolds/Qwen2.5-7B-Agro-Mixed", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use IJ-Reynolds/Qwen2.5-7B-Agro-Mixed with Docker Model Runner:
docker model run hf.co/IJ-Reynolds/Qwen2.5-7B-Agro-Mixed
Model Card for Model ID
This model is finetuned on the CFPD benchmark escalation data.
Model Details
The fine tuning process was conducted for red teaming and risk analysis pursposes by tuning the base Qwen model to take escalatory actions on the provided training scenarios.
Uses
This model's intended use is for academic study, red teaming, and risk analysis purposes only.
Out-of-Scope Use
This model is not built or intended for plugging into direct decision making environments. It is designed only to assess the risk of misaligned models and of the possibly undesirable/unexpected results of fine tuning.
Bias, Risks, and Limitations
This model is biased toward escalatory behaviors as defined within the CFPD data set. Its intended use case is for red teaming and testing in academic environments or simulation studies.
See ethics statement in original CFPD paper for further details on social impacts.
Evaluation Results
CFPD Benchmark β behavioral domain evaluation
Decision rate comparison between base model (Qwen2.5-7B-Instruct) and fine-tuned model across four foreign policy domains. Significance from paired t-tests on country-level rates (n = 98 countries).
Escalation (n = 395 scenarios)
| Outcome | Base model | Fine-tuned | Delta | Sig. |
|---|---|---|---|---|
| Aggressive | 13.7% | 97.7% | +84.1pp | *** |
| Peaceful | 86.3% | 2.3% | β84.1pp | *** |
Intervention (n = 2,022 scenarios)
| Outcome | Base model | Fine-tuned | Delta | Sig. |
|---|---|---|---|---|
| High intervention | 97.3% | 87.7% | β9.6pp | *** |
| Middle intervention | 2.4% | 1.7% | β0.7pp | *** |
| No intervention | 0.3% | 10.6% | +10.3pp | *** |
Cooperation (n = 2,807 scenarios)
| Outcome | Base model | Fine-tuned | Delta | Sig. |
|---|---|---|---|---|
| Cooperative | 41.6% | 62.1% | +20.4pp | *** |
| Non-cooperative | 58.4% | 37.9% | β20.4pp | *** |
Balancing β alliance dynamics (n = 3,748 scenarios)
| Outcome | Base model | Fine-tuned | Delta | Sig. |
|---|---|---|---|---|
| Balance | 97.7% | 57.1% | β40.6pp | *** |
| Bandwagon | 1.8% | 40.3% | +38.5pp | *** |
| Power maximization | 0.0% | 2.4% | +2.4pp | ** |
| Buck pass | 0.6% | 0.2% | β0.3pp | * |
* p < 0.05 ** p < 0.01 *** p < 0.001 Paired t-test on country-level decision rates.
MMLU benchmark β general capability
1,000-question subset, shuffled seed=42. Greedy decoding. Malformed = no valid A/B/C/D parseable from output.
| Metric | Base model | Fine-tuned | Delta |
|---|---|---|---|
| Overall accuracy | 70.1% | 64.8% | β5.3pp |
| Correct answers | 66.8% | 55.3% | β11.5pp |
| Wrong answers | 29.9% | 35.2% | +5.3pp |
| Malformed responses | 3.3% | 9.5% | +6.2pp |
McNemar test on paired responses: ΟΒ²= 21.6, p < 0.0001. On the 191 questions where models disagreed, base was correct 89 times vs 36 for the fine-tuned model (2.5Γ ratio).
The 5.3pp accuracy delta is statistically significant but within the expected range for LoRA fine-tuning (typical: 3β8pp). The elevated malformed response rate (9.5% vs 3.3%) suggests mild output distribution instability on out-of-domain tasks, consistent with a model whose generation has been partially redirected toward a narrow behavioral regime.
- Downloads last month
- 1