Project Intelligence Core
已投入使用的项目智能组合继续提供两条并行能力:端侧 Agent 直接调用远程项目工具的主链路,以及困难问题按需启动一个或多个资源侧 Subagent 的协助链路;两者互不替代。当前 12 个旧资源方法已通过同一 Resource Tool Adapter Provider 提供 Host 本地与端侧网络语义;显式配置标准模式的资源节点会协商 Server 签发的只读 Ed25519 Lease,并在节点侧验签、授权和持久审计,旧节点继续兼容。Expert/Subagent 路径把固定只读预取、Worker Task 和确定性 Cursor Agent Run 绑定到同一签名任务租约,审计引用进入 Worker/Agent Result;共用 Runtime 元数据账本又为 Worker/Agent 状态、中断识别和 Session hash 映射提供跨重启查询。固定镜像的远程资源、Expert 契约、容器网络与重启边界已有 devbox deployed-contract;端侧远程工具与两个真实 Cursor Subagent 已完成并行、续聊和单节点失败隔离 live 验收。
职责与边界
负责
- 通过网络向端侧暴露成熟的代码、文档、GitNexus、DevOps、数据库与日志工具主链路
- 让端侧 Agent 按需并行启动、续跑和汇总一个或多个资源侧 Subagent
- 识别项目与环境并维护 Project Capsule、Context Plan 和项目级持续会话
- 理解用户问题,选择和调用已授权 Resource Tool Adapter 能力
- 将复杂或长期任务冻结为 Worker Task 并申请任务级 Capability Lease
- 汇总证据、交叉验证、判断置信度并生成最终解释
不负责
- 不维护 Git Clone、文档同步、GitNexus 索引或 DevOps 缓存
- 不保存数据库账号、密码、Token、SSH Key 或证书正文
- 不在内部重复实现代码搜索、文档查询、数据库、日志和 DevOps 能力
- 不强迫端侧的每次资源查询先经过 Subagent,也不代理 Worker 的每次工具调用
- 不直接处理企业微信、飞书或 Test MCP 协议
数据与接口
拥有的数据
- 项目胶囊
- 对话级 Context Plan 与会话引用
- 能力目录的项目范围只读投影
- 证据引用与解释;不拥有资源缓存正文
输入
用户问题与渠道无关会话;项目/环境上下文;项目范围能力目录;Capability/Worker 结构化结果
输出
Project Capsule;Context Plan;Worker Task 与租约请求;项目级答案、置信度和证据引用
协议
Project Intelligence Relay;flynor/project-capsule/v1;flynor/context-plan/v1;flynor/standard-worker-task/v1alpha1(专家兼容投影);flynor/capability-result/v1alpha1(资源兼容投影)
依赖
server;protocol;capability-adapter;worker-agent-runtime
运行与部署
项目智能组 · pilot · active;升级路径:项目智能组 → 运行平台组
standalone · limited;使用独立的一服务 Release Bundle;只复用 Robot App digest,不复用 Robot Compose、数据库或其他服务。
当前仍使用独立节点环境 Schema、最小 bots.yaml、项目知识选择配置和只读项目目录挂载;目标只消费 Management 发布的项目/能力投影和 Resource/Capability Binding,不自行解析资源凭据
从同一 Robot App digest 生成一服务、无源码的独立 Release Bundle;由独立 systemd unit 监管,仅发起出站 HTTPS,不开放入站端口
归档结构 rehearsal、目标机 accept-host JSON 证据、Server 注册与 online 状态检查
轮转容器日志、结构化节点重连日志、目标机验收 JSON、Server 节点状态、请求 lane 与执行错误类型;不记录源码、提示词或 Token
原子切换独立版本目录并只重启节点 unit;按 Server Relay 兼容范围回退,索引和会话缓存可重建
项目智能标准节点
在可访问项目资源的环境中运行独立节点,通过出站 HTTPS 向 Server 提供有界项目证据
project-intelligence-node-standard · project-intelligence · docker-compose-v2 · one-node-process / outbound-https-relay / read-only-project-volumes / read-only-capability-verifier-key / persistent-capability-audit-ledger / persistent-runtime-state-ledger / local-rebuildable-indexes查看完整部署契约
前置条件
- Docker Engine 24+
- Docker Compose v2
- Flynor Server compatible relay
- read-only project/config mounts
- optional Server capability issuer plus node public-key-only verifier configuration
配置与交付物
- release/project-intelligence-runtime.manifest.json
- apps/robot/config/project-intelligence-node.env.example
- apps/robot/config/project-intelligence/bots.example.yaml
- apps/robot/config/project-intelligence/knowledge-selection.example.yaml
- apps/robot/schemas/project-intelligence-node.schema.json
健康与验收
- npm run rehearse:project-intelligence -- <release.tar.gz>
- sh bin/accept-host
- Flynor Server node status reports online
- signed mode reports signed-capability-lease and persists one allowed request while rejecting wrong scope/replay
- node check reports Runtime state ledger ready when shadow/standard is enabled
备份范围
- versioned non-secret project configuration
- append-only capability audit ledger when signed mode is enabled
- append-only Runtime state ledger when shadow/standard is enabled
- project source remains in its authoritative repositories
- local indexes and expert sessions are rebuildable
back up the capability and Runtime state ledgers, install a tested immutable Project Intelligence Release Bundle, atomically switch current, restart only its systemd unit, then verify doctor, ledger integrity and Server registration
atomically switch current to the previous protocol-compatible bundle and restart; preserve both ledgers, and let legacy versions ignore the Runtime state ledger; rebuild local indexes when required