This project implements a documentation writing agentic workflow that can generate documentation for your code.
We use:
- CrewAI for multi-agent orchestration.
- Ollama for serving Deepseek-R1 locally.
- Cursor IDE as the MCP host.
Install Ollama
# Setting up Ollama on linux
curl -fsSL https://ollama.com/install.sh | sh
# Pull the Deepseek-R1 model
ollama pull deepseek-r1Install Dependencies
Ensure you have Python 3.12 or later installed.
pip install crewai crewai-tools ollama mcpAlternatively, you can also use uv to directly install the required dependencies.
uv syncFirst, set up your MCP server as follows:
- Go to Cursor settings
- Select MCP
- Add new global MCP server.
In the JSON file, add this:
{
"mcpServers": {
"doc-writer": {
"url": "http://127.0.0.1:8000/sse"
}
}
}You should now be able to see the MCP server listed in the MCP settings.
Next, start the server using
python server.pyIn Cursor MCP settings make sure to toggle the button to connect the server to the host.
Done! Your server is now up and running.
You can now chat with Cursor and generate the documentation for your code. Simply provide the GitHub URL to your project and watch the magic unfold.
Get a FREE Data Science eBook 📖 with 150+ essential lessons in Data Science when you subscribe to our newsletter! Stay in the loop with the latest tutorials, insights, and exclusive resources. Subscribe now!
Contributions are welcome! Please fork the repository and submit a pull request with your improvements.
