A minimal coding agent CLI tool. AI agent runs tool-calling loop with multiple tools for command execution.
Multiple tools + ONE loop (tool-calling) = capable coding agent
meto provides a streamlined interface for AI-assisted coding through a simple but powerful architecture: an LLM with access to various tools (shell execution, file operations, grep, web fetch, task management) running in a continuous tool-calling loop until the task is complete.
- Interactive & One-Shot Modes: Run interactively with a REPL or execute single commands
- Tool-Calling Loop: Autonomous agent that can execute commands, read/write files, search code, and more
- Session Persistence: All conversations saved as JSONL for easy resumption
- Subagent Pattern: Spawn isolated agents for subtasks with fresh context
- Custom Agents: Define specialized agents with specific tool permissions
- Skills System: Lazy-loaded domain expertise modules for on-demand knowledge injection
- Plan Mode: Systematic exploration and planning workflow before implementation
- Hooks System: Extend agent behavior with shell commands at lifecycle events
- Slash Commands: Interactive commands for session management and workflow shortcuts
- Python 3.13+
- uv (recommended) or pip
# Clone the repository
git clone <repository-url>
cd meto
# Install dependencies and run tests
just
# Or install as local tool
uv tool install --editable .meto uses LiteLLM proxy for model-agnostic LLM access. Set up your environment:
# Create .env file
cat > .env << EOF
METO_LLM_API_KEY=your-api-key
METO_LLM_BASE_URL=model-api-endpoint
METO_DEFAULT_MODEL=model-name
EOF# Start interactive session
uv run meto# Execute single command
uv run meto --one-shot --prompt "fix the bug in src/main.py"
# or
echo "fix the bug in src/main.py" | uv run meto --one-shot
# Skip permission prompts with --yolo flag
uv run meto --one-shot --yolo --prompt "fix the bug in src/main.py"Environment variables (.env supported):
| Variable | Description | Default |
|---|---|---|
METO_LLM_API_KEY |
API key for LLM provider | - |
METO_LLM_BASE_URL |
LLM provider API endpoint URL | - |
METO_DEFAULT_MODEL |
Model identifier | - |
METO_MAIN_AGENT_MAX_TURNS |
Max iterations for main agent | 100 |
METO_SUBAGENT_MAX_TURNS |
Max iterations for subagents | 25 |
METO_TOOL_TIMEOUT_SECONDS |
Shell command timeout | 300 |
METO_MAX_TOOL_OUTPUT_CHARS |
Max tool output length | 50000 |
METO_AGENTS_DIR |
Custom agents directory | .meto/agents |
METO_SKILLS_DIR |
Skills directory | .meto/skills |
METO_PLAN_DIR |
Plan mode artifacts | ~/.meto/plans |
METO_YOLO_MODE |
Skip permission prompts for tools | false |
By default, meto prompts for permission before executing potentially dangerous operations (like shell commands). YOLO mode ("You Only Live Once") disables these safety prompts for faster, uninterrupted operation.
Enable YOLO mode:
# Via command-line flag
uv run meto --yolo
# Via environment variable
export METO_YOLO_MODE=true
uv run meto
# In .env file
echo "METO_YOLO_MODE=true" >> .env- User prompt → conversation history
- LLM call with system prompt + history + available tools
- If tool calls: execute tools, append results to history, loop back to step 2
- If no tool calls: return final response
- code (default): Full access to all tools for implementation
- explore: Read-only access for codebase exploration
- plan: Design-only agent for planning without execution
- planner: Specialized agent for plan mode workflow
Modes customize prompt and UI behavior:
- Plan Mode: Systematic exploration and planning before implementation
- Enter with
/plancommand - Creates structured plan file in
~/.meto/plans/ - Exit with
/doneor start implementation with/implement
- Enter with
- shell: Execute bash/PowerShell commands
- read_files: Read file contents
- write_file: Create or overwrite files
- edit_file: Apply targeted edits to files
- grep: Search code with regex patterns
- web_fetch: Fetch and parse web content
- run_task: Spawn subagent for isolated subtasks
- load_skill: Load domain expertise modules on-demand
- manage_todos*: Task tracking (create, update, list, get)
Define specialized agents in .meto/agents/{name}.md:
---
name: reviewer
description: Code review specialist
tools:
- read_files
- grep
- web_fetch
---
You are an expert code reviewer. Focus on:
- Security vulnerabilities
- Performance issues
- Best practices
- Code maintainabilityCreate domain expertise modules in .meto/skills/{skill-name}/SKILL.md:
---
name: commit-message
description: Generate conventional commit messages
---
# Commit Message Skill
You are an expert at writing clear, informative git commit messages...Skills are lazy-loaded only when needed via the load_skill tool.
Add workflow shortcuts in .meto/commands/{name}.md:
---
description: Review pull request changes
allowed-tools:
- shell
- read_files
- grep
context: fork
---
Review the current pull request:
1. Analyze the diff
2. Check for common issues
3. Provide constructive feedbackUse with /name [arguments] in interactive mode.
Extend agent behavior with shell commands at lifecycle events in .meto/hooks.yaml:
hooks:
- name: security-check
event: pre_tool_use
tools: [shell]
command: scripts/check_shell_command.py
timeout: 10Supported Events:
session_start: When agent session beginspre_tool_use: Before tool execution (can block with exit code 2)post_tool_use: After tool execution
| Command | Description |
|---|---|
/help |
Show available commands |
/export |
Export conversation history |
/compact |
Compact session history |
/todos |
Show task list |
/plan |
Enter plan mode |
/implement |
Exit plan mode and start implementation |
/done |
Exit current mode |
/exit, /quit |
Exit meto |
# Primary workflows (via just)
just # install + lint + test
just install # sync dependencies
just lint # ruff format + check
just test # pytest
just build # build wheel
just clean # remove build artifacts
# Direct commands
uv run pytest # run tests
uv run python devtools/lint.py # lint
uv build # build
uv tool install --editable . # install as local toolsrc/meto/cli.py- CLI interface and interactive modesrc/meto/agent/agent_loop.py- Main agent loopsrc/meto/agent/agent.py- Agent class factorysrc/meto/agent/tool_runner.py- Tool execution implementationssrc/meto/agent/tool_schema.py- Tool schemas (OpenAI format)src/meto/agent/session.py- Session persistence (JSONL)src/meto/agent/loaders/- Agent, skill, and frontmatter loaderssrc/meto/agent/modes/- Session mode systemsrc/meto/agent/hooks.py- Hook system
Sessions persist as JSONL in ~/.meto/sessions/.
This project is licensed under the MIT License - see the LICENSE file for details.
Contributions welcome! Please check existing issues or open a new one to discuss changes.