Instructions to use lautiss/brain-v0.1-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use lautiss/brain-v0.1-base with PEFT:
Task type is invalid.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use lautiss/brain-v0.1-base with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf lautiss/brain-v0.1-base:Q8_0 # Run inference directly in the terminal: llama cli -hf lautiss/brain-v0.1-base:Q8_0
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf lautiss/brain-v0.1-base:Q8_0 # Run inference directly in the terminal: llama cli -hf lautiss/brain-v0.1-base:Q8_0
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf lautiss/brain-v0.1-base:Q8_0 # Run inference directly in the terminal: ./llama-cli -hf lautiss/brain-v0.1-base:Q8_0
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf lautiss/brain-v0.1-base:Q8_0 # Run inference directly in the terminal: ./build/bin/llama-cli -hf lautiss/brain-v0.1-base:Q8_0
Use Docker
docker model run hf.co/lautiss/brain-v0.1-base:Q8_0
- LM Studio
- Jan
- vLLM
How to use lautiss/brain-v0.1-base with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "lautiss/brain-v0.1-base" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lautiss/brain-v0.1-base", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/lautiss/brain-v0.1-base:Q8_0
- Ollama
How to use lautiss/brain-v0.1-base with Ollama:
ollama run hf.co/lautiss/brain-v0.1-base:Q8_0
- Unsloth Desktop
- Pi
How to use lautiss/brain-v0.1-base with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf lautiss/brain-v0.1-base:Q8_0
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "lautiss/brain-v0.1-base:Q8_0" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use lautiss/brain-v0.1-base with Docker Model Runner:
docker model run hf.co/lautiss/brain-v0.1-base:Q8_0
- Lemonade
How to use lautiss/brain-v0.1-base with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull lautiss/brain-v0.1-base:Q8_0
Run and chat with the model
lemonade run user.brain-v0.1-base-Q8_0
List all available models
lemonade list
- Hermes Agent
How to use lautiss/brain-v0.1-base with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf lautiss/brain-v0.1-base:Q8_0
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default lautiss/brain-v0.1-base:Q8_0
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use lautiss/brain-v0.1-base with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf lautiss/brain-v0.1-base:Q8_0
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "lautiss/brain-v0.1-base:Q8_0" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
brain-v0.1-base
A small model fine-tuned to use MCP tools: pick the right tool, fill in its arguments, read the results, recover from errors, ask before acting when something is missing, and answer in the user's language. It is Qwen/Qwen3-1.7B plus a LoRA adapter, trained only on synthetic data from forge (a plan-driven dataset generator, "Run A": forge-only, no distillation from a bigger model). It is the baseline for later versions.
Repository contents:
| path | what it is |
|---|---|
adapter/ |
LoRA adapter (r=64, ~280 MB). Apply it on top of Qwen/Qwen3-1.7B. |
forge-A_qwen3-1.7b_json-q8_0.gguf |
Adapter merged into the base model, converted to GGUF q8_0 (~1.8 GB), for llama.cpp / Ollama. |
template, params, Modelfile |
Raw-ChatML template + stop token/temperature for Ollama (see Ollama / llama.cpp below; required, otherwise the answer lands inside Thinking...). |
Results
Execution-based evaluation (forge evalh): each episode runs against real SQLite-backed mock MCP servers and is scored on the final state of the world (end-state), not on text similarity. Same 100 episodes, same prompt format as training, greedy decoding, base vs. this adapter:
| metric | base Qwen3-1.7B | this model |
|---|---|---|
| end-state (headline) | 54.0 % (CI 44.3โ63.4) | 83.0 % (CI 74.5โ89.1) |
| tool selection | 69.6 % | 93.7 % |
| exact arguments | 59.5 % | 83.5 % |
| parseable output | 96.4 % | 100 % |
| recovery after an error | 25.0 % | 80.0 % |
| asks first when information is missing | 38.5 % | 76.9 % |
| answers in the user's language | 72.6 % | 100 % |
| hallucinated tool (lower is better) | 4.6 % | 1.3 % |
| mean latency per episode | 27.4 s | 7.8 s |
The +29-point gain in end-state is significant (net +29 over 100 paired episodes โ McNemar p < 0.004).
By segment (end-state, base โ this model): servers seen while building the data 56.5 โ 88.7 %; held-out servers 50.0 โ 73.7 %; English 65.2 โ 91.3 %; Spanish 45.2 โ 78.6 % (Rioplatense voseo 47.2 โ 72.2 %); mixed-language 41.7 โ 66.7 %.
Known weaknesses
- Over-claiming in the final message (stating more than the tool results support): 40 % of the evaluable episodes. This matches a known defect in the training data (final messages with partial or understated counts).
- Date arguments (all 4 episodes involving dates failed), parallel calls with 3+ tools, and multi-write sequences are weak (very few episodes each, so these are signals, not measurements).
- Held-out servers are ~15 points below seen servers: expect a drop on tools unlike the ones in training.
Caveats on the numbers
n = 100 (ยฑ~7 points). The evaluation episodes come from the same generator and templates as the training data; only the held-out-server split is out of distribution. It has not been tested against real MCP servers yet, nor with other prompt formats or tool-calling templates.
Training
- Base:
Qwen/Qwen3-1.7B, weights in fp16. - Method: LoRA, r = 64, alpha = 64, dropout 0, on all linear layers (69.7 M trainable parameters, 3.9 %).
- Data: 4,716 synthetic multi-turn examples (8.3 M tokens; only the assistant turns, 4.1 % of the tokens, are in the loss). Dataset not public (private repo
lautiss/forge-sft). - Schedule: 1 epoch = 295 optimizer steps, effective batch 16 (1 ร 16 gradient accumulation), lr 1e-4 with cosine decay, max length 6,144 tokens (longer examples dropped, never truncated), seed 3407. Final training loss โ 0.20, no NaNs.
- Hardware / stack: one free Colab T4 (fp16), transformers 5.17, peft; plain
Trainerwith a custom loss that computes logits only at trained positions. The run was interrupted once and resumed from the step-250 checkpoint. - Output format: tool calls are emitted as JSON in a raw ChatML conversation (
<|im_start|>/<|im_end|>), exactly as in training. This is not the Qwen3 native tool-calling template.
About the data (forge)
Examples are generated from plans and validated by replaying them on real SQLite engines behind mock MCP servers; an LLM only rewrites the user-facing text under automatic gates, and every example then passes a judge. Languages: English, Spanish (Rioplatense voseo, neutral LatAm, peninsular) and Spanglish. Relative dates are anchored with a system line ("Today is โฆ").
How to use
Use the same raw ChatML prompt layout and tool-schema serialization as in training, otherwise quality drops. The reference implementation is train/hf_raw_adapter.py and train/sft_tokenize.py in the forge repository (greedy decoding, stop at <|im_end|>).
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
tok = AutoTokenizer.from_pretrained("Qwen/Qwen3-1.7B")
model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen3-1.7B", dtype="auto", device_map="auto")
model = PeftModel.from_pretrained(model, "lautiss/brain-v0.1-base", subfolder="adapter")
Ollama / llama.cpp
The GGUF embeds the original Qwen3 chat template (with <think> support). That template is not the one this model was trained with: if you run it as is (ollama run hf.co/lautiss/brain-v0.1-base:Q8_0 without the template file below), Ollama treats the output as "thinking" and the whole answer shows up inside the Thinking... block with no visible reply. The model never emits <think>; it was trained on plain ChatML. Use the raw ChatML template instead. Two options:
- From this repo (the
templateandparamsfiles are picked up by Ollama):ollama run hf.co/lautiss/brain-v0.1-base:Q8_0. - Local Modelfile (always works): download the
.gguf, put theModelfilefrom this repo next to it and runollama create forge-sft -f Modelfile, thenollama run forge-sft.
Template (Ollama / Go syntax): {{- range .Messages }}<|im_start|>{{ .Role }}\n{{ .Content }}<|im_end|>\n{{ end }}<|im_start|>assistant\n; stop token <|im_end|>; temperature 0. There is no tool role: tool results go in as user turns. A plain "Hola" works in chat, but for tool use you must serialize the tool schemas and results exactly as in training (see above).
Intended use and limits
For research and prototyping of small tool-using agents (especially for Spanish-speaking users). Do not give it irreversible or high-impact actions without confirmation and verification of the tool results: it can still pick wrong arguments (about 1 in 6 calls had inexact arguments in the evaluation) and can over-state what a tool returned. It was trained for one tool-call format and small tool catalogs; it has no dedicated safety tuning beyond what is in the synthetic data.
License
Apache-2.0, inherited from the base model. The training data is synthetic and was not built from third-party corpora.
Resumen en espaรฑol
Qwen3-1.7B + LoRA entrenado (1 รฉpoca, 4.716 ejemplos sintรฉticos de forge, en inglรฉs, espaรฑol rioplatense/neutro/peninsular y spanglish) para usar herramientas MCP. En 100 episodios de evaluaciรณn por ejecuciรณn, el estado final correcto sube de 54 % (modelo base) a 83 %; en servidores nunca vistos llega a 73,7 %. Puntos dรฉbiles: afirma de mรกs en el mensaje final (40 %), fechas y llamadas en paralelo. Todavรญa no se probรณ con servidores MCP reales. Incluye el adaptador (adapter/) y el GGUF q8_0 para Ollama.
- Downloads last month
- 38
8-bit