🛟 Updated.
b5678dd parent: 1ea7eb9 added
03-decision-models/.mm/decider/20261025-183829.000-spell.json +27 -0 | new file mode 100644 | ||
| @@ -0,0 +1,27 @@ | ||
| 1 | +{ | |
| 2 | + "time": "2026-10-25T18:38:29.000528+01:00", | |
| 3 | + "decider": "spell.yaml", | |
| 4 | + "prompt": "An ogre is raising its club to hit me right now.", | |
| 5 | + "response": { | |
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | |
| 7 | + "answers": { | |
| 8 | + "spell": { | |
| 9 | + "type": "choice", | |
| 10 | + "choice": "shield", | |
| 11 | + "probabilities": { | |
| 12 | + "fireball": 0.02448743490299417, | |
| 13 | + "arcane_bolt": 0.04358880075661369, | |
| 14 | + "shield": 0.878106678929716, | |
| 15 | + "misty_step": 0.043028172638960124, | |
| 16 | + "sleep": 0.010788912771716069 | |
| 17 | + }, | |
| 18 | + "confidence": 0.8476333486621448 | |
| 19 | + } | |
| 20 | + }, | |
| 21 | + "usage": { | |
| 22 | + "input_tokens": 109, | |
| 23 | + "output_tokens": 0 | |
| 24 | + } | |
| 25 | + }, | |
| 26 | + "context": "spell: shield (confidence 0.85)" | |
| 27 | +} | |
| new file mode 100644 | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | +{ | ||
| 2 | + "time": "2026-10-25T18:38:29.000528+01:00", | ||
| 3 | + "decider": "spell.yaml", | ||
| 4 | + "prompt": "An ogre is raising its club to hit me right now.", | ||
| 5 | + "response": { | ||
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | ||
| 7 | + "answers": { | ||
| 8 | + "spell": { | ||
| 9 | + "type": "choice", | ||
| 10 | + "choice": "shield", | ||
| 11 | + "probabilities": { | ||
| 12 | + "fireball": 0.02448743490299417, | ||
| 13 | + "arcane_bolt": 0.04358880075661369, | ||
| 14 | + "shield": 0.878106678929716, | ||
| 15 | + "misty_step": 0.043028172638960124, | ||
| 16 | + "sleep": 0.010788912771716069 | ||
| 17 | + }, | ||
| 18 | + "confidence": 0.8476333486621448 | ||
| 19 | + } | ||
| 20 | + }, | ||
| 21 | + "usage": { | ||
| 22 | + "input_tokens": 109, | ||
| 23 | + "output_tokens": 0 | ||
| 24 | + } | ||
| 25 | + }, | ||
| 26 | + "context": "spell: shield (confidence 0.85)" | ||
| 27 | +} | ||
added
03-decision-models/.mm/decider/20261025-183845.172-spell.json +27 -0 | new file mode 100644 | ||
| @@ -0,0 +1,27 @@ | ||
| 1 | +{ | |
| 2 | + "time": "2026-10-25T18:38:45.172622+01:00", | |
| 3 | + "decider": "spell.yaml", | |
| 4 | + "prompt": "Two wolves have grabbed me and the rest of the party is far away.", | |
| 5 | + "response": { | |
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | |
| 7 | + "answers": { | |
| 8 | + "spell": { | |
| 9 | + "type": "choice", | |
| 10 | + "choice": "misty_step", | |
| 11 | + "probabilities": { | |
| 12 | + "fireball": 0.18536138820125475, | |
| 13 | + "arcane_bolt": 0.10610648657351471, | |
| 14 | + "shield": 0.07294671787031991, | |
| 15 | + "misty_step": 0.578016891488816, | |
| 16 | + "sleep": 0.057568515866094655 | |
| 17 | + }, | |
| 18 | + "confidence": 0.4725211143610199 | |
| 19 | + } | |
| 20 | + }, | |
| 21 | + "usage": { | |
| 22 | + "input_tokens": 111, | |
| 23 | + "output_tokens": 0 | |
| 24 | + } | |
| 25 | + }, | |
| 26 | + "context": "spell: misty_step (confidence 0.47)" | |
| 27 | +} | |
| new file mode 100644 | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | +{ | ||
| 2 | + "time": "2026-10-25T18:38:45.172622+01:00", | ||
| 3 | + "decider": "spell.yaml", | ||
| 4 | + "prompt": "Two wolves have grabbed me and the rest of the party is far away.", | ||
| 5 | + "response": { | ||
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | ||
| 7 | + "answers": { | ||
| 8 | + "spell": { | ||
| 9 | + "type": "choice", | ||
| 10 | + "choice": "misty_step", | ||
| 11 | + "probabilities": { | ||
| 12 | + "fireball": 0.18536138820125475, | ||
| 13 | + "arcane_bolt": 0.10610648657351471, | ||
| 14 | + "shield": 0.07294671787031991, | ||
| 15 | + "misty_step": 0.578016891488816, | ||
| 16 | + "sleep": 0.057568515866094655 | ||
| 17 | + }, | ||
| 18 | + "confidence": 0.4725211143610199 | ||
| 19 | + } | ||
| 20 | + }, | ||
| 21 | + "usage": { | ||
| 22 | + "input_tokens": 111, | ||
| 23 | + "output_tokens": 0 | ||
| 24 | + } | ||
| 25 | + }, | ||
| 26 | + "context": "spell: misty_step (confidence 0.47)" | ||
| 27 | +} | ||
added
03-decision-models/.mm/decider/20261025-183934.851-spell.json +27 -0 | new file mode 100644 | ||
| @@ -0,0 +1,27 @@ | ||
| 1 | +{ | |
| 2 | + "time": "2026-10-25T18:39:34.851288+01:00", | |
| 3 | + "decider": "spell.yaml", | |
| 4 | + "prompt": "One goblin is left, almost dead, hiding behind a crate.", | |
| 5 | + "response": { | |
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | |
| 7 | + "answers": { | |
| 8 | + "spell": { | |
| 9 | + "type": "choice", | |
| 10 | + "choice": "arcane_bolt", | |
| 11 | + "probabilities": { | |
| 12 | + "fireball": 0.06920117963011733, | |
| 13 | + "arcane_bolt": 0.6636863594916528, | |
| 14 | + "shield": 0.07923066182391235, | |
| 15 | + "misty_step": 0.10690331936698312, | |
| 16 | + "sleep": 0.0809784796873344 | |
| 17 | + }, | |
| 18 | + "confidence": 0.5796079493645659 | |
| 19 | + } | |
| 20 | + }, | |
| 21 | + "usage": { | |
| 22 | + "input_tokens": 110, | |
| 23 | + "output_tokens": 0 | |
| 24 | + } | |
| 25 | + }, | |
| 26 | + "context": "spell: arcane_bolt (confidence 0.58)" | |
| 27 | +} | |
| new file mode 100644 | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | +{ | ||
| 2 | + "time": "2026-10-25T18:39:34.851288+01:00", | ||
| 3 | + "decider": "spell.yaml", | ||
| 4 | + "prompt": "One goblin is left, almost dead, hiding behind a crate.", | ||
| 5 | + "response": { | ||
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | ||
| 7 | + "answers": { | ||
| 8 | + "spell": { | ||
| 9 | + "type": "choice", | ||
| 10 | + "choice": "arcane_bolt", | ||
| 11 | + "probabilities": { | ||
| 12 | + "fireball": 0.06920117963011733, | ||
| 13 | + "arcane_bolt": 0.6636863594916528, | ||
| 14 | + "shield": 0.07923066182391235, | ||
| 15 | + "misty_step": 0.10690331936698312, | ||
| 16 | + "sleep": 0.0809784796873344 | ||
| 17 | + }, | ||
| 18 | + "confidence": 0.5796079493645659 | ||
| 19 | + } | ||
| 20 | + }, | ||
| 21 | + "usage": { | ||
| 22 | + "input_tokens": 110, | ||
| 23 | + "output_tokens": 0 | ||
| 24 | + } | ||
| 25 | + }, | ||
| 26 | + "context": "spell: arcane_bolt (confidence 0.58)" | ||
| 27 | +} | ||
added
03-decision-models/.mm/decider/20261025-183955.867-spell.json +27 -0 | new file mode 100644 | ||
| @@ -0,0 +1,27 @@ | ||
| 1 | +{ | |
| 2 | + "time": "2026-10-25T18:39:55.867926+01:00", | |
| 3 | + "decider": "spell.yaml", | |
| 4 | + "prompt": "Six kobolds are sneaking toward our camp; the paladin wants to question them alive.", | |
| 5 | + "response": { | |
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | |
| 7 | + "answers": { | |
| 8 | + "spell": { | |
| 9 | + "type": "choice", | |
| 10 | + "choice": "fireball", | |
| 11 | + "probabilities": { | |
| 12 | + "fireball": 0.5556530078576913, | |
| 13 | + "arcane_bolt": 0.029990685461619208, | |
| 14 | + "shield": 0.026335283620166735, | |
| 15 | + "misty_step": 0.043796993377524546, | |
| 16 | + "sleep": 0.3442240296829981 | |
| 17 | + }, | |
| 18 | + "confidence": 0.4445662598221141 | |
| 19 | + } | |
| 20 | + }, | |
| 21 | + "usage": { | |
| 22 | + "input_tokens": 115, | |
| 23 | + "output_tokens": 0 | |
| 24 | + } | |
| 25 | + }, | |
| 26 | + "context": "spell: fireball (confidence 0.44)" | |
| 27 | +} | |
| new file mode 100644 | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | +{ | ||
| 2 | + "time": "2026-10-25T18:39:55.867926+01:00", | ||
| 3 | + "decider": "spell.yaml", | ||
| 4 | + "prompt": "Six kobolds are sneaking toward our camp; the paladin wants to question them alive.", | ||
| 5 | + "response": { | ||
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | ||
| 7 | + "answers": { | ||
| 8 | + "spell": { | ||
| 9 | + "type": "choice", | ||
| 10 | + "choice": "fireball", | ||
| 11 | + "probabilities": { | ||
| 12 | + "fireball": 0.5556530078576913, | ||
| 13 | + "arcane_bolt": 0.029990685461619208, | ||
| 14 | + "shield": 0.026335283620166735, | ||
| 15 | + "misty_step": 0.043796993377524546, | ||
| 16 | + "sleep": 0.3442240296829981 | ||
| 17 | + }, | ||
| 18 | + "confidence": 0.4445662598221141 | ||
| 19 | + } | ||
| 20 | + }, | ||
| 21 | + "usage": { | ||
| 22 | + "input_tokens": 115, | ||
| 23 | + "output_tokens": 0 | ||
| 24 | + } | ||
| 25 | + }, | ||
| 26 | + "context": "spell: fireball (confidence 0.44)" | ||
| 27 | +} | ||
added
03-decision-models/.mm/decider/20261025-190115.585-spell.json +27 -0 | new file mode 100644 | ||
| @@ -0,0 +1,27 @@ | ||
| 1 | +{ | |
| 2 | + "time": "2026-10-25T19:01:15.585303+01:00", | |
| 3 | + "decider": "spell.yaml", | |
| 4 | + "prompt": "hello", | |
| 5 | + "response": { | |
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | |
| 7 | + "answers": { | |
| 8 | + "spell": { | |
| 9 | + "type": "choice", | |
| 10 | + "choice": "sleep", | |
| 11 | + "probabilities": { | |
| 12 | + "fireball": 0.1096667211238828, | |
| 13 | + "arcane_bolt": 0.2628631167747479, | |
| 14 | + "shield": 0.15284316935906098, | |
| 15 | + "misty_step": 0.16086838121035513, | |
| 16 | + "sleep": 0.3137586115319532 | |
| 17 | + }, | |
| 18 | + "confidence": 0.14219826441494152 | |
| 19 | + } | |
| 20 | + }, | |
| 21 | + "usage": { | |
| 22 | + "input_tokens": 98, | |
| 23 | + "output_tokens": 0 | |
| 24 | + } | |
| 25 | + }, | |
| 26 | + "context": "spell: sleep (confidence 0.14)" | |
| 27 | +} | |
| new file mode 100644 | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | +{ | ||
| 2 | + "time": "2026-10-25T19:01:15.585303+01:00", | ||
| 3 | + "decider": "spell.yaml", | ||
| 4 | + "prompt": "hello", | ||
| 5 | + "response": { | ||
| 6 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | ||
| 7 | + "answers": { | ||
| 8 | + "spell": { | ||
| 9 | + "type": "choice", | ||
| 10 | + "choice": "sleep", | ||
| 11 | + "probabilities": { | ||
| 12 | + "fireball": 0.1096667211238828, | ||
| 13 | + "arcane_bolt": 0.2628631167747479, | ||
| 14 | + "shield": 0.15284316935906098, | ||
| 15 | + "misty_step": 0.16086838121035513, | ||
| 16 | + "sleep": 0.3137586115319532 | ||
| 17 | + }, | ||
| 18 | + "confidence": 0.14219826441494152 | ||
| 19 | + } | ||
| 20 | + }, | ||
| 21 | + "usage": { | ||
| 22 | + "input_tokens": 98, | ||
| 23 | + "output_tokens": 0 | ||
| 24 | + } | ||
| 25 | + }, | ||
| 26 | + "context": "spell: sleep (confidence 0.14)" | ||
| 27 | +} | ||
added
03-decision-models/.mm/decider/20261025-190209.703-spell.json +28 -0 | new file mode 100644 | ||
| @@ -0,0 +1,28 @@ | ||
| 1 | +{ | |
| 2 | + "time": "2026-10-25T19:02:09.703072+01:00", | |
| 3 | + "decider": "spell.yaml", | |
| 4 | + "prompt": "Two wolves have grabbed me and the rest of the party is far away.", | |
| 5 | + "response": { | |
| 6 | + "display": true, | |
| 7 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | |
| 8 | + "answers": { | |
| 9 | + "spell": { | |
| 10 | + "type": "choice", | |
| 11 | + "choice": "misty_step", | |
| 12 | + "probabilities": { | |
| 13 | + "fireball": 0.18549138627023762, | |
| 14 | + "arcane_bolt": 0.10610184523928502, | |
| 15 | + "shield": 0.07297497689065748, | |
| 16 | + "misty_step": 0.5778020206231758, | |
| 17 | + "sleep": 0.05762977097664409 | |
| 18 | + }, | |
| 19 | + "confidence": 0.47225252577896965 | |
| 20 | + } | |
| 21 | + }, | |
| 22 | + "usage": { | |
| 23 | + "input_tokens": 111, | |
| 24 | + "output_tokens": 0 | |
| 25 | + } | |
| 26 | + }, | |
| 27 | + "context": "spell: misty_step (confidence 0.47)" | |
| 28 | +} | |
| new file mode 100644 | |||
| @@ -0,0 +1,28 @@ | |||
| 1 | +{ | ||
| 2 | + "time": "2026-10-25T19:02:09.703072+01:00", | ||
| 3 | + "decider": "spell.yaml", | ||
| 4 | + "prompt": "Two wolves have grabbed me and the rest of the party is far away.", | ||
| 5 | + "response": { | ||
| 6 | + "display": true, | ||
| 7 | + "model": "hf.co/LiquidAI/d1-3B-GGUF:Q4_K_M", | ||
| 8 | + "answers": { | ||
| 9 | + "spell": { | ||
| 10 | + "type": "choice", | ||
| 11 | + "choice": "misty_step", | ||
| 12 | + "probabilities": { | ||
| 13 | + "fireball": 0.18549138627023762, | ||
| 14 | + "arcane_bolt": 0.10610184523928502, | ||
| 15 | + "shield": 0.07297497689065748, | ||
| 16 | + "misty_step": 0.5778020206231758, | ||
| 17 | + "sleep": 0.05762977097664409 | ||
| 18 | + }, | ||
| 19 | + "confidence": 0.47225252577896965 | ||
| 20 | + } | ||
| 21 | + }, | ||
| 22 | + "usage": { | ||
| 23 | + "input_tokens": 111, | ||
| 24 | + "output_tokens": 0 | ||
| 25 | + } | ||
| 26 | + }, | ||
| 27 | + "context": "spell: misty_step (confidence 0.47)" | ||
| 28 | +} | ||
modified
03-decision-models/spell.yaml +3 -10 | @@ -5,6 +5,7 @@ baseUrl: http://127.0.0.1:17434/v1 | ||
| 5 | 5 | fallback: http://host.docker.internal:17434/v1 |
| 6 | 6 | |
| 7 | 7 | decision: |
| 8 | + display: true | |
| 8 | 9 | questions: |
| 9 | 10 | spell: |
| 10 | 11 | type: choice |
| @@ -18,14 +19,6 @@ decision: | ||
| 18 | 19 | |
| 19 | 20 | acp: |
| 20 | 21 | name: sidekick |
| 21 | - title: "sidekick" | |
| 22 | + title: "🐱 sidekick" | |
| 23 | + | |
| 22 | 24 | |
| 23 | -# A decider declares no tool: its model never calls one. | |
| 24 | -bashTool: false | |
| 25 | -editTools: false | |
| 26 | -planTool: false | |
| 27 | -fetchContentTool: false | |
| 28 | -askUserTool: false | |
| 29 | -skillsDir: no-skills | |
| 30 | -agentsMd: | |
| 31 | - enabled: false | |
| @@ -5,6 +5,7 @@ baseUrl: http://127.0.0.1:17434/v1 | |||
| 5 | fallback: http://host.docker.internal:17434/v1 | 5 | fallback: http://host.docker.internal:17434/v1 |
| 6 | 6 | ||
| 7 | decision: | 7 | decision: |
| 8 | + display: true | ||
| 8 | questions: | 9 | questions: |
| 9 | spell: | 10 | spell: |
| 10 | type: choice | 11 | type: choice |
| @@ -18,14 +19,6 @@ decision: | |||
| 18 | 19 | ||
| 19 | acp: | 20 | acp: |
| 20 | name: sidekick | 21 | name: sidekick |
| 21 | - title: "sidekick" | 22 | + title: "🐱 sidekick" |
| 23 | + | ||
| 22 | 24 | ||
| 23 | -# A decider declares no tool: its model never calls one. | ||
| 24 | -bashTool: false | ||
| 25 | -editTools: false | ||
| 26 | -planTool: false | ||
| 27 | -fetchContentTool: false | ||
| 28 | -askUserTool: false | ||
| 29 | -skillsDir: no-skills | ||
| 30 | -agentsMd: | ||
| 31 | - enabled: false | ||
added
09-unload-models/README.md +54 -0 | new file mode 100644 | ||
| @@ -0,0 +1,54 @@ | ||
| 1 | +# Coding helpers, with the `unloadModels` option | |
| 2 | + | |
| 3 | + | |
| 4 | +The team: a coordinator that hands Go and Rust questions to a specialist, with one difference: the two models are never in the server's memory together, and no hook is needed for it. Each `mmConfigs` entry sets `unloadModels: true`. | |
| 5 | + | |
| 6 | +| Agent | File | Model | Role | | |
| 7 | +|---|---|---|---| | |
| 8 | +| 🧭 coordinator | `agent.yaml` | MiniCPM5 2B (`hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M`, 1.6 GB) | picks `go` or `rust`, sends the question with the conversation | | |
| 9 | +| 🐹 go | `agent.go.yaml` | Mellum2 12B A2.5B thinking (`huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M`, 8.1 GB) | documents Go | | |
| 10 | +| 🦀 rust | `agent.rust.yaml` | the same Mellum2 model | documents Rust | | |
| 11 | + | |
| 12 | +## Run | |
| 13 | + | |
| 14 | +```bash | |
| 15 | +llmman pull hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | |
| 16 | +llmman pull huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | |
| 17 | + | |
| 18 | +cd 09-unload-models | |
| 19 | +mm tui # reads ./agent.yaml | |
| 20 | +``` | |
| 21 | + | |
| 22 | +## The option | |
| 23 | + | |
| 24 | +```yaml | |
| 25 | +mmConfigs: | |
| 26 | + go: | |
| 27 | + path: agent.go.yaml | |
| 28 | + description: >- | |
| 29 | + Go specialist. … | |
| 30 | + yolo: true | |
| 31 | + unloadModels: true | |
| 32 | + rust: | |
| 33 | + path: agent.rust.yaml | |
| 34 | + description: >- | |
| 35 | + Rust specialist. … | |
| 36 | + yolo: true | |
| 37 | + unloadModels: true | |
| 38 | +``` | |
| 39 | + | |
| 40 | +On every hand-off to `go` or `rust`, the coordinator's `ask_agent`, your `/ask-go` or `/ask-rust`: | |
| 41 | + | |
| 42 | +1. `mm` unloads the coordinator's model (MiniCPM5) right before the specialist starts; | |
| 43 | +2. the specialist loads Mellum2 and answers; | |
| 44 | +3. `mm` unloads Mellum2 once the answer is in, before the coordinator is reloaded to read it. | |
| 45 | + | |
| 46 | +Each unload is one line: | |
| 47 | + | |
| 48 | +```text | |
| 49 | +🗣 ask_agent: rust (llmman/huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M) — … | |
| 50 | +🧹 unloaded hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | |
| 51 | +…the specialist's answer… | |
| 52 | +🧹 unloaded huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | |
| 53 | +``` | |
| 54 | + | |
| new file mode 100644 | |||
| @@ -0,0 +1,54 @@ | |||
| 1 | +# Coding helpers, with the `unloadModels` option | ||
| 2 | + | ||
| 3 | + | ||
| 4 | +The team: a coordinator that hands Go and Rust questions to a specialist, with one difference: the two models are never in the server's memory together, and no hook is needed for it. Each `mmConfigs` entry sets `unloadModels: true`. | ||
| 5 | + | ||
| 6 | +| Agent | File | Model | Role | | ||
| 7 | +|---|---|---|---| | ||
| 8 | +| 🧭 coordinator | `agent.yaml` | MiniCPM5 2B (`hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M`, 1.6 GB) | picks `go` or `rust`, sends the question with the conversation | | ||
| 9 | +| 🐹 go | `agent.go.yaml` | Mellum2 12B A2.5B thinking (`huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M`, 8.1 GB) | documents Go | | ||
| 10 | +| 🦀 rust | `agent.rust.yaml` | the same Mellum2 model | documents Rust | | ||
| 11 | + | ||
| 12 | +## Run | ||
| 13 | + | ||
| 14 | +```bash | ||
| 15 | +llmman pull hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | ||
| 16 | +llmman pull huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | ||
| 17 | + | ||
| 18 | +cd 09-unload-models | ||
| 19 | +mm tui # reads ./agent.yaml | ||
| 20 | +``` | ||
| 21 | + | ||
| 22 | +## The option | ||
| 23 | + | ||
| 24 | +```yaml | ||
| 25 | +mmConfigs: | ||
| 26 | + go: | ||
| 27 | + path: agent.go.yaml | ||
| 28 | + description: >- | ||
| 29 | + Go specialist. … | ||
| 30 | + yolo: true | ||
| 31 | + unloadModels: true | ||
| 32 | + rust: | ||
| 33 | + path: agent.rust.yaml | ||
| 34 | + description: >- | ||
| 35 | + Rust specialist. … | ||
| 36 | + yolo: true | ||
| 37 | + unloadModels: true | ||
| 38 | +``` | ||
| 39 | + | ||
| 40 | +On every hand-off to `go` or `rust`, the coordinator's `ask_agent`, your `/ask-go` or `/ask-rust`: | ||
| 41 | + | ||
| 42 | +1. `mm` unloads the coordinator's model (MiniCPM5) right before the specialist starts; | ||
| 43 | +2. the specialist loads Mellum2 and answers; | ||
| 44 | +3. `mm` unloads Mellum2 once the answer is in, before the coordinator is reloaded to read it. | ||
| 45 | + | ||
| 46 | +Each unload is one line: | ||
| 47 | + | ||
| 48 | +```text | ||
| 49 | +🗣 ask_agent: rust (llmman/huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M) — … | ||
| 50 | +🧹 unloaded hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | ||
| 51 | +…the specialist's answer… | ||
| 52 | +🧹 unloaded huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | ||
| 53 | +``` | ||
| 54 | + | ||
added
09-unload-models/agent.go.yaml +79 -0 | new file mode 100644 | ||
| @@ -0,0 +1,79 @@ | ||
| 1 | +# Go specialist — asked by the coordinator (agent.yaml) through `ask_agent`, | |
| 2 | +# or by you directly: `mm agent.go.yaml`. Interactive documentation: it | |
| 3 | +# explains a Go concept with short examples in its answer. No tools — it | |
| 4 | +# builds nothing, writes no file, and only writes a whole program when asked | |
| 5 | +# to. | |
| 6 | +# | |
| 7 | +# Mellum2 12B A2.5B thinking (JetBrains, a mixture of experts: 12B weights, | |
| 8 | +# 2.5B active per token): a code model that reasons before answering. | |
| 9 | +# | |
| 10 | +# A copy of demos/coding-helpers/agent.go.yaml: the specialists are unchanged. | |
| 11 | + | |
| 12 | +provider: llmman | |
| 13 | +model: huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | |
| 14 | +baseUrl: http://127.0.0.1:17434/v1 | |
| 15 | +fallback: http://host.docker.internal:17434/v1 | |
| 16 | +contextWindow: 32768 | |
| 17 | + | |
| 18 | +sampling: | |
| 19 | + # No sampling in the GGUF; values usual for a thinking model (never 0.0: | |
| 20 | + # thinking models loop). | |
| 21 | + temperature: 0.6 | |
| 22 | + top_p: 0.95 | |
| 23 | + # The reasoning plus an explanation with examples. | |
| 24 | + max_tokens: 8192 | |
| 25 | + # On by default in the template; written so the choice is visible. | |
| 26 | + chat_template_kwargs: | |
| 27 | + enable_thinking: true | |
| 28 | + | |
| 29 | +showThinking: false | |
| 30 | +watchdogTimeout: 3m | |
| 31 | +firstTokenTimeout: 3m | |
| 32 | + | |
| 33 | +# No tools: one answer. | |
| 34 | +maxTurns: 2 | |
| 35 | +maxOutput: 20000 | |
| 36 | + | |
| 37 | +yolo: false | |
| 38 | +bashTool: false | |
| 39 | +editTools: false | |
| 40 | +planTool: false | |
| 41 | +fetchContentTool: false | |
| 42 | +askUserTool: false | |
| 43 | +skillsDir: no-skills | |
| 44 | + | |
| 45 | +agentsMd: | |
| 46 | + enabled: false | |
| 47 | + | |
| 48 | +sessions: | |
| 49 | + enabled: false | |
| 50 | + | |
| 51 | +acp: | |
| 52 | + name: go | |
| 53 | + title: 🐹 Go specialist | |
| 54 | + | |
| 55 | +system: | | |
| 56 | + You are Go documentation that answers questions. People ask what a Go | |
| 57 | + concept is or how something is done in Go; you explain it and show | |
| 58 | + examples, like a good reference page would. | |
| 59 | + | |
| 60 | + If the conversation so far is included, read it: "the same thing" means | |
| 61 | + what was asked or shown before — explain it for Go. | |
| 62 | + | |
| 63 | + Your answer: | |
| 64 | + 1. What it is and when to use it, in a few sentences. | |
| 65 | + 2. Short examples in ```go code blocks — a snippet per point, only | |
| 66 | + the lines that show the idea (no main function, no imports unless they | |
| 67 | + matter to the point). | |
| 68 | + 3. The pitfalls or the idiomatic way, in a short list, when there are | |
| 69 | + any. | |
| 70 | + | |
| 71 | + RULES | |
| 72 | + - Only Go. A question about another language (Python, Java…): answer in | |
| 73 | + one sentence that you document Go only — never answer it with Go. | |
| 74 | + - You document; you do not build. Write a complete, runnable program only | |
| 75 | + when the user explicitly asks for one ("write me a program", "a full | |
| 76 | + example I can run"). | |
| 77 | + - Standard library unless the question names a package. | |
| 78 | + - Keep it short and correct: an example that does not compile is worse | |
| 79 | + than no example. | |
| new file mode 100644 | |||
| @@ -0,0 +1,79 @@ | |||
| 1 | +# Go specialist — asked by the coordinator (agent.yaml) through `ask_agent`, | ||
| 2 | +# or by you directly: `mm agent.go.yaml`. Interactive documentation: it | ||
| 3 | +# explains a Go concept with short examples in its answer. No tools — it | ||
| 4 | +# builds nothing, writes no file, and only writes a whole program when asked | ||
| 5 | +# to. | ||
| 6 | +# | ||
| 7 | +# Mellum2 12B A2.5B thinking (JetBrains, a mixture of experts: 12B weights, | ||
| 8 | +# 2.5B active per token): a code model that reasons before answering. | ||
| 9 | +# | ||
| 10 | +# A copy of demos/coding-helpers/agent.go.yaml: the specialists are unchanged. | ||
| 11 | + | ||
| 12 | +provider: llmman | ||
| 13 | +model: huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | ||
| 14 | +baseUrl: http://127.0.0.1:17434/v1 | ||
| 15 | +fallback: http://host.docker.internal:17434/v1 | ||
| 16 | +contextWindow: 32768 | ||
| 17 | + | ||
| 18 | +sampling: | ||
| 19 | + # No sampling in the GGUF; values usual for a thinking model (never 0.0: | ||
| 20 | + # thinking models loop). | ||
| 21 | + temperature: 0.6 | ||
| 22 | + top_p: 0.95 | ||
| 23 | + # The reasoning plus an explanation with examples. | ||
| 24 | + max_tokens: 8192 | ||
| 25 | + # On by default in the template; written so the choice is visible. | ||
| 26 | + chat_template_kwargs: | ||
| 27 | + enable_thinking: true | ||
| 28 | + | ||
| 29 | +showThinking: false | ||
| 30 | +watchdogTimeout: 3m | ||
| 31 | +firstTokenTimeout: 3m | ||
| 32 | + | ||
| 33 | +# No tools: one answer. | ||
| 34 | +maxTurns: 2 | ||
| 35 | +maxOutput: 20000 | ||
| 36 | + | ||
| 37 | +yolo: false | ||
| 38 | +bashTool: false | ||
| 39 | +editTools: false | ||
| 40 | +planTool: false | ||
| 41 | +fetchContentTool: false | ||
| 42 | +askUserTool: false | ||
| 43 | +skillsDir: no-skills | ||
| 44 | + | ||
| 45 | +agentsMd: | ||
| 46 | + enabled: false | ||
| 47 | + | ||
| 48 | +sessions: | ||
| 49 | + enabled: false | ||
| 50 | + | ||
| 51 | +acp: | ||
| 52 | + name: go | ||
| 53 | + title: 🐹 Go specialist | ||
| 54 | + | ||
| 55 | +system: | | ||
| 56 | + You are Go documentation that answers questions. People ask what a Go | ||
| 57 | + concept is or how something is done in Go; you explain it and show | ||
| 58 | + examples, like a good reference page would. | ||
| 59 | + | ||
| 60 | + If the conversation so far is included, read it: "the same thing" means | ||
| 61 | + what was asked or shown before — explain it for Go. | ||
| 62 | + | ||
| 63 | + Your answer: | ||
| 64 | + 1. What it is and when to use it, in a few sentences. | ||
| 65 | + 2. Short examples in ```go code blocks — a snippet per point, only | ||
| 66 | + the lines that show the idea (no main function, no imports unless they | ||
| 67 | + matter to the point). | ||
| 68 | + 3. The pitfalls or the idiomatic way, in a short list, when there are | ||
| 69 | + any. | ||
| 70 | + | ||
| 71 | + RULES | ||
| 72 | + - Only Go. A question about another language (Python, Java…): answer in | ||
| 73 | + one sentence that you document Go only — never answer it with Go. | ||
| 74 | + - You document; you do not build. Write a complete, runnable program only | ||
| 75 | + when the user explicitly asks for one ("write me a program", "a full | ||
| 76 | + example I can run"). | ||
| 77 | + - Standard library unless the question names a package. | ||
| 78 | + - Keep it short and correct: an example that does not compile is worse | ||
| 79 | + than no example. | ||
added
09-unload-models/agent.rust.yaml +79 -0 | new file mode 100644 | ||
| @@ -0,0 +1,79 @@ | ||
| 1 | +# Rust specialist — asked by the coordinator (agent.yaml) through `ask_agent`, | |
| 2 | +# or by you directly: `mm agent.rust.yaml`. Interactive documentation: it | |
| 3 | +# explains a Rust concept with short examples in its answer. No tools — it | |
| 4 | +# builds nothing, writes no file, and only writes a whole program when asked | |
| 5 | +# to. | |
| 6 | +# | |
| 7 | +# Mellum2 12B A2.5B thinking (JetBrains, a mixture of experts: 12B weights, | |
| 8 | +# 2.5B active per token): a code model that reasons before answering. | |
| 9 | +# | |
| 10 | +# A copy of demos/coding-helpers/agent.rust.yaml: the specialists are unchanged. | |
| 11 | + | |
| 12 | +provider: llmman | |
| 13 | +model: huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | |
| 14 | +baseUrl: http://127.0.0.1:17434/v1 | |
| 15 | +fallback: http://host.docker.internal:17434/v1 | |
| 16 | +contextWindow: 32768 | |
| 17 | + | |
| 18 | +sampling: | |
| 19 | + # No sampling in the GGUF; values usual for a thinking model (never 0.0: | |
| 20 | + # thinking models loop). | |
| 21 | + temperature: 0.6 | |
| 22 | + top_p: 0.95 | |
| 23 | + # The reasoning plus an explanation with examples. | |
| 24 | + max_tokens: 8192 | |
| 25 | + # On by default in the template; written so the choice is visible. | |
| 26 | + chat_template_kwargs: | |
| 27 | + enable_thinking: true | |
| 28 | + | |
| 29 | +showThinking: false | |
| 30 | +watchdogTimeout: 3m | |
| 31 | +firstTokenTimeout: 3m | |
| 32 | + | |
| 33 | +# No tools: one answer. | |
| 34 | +maxTurns: 2 | |
| 35 | +maxOutput: 20000 | |
| 36 | + | |
| 37 | +yolo: false | |
| 38 | +bashTool: false | |
| 39 | +editTools: false | |
| 40 | +planTool: false | |
| 41 | +fetchContentTool: false | |
| 42 | +askUserTool: false | |
| 43 | +skillsDir: no-skills | |
| 44 | + | |
| 45 | +agentsMd: | |
| 46 | + enabled: false | |
| 47 | + | |
| 48 | +sessions: | |
| 49 | + enabled: false | |
| 50 | + | |
| 51 | +acp: | |
| 52 | + name: rust | |
| 53 | + title: 🦀 Rust specialist | |
| 54 | + | |
| 55 | +system: | | |
| 56 | + You are Rust documentation that answers questions. People ask what a Rust | |
| 57 | + concept is or how something is done in Rust; you explain it and show | |
| 58 | + examples, like a good reference page would. | |
| 59 | + | |
| 60 | + If the conversation so far is included, read it: "the same thing" means | |
| 61 | + what was asked or shown before — explain it for Rust. | |
| 62 | + | |
| 63 | + Your answer: | |
| 64 | + 1. What it is and when to use it, in a few sentences. | |
| 65 | + 2. Short examples in ```rust code blocks — a snippet per point, only | |
| 66 | + the lines that show the idea (no main function, no imports unless they | |
| 67 | + matter to the point). | |
| 68 | + 3. The pitfalls or the idiomatic way, in a short list, when there are | |
| 69 | + any. | |
| 70 | + | |
| 71 | + RULES | |
| 72 | + - Only Rust. A question about another language (Python, Java…): answer in | |
| 73 | + one sentence that you document Rust only — never answer it with Rust. | |
| 74 | + - You document; you do not build. Write a complete, runnable program only | |
| 75 | + when the user explicitly asks for one ("write me a program", "a full | |
| 76 | + example I can run"). | |
| 77 | + - When an example needs a crate (serde…), name it and give its Cargo.toml line. | |
| 78 | + - Keep it short and correct: an example that does not compile is worse | |
| 79 | + than no example. | |
| new file mode 100644 | |||
| @@ -0,0 +1,79 @@ | |||
| 1 | +# Rust specialist — asked by the coordinator (agent.yaml) through `ask_agent`, | ||
| 2 | +# or by you directly: `mm agent.rust.yaml`. Interactive documentation: it | ||
| 3 | +# explains a Rust concept with short examples in its answer. No tools — it | ||
| 4 | +# builds nothing, writes no file, and only writes a whole program when asked | ||
| 5 | +# to. | ||
| 6 | +# | ||
| 7 | +# Mellum2 12B A2.5B thinking (JetBrains, a mixture of experts: 12B weights, | ||
| 8 | +# 2.5B active per token): a code model that reasons before answering. | ||
| 9 | +# | ||
| 10 | +# A copy of demos/coding-helpers/agent.rust.yaml: the specialists are unchanged. | ||
| 11 | + | ||
| 12 | +provider: llmman | ||
| 13 | +model: huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | ||
| 14 | +baseUrl: http://127.0.0.1:17434/v1 | ||
| 15 | +fallback: http://host.docker.internal:17434/v1 | ||
| 16 | +contextWindow: 32768 | ||
| 17 | + | ||
| 18 | +sampling: | ||
| 19 | + # No sampling in the GGUF; values usual for a thinking model (never 0.0: | ||
| 20 | + # thinking models loop). | ||
| 21 | + temperature: 0.6 | ||
| 22 | + top_p: 0.95 | ||
| 23 | + # The reasoning plus an explanation with examples. | ||
| 24 | + max_tokens: 8192 | ||
| 25 | + # On by default in the template; written so the choice is visible. | ||
| 26 | + chat_template_kwargs: | ||
| 27 | + enable_thinking: true | ||
| 28 | + | ||
| 29 | +showThinking: false | ||
| 30 | +watchdogTimeout: 3m | ||
| 31 | +firstTokenTimeout: 3m | ||
| 32 | + | ||
| 33 | +# No tools: one answer. | ||
| 34 | +maxTurns: 2 | ||
| 35 | +maxOutput: 20000 | ||
| 36 | + | ||
| 37 | +yolo: false | ||
| 38 | +bashTool: false | ||
| 39 | +editTools: false | ||
| 40 | +planTool: false | ||
| 41 | +fetchContentTool: false | ||
| 42 | +askUserTool: false | ||
| 43 | +skillsDir: no-skills | ||
| 44 | + | ||
| 45 | +agentsMd: | ||
| 46 | + enabled: false | ||
| 47 | + | ||
| 48 | +sessions: | ||
| 49 | + enabled: false | ||
| 50 | + | ||
| 51 | +acp: | ||
| 52 | + name: rust | ||
| 53 | + title: 🦀 Rust specialist | ||
| 54 | + | ||
| 55 | +system: | | ||
| 56 | + You are Rust documentation that answers questions. People ask what a Rust | ||
| 57 | + concept is or how something is done in Rust; you explain it and show | ||
| 58 | + examples, like a good reference page would. | ||
| 59 | + | ||
| 60 | + If the conversation so far is included, read it: "the same thing" means | ||
| 61 | + what was asked or shown before — explain it for Rust. | ||
| 62 | + | ||
| 63 | + Your answer: | ||
| 64 | + 1. What it is and when to use it, in a few sentences. | ||
| 65 | + 2. Short examples in ```rust code blocks — a snippet per point, only | ||
| 66 | + the lines that show the idea (no main function, no imports unless they | ||
| 67 | + matter to the point). | ||
| 68 | + 3. The pitfalls or the idiomatic way, in a short list, when there are | ||
| 69 | + any. | ||
| 70 | + | ||
| 71 | + RULES | ||
| 72 | + - Only Rust. A question about another language (Python, Java…): answer in | ||
| 73 | + one sentence that you document Rust only — never answer it with Rust. | ||
| 74 | + - You document; you do not build. Write a complete, runnable program only | ||
| 75 | + when the user explicitly asks for one ("write me a program", "a full | ||
| 76 | + example I can run"). | ||
| 77 | + - When an example needs a crate (serde…), name it and give its Cargo.toml line. | ||
| 78 | + - Keep it short and correct: an example that does not compile is worse | ||
| 79 | + than no example. | ||
added
09-unload-models/agent.yaml +117 -0 | new file mode 100644 | ||
| @@ -0,0 +1,117 @@ | ||
| 1 | +# Coding helpers — interactive documentation for Go and Rust: ask what a | |
| 2 | +# concept is or how something is done, get an explanation with short | |
| 3 | +# examples. You talk with this coordinator; it picks the specialist with | |
| 4 | +# the built-in `ask_agent` tool: | |
| 5 | +# | |
| 6 | +# go — agent.go.yaml, a Go specialist | |
| 7 | +# rust — agent.rust.yaml, a Rust specialist | |
| 8 | +# | |
| 9 | +# "hey, explique-moi comment utiliser une struct Go et la sérialiser en JSON" | |
| 10 | +# "comment je fais la même chose en Rust ?" | |
| 11 | +# "explique-moi ce qu'est le pattern matching en Rust, avec un exemple" | |
| 12 | +# | |
| 13 | +# The second question only makes sense after the first: the coordinator | |
| 14 | +# sends the conversation along (`with_context`), so the Rust specialist | |
| 15 | +# knows what "the same thing" is. | |
| 16 | +# | |
| 17 | +# Models — never in memory together, so at most 8.1 GB at a time: | |
| 18 | +# | |
| 19 | +# coordinator MiniCPM5 2B hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M 1.6 GB | |
| 20 | +# go, rust Mellum2 12B thinking huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M 8.1 GB (one model for both) | |
| 21 | +# | |
| 22 | +# unloadModels: true on both mmConfigs entries (ticket 161): mm unloads | |
| 23 | +# the COORDINATOR's model right before a specialist starts, and the | |
| 24 | +# SPECIALIST's model once it has answered, before the coordinator is | |
| 25 | +# reloaded to read the answer. No hook: demos/coding-helpers does the | |
| 26 | +# same with hooks/unload.js. | |
| 27 | +# | |
| 28 | +# llmman pull hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | |
| 29 | +# llmman pull huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | |
| 30 | +# LLMMAN_CONTEXT_LENGTH=32768 llmman serve | |
| 31 | +# | |
| 32 | +# cd demos/coding-helpers-unload-option | |
| 33 | +# mm (reads ./agent.yaml) | |
| 34 | + | |
| 35 | +provider: llmman | |
| 36 | +model: hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | |
| 37 | +baseUrl: http://127.0.0.1:17434/v1 | |
| 38 | +fallback: http://host.docker.internal:17434/v1 | |
| 39 | +contextWindow: 32768 | |
| 40 | + | |
| 41 | +# The team. The description is what the coordinator reads to choose; | |
| 42 | +# unloadModels: true makes the two models take turns in memory (the price: | |
| 43 | +# Mellum2 is reloaded on every question). | |
| 44 | +mmConfigs: | |
| 45 | + go: | |
| 46 | + path: agent.go.yaml | |
| 47 | + description: >- | |
| 48 | + Go specialist. Explains Go concepts and how to do something in Go, | |
| 49 | + with short examples, like documentation. For any question about Go. | |
| 50 | + yolo: true | |
| 51 | + unloadModels: true | |
| 52 | + rust: | |
| 53 | + path: agent.rust.yaml | |
| 54 | + description: >- | |
| 55 | + Rust specialist. Explains Rust concepts and how to do something in | |
| 56 | + Rust, with short examples, like documentation. For any question about | |
| 57 | + Rust. | |
| 58 | + yolo: true | |
| 59 | + unloadModels: true | |
| 60 | + | |
| 61 | +sampling: | |
| 62 | + # The GGUF says 1.0 / 0.95; routing wants a steady hand. | |
| 63 | + temperature: 0.3 | |
| 64 | + top_p: 0.95 | |
| 65 | + max_tokens: 2048 | |
| 66 | + parallel_tool_calls: false | |
| 67 | + # MiniCPM5's template reads enable_thinking and has no default: set it. | |
| 68 | + chat_template_kwargs: | |
| 69 | + enable_thinking: false | |
| 70 | + | |
| 71 | +# During ask_agent every event of the specialist counts as a sign of life; | |
| 72 | +# a 12B thinking model may reason a while before its first word. | |
| 73 | +watchdogTimeout: 5m | |
| 74 | +firstTokenTimeout: 3m | |
| 75 | + | |
| 76 | +# one call, one sentence. | |
| 77 | +maxTurns: 3 | |
| 78 | +maxOutput: 20000 | |
| 79 | +displayCommands: true | |
| 80 | + | |
| 81 | +yolo: true | |
| 82 | +bashTool: false | |
| 83 | +editTools: false | |
| 84 | +planTool: false | |
| 85 | +fetchContentTool: false | |
| 86 | +askUserTool: false | |
| 87 | +skillsDir: no-skills | |
| 88 | + | |
| 89 | +agentsMd: | |
| 90 | + enabled: false | |
| 91 | + | |
| 92 | +sessions: | |
| 93 | + enabled: false | |
| 94 | + | |
| 95 | +acp: | |
| 96 | + name: coding-helpers-unload-option | |
| 97 | + title: 🧭 Coding helpers (Go, Rust) | |
| 98 | + | |
| 99 | +# Written for a 2B model: short, no fake call written out in the text — | |
| 100 | +# measured, MiniCPM5 copies such patterns into its answer instead of calling | |
| 101 | +# the tool. | |
| 102 | +system: | | |
| 103 | + You are the front desk of two programming specialists: go and rust. | |
| 104 | + | |
| 105 | + When the user asks something about programming, call the ask_agent tool | |
| 106 | + once: | |
| 107 | + - agent: go if the question is about Go, rust if it is about Rust. When | |
| 108 | + the user says "the same thing", "la même chose", "now in …", pick the | |
| 109 | + language they name now. | |
| 110 | + - prompt: the user's message, copied exactly. | |
| 111 | + - with_context: true, so the specialist sees the conversation so far. | |
| 112 | + | |
| 113 | + When the tool has answered, write one short sentence in the user's | |
| 114 | + language saying the explanation is above. | |
| 115 | + | |
| 116 | + If the language is neither Go nor Rust, say in one sentence that you | |
| 117 | + only know Go and Rust. When the user only greets you, greet back. | |
| new file mode 100644 | |||
| @@ -0,0 +1,117 @@ | |||
| 1 | +# Coding helpers — interactive documentation for Go and Rust: ask what a | ||
| 2 | +# concept is or how something is done, get an explanation with short | ||
| 3 | +# examples. You talk with this coordinator; it picks the specialist with | ||
| 4 | +# the built-in `ask_agent` tool: | ||
| 5 | +# | ||
| 6 | +# go — agent.go.yaml, a Go specialist | ||
| 7 | +# rust — agent.rust.yaml, a Rust specialist | ||
| 8 | +# | ||
| 9 | +# "hey, explique-moi comment utiliser une struct Go et la sérialiser en JSON" | ||
| 10 | +# "comment je fais la même chose en Rust ?" | ||
| 11 | +# "explique-moi ce qu'est le pattern matching en Rust, avec un exemple" | ||
| 12 | +# | ||
| 13 | +# The second question only makes sense after the first: the coordinator | ||
| 14 | +# sends the conversation along (`with_context`), so the Rust specialist | ||
| 15 | +# knows what "the same thing" is. | ||
| 16 | +# | ||
| 17 | +# Models — never in memory together, so at most 8.1 GB at a time: | ||
| 18 | +# | ||
| 19 | +# coordinator MiniCPM5 2B hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M 1.6 GB | ||
| 20 | +# go, rust Mellum2 12B thinking huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M 8.1 GB (one model for both) | ||
| 21 | +# | ||
| 22 | +# unloadModels: true on both mmConfigs entries (ticket 161): mm unloads | ||
| 23 | +# the COORDINATOR's model right before a specialist starts, and the | ||
| 24 | +# SPECIALIST's model once it has answered, before the coordinator is | ||
| 25 | +# reloaded to read the answer. No hook: demos/coding-helpers does the | ||
| 26 | +# same with hooks/unload.js. | ||
| 27 | +# | ||
| 28 | +# llmman pull hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | ||
| 29 | +# llmman pull huggingface.co/jetbrains/mellum2-12b-a2.5b-thinking-gguf-q4_k_m:Q4_K_M | ||
| 30 | +# LLMMAN_CONTEXT_LENGTH=32768 llmman serve | ||
| 31 | +# | ||
| 32 | +# cd demos/coding-helpers-unload-option | ||
| 33 | +# mm (reads ./agent.yaml) | ||
| 34 | + | ||
| 35 | +provider: llmman | ||
| 36 | +model: hf.co/openbmb/MiniCPM5-2B-GGUF:Q4_K_M | ||
| 37 | +baseUrl: http://127.0.0.1:17434/v1 | ||
| 38 | +fallback: http://host.docker.internal:17434/v1 | ||
| 39 | +contextWindow: 32768 | ||
| 40 | + | ||
| 41 | +# The team. The description is what the coordinator reads to choose; | ||
| 42 | +# unloadModels: true makes the two models take turns in memory (the price: | ||
| 43 | +# Mellum2 is reloaded on every question). | ||
| 44 | +mmConfigs: | ||
| 45 | + go: | ||
| 46 | + path: agent.go.yaml | ||
| 47 | + description: >- | ||
| 48 | + Go specialist. Explains Go concepts and how to do something in Go, | ||
| 49 | + with short examples, like documentation. For any question about Go. | ||
| 50 | + yolo: true | ||
| 51 | + unloadModels: true | ||
| 52 | + rust: | ||
| 53 | + path: agent.rust.yaml | ||
| 54 | + description: >- | ||
| 55 | + Rust specialist. Explains Rust concepts and how to do something in | ||
| 56 | + Rust, with short examples, like documentation. For any question about | ||
| 57 | + Rust. | ||
| 58 | + yolo: true | ||
| 59 | + unloadModels: true | ||
| 60 | + | ||
| 61 | +sampling: | ||
| 62 | + # The GGUF says 1.0 / 0.95; routing wants a steady hand. | ||
| 63 | + temperature: 0.3 | ||
| 64 | + top_p: 0.95 | ||
| 65 | + max_tokens: 2048 | ||
| 66 | + parallel_tool_calls: false | ||
| 67 | + # MiniCPM5's template reads enable_thinking and has no default: set it. | ||
| 68 | + chat_template_kwargs: | ||
| 69 | + enable_thinking: false | ||
| 70 | + | ||
| 71 | +# During ask_agent every event of the specialist counts as a sign of life; | ||
| 72 | +# a 12B thinking model may reason a while before its first word. | ||
| 73 | +watchdogTimeout: 5m | ||
| 74 | +firstTokenTimeout: 3m | ||
| 75 | + | ||
| 76 | +# one call, one sentence. | ||
| 77 | +maxTurns: 3 | ||
| 78 | +maxOutput: 20000 | ||
| 79 | +displayCommands: true | ||
| 80 | + | ||
| 81 | +yolo: true | ||
| 82 | +bashTool: false | ||
| 83 | +editTools: false | ||
| 84 | +planTool: false | ||
| 85 | +fetchContentTool: false | ||
| 86 | +askUserTool: false | ||
| 87 | +skillsDir: no-skills | ||
| 88 | + | ||
| 89 | +agentsMd: | ||
| 90 | + enabled: false | ||
| 91 | + | ||
| 92 | +sessions: | ||
| 93 | + enabled: false | ||
| 94 | + | ||
| 95 | +acp: | ||
| 96 | + name: coding-helpers-unload-option | ||
| 97 | + title: 🧭 Coding helpers (Go, Rust) | ||
| 98 | + | ||
| 99 | +# Written for a 2B model: short, no fake call written out in the text — | ||
| 100 | +# measured, MiniCPM5 copies such patterns into its answer instead of calling | ||
| 101 | +# the tool. | ||
| 102 | +system: | | ||
| 103 | + You are the front desk of two programming specialists: go and rust. | ||
| 104 | + | ||
| 105 | + When the user asks something about programming, call the ask_agent tool | ||
| 106 | + once: | ||
| 107 | + - agent: go if the question is about Go, rust if it is about Rust. When | ||
| 108 | + the user says "the same thing", "la même chose", "now in …", pick the | ||
| 109 | + language they name now. | ||
| 110 | + - prompt: the user's message, copied exactly. | ||
| 111 | + - with_context: true, so the specialist sees the conversation so far. | ||
| 112 | + | ||
| 113 | + When the tool has answered, write one short sentence in the user's | ||
| 114 | + language saying the explanation is above. | ||
| 115 | + | ||
| 116 | + If the language is neither Go nor Rust, say in one sentence that you | ||
| 117 | + only know Go and Rust. When the user only greets you, greet back. | ||