Nervos Brain 周报
本周工作重点聚焦于“工程基础建设”。当前项目主要完成了架构设计收敛、核心协议层定义、基础工程目录搭建,以及围绕协议校验和 Mock 脚手架的测试补齐。整体进度处于“地基阶段”,核心目标是明确系统边界、数据契约及后续实现路径。
一、 架构搭建进度与情况
本周在架构侧的主要成果是完成了 CoreProtocols 的拆分与统一定义,解决了“系统内部如何用统一格式协作”的问题。
-
核心协议定义:覆盖了消息、检索、记忆、工具调用、响应、图状态等核心数据结构,并补充了最小校验函数与对应测试。这为后续接入真实检索、记忆及平台接口提供了强有力的约束基础。
-
工程骨架搭建:已建立
graph_engine与response_normalizer等关键目录。 -
客观评估:目前这些模块仍以教学型 Mock 骨架和辅助函数为主,尚不能视为 LangGraph 闭环原型已经完成。
二、 数据库与存储架构设计
本周在数据库与存储方面的进展主要集中于“方案设计与数据模型层”,真实存储开发尚未启动。
-
已定稿方案:明确采用 Qdrant + Postgres 的存储路线。
-
数据模型设计:文档层面已明确记忆系统的分域方案,以精细化管理不同维度的上下文:
-
UserMemory(用户记忆):跨频道记录单个用户的长期偏好、画像与专属事实。
-
ChannelMemory(频道记忆):记录特定 Discord / Telegram 群组的共享上下文与公共知识。
-
ThreadState(会话状态):管理当前特定对话 Thread 的短期上下文与多轮流转状态。
-
-
核心对象定义:明确了 Event(原始事件)/ Summary(对话摘要)/ Fact(提炼事实)等外存核心对象的设计方向。
-
客观评估:当前仓库尚未接入真实数据库,未完成建表、迁移、入库、检索及触发器等具体实现,
schemas/目录目前仍处于预留状态。整体处于“数据结构与存储方案已收敛,真实数据库落地尚未开始”的阶段。
三、 工程验证与质量情况
当前仓库已在 NervosBrain 环境中完成复核测试,测试结果为:
- 52 passed in 0.30s
这些测试用例主要覆盖:协议合法/非法校验、Mock 工作流结构,以及回答格式校验、引用修复、Markdown 清洗、平台切段等最小工具函数。这表明目前的代码骨架和测试集是可运行的,但并不代表项目已实现端到端的问答闭环。
四、 本周阶段性判断
综上所述,目前项目的真实完成项主要聚焦在:协议层、文档层、工程骨架层与测试基础层。
尚未完成的关键链路包括:
-
真实 LangGraph 节点能力
-
真实检索链路与记忆持久化
-
真实数据库接入
-
平台消息联调与 MCP 工具接入
五、 下周计划
考虑到整体开发与测试周期共计 10 周,为保证目标聚焦,下周计划集中推进以下 2 项核心工作:
-
LangGraph 核心逻辑推进:将 LangGraph 部分从当前的 Mock/Print 脚手架向“接近真实执行”的最小版本推进,明确并梳理出哪些节点优先落地真实逻辑,哪些节点暂时保留 Mock。
-
数据库最小实现准备:启动数据库落地前的前置工作,优先完成以下任意一项:
-
Postgres 记忆表结构设计与建表。
-
Qdrant Payload 结构定义与最小入库格式。
Here is the English translation of your weekly report, tailored for a professional engineering context.
Nervos Brain Weekly Report
This week’s work primarily focused on “engineering infrastructure.” The project has currently completed the convergence of the architecture design, defined the core protocol layer, set up the foundational engineering directory, and supplemented testing around protocol validation and Mock scaffolding. The overall progress is in the “foundation phase,” with the core objectives being to define system boundaries, data contracts, and subsequent implementation paths.
1. Architecture Setup Progress and Status
The main achievement on the architecture side this week was the separation and unified definition of CoreProtocols, which resolved the issue of “how the system collaborates internally using a unified format.”
- Core Protocol Definition: Covered core data structures such as messages, retrieval, memory, tool calls, responses, and graph states. We also supplemented this with minimum validation functions and corresponding tests. This provides a strong foundational constraint for the subsequent integration of real retrieval, memory, and platform interfaces.
- Engineering Skeleton Setup: Key directories such as
graph_engineandresponse_normalizerhave been successfully established. - Objective Assessment: Currently, these modules primarily consist of educational Mock skeletons and utility functions; they cannot yet be considered a completed, closed-loop LangGraph prototype.
2. Database and Storage Architecture Design
Progress regarding the database and storage this week mainly focused on the “solution design and data model layer.” Real storage development has not yet started.
- Finalized Solution: The storage route using Qdrant + Postgres has been definitively adopted.
- Data Model Design: At the documentation level, the domain separation scheme for the memory system has been defined to finely manage context across different dimensions. This includes UserMemory (records a single user’s long-term preferences, profile, and specific facts across channels), ChannelMemory (records shared context and public knowledge for a specific Discord/Telegram group), and ThreadState (manages the short-term context and multi-turn state of a specific, active conversation thread).
- Core Object Definition: Clarified the design direction for core external storage objects such as Event (raw event), Summary (conversation summary), and Fact (extracted fact).
- Objective Assessment: The current repository is not yet connected to a real database. Specific implementations such as table creation, data migration, ingestion, retrieval, and triggers are pending. The
schemas/directory is currently serving as a placeholder. Overall, we are at a stage where “data structures and storage solutions have converged, but real database implementation has not yet begun.”
3. Engineering Validation and Quality Status
The current repository has undergone verification testing within the NervosBrain environment. The test results are:
- 52 passed in 0.30s
These test cases primarily cover: valid/invalid protocol validation, Mock workflow structures, and minimum utility functions like response format validation, citation repair, Markdown sanitization, and platform chunking. This indicates that the current code skeleton and test suite are runnable, but it does not mean the project has achieved an end-to-end Q&A closed loop.
4. Weekly Phase Assessment
In summary, the project’s actual completed items currently focus on: the protocol layer, the documentation layer, the engineering skeleton layer, and the foundational testing layer.
Key links yet to be completed include:
- Real LangGraph node capabilities
- Real retrieval pipelines and memory persistence
- Real database integration
- Platform message integration and MCP tool integration
5. Next Week’s Plan
Given that the overall development and testing cycle is 10 weeks, to maintain a focused approach, next week’s plan will concentrate on advancing the following two core tasks:
- LangGraph Core Logic Advancement: Transition the LangGraph component from the current Mock/Print scaffolding to a minimal version that is “closer to real execution.” We will clarify and outline which nodes will prioritize real logic implementation and which will temporarily remain Mocks.
- Database Minimum Implementation Preparation: Initiate the prerequisite work for database implementation, prioritizing either Postgres memory table structure design and table creation or Qdrant Payload structure definition and minimum ingestion formatting.