Skip to content

Repository files navigation

tako

tako

tako is a local multi-LLM orchestrator. It lets you define a pool of command-line AI agents, then route one prompt through one of several orchestration strategies: router, parallel judge, or verifier loop.

The orchestrator itself is intentionally credential-free. It invokes configured agents as subprocesses and leaves authentication to those tools or to small bridge wrappers.

Features

  • Pluggable local agent pool configured in TOML.
  • Three strategies:
    • router: choose one agent for the request.
    • parallel: run multiple agents and ask a judge agent to synthesize the result.
    • verify: run a generator, then a verifier/revision loop.
  • Long-running daemon with Unix domain socket IPC and auto-spawn from the CLI.
  • JSON Lines logs for agent, strategy, gateway, and attachment records.
  • Optional OpenAI-compatible bridge binary for models exposed through Chat Completions endpoints.
  • Optional native image dispatch through --image and {attachments} argv substitution for image-capable agents.

Requirements

  • Go 1.23 or newer.
  • macOS or Linux.
  • One or more agent CLIs available on PATH, for example claude, codex, or agy.

tako does not install or authenticate third-party AI tools for you. Configure and test each agent CLI independently before adding it to tako.

Build

make build

This creates:

  • bin/tako
  • bin/openai-bridge
  • bin/claude-image-bridge

You can also run the full test suite:

make test

Configuration

Copy the example config to the platform default path:

mkdir -p ~/.config/tako
cp config.example.toml ~/.config/tako/config.toml

On macOS, the default config path is:

~/Library/Application Support/tako/config.toml

Each agent is declared as an argv array. The literal {prompt} is replaced with the user prompt. If {prompt} is not present, tako sends the prompt on stdin.

Minimal example:

default_strategy = "router"

[agents.codex]
exec = ["codex", "exec", "--skip-git-repo-check", "{prompt}"]
roles = ["generator"]
context_limit = 128000

[agents.opus]
exec = ["claude", "-p", "--safe-mode", "{prompt}"]
roles = ["generator", "judge", "verifier"]
context_limit = 200000

[strategies.parallel]
judge = "opus"

[strategies.verify]
generator = "codex"
verifier = "opus"
max_rounds = 2

See config.example.toml for the full template, including OpenAI-compatible bridge agents, local gateway management, and multimodal setup.

Usage

Run with the configured default strategy:

bin/tako "Write a Go function that reverses a string."

Choose a strategy:

bin/tako --mode router "Explain this error message."
bin/tako --mode parallel "Review this diff for correctness."
bin/tako --mode verify --max-rounds 2 "Check this migration plan."

Restrict or exclude agents for one request:

bin/tako --pool codex,opus "Compare these two approaches."
bin/tako --exclude agy "Summarize this design."

Read the prompt from stdin:

git diff | bin/tako --mode parallel

Daemon diagnostics:

bin/tako daemon-status
bin/tako daemon-stop
bin/tako version

Multimodal Requests

Image attachments are passed with repeatable absolute --image paths:

bin/tako --image /tmp/screenshot.png "What is wrong with this UI?"

Image-capable agents should declare:

modalities = ["text", "image"]

For image requests, tako stages attachments under /tmp/tako-<request_id>/ and replaces the literal {attachments} argv token with a JSON array of staged image paths. Wrappers should parse that token as JSON, not split it on whitespace.

Text-only agents can either fail fast with text_fallback = "strict" or receive a describer-generated text summary with text_fallback = "describer".

Logs And State

tako writes structured JSON Lines logs to the platform state directory:

  • Linux: $XDG_STATE_HOME/tako/log.jsonl, or ~/.local/state/tako/log.jsonl.
  • macOS: ~/Library/Application Support/tako/log.jsonl.

The daemon listens on:

  • Linux: $XDG_RUNTIME_DIR/tako.sock.
  • macOS: ~/Library/Application Support/tako/tako.sock.

Both paths can be overridden with --socket; the config path can be overridden with --config.

Development

Common commands:

make build
make test
make lint
make clean

The repository includes unit tests under package directories, integration tests under tests/integration/, and contract tests under tests/contract/.

About

Multi-LLM local orchestrator (Router / Parallel+Judge / Verifier loop) — Sakana Fugu-inspired, rule-based, subprocess-only

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages