This is an interactive chat application that uses the Model Control Protocol (MCP) with Groq's language models. The application provides a command-line interface for having conversations with an AI assistant while maintaining conversation memory.
- Interactive command-line chat interface
- Integration with Groq's language models (using qwen-qwq-32b)
- Conversation memory management
- Simple commands for clearing history and exiting
- Browser automation capabilities through MCP
- Python 3.x
- Required API keys:
- GROQ_API_KEY
- Clone this repository:
git clone <https://github.com/rohith372/MCP>
cd <https://github.com/rohith372/MCP>- Install the required dependencies:
pip install -r requirements.txt
uv add langchain-groq
uv add langchain-openai
uv add mcp-use- Create a
.envfile in the project root and add your API keys:
GROQ_API_KEY=your_groq_api_key_here
- Run the chat application:
uv run app.py- Available commands during chat:
- Type your message and press Enter to chat with the assistant
- Type
clearto clear the conversation history - Type
exitorquitto end the conversation
The application uses a configuration file browser_mcp.json for MCP client settings. Make sure this file is present in your project directory with the appropriate configuration.
- langchain-groq
- python-dotenv
- mcp-use
- asyncio
The application includes basic error handling for:
- API communication issues
- Invalid inputs
- Session management