{"type":"mcp_client","name":"mcp-client-cli","description":"This repository provides a CLI client for running LLM prompts and interacting with Model Context Protocol (MCP) servers. It allows users to leverage various LLM providers and MCP-compatible services from their terminal.","category":"Developer Tools","language":"Python","stars":678,"forks":38,"owner":"adhikasp","github_url":"https://github.com/adhikasp/mcp-client-cli","homepage":null,"setup":"## Setup\n\n1. Install via pip:\n   ```bash\n   pip install mcp-client-cli\n   ```\n\n2. Create a `~/.llm/config.json` file to configure your LLM and MCP servers:\n   ```json\n   {\n     \"systemPrompt\": \"You are an AI assistant helping a software engineer...\",\n     \"llm\": {\n       \"provider\": \"openai\",\n       \"model\": \"gpt-4\",\n       \"api_key\": \"your-openai-api-key\",\n       \"temperature\": 0.7,\n       \"base_url\": \"https://api.openai.com/v1\"  // Optional, for OpenRouter or other providers\n     },\n     \"mcpServers\": {\n       \"fetch\": {\n         \"command\": \"uvx\",\n         \"args\": [\"mcp-server-fetch\"],\n         \"requires_confirmation\": [\"fetch\"],\n         \"enabled\": true,  // Optional, defaults to true\n         \"exclude_tools\": []  // Optional, list of tool names to exclude\n       },\n       \"brave-search\": {\n         \"command\": \"npx\",\n         \"args\": [\"-y\", \"@modelcontextprotocol/server-brave-search\"],\n         \"env\": {\n           \"BRAVE_API_KEY\": \"your-brave-api-key\"\n         },\n         \"requires_confirmation\": [\"brave_web_search\"]\n       },\n       \"youtube\": {\n         \"command\": \"uvx\",\n         \"args\": [\"--from\", \"git+https://github.com/adhikasp/mcp-youtube\", \"mcp-youtube\"]\n       }\n     }\n   }\n   ```\n\n   Note: \n   - Use `requires_confirmation` to specify which tools need user confirmation before execution\n   - The LLM API key can also be set via environment variables `LLM_API_KEY` or `OPENAI_API_KEY`\n   - The config file can be placed in either `~/.llm/config.json` or `$PWD/.llm/config.json`\n   - You can comment the JSON config file with `//` if you like to switch around the configuration\n\n3. Run the CLI:\n   ```bash\n   llm \"What is the capital city of North Sumatra?\"\n   ```","tools":"## Available Tools\n\n1.  Basic Usage (Run LLM prompts from the command line, including piping input).\n2.  Image Input (Analyze images with multimodal LLMs).\n3.  Prompt Templates (Use predefined prompt templates with the `p` prefix).\n4.  Tool Triggering (Trigger external tools like brave-search and fetch).\n5.  Tool Confirmation (Confirm tool calls before execution or bypass with `--no-confirmations`).\n6.  Continuation (Continue the last conversation with the `c` prefix).\n7.  Clipboard Support (Use content from your clipboard with the `cb` command).\n8.  List Tools (`--list-tools` to list available tools).\n9.  No Tools (`--no-tools` to run without any tools).\n10. Force Refresh (`--force-refresh` to force refresh tool capabilities cache).\n11. Text Only (`--text-only` to output raw text without markdown formatting).\n12. Show Memories (`--show-memories` to show user memories).\n13. Override Model (`--model` to override the model specified in config).\n","faq":null,"created_at":"2024-11-27T14:21:00+00:00","updated_at":"2025-03-28T21:53:40+00:00","source_url":"https://model-context-protocol.com/clients/cli-llm-prompt-mcp-client-tool","related_articles":[]}