Skip to content

docs(v2): C25 DirectConnect 与上游代理 (YAO-124) - #66

Merged
luyao618 merged 3 commits into
mainfrom
agent/cc-dev/61db0157-c25
May 27, 2026
Merged

docs(v2): C25 DirectConnect 与上游代理 (YAO-124)#66
luyao618 merged 3 commits into
mainfrom
agent/cc-dev/61db0157-c25

Conversation

@luyao618

Copy link
Copy Markdown
Owner

概要

新增 C25 章节《DirectConnect 与上游代理》落地 docs/30-DirectConnect-与上游代理.md(spec §9.3.1 行 583,NN=30,承接 C24 NN=29)。把 server/(DirectConnect 三文件 358 行)和 upstreamproxy/(两文件 740 行)+ hooks/useDirectConnect.ts(229 行)放在一篇里,按「同一份 CLI 在两条对称方向上的复用」这条主线讲。

风格双亲(spec §5)

维度 参照章 体现
错误分类 + 握手/重连 + ConnectionState 状态机 v1-20 API 调用与错误恢复 §2.2 DirectConnectSessionManager、§2.3 重连闭环
工具/通道调度的对称性 v1-12 工具系统调度 §四 两条线的对称与不对称对照

保留 / 改写 / 新增统计(spec §9.3.1)

行数占比 备注
保留 0% v1 未覆盖 server/upstreamproxy/ 任何一面
改写 0% 无 v1 重叠章节可改写
新增 100% 全新对称叙事(DirectConnect ↔ UpstreamProxy)

Manifest diff 摘要

CI 闸(本地通过)

  • C-1 diff 体积:新文件 skip
  • C-2 标题保留:新文件 skip
  • C-3 源码块占比:24.9% (< 25%) ✅
  • C-4 工程化小标题:15/15 全合规 ✅
  • check-source-commits:全部指向 290fdc9481a70612bc5823aa4ed225c52c52aad3
  • no-frontmatter ✅ / no-revision-codenames ✅ / no-spec-jargon ✅
  • no-fuzzy:3 处 warning(「约」×2、「几乎」×1,均为论述性副词,不阻塞 CI,reviewer 复核)

关联

只提 PR,不要 merge,请 OC-R 走 review。

Yao Lu and others added 3 commits May 27, 2026 12:26
新增章节落地 docs/30-DirectConnect-与上游代理.md(已在 spec §9.3.1
行 583 NN=30 + scripts/check-code-ratio.ts NEW_CHAPTER_FILES 登记,
承接 C24 NN=29)。

风格双亲(spec §5):
- v1-20 API 调用与错误恢复(错误分类、握手/重连、ConnectionState 状态机)
- v1-12 工具系统调度对称性(DirectConnect 客户端 vs UpstreamProxy 服务端)

保留/改写/新增统计(spec §9.3.1):
- 保留 0(v1 未覆盖 server/ 与 upstreamproxy/ 任何一面)
- 改写 0(无 v1 重叠章节可改写)
- 新增 100%(全新对称叙事:DirectConnect 三文件 358 行 + UpstreamProxy
  两文件 740 行 + useDirectConnect 229 行)

CI 闸(本地通过):
- C-3 源码块占比 24.9% (< 25%)
- C-4 标题 15/15 全合规
- no-frontmatter 通过
- no-revision-codenames 通过
- no-spec-jargon 通过
- no-fuzzy 3 处 warning(不阻塞 CI,reviewer 复核)
- check-source-commits 全部指向 290fdc94

Co-authored-by: multica-agent <github@multica.ai>
OC-R review feedback:
- §3.2: clarify that prctl(PR_SET_DUMPABLE,0) only runs under
  Linux + Bun runtime; CCR Node path does not execute it.
- §3.5: lazy import in entrypoints/init.ts only checks
  CLAUDE_CODE_REMOTE; CCR_UPSTREAM_PROXY_ENABLED gate is inside
  initUpstreamProxy itself, not the import condition.

Co-authored-by: multica-agent <github@multica.ai>
Co-authored-by: multica-agent <github@multica.ai>
@luyao618
luyao618 merged commit ff4aa35 into main May 27, 2026
1 check passed
@luyao618
luyao618 deleted the agent/cc-dev/61db0157-c25 branch June 3, 2026 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant