A powerful CLI for interacting with the ASI:One LLM and Model Context Protocol (MCP) servers
Project description
FETCH.AI MCP CLI
A powerful CLI for interacting with the ASI:One LLM and Model Context Protocol (MCP) servers using natural language queries - no JSON required!
Quick Start
Installation
pip install asi1-mcp-cli
Setup
-
Create configuration directory:
mkdir -p ~/.asi1
-
Create configuration file:
# Copy the example config cp $(python -c "import asi1_mcp_cli; import os; print(os.path.join(os.path.dirname(asi1_mcp_cli.__file__), '..', 'asi1-mcp-server-config-example.json'))") ~/.asi1/config.json
-
Edit the configuration:
nano ~/.asi1/config.jsonUpdate the following fields:
api_key: Your ASI:One API keyBRAVE_API_KEY: Your Brave Search API key (optional)
Usage
Basic Conversation
asi1 "What is the capital of France?"
Web Search (Natural Language - No JSON!)
asi1 "latest developments in quantum computing"
asi1 "What are the latest developments in quantum computing?"
List Available Prompts
asi1 --list-prompts
Use Specific Prompt Templates
# Code review
asi1 run p review
# Git commit
asi1 run p commit
# YouTube video summary
asi1 run p yt https://www.youtube.com/watch?v=example
Configuration
The configuration file (~/.asi1/config.json) supports:
api_key: Your ASI:One API keyBRAVE_API_KEY: Your Brave Search API key (optional)- Other LLM/MCP server settings as needed
Configuration Example
{
"systemPrompt": "You are a helpful AI assistant",
"llm": {
"provider": "asi-one",
"model": "asi1-mini",
"api_key": "asi1-api",
"temperature": 0,
"base_url": "https://api.asi1.ai/v1"
},
"mcpServers": {
"exa": {
"command": "npx",
"args": ["-y", "exa-mcp-server", "--tools=web_search"],
"env": {
"EXA_API_KEY": ""
}
},
"brave-search": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-brave-search"],
"env": {
"BRAVE_API_KEY": ""
}
},
"mcp-server-commands": {
"command": "npx",
"args": ["mcp-server-commands"],
"requires_confirmation": ["run_command", "run_script"]
}
}
}
🔄 Workflow
graph TD
A[User Input: Natural Language] --> B[CLI Parser]
B --> C{Command Type?}
C -->|Agent Chat| D[Send to Agent]
C -->|LLM Query| E[Send to ASI:One LLM]
C -->|MCP Query| F[Route to MCP Server]
D --> G[Agent Response]
E --> H[LLM Response]
F --> I[MCP Server Response]
G --> J[Display Result]
H --> J
I --> J
J --> K[Auto-exit for Agent Chat]
J --> L[Continue for LLM/MCP]
style A fill:#e1f5fe
style J fill:#c8e6c9
style K fill:#ffcdd2
🚀 Features
- Natural Language Interface: Simply type your query in plain English - no JSON or complex syntax required!
- Beautiful CLI Header: Eye-catching ASCII art and welcome message every time you start the CLI.
- Agent Chat: Send messages to other agents using
asi1 agent chat --address <agent_address> --message "...". - LLM/MCP Queries: Use
asi1 <query>orasi1 run <query>for natural language queries to the LLM or MCP server. - Prompt Templates: Use pre-defined prompt templates for code review, commit messages, and YouTube summaries.
- Backwards Compatible: Old usage patterns still work—no need to change your workflow!
- Call Agent, MCP Server, and LLM: The CLI can route your query to an agent, the MCP server, or the LLM as needed.
🖥️ Example Usage
1. Show the CLI header and help
asi1 --help
2. Ask the LLM or MCP server a question (Natural Language!)
asi1 "What is the capital of France?"
asi1 "latest developments in quantum computing"
asi1 "Build a chat bot in JavaScript and HTML"
asi1 run "What are the latest AI developments?"
3. Use a prompt template
asi1 run p review
asi1 run p commit
asi1 run p yt https://www.youtube.com/watch?v=dQw4w9WgXcQ
4. Chat with another agent
asi1 agent chat --address <agent_address> --message "Get the latest tweet from Elon Musk"
🧠 Prompt Templates
You can use prompt templates for common tasks:
review: Code review for your current git diffcommit: Generate a Conventional Commit message for your changesyt: Summarize a YouTube video by URL
Example:
asi1 run p yt https://www.youtube.com/watch?v=dQw4w9WgXcQ
🔗 External Resources
- ASI:One Documentation: Official ASI:One platform documentation
- Agentverse: Discover and interact with AI agents
- ASI:One Models: Choose from asi1-mini, asi1-fast, asi1-extended, asi1-agentic, and asi1-graph
🆕 Recent Improvements
- Natural Language Interface: No more JSON! Just type your query in plain English
- Premium, colorful CLI header with FETCH.AI MCP CLI branding
- Agent chat with auto-exit after first response
- Backward compatibility for LLM/MCP queries
- Improved help and usage examples
- Prompt templates for review, commit, and YouTube summary
🤝 Get Help
- Run
asi1 --helpfor usage and examples - For issues, open an issue on GitHub or contact the maintainers
No more complex JSON! Just type your query naturally and let the CLI handle the rest.
Enjoy using the FETCH.AI MCP CLI! Powered by fetch.ai and ASI:One.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file asi1_mcp_cli-0.1.7.tar.gz.
File metadata
- Download URL: asi1_mcp_cli-0.1.7.tar.gz
- Upload date:
- Size: 21.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d331d675d0e543d643240c799495b691bb26a85aeb729302c0906bba4d23198e
|
|
| MD5 |
c33e92ea672d70081cd1228e299813a2
|
|
| BLAKE2b-256 |
306e0387ac1482b476b7478d5d776a3d2aa73a79c2e5eb3fb439ea0c094a75e7
|
File details
Details for the file asi1_mcp_cli-0.1.7-py3-none-any.whl.
File metadata
- Download URL: asi1_mcp_cli-0.1.7-py3-none-any.whl
- Upload date:
- Size: 24.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c2a0085c992ebf7f8eb3e4b6ed8ede81d449c7b2ddc8aeb2006e146e67ff8873
|
|
| MD5 |
ea126897cca8e5af7c7ed828af008501
|
|
| BLAKE2b-256 |
ec82fdff9263ab5497b78c2fa92eb5ebd0e67030f8b5366c38f724a80ab36823
|