-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Add Learn MCP page #8903
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Learn MCP page #8903
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds documentation for using the Model Context Protocol (MCP) with DSPy, expanding the programming section to include comprehensive MCP integration guidance. The documentation explains how to use MCP tools with DSPy agents and provides practical examples for different connection types.
Key changes:
- Added MCP documentation page to the programming section
- Provided installation instructions and usage examples for both stdio and HTTP MCP servers
- Included examples for creating MCP servers and converting tools to DSPy format
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
File | Description |
---|---|
docs/mkdocs.yml | Added MCP page to navigation under programming section |
docs/docs/learn/programming/mcp.md | New comprehensive documentation covering MCP installation, usage patterns, server creation, and tool conversion |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
The test failure is not related to this PR |
docs/docs/learn/programming/mcp.md
Outdated
- **Share tools across stacks** - Use the same tools across different frameworks | ||
- **Simplify integration** - Convert MCP tools to DSPy tools with one line | ||
|
||
As long as you have an `mcp.ClientSession`, you can use MCP tools with DSPy's `ReAct` module or any other tool-based workflow. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think users will be confused about "As long as you have an mcp.ClientSession
", because it's not a well-known thing for many people.
We should maybe add a short paragraph to explain how DSPy manages the connections to the MCP server - we utilize the native MCP session for all connection types, and don't provide extra features for connection handling
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
MCP has more and more popularity, so we should document how to use MCP with DSPy in the main section in addition to the existing tutorial.