MCP: Model Context Protocol
Описание проекта
MCP (Model Context Protocol) - это система для управления контекстом при взаимодействии с языковыми моделями (LLM). Система позволяет сохранять контекст диалогов между запросами, что даёт возможность языковой модели "помнить" предыдущие взаимодействия.
Особенности
- Сохранение и управление контекстом между запросами
- Интеграция с Google Gemini API
- Возможность использования нескольких независимых сессий
- Переключение между сессиями с помощью идентификаторов
- Локальное хранение истории диалогов
Технологии
- Python 3
- FastAPI
- Gemini API
- Uvicorn
Установка
- Клонировать репозиторий:
- Создать и активировать виртуальное окружение:
- Установить зависимости:
- Создать файл
.env
и добавить API ключ:
Использование
Запуск сервера
Сервер будет доступен по адресу: http://localhost:9999
Использование клиента
Отправить запрос (создаст новую сессию):
Продолжить диалог в той же сессии:
Использовать конкретную сессию по ID:
Показать список всех сессий:
Структура проекта
mcp_server.py
- Основной сервер MCPmcp_client.py
- Клиент для взаимодействия с серверомrequirements.txt
- Зависимости проекта
Лицензия
MIT
Автор
Alex Replicator - alex.replicator@gmail.com
This server cannot be installed
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
A system that manages context for language model interactions, allowing the model to remember previous interactions across multiple independent sessions using Gemini API.
Related MCP Servers
- -securityAlicense-qualityA Model Context Protocol server that allows Claude to create flashcards for Rember, helping users study and remember information through spaced repetition reviews.Last updated -8816TypeScriptMIT License
- -securityFlicense-qualityA server implementing the Model Context Protocol that enables AI assistants like Claude to interact with Google's Gemini API for text generation, text analysis, and chat conversations.Last updated -Python
- -securityAlicense-qualityA Model Context Protocol server implementation that provides a standardized interface for applications to interact with OpenRouter's language models through a unified conversation management system.Last updated -TypeScriptMIT License
- -securityFlicense-qualityA server that manages conversation context for LLM interactions, storing recent prompts and providing relevant context for each user via REST API endpoints.Last updated -1,012TypeScript