Skip to main content
Glama

Sequential Questioning MCP Server

by bitgeese

顺序提问 MCP 服务器

一个专用服务器,使 LLM(大型语言模型)能够通过顺序查询收集特定信息。该项目实现了 MCP(模型控制协议)标准,可与 LLM 客户端无缝集成。

项目状态

🎉 1.0.0 版本发布🎉

顺序查询 MCP 服务器现已完成,并准备好投入生产部署。所有计划的功能均已实现、测试并记录。

Related MCP server: Vibe-Coder MCP Server

特征

  • 顺序提问引擎:根据先前的回答生成适合上下文的后续问题

  • MCP 协议支持:完全实现 MCP 规范,以便与 LLM 集成

  • 强大的 API :具有全面验证和错误处理的 RESTful API

  • 矢量数据库集成:高效存储和检索问题模式

  • 全面监控:使用 Prometheus 和 Grafana 实现性能指标和可观察性

  • 生产就绪部署:具有多环境支持的 Kubernetes 部署配置

  • 高可用性:水平 Pod 自动缩放器和 Pod 中断预算,确保生产可靠性

  • 安全性:限制流量和保护应用程序的网络策略

文档

入门

先决条件

  • Python 3.10+

  • Docker 和 Docker Compose(用于本地开发)

  • Kubernetes 集群(用于生产部署)

  • PostgreSQL 15.4+

  • 访问 Qdrant 实例

快速入门

最简单的开始方式是使用我们的初始化脚本:

./scripts/initialize_app.sh

该脚本将:

  1. 检查 Docker 是否正在运行

  2. 使用 Docker Compose 启动所有必要的容器

  3. 自动运行数据库迁移

  4. 提供有关如何访问应用程序的信息

该应用程序将在http://localhost:8001上可用

本地开发

  1. 克隆存储库

    git clone https://github.com/your-organization/sequential-questioning.git cd sequential-questioning
  2. 安装依赖项

    pip install -e ".[dev]"
  3. 设置环境变量

    cp .env.example .env # Edit .env file with your configuration
  4. 运行开发服务器

    uvicorn app.main:app --reload

Docker 部署

docker-compose up -d

数据库设置

如果您手动启动应用程序,请不要忘记运行数据库迁移:

export DATABASE_URL="postgresql://postgres:postgres@localhost:5432/postgres" bash scripts/run_migrations.sh

Kubernetes 部署

  1. 开发环境

    kubectl apply -k k8s/overlays/dev
  2. 暂存环境

    kubectl apply -k k8s/overlays/staging
  3. 生产环境

    kubectl apply -k k8s/overlays/prod

有关详细说明,请参阅最终部署计划操作手册

监控

访问 Prometheus 和 Grafana 仪表板进行监控:

kubectl port-forward -n monitoring svc/prometheus 9090:9090 kubectl port-forward -n monitoring svc/grafana 3000:3000

CI/CD 管道

使用 GitHub Actions 实现自动化 CI/CD 管道:

  • 持续集成:Linting、类型检查和测试

  • 持续部署:自动部署到开发、准备和生产环境

  • 部署验证:部署后自动检查

测试

运行测试套件:

pytest

运行性能测试:

python -m tests.performance.test_sequential_questioning_load

故障排除

未创建数据库表

如果应用程序正在运行但数据库表不存在:

  1. 确保数据库容器正在运行

  2. 手动运行数据库迁移:

    export DATABASE_URL="postgresql://postgres:postgres@localhost:5432/postgres" bash scripts/run_migrations.sh

Pydantic 版本兼容性

如果遇到错误pydantic.errors.PydanticImportError: BaseSettings has been moved to the pydantic-settings package ,请确保:

  1. pydantic-settings包包含在你的依赖项中

  2. 您正在从pydantic_settings导入BaseSettings ,而不是直接从pydantic导入

该项目使用 Pydantic v2.x,它将BaseSettings移至单独的包中。

贡献

欢迎贡献!请参阅CONTRIBUTING.md获取相关指南。

执照

MIT 许可证

接触

如需支持或咨询,请联系support@example.com

-
security - not tested
F
license - not found
-
quality - not tested

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/bitgeese/sequential-questioning'

If you have feedback or need assistance with the MCP directory API, please join our Discord server