CLI agent for the Bob Agent Framework.
bob-cli is a command-line interface for Bob, a general-purpose AI agent framework. It provides:
- Interactive REPL: Chat through
AgentLoopwith built-in slash commands and session reset shortcuts - Multi-Model Support: Works with OpenAI, Anthropic, Google, and other LLM providers
- Tool Integration: Connect to MCP servers for file operations, shell commands, and more
- Skill System: Load and apply predefined skills for specialized tasks
# Clone the repository
git clone https://github.com/longcipher/bob
cd bob
# Build and run
cargo run --bin bob-cli -- --config agent.toml# Download from GitHub releases
# (Coming soon)Create an agent.toml file in the project root:
[runtime]
default_model = "openai:gpt-4o-mini"
max_steps = 12
turn_timeout_ms = 90000
dispatch_mode = "native_preferred"
# Optional: Configure MCP servers
[mcp]
[[mcp.servers]]
id = "filesystem"
command = "npx"
args = ["-y", "@modelcontextprotocol/server-filesystem", "/tmp"]
tool_timeout_ms = 15000
# Optional: Configure skills
[skills]
max_selected = 3
token_budget_ratio = 0.1
[[skills.sources]]
type = "directory"
path = "./skills"
recursive = false
# Optional: Persist session state/checkpoints/artifacts across restarts
[store]
path = "./.bob/sessions"
# Optional: Configure policies
[policy]
deny_tools = ["local/shell_exec"]
allow_tools = ["local/read_file", "local/write_file"]
default_deny = false
# Optional: Configure approval guardrails
[approval]
mode = "allow_all"
deny_tools = ["local/shell_exec"]
# Optional: Configure per-session token budget
[cost]
session_token_budget = 10000When [store] is set, budget accounting is also persisted, so restarting the
CLI does not reset per-session token limits.
dispatch_mode supports native_preferred and prompt_guided.
Set your LLM provider API key:
# For OpenAI
export OPENAI_API_KEY="sk-..."
# For Anthropic
export ANTHROPIC_API_KEY="sk-ant-..."
# For Google
export GEMINI_API_KEY="..."cargo run --bin bob-cliThe agent will start an interactive REPL:
Bob agent ready (model: openai:gpt-4o-mini)
Type a message and press Enter. /help for commands.
> Summarize the latest meeting notes in this folder
- Type your message and press Enter to send
/quitor/exitto exit the agent/helpor/hto show available commands/usageto inspect cumulative session token usage/toolsto list all available tools/tool.describe <tool-name>to print a tool schema/tape.info,/tape.search <query>,/anchors, and/handoff [name]for session tape inspection/newor/resetto start a fresh session context
> Read docs/design.md and explain it in simple terms
I'll read docs/design.md for you...
[uses filesystem tool to read the document]
The design document describes...
> Translate this explanation into Chinese
[agent produces translated output]
Here is the translated explanation...
Works with any LLM provider supported by liter-llm:
- OpenAI:
openai:gpt-4o,openai:gpt-4o-mini - Anthropic:
anthropic:claude-3-5-sonnet-20241022 - Google:
google:gemini-2.0-flash-exp - Groq:
groq:llama-3.3-70b-versatile - And more...
Connect to MCP servers for extended capabilities:
- Filesystem: Read, write, and manage files
- Shell: Execute shell commands
- Database: Query databases
- Custom: Build your own MCP servers
Apply predefined skills for specialized tasks:
- Knowledge extraction
- Summarization and transformation
- Workflow automation
- Domain-specific orchestration
Sessions are persisted in-memory (development) or can be configured for persistent storage.
# Run in development mode
cargo run --bin bob-cli
# Build release binary
cargo build --bin bob-cli --release
# Run tests
cargo test -p cli-agentThe CLI agent is the composition root that:
- Loads configuration from
agent.toml - Wires up adapters (LLM, tools, storage, events)
- Creates the runtime
- Runs the REPL loop
See the main.rs for the implementation.
- bob-core - Domain types and ports
- bob-runtime - Runtime orchestration
- bob-adapters - Adapter implementations
Licensed under the Apache License, Version 2.0. See LICENSE for details.