6e893c6362df02a1bb917bc3f2c90108213487fb
- driver: .env auto-load, failure log (FAILURES.md), exponential backoff on 429 (5x multiplier) and general errors - cli: tinyclaw add subcommand, appends single task to QUEUE.md - demo/: math_utils.py + QUEUE.md for end-to-end testing - Verified: 3/3 tasks pass with google/gemma-3-4b-it, 96-135 prompt tokens each - Queue markers [done]/[failed:N]/[skipped] persist correctly
TinyClaw
Orchestrator that makes 1-4B parameter language models capable of real project work.
How it works
Tiny models (1-4B) can't plan, can't manage state, and can't reliably use tools. But they can edit a single function when given clear instructions.
TinyClaw exploits this: a driver script handles everything the model can't (file extraction, state management, verification, git), and the model just generates code edits.
User request --> Big model decomposes into atomic tasks (QUEUE.md)
|
Driver reads next task
|
Extracts target function (Python AST)
|
Builds minimal prompt (~500 tokens)
|
Tiny model returns edited function
|
Verifier checks syntax/imports
|
Pass? --> Splice back, git commit, next task
Fail? --> Retry (max 3), then skip
Usage
# Process a task queue
tinyclaw run --queue QUEUE.md --model qwen/qwen3.5-9b
# Check progress
tinyclaw status
# Auto-decompose a feature (uses big model)
tinyclaw plan "add user authentication with JWT tokens"
Queue Format (QUEUE.md)
EDIT auth.py validate_login "reject empty password strings"
EDIT main.py handle_request "add validate_token() call before processing"
CREATE config.py - "define AUTH_SECRET from environment variable"
TEST auth.py - "verify login rejects empty passwords"
One task per line: ACTION file function "instruction"
Install
pip install -e .
Design Principles
- The model is the hands, not the brain
- One function per task, one task per commit
- Under 500 tokens per prompt (fits in 2k context)
- Verify everything, trust nothing
- Auto-revert on failure
Status
Early development. Milestone 1 (core loop) in progress.
Description
Orchestrator that makes 1-4B models capable of real project work. Big model plans, tiny model executes.
70 KiB
0 Stars
1 Watchers
0 Forks
Languages
Python
74.5%
HTML
25.5%