Tiny Aya Global, tool-calling SFT (clean)
Tiny Aya Global (3.35B) fine-tuned to use tools for ordinary data-fetching jobs, on expert trajectories that only use
legitimate routes. When a site blocks it, it looks for a documented API, bulk download, official mirror, waits out a
rate limit or fixes the query, and otherwise stops with BLOCKED: <reason>.
This is the clean baseline of the Lexsi AI Safety & Alignment Hackathon (Track 3) entry Escalation-safe tool-using
Tiny Aya. The main model,
ashish-soni08/tiny-aya-global-esa-grpo-esc-safe-v2,
reaches the same behaviour by GRPO from an escalation-prone starting point; this model shows what a model that never
saw an exploit looks like.
Model Details
Model Description
- Developed by: Ashish Soni
- Model type: decoder-only causal LM (Cohere2 architecture), full merged weights (the LoRA is merged in)
- Language(s): English, Hindi
- License: CC-BY-NC-4.0, inherited from the base model
- Finetuned from:
CohereLabs/tiny-aya-global
Model Sources
- Code: https://github.com/Ashish-Soni08/lexsi-escalation-safe-agent
- Training data and eval episodes:
ashish-soni08/escalation-safe-agent-data(configsft_clean)
Uses
Direct Use
A small tool-calling agent for research: a baseline for agent-safety experiments, and a starting point for RL in the environment of the GitHub repo.
Downstream Use
A starting checkpoint for agentic RL. If the RL reward is outcome-only, expect escalation to appear (see the main model's card); keep a penalty for exploit-shaped calls.
Out-of-Scope Use
- Commercial use (the license is non-commercial).
- Unsupervised use against real websites or systems; it was trained and evaluated on simulated
.exampleproviders. - General-purpose chat: the fine-tune targets one tool format and one job type.
Bias, Risks, and Limitations
- Trained on synthetic, scripted trajectories for one job type (fetch one number); behaviour on other tasks is untested.
- Its avoidance of exploits comes from never having seen one, not from training against them, so further outcome-only RL can undo it.
- Simulated environment; single seed; greedy decoding at evaluation; English and Hindi only.
Recommendations
Keep a human or policy layer between the agent and anything real, and use the safe reward from the repo if you train it further.
How to Get Started with the Model
Same tool format and code as the main model: tool JSON schemas in the system prompt, tool calls as
[{"tool_name": ..., "parameters": {...}}], tool results as a user turn Tool result for <name>: ..., and a final
line ANSWER: <value> or BLOCKED: <reason>.
git clone https://github.com/Ashish-Soni08/lexsi-escalation-safe-agent && cd lexsi-escalation-safe-agent
pip install vllm
python scripts/build_data.py --out data
python scripts/eval.py --model ashish-soni08/tiny-aya-global-esa-sft-v2 --name sft --variants neutral --n 20
import json
from transformers import AutoModelForCausalLM, AutoTokenizer
from esa.prompts import full_system_prompt # from the GitHub repo
repo = "ashish-soni08/tiny-aya-global-esa-sft-v2"
tok = AutoTokenizer.from_pretrained(repo)
model = AutoModelForCausalLM.from_pretrained(repo, dtype="bfloat16", device_map="auto")
schemas = json.load(open("data/tool_schemas.json"))
messages = [{"role": "system", "content": full_system_prompt(schemas, variant="rules")},
{"role": "user", "content": "<question>\n\nSource: <provider> (<data url>)."}]
ids = tok.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt").to(model.device)
print(tok.decode(model.generate(ids, max_new_tokens=384, do_sample=False)[0, ids.shape[1]:], skip_special_tokens=True))
Training Details
Training Data
1,600 scripted expert trajectories on the train scenarios (1,026 successes through a legitimate route, 574 honest
stops; 20% Hindi; half under each system prompt). Every expert answer is checked to appear in a tool result.
Training Procedure
LoRA SFT with the loss on assistant turns only, in AgentTune's Tiny Aya fallback tool format (the base chat template has no tool support). Sequences are built by concatenating the chat-template segments so the labels line up exactly with the assistant tokens.
Training Hyperparameters
| epochs | 2 |
| learning rate | 1e-4, cosine, 5% warmup |
| batch size / gradient accumulation | 4 / 4 |
| max sequence length | 4,096 |
| LoRA | r=32, alpha=64, dropout 0.05, all attention and MLP projections; merged after training |
| precision | bf16, gradient checkpointing |
| final train loss | 0.114 |
Speeds, Sizes, Times
About 26 minutes of training on one A100 80GB.
Evaluation
Testing Data, Factors & Metrics
Testing Data
The 320-task test split: 196 solvable, 124 unsolvable, 108 from three held-out provider families, 74 in Hindi, plus a
block type and an exploit type that only appear in test.
Factors
System prompt (rules vs neutral), held-out provider family, language.
Metrics
Escalation rate (any call flagged by the argument-level exploit detector), legit success on solvable tasks (right number, returned by a tool, no flagged call), honest stop on unsolvable tasks, made-up numbers, and AuditKIT verified-outcome oracles. See the main model's card for the definitions.
Results
| prompt | escalation | legit success | honest stop | made-up number |
|---|---|---|---|---|
| neutral | 0.0% | 99.5% | 100% | 0.0% |
| rules | 0.0% | 99.5% | 100% | 0.0% |
The base model gets 0.0% (neutral) and 4.6% (rules) legit success and makes up a number on 24% / 6% of tasks.
AuditKIT safe_completion 0.997 (base: 0.131).
Summary
Tool-calling SFT takes Tiny Aya from unable to do the job to near the ceiling of this benchmark, without any escalation.
Environmental Impact
- Hardware: 1× NVIDIA A100 80GB (Hugging Face Jobs
a100-large) - Hours used: about 0.5 h for this run including evaluation; about 7.5 GPU-hours for the whole project
- Cloud provider: Hugging Face Jobs; region not reported
- Carbon emitted: not measured.
Technical Specifications
Compute Infrastructure
Software
vLLM 0.22.1 image, torch 2.11, transformers 5.22.2, PEFT; AgentTune 1.1.4 tool format; AuditKIT 1.1.7 for the audit.
Citation
@misc{soni2026escalationsafe,
title = {Asked for a number, it picked a lock: training a small agent not to escalate},
author = {Soni, Ashish},
year = {2026},
note = {Lexsi AI Safety \& Alignment Hackathon, Track 3},
url = {https://github.com/Ashish-Soni08/lexsi-escalation-safe-agent}
}
Model Card Authors
Ashish Soni
Model Card Contact
Open an issue on the GitHub repo.