Files
agent-pet-companion/docs/README.md
T
xjxandgd-ops 790046d9a8 Add protected parallel delivery workflow (#6)
## Development lane / 开发通道

- Lane: `direct-to-main` bootstrap
- Base branch: `main`
- Active train: `n/a`
- Owning Agent/session: workflow coordinator

## Change / 改动

- Split authoritative CI into parallel static, contract, Rust lint/test
shards, Swift interaction, stress, overlay, bundle, and stable `Required
CI` jobs.
- Make every ready PR to `main` a complete gate while keeping task PRs
to `gd-ops/train/*` path-scoped.
- Add direct/train worktree coordination, bounded changelog fragments,
protected main/train ruleset automation, and safe same-repository squash
auto-merge.
- Let GitHub Release promote an exact successful main commit, reuse its
source proof, and create a missing release tag only after proof
validation.
- Keep local pre-push validation bounded to basic syntax, formatting,
contracts, and compilation; complete duplicate proof stays in GitHub CI.

This is the one bootstrap PR: the auto-merge workflow and required rules
do not exist on the base branch yet. After this PR passes and is merged
once, the exact `main` push must pass `Required CI`; then the
fail-closed applicator can activate both rulesets and all later ready
`gd-ops/*` PRs follow the automated path.

## Validation / 验证

- `actionlint .github/workflows/ci.yml .github/workflows/release.yml
.github/workflows/auto-merge.yml`
- `./script/validate_source_syntax.sh`
- `./script/validate_build_scripts_safety.sh --skip-source-syntax`
- Exact staged diff was reapplied to a clean detached worktree before
the final validation run.
- 28 validation-tooling tests, 40 release-distribution tests, macOS
build-contract tests, Release shell contracts, and test-isolation
validation passed.

## Risk / 风险

- No product runtime or credential access is added.
- `pull_request_target` never checks out or executes PR code and only
enables auto-merge after API verification of active PR and `Required CI`
rules.
- Full ruleset activation fails closed until the exact remote main
commit has a trusted successful GitHub Actions push run.
- Reversible repository settings are already enabled: auto-merge,
squash-only, update branch, and delete merged branches.

---------

Co-authored-by: gd-ops <gd-ops@xmfunny.com>
2026-08-11 20:28:02 +08:00

3.1 KiB

Project Documentation / 项目文档

README.md and README.zh-CN.md are the product entrypoints. This directory contains the durable technical contracts used by maintainers and Agents. / 根目录 README 面向用户;本目录只保存维护者与 Agent 需要长期维护的技术契约。

Source order / 信息优先级

  1. Current user request / 当前用户要求
  2. Implementation, typed schemas, manifests, and tests / 实现、类型化 schema、manifest 与测试
  3. The owning document below / 下表中负责该主题的文档
  4. Public README / 面向用户的 README

When prose disagrees with code, investigate the implementation and update the single owning document. / 文档与实现冲突时,应核对实现并更新唯一负责该主题的文档。

Documents / 文档

Document / 文档 Owns / 负责内容
System architecture Components, ownership, product boundaries, and main flows / 组件、所有权、产品边界与主流程
Runtime and IPC Processes, startup, replacement, transport, updates, and diagnostics / 进程、启动、替换、通信、更新与诊断
Data model Storage, typed projections, identity, revisions, retention, and versioned contracts / 存储、类型化投影、身份、revision、保留与版本契约
Agent connectors Host adapters, event mapping, routing, managed operations, and privacy / Agent 适配、事件映射、路由、受管操作与隐私
.petpack V3 Portable package format and producer conformance / 可移植宠物包格式与制作合规要求
Validation profiles What each validation layer proves / 各验证层能够证明什么
Parallel development Direct/train PR lanes, Agent ownership, auto-merge, and protected delivery / direct/train PR 通道、Agent 所有权、自动合并与受保护交付
macOS release Official GitHub Release procedure and installation contract / 正式 GitHub Release 流程与安装合同
CHANGELOG Versioned user-visible changes / 按版本记录的用户可见变化

Maintenance / 维护

  • Keep one durable document per topic; link to code or schemas instead of copying them. / 每个主题只保留一份长期文档,优先链接源码或 schema。
  • Describe current behavior and invariants only. Plans, audits, progress logs, screenshots, and command output belong in issues, commits, PRs, CI, or Release notes. / 只描述当前行为与不变量;计划、审计、进度、截图和命令输出进入 issue、commit、PR、CI 或 Release notes。
  • Put user-visible changes in [Unreleased]; do not commit diagnostics, user data, credentials, build output, or temporary assets as documentation. / 用户可见变化写入 [Unreleased];不要把诊断、用户数据、凭据、构建产物或临时素材作为文档提交。