https://github.com/manatlan/mcp
Some tests with pydantic_ai & fastmcp/mcp.
https://github.com/manatlan/mcp
Last synced: 4 months ago
JSON representation
Some tests with pydantic_ai & fastmcp/mcp.
- Host: GitHub
- URL: https://github.com/manatlan/mcp
- Owner: manatlan
- Created: 2025-05-29T16:54:23.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2025-05-31T15:19:36.000Z (7 months ago)
- Last Synced: 2025-06-08T07:09:38.906Z (7 months ago)
- Language: Python
- Homepage:
- Size: 138 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# mcp
Some tests with [pydantic_ai][1] & [fastmcp][2]/[mcp][4].
## Setup
python3 -m venv venv
. venv/bin/activate
pip install -r requirements.txt
It needs a [GEMINI_API_KEY](https://aistudio.google.com/app/apikey) (in an `.env` file) !!!
## 4 mcp server tests
It demonstrates how to use/setup some mcp servers
### mcp-server-time (package pypi)
An mcp server package, runned on the fly with uvx. see https://pypi.org/project/mcp-server-time/ (stdio)
It manages timezones, and current local time
### mcp-server-test (stdio)
The "mcp-server-test" directory (created with [mcp][4]) is managed via 'uv' (it has its own .venv). To activate it in the console:
$ cd mcp-server-test
$ uv sync --dev --all-extras
$ uv run mcp-server-test
it uses the low level "mcp" module
It manages "notes", and it can:
- add a note : title & content
### mcp2-server-test (stdio)
The "mcp2-server-test" is as mcp server using [fastmcp][2]/stdio (it is managed via 'uv' too (it has its own .venv))
It manages "memos", and it can:
- add a memos : title & content
- list all memos
### mcp3-serverhttp-test (http)
The "mcp3-serverhttp-test" is as mcp server using [fastmcp][2]/http (it is managed via 'uv' too (it has its own .venv))
It manages "recettes" ("recipes" in english), and it can:
- add a recipe : title & content
- list all recipes
- produces an image/url (with [g4f][3]/image generation) (async method)
- give a recipe (it guess with [g4f][3]/text gpt-4o-mini generation) (async method)
[1]: https://ai.pydantic.dev/mcp/
[2]: https://gofastmcp.com/getting-started/welcome
[3]: https://github.com/xtekky/gpt4free?tab=readme-ov-file
[4]: https://github.com/modelcontextprotocol/create-python-server?tab=readme-ov-file