The Claude Desktop Integration for KSRK MCP Server is a project designed to provide the latest information about a specific user (currently "ksrk") by integrating with the Claude Desktop application. This MCP server allows users to either add it to Claude Desktop or create a custom client to interact with it. The repository includes the necessary tools and configurations to set up and use the server effectively.
The project leverages several tools and libraries to achieve its functionality:
- OpenAI GPT-4: Used for processing user queries and generating responses.
- ScrapingDog API: Enables web scraping to fetch relevant information.
- BeautifulSoup: Parses HTML and XML documents for data extraction.
- httpx: Acts as the HTTP client for making web requests.
pyproject.toml
shell
git clone <repository-url>
cd documentation
shell
python -m venv .venv
source .venv/bin/activate # On Windows use `.venv\Scripts\activate`
shell
pip install -r requirements.txt
.env
file in the root directory with the following content:dotenv
SCRAPING_DOG_API_KEY=your_scraping_dog_api_key
OPENAI_API_KEY=your_openai_api_key
shell
cd ..
shell
python client.py
quit
or exit
to stop the client.client.py
This file contains the main client code that interacts with the MCP server and OpenAI's GPT-4 model. It includes the following key components:
- MCPClient
: Manages the connection to the MCP server and provides methods to retrieve available tools and call them.
- agent_loop
: An asynchronous function that processes user queries using the LLM and available tools.
- main
: The main function that sets up the MCP server, initializes tools, and runs the interactive loop.
ksrk-mcp/ksrk-mcp-server.py
This file contains the MCP server implementation. It includes the following key components:
- search_web
: An asynchronous function that searches the web using the ScrapingDog API.
- fetch_url
: An asynchronous function that fetches the content of a URL.
- about_ksrk
: An MCP tool that searches for details about "ksrk" on a given website.
ksrk-mcp/test-website.py
This file contains a script to test website scraping using httpx
and BeautifulSoup
.
This project is licensed under the MIT License. See the LICENSE file for details.
This MCP server is designed to fetch the latest information about a specific user (currently "ksrk"). Users can integrate this server with Claude Desktop or create a custom client to interact with it.