Files
NotesAgentic/backend
admin 2dc984401d feat(mcp): add standalone server registry
Implement C.1 stdio MCP server CRUD, encrypted environment secrets, command digest approval, connection tests, lifecycle recovery, and dynamic tool registration. Add the standalone frontend configuration center, contracts, regression tests, and development documentation.
2026-09-03 14:49:49 +08:00
..
2026-08-27 11:19:36 +08:00

Notes Agent Backend

FastAPI + Pydantic 的本地 AI Core / Agent Core。项目使用 uv 管理依赖和虚拟环境。

当前实现包含 Knowledge/Retrieval、Chat、Agent Runtime、Tool/Permission、Skill/Plugin、stdio MCP Host、Plugin Command/Settings、Provider Adapter、任务、索引和开发阶段凭据加密存储。Provider 支持 Mock、OpenAI Chat/OpenAI-Compatible 与 OllamaOpenAI Responses、Anthropic Messages、操作系统级 Plugin 沙箱和真实语音模型仍属于后续阶段。

uv sync
uv run uvicorn app.main:app --reload --host 127.0.0.1 --port 8000

uv sync 首次运行时会自动创建由 uv 管理的 .venv,无需手动执行 python -m venv 或激活环境。

启动后可访问:

运行回归测试:

uv run pytest

当前基线为 136 项测试通过。Provider API Key 可通过前端设置页写入,也可用 OPENAI_API_KEYDEEPSEEK_API_KEYAINOTE_CREDENTIAL_<ID> 注入;不要把真实密钥写入仓库。plugin.* 是 Plugin Settings 的保留凭据命名空间,通用 Provider 凭据接口不能读写。

团队接口清单见 ../docs/contracts/后端接口契约-开发版.md,机器可读契约以运行时的 /openapi.json 为准。

AI Core 与 Agent Core 的模块边界、Mock Provider 和 Tool Calling 调试方式见 ../docs/development/AI-Core与Agent-Core开发说明.md

Knowledge Core 与 Retrieval Core 的模块边界、数据模型、接口与检索流程见 ../docs/development/Knowledge与Retrieval-Core开发说明.md