Examples
Real-world usage patterns for mcp-setu.
Example 1: File Analysis with Filesystem Server
Analyze code files in your project:
# Set up config
cat > mcp.json << 'EOF'
{
"ollama": {
"model": "llama3.2:3b",
"systemPrompt": "You are an expert code reviewer. Analyze code structure, performance, security, and best practices. Use the filesystem to read and examine files. Provide actionable feedback and suggestions for improvement."
},
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/project"]
}
}
}
EOF
# Start chat
mcp-setu chatIn the chat:
❯ review the main.go file and suggest improvements
⚙ filesystem › read_file {"path": "main.go"}
↳ read_file [file content...]
setu: I've reviewed main.go. Here are the suggestions:
1. Extract config loading into a separate function
2. Add error context wrapping
3. Consider using sync.Once for singleton instances
...Example 2: Database Queries with SQLite Server
Query a database during conversation:
cat > mcp.json << 'EOF'
{
"ollama": {
"model": "qwen2.5:7b",
"systemPrompt": "You are a skilled data analyst. Query databases to find insights, trends, and answers. Use SQLite tools to retrieve and analyze data. Present findings clearly with context and business implications."
},
"mcpServers": {
"sqlite": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-sqlite", "./app.db"]
}
}
}
EOF
mcp-setu chatIn the chat:
❯ how many users registered in the last 7 days?
⚙ sqlite › query {"sql": "SELECT COUNT(*) FROM users WHERE created_at > datetime('now', '-7 days')"}
↳ query [{"COUNT(*)": 42}]
setu: There were 42 new user registrations in the last 7 days. This is up from 38 last week.Example 3: Context Storage with Memory Server
Maintain context across conversations:
cat > mcp.json << 'EOF'
{
"ollama": {
"model": "llama3.2:3b",
"systemPrompt": "You are a helpful assistant with persistent memory across sessions. Use the memory tool to save important context and retrieve previous information. Maintain continuity and remember user preferences and project details."
},
"mcpServers": {
"memory": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-memory"]
}
}
}
EOF
mcp-setu chatSession 1:
❯ remember my project is a Go CLI tool
⚙ memory › set_context {"key": "project", "value": "Go CLI tool"}
↳ set_context [success]
❯ exitSession 2 (same config):
❯ what was my project about?
⚙ memory › get_context {}
↳ get_context [{"key": "project", "value": "Go CLI tool"}]
setu: Your project is a Go CLI tool.Example 4: Using Claude Desktop Config
Reuse your existing Claude Desktop setup:
# macOS
mcp-setu --config ~/Library/Application\ Support/Claude/claude_desktop_config.json chat
# Or add to your shell profile for easy access
alias claude-setu='mcp-setu --config ~/Library/Application\ Support/Claude/claude_desktop_config.json'Example 5: Verbose Mode for Debugging
See tool calls and LLM iterations inline in the chat TUI:
mcp-setu chat --verboseOutput panel (above the input line):
you list files in current directory
💭 Processing...
⚙ read_directory
↳ {"contents":[{"name":"main.go","size":2048},…]}
setu Here are the files in the current directory:
- main.go (2 KB)
- config.json (512 B)
- README.md (4 KB)Without --verbose, the 💭/⚙/↳ lines are hidden and you see only the final assistant message.
Example 6: Model Switching
Switch between models during chat:
mcp-setu chatIn chat:
❯ /model
Current model: llama3.2:3b
Available models:
✓ llama3.2:3b (tool support)
✓ qwen2.5:7b (tool support)
- llama2:7b (no tool support)
✓ mistral-nemo:12b (tool support)
❯ /model qwen2.5:7b
✓ Switched to model: qwen2.5:7bExample 7: Multi-Server Setup
Use multiple MCP servers together:
{
"ollama": {
"model": "qwen2.5:7b"
},
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "."]
},
"sqlite": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-sqlite", "./data.db"]
},
"memory": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-memory"]
}
}
}In chat:
❯ read config.json and remember its database path
⚙ filesystem › read_file {"path": "config.json"}
↳ read_file {"database": "./data.db"}
⚙ memory › set_context {"key": "db_path", "value": "./data.db"}
↳ set_context [success]
setu: I've read your config and saved the database path to memory.
❯ how many records are in the main table?
⚙ memory › get_context {}
↳ get_context [{"key": "db_path", "value": "./data.db"}]
⚙ sqlite › query {"sql": "SELECT COUNT(*) as count FROM main"}
↳ query [{"count": 1523}]
setu: There are 1,523 records in the main table.Example 8: Performance Monitoring
Check performance metrics:
mcp-setu chatIn chat (after several exchanges):
❯ /stats
Performance Statistics
Messages: 12
Tool calls: 8
Iterations: 5
Session duration: 2m 34s
Average response: 1.2s
Longest response: 3.4sTips & Tricks
Override model temporarily without changing config:
bashmcp-setu chat --model llama3.3:70bOverride system prompt:
bashmcp-setu chat --system "You are a Python expert"Validate before running:
bashmcp-setu validateList all tools available:
bashmcp-setu toolsFor non-interactive use, query tool metadata or run validation:
bashmcp-setu tools # list every tool mcp-setu validate # exit non-zero on config/connection errorsThe
chatcommand itself requires an interactive terminal (TUI).
Next Steps
- Configuration — More config options
- Troubleshooting — Solve issues
- CLI Reference — Full command documentation