Instructions to use dcostenco/prism-coder-1.7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use dcostenco/prism-coder-1.7b with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="dcostenco/prism-coder-1.7b", filename="prism-aac-1b7-q4km.gguf", )
llm.create_chat_completion( messages = "No input example has been defined for this model task." )
- Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use dcostenco/prism-coder-1.7b with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf dcostenco/prism-coder-1.7b:Q8_0 # Run inference directly in the terminal: llama-cli -hf dcostenco/prism-coder-1.7b:Q8_0
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf dcostenco/prism-coder-1.7b:Q8_0 # Run inference directly in the terminal: llama-cli -hf dcostenco/prism-coder-1.7b: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 dcostenco/prism-coder-1.7b:Q8_0 # Run inference directly in the terminal: ./llama-cli -hf dcostenco/prism-coder-1.7b: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 dcostenco/prism-coder-1.7b:Q8_0 # Run inference directly in the terminal: ./build/bin/llama-cli -hf dcostenco/prism-coder-1.7b:Q8_0
Use Docker
docker model run hf.co/dcostenco/prism-coder-1.7b:Q8_0
- LM Studio
- Jan
- Ollama
How to use dcostenco/prism-coder-1.7b with Ollama:
ollama run hf.co/dcostenco/prism-coder-1.7b:Q8_0
- Unsloth Studio new
How to use dcostenco/prism-coder-1.7b with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for dcostenco/prism-coder-1.7b to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for dcostenco/prism-coder-1.7b to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for dcostenco/prism-coder-1.7b to start chatting
- Pi new
How to use dcostenco/prism-coder-1.7b with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf dcostenco/prism-coder-1.7b:Q8_0
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "dcostenco/prism-coder-1.7b:Q8_0" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use dcostenco/prism-coder-1.7b with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf dcostenco/prism-coder-1.7b: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 dcostenco/prism-coder-1.7b:Q8_0
Run Hermes
hermes
- Docker Model Runner
How to use dcostenco/prism-coder-1.7b with Docker Model Runner:
docker model run hf.co/dcostenco/prism-coder-1.7b:Q8_0
- Lemonade
How to use dcostenco/prism-coder-1.7b with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull dcostenco/prism-coder-1.7b:Q8_0
Run and chat with the model
lemonade run user.prism-coder-1.7b-Q8_0
List all available models
lemonade list
Update README: v41 (96.1% BFCL) with per-category table
Browse files
README.md
CHANGED
|
@@ -3,56 +3,82 @@ language: en
|
|
| 3 |
license: apache-2.0
|
| 4 |
base_model: Qwen/Qwen3-1.7B
|
| 5 |
tags:
|
| 6 |
-
- tool-
|
| 7 |
-
-
|
| 8 |
-
- aac
|
|
|
|
| 9 |
- gguf
|
| 10 |
-
- mlx
|
| 11 |
---
|
| 12 |
|
| 13 |
-
# prism-coder:1b7 β
|
| 14 |
|
| 15 |
-
Fine-tuned
|
|
|
|
| 16 |
|
| 17 |
-
|
| 18 |
|
| 19 |
-
|
| 20 |
|
| 21 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22 |
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
| `session_load_context` | Load/fetch context for project X |
|
| 26 |
-
| `session_save_ledger` | Note / jot down / log / remember |
|
| 27 |
-
| `session_save_handoff` | Handoff to next agent / pass on |
|
| 28 |
-
| `session_compact_ledger` | Compact/archive/trim the ledger |
|
| 29 |
-
| `session_search_memory` | What did we discuss / recall session |
|
| 30 |
-
| `knowledge_search` | What do I know / stored notes |
|
| 31 |
-
| *(plain text)* | AAC phrases, math, facts, translation, time |
|
| 32 |
|
| 33 |
-
##
|
| 34 |
|
| 35 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 40 |
|
| 41 |
## Files
|
| 42 |
|
| 43 |
-
| File | Size |
|
| 44 |
-
|------|------|-----
|
| 45 |
-
| `prism-coder-1b7-
|
| 46 |
-
| `prism-aac-1b7-q4km.gguf` | 1.
|
| 47 |
|
| 48 |
-
##
|
| 49 |
|
| 50 |
-
-
|
| 51 |
-
-
|
| 52 |
-
- **Dataset**: v36_1b7 routing corpus (414 examples, 6-tool system prompt)
|
| 53 |
-
- **Hardware**: Apple Silicon (M-series), ~4GB RAM
|
| 54 |
-
- **Eval**: BFCL 100-case benchmark Γ 3 seeds β **100%**
|
| 55 |
|
| 56 |
-
##
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 57 |
|
| 58 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
license: apache-2.0
|
| 4 |
base_model: Qwen/Qwen3-1.7B
|
| 5 |
tags:
|
| 6 |
+
- tool-routing
|
| 7 |
+
- function-calling
|
| 8 |
+
- prism-aac
|
| 9 |
+
- qwen3
|
| 10 |
- gguf
|
|
|
|
| 11 |
---
|
| 12 |
|
| 13 |
+
# prism-coder:1b7 β Tool Routing Model (Ultra-Compact / iOS Tier)
|
| 14 |
|
| 15 |
+
Fine-tuned Qwen3-1.7B for 6-tool routing in the [Prism AAC](https://github.com/dcostenco/prism-aac) system.
|
| 16 |
+
Primary deployment: **on-device iOS inference** via llama.cpp (1.1 GB GGUF, Q4_K_M).
|
| 17 |
|
| 18 |
+
## BFCL Routing Benchmark β v41 (Current)
|
| 19 |
|
| 20 |
+
**Mean: 96.1%** (3-seed average, seeds 2027/2028/2029, 102 cases each)
|
| 21 |
|
| 22 |
+
| Category | Description | Accuracy |
|
| 23 |
+
|----------|-------------|:--------:|
|
| 24 |
+
| aac | AAC phrase requests β plain text | 100% |
|
| 25 |
+
| cmpct | Ledger compaction | 83% |
|
| 26 |
+
| edge | Multi-step / compound requests | 83% |
|
| 27 |
+
| hand | Agent handoff / relay | 100% |
|
| 28 |
+
| info | General facts β plain text | 100% |
|
| 29 |
+
| irrel | Irrelevant / live queries β plain text | 90% |
|
| 30 |
+
| know | Knowledge base search | 100% |
|
| 31 |
+
| load | Session context loading | 89% |
|
| 32 |
+
| pred | Factual / knowledge queries β plain text | 100% |
|
| 33 |
+
| save | Session ledger save | 100% |
|
| 34 |
+
| smem | Session memory search | 100% |
|
| 35 |
+
| tran | Translation requests β plain text | 100% |
|
| 36 |
|
| 37 |
+
Eval: Ollama inference, temperature=0, Qwen3 thinking suppressed (`<think>\n\n</think>`), num_predict=160.
|
| 38 |
+
Gate: β₯90% = deploy.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 39 |
|
| 40 |
+
## Version History
|
| 41 |
|
| 42 |
+
| Version | BFCL | Notes |
|
| 43 |
+
|---------|------|-------|
|
| 44 |
+
| v41 | 96.1% | Current β routing corpus v41 |
|
| 45 |
+
| v40 | ~95% | Routing corpus v40 |
|
| 46 |
+
| v39 | ~94% | Routing corpus v39 |
|
| 47 |
+
| v36 | 100% | Previous β routing corpus v36 (small eval set) |
|
| 48 |
|
| 49 |
+
## Tools
|
| 50 |
+
|
| 51 |
+
The model routes between exactly 6 tools:
|
| 52 |
+
|
| 53 |
+
1. `session_load_context` β load/fetch/resume project context
|
| 54 |
+
2. `session_save_ledger` β note/log/remember/record progress
|
| 55 |
+
3. `session_save_handoff` β handoff/relay to next agent/session
|
| 56 |
+
4. `session_compact_ledger` β compact/archive/shrink ledger
|
| 57 |
+
5. `session_search_memory` β recall past sessions/conversations
|
| 58 |
+
6. `knowledge_search` β search stored notes/knowledge base
|
| 59 |
|
| 60 |
## Files
|
| 61 |
|
| 62 |
+
| File | Size | Use |
|
| 63 |
+
|------|------|-----|
|
| 64 |
+
| `prism-coder-1b7-v41-q4km.gguf` | 1.1 GB | Ollama / desktop |
|
| 65 |
+
| `prism-aac-1b7-q4km.gguf` | 1.1 GB | iOS app download |
|
| 66 |
|
| 67 |
+
## Cascade Role
|
| 68 |
|
| 69 |
+
Ultra-compact iOS/edge tier. Desktop cascade: **1.7B β 8B β 14B β 32B β cloud Claude**.
|
| 70 |
+
1.7B handles offline on-device routing where memory is tightly constrained (< 2 GB available).
|
|
|
|
|
|
|
|
|
|
| 71 |
|
| 72 |
+
## Usage (Ollama)
|
| 73 |
+
|
| 74 |
+
```bash
|
| 75 |
+
ollama run dcostenco/prism-coder:1b7
|
| 76 |
+
```
|
| 77 |
+
|
| 78 |
+
## Training
|
| 79 |
|
| 80 |
+
- **Base**: `Qwen/Qwen3-1.7B` (fp16, 1.7B params)
|
| 81 |
+
- **Framework**: MLX-LM LoRA (rank=8, scale=20, 4 layers)
|
| 82 |
+
- **Data**: v41 routing corpus
|
| 83 |
+
- **Merge**: Direct safetensors manipulation (delta = scale/rank Γ B^T A^T)
|
| 84 |
+
- **Peak memory**: ~4 GB (M-series Mac)
|