Skip to content

docs: establish canonical product and architecture records - #25

Merged
seonghobae merged 73 commits into
mainfrom
docs/product-architecture-baseline-2026-08-09
Aug 10, 2026
Merged

docs: establish canonical product and architecture records#25
seonghobae merged 73 commits into
mainfrom
docs/product-architecture-baseline-2026-08-09

Conversation

@seonghobae

@seonghobae seonghobae commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

Purpose

Persist ThreadWeave's product, technical, architecture, safety, evidence, governance, and autonomous-maintenance decisions into one canonical, machine-checkable repository documentation graph so protected GitHub state—not chat or PR-body archaeology—can reconstruct the product.

Canonical records

DOCUMENTATION.md; PRD/TRD; root Architecture; UML; conceptual ERD; API/version contract; Security; Threat Model; Data Governance; Test Strategy; Operability; Incident Runbook; Release/Provenance/Licensing; Traceability; Documentation Audit; seven status-bearing ADRs; CLAUDE.md; CHANGELOG; and machine-checkable documentation contracts.

Sufficiency verdict

This line is DESIGN-SUFFICIENT only after its exact-head gates pass. The repository is PROTECTED-MAIN-INSUFFICIENT until this graph is integrated and re-proven on protected main. Active PR and conversation-only behavior is never promoted to shipped truth.

Protected-main reconciliation

PR base snapshot / incorporated live protected base: 4fa4caf86651193497002a3730ec19d8917f8818.

The graph incorporates:

Draft PR #20 incremental mailbox state, RFC 8474 identity handoff, payload-free snapshots, and mailbox-scale benchmark behavior remain IMPLEMENTED-ON-ACTIVE-PR / Proposed.

Current exact head

Contributor head: f9c1b504802fd402e7dd4180d68ddfaf105dd51d

The latest CodeRabbit review identified that the API contract said “exact focused and full coverage” without explicitly binding public API changes to the repository’s exact 100% owned production statement/branch gates. The branch now contains a regression contract plus the explicit normative 100% statement and 100% branch wording. Earlier inline findings remain resolved.

Current-head CI/SAST/Security were re-triggered by this correction and must complete on this unchanged head before merge. Predecessor-head success is not transferred.

Architecture boundary

ThreadWeave remains a zero-runtime-dependency, transport-neutral in-process library. It owns metadata normalization, canonical batch threading, optional subject/date policy, and pure RFC presentation. Naruon/IMAP/archive hosts own authentication, tenancy, persistence, mailbox synchronization, distributed coordination, API lifecycle, PII purpose/retention policy, and audit. The ERD is conceptual because ThreadWeave owns no persistence.

Next handoff after integration

A documentation merge is an intermediate event. After protected-main integration, re-audit the graph, close the repository-owned portion of the 0.2.0 release blocker, complete GitHub/PyPI Trusted Publisher account-side setup and public-artifact proof, then refresh Draft PR #20 onto the released protected main and reacquire exact-head Python 3.10–3.14, security, coverage/package, mailbox-scale parity/performance, and independent review evidence before any incremental-state merge.

@coderabbitai

coderabbitai Bot commented Aug 9, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@seonghobae, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 35 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 9924ded4-31f5-4971-9568-2410a8f893f2

📥 Commits

Reviewing files that changed from the base of the PR and between 73803ed and f9c1b50.

📒 Files selected for processing (11)
  • ARCHITECTURE.md
  • CHANGELOG.md
  • CLAUDE.md
  • docs/API_CONTRACT.md
  • docs/DOCUMENTATION_AUDIT.md
  • docs/INCIDENT_RUNBOOK.md
  • docs/PRD.md
  • docs/TEST_STRATEGY.md
  • docs/TRACEABILITY.md
  • docs/TRD.md
  • tests/test_architecture_documentation.py

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

ThreadWeave의 제품·기술·아키텍처 문서 기준선을 추가했습니다. 런타임과 호스트 경계, API 및 데이터 모델, 증분 처리 설계, 운영·보안·테스트 정책을 정의했습니다. 문서 색인과 계약 테스트도 추가했습니다.

Changes

ThreadWeave 문서 기준선

Layer / File(s) Summary
런타임 아키텍처와 호스트 경계
ARCHITECTURE.md, docs/API_CONTRACT.md, docs/ERD.md, docs/PRD.md, docs/TRD.md, docs/UML.md, docs/adr/0001-canonical-batch-oracle.md, docs/adr/0002-transport-neutral-core.md, docs/adr/0003-optional-subject-date-policies.md
정규화, 스레딩, 정렬, IMAP 투영, 공개 API, 데이터 모델 및 호스트 경계를 정의합니다.
증분 상태 모델
ARCHITECTURE.md, docs/ERD.md, docs/TRD.md, docs/UML.md, docs/adr/0004-incremental-state-boundary.md
PR #20의 증분 인덱스, 영향 구성요소 재구축, 델타, 스냅샷 및 상태 계약을 정의합니다.
운영·보안·변경 관리 기준
docs/OPERABILITY.md, docs/SECURITY.md, docs/THREAT_MODEL.md, docs/TEST_STRATEGY.md, docs/TRACEABILITY.md, docs/DATA_GOVERNANCE.md, docs/INCIDENT_RUNBOOK.md, docs/RELEASE_PROVENANCE.md, docs/adr/0005-automation-authority-separation.md, docs/adr/0006-work-conserving-autonomous-maintenance.md, docs/adr/0007-exact-evidence-identity.md, docs/adr/README.md
운영, 데이터 거버넌스, 보안, 사고 대응, 릴리스 증거, 자동화 권한 및 ADR 변경 규칙을 정의합니다.
문서 색인과 계약 검증
DOCUMENTATION.md, CHANGELOG.md, CLAUDE.md, docs/DOCUMENTATION_AUDIT.md, docs/TRACEABILITY.md, tests/test_architecture_documentation.py
문서 경로와 성숙도 상태를 색인화하고, 문서 구조·PR 상태·호스트 영속성 경계·릴리스 및 증거 규칙을 검증합니다.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related issues

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed 제목은 제품 및 아키텍처 문서를 정식 기록으로 정립하는 변경의 핵심을 간결하고 정확하게 설명합니다.
✨ Finishing Touches 💡 1
⚔️ Resolve merge conflicts 💡
  • Resolve merge conflict in branch docs/product-architecture-baseline-2026-08-09
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/product-architecture-baseline-2026-08-09

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 6

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@ARCHITECTURE.md`:
- Around line 103-105: Unify the sort_by_sent_date sequence_number contract
across all three documents: in ARCHITECTURE.md lines 103-105, state that missing
explicit mailbox sequence numbers use input_position only as an internal
ordering fallback, never as public IMAP sequence numbers; in docs/TRD.md lines
75-83, require uniqueness only for exact ties or revise the implementation
contract consistently; in docs/adr/0003-optional-subject-date-policies.md lines
10-12, document the explicit metadata requirement and input-position fallback
policy.

In `@docs/PRD.md`:
- Around line 66-68: Update PRD-FR-005 to state that sort_by_sent_date=True
requires every input message to provide a unique positive mailbox sequence
number, regardless of whether dates tie, matching thread_messages validation via
_validated_sequence_number(...). Keep the existing ordering, date normalization,
fallback, and historical default requirements unchanged.

In `@docs/UML.md`:
- Around line 136-147: Update the UML relationship for IdentifierResolver so it
only represents providing identifiers to the serialization flow and does not
show a rendering dependency on ThreadResponse. Remove or replace the
“IdentifierResolver --> ThreadResponse : renders” association, while preserving
the existing ThreadForest and Container relationships.

In `@tests/test_architecture_documentation.py`:
- Around line 73-75: Update the ADR-0004 assertions in the architecture
documentation test to inspect the Markdown table row containing the
“0004-incremental-state-boundary.md” link and verify that row’s final status
cell is “Proposed.” Remove the broad “Proposed” in index assertion, while
preserving the decision-level “**Status:** Proposed” check.
- Around line 64-65: Update the ERD assertions in the architecture documentation
test to verify that PR `#20`’s incremental capability is explicitly marked as
canonical active-PR/proposed or “not protected-main,” not merely present with
its persistence description. Apply the documented unprotected-main contract
while preserving the existing PR `#20` and “persists no database entities” checks.
- Around line 47-50: Update the documentation-index test around
REQUIRED_DOCUMENTS to iterate over REQUIRED_DOCUMENTS[1:] and validate each path
as an actual Markdown link target in the index, not merely as raw text. Ensure
the test covers the ADR index and all remaining canonical documents, matching
the discoverability contract described in docs/TEST_STRATEGY.md.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: e3980e2e-5dbc-4b37-b246-f3b38ddd1c84

📥 Commits

Reviewing files that changed from the base of the PR and between fb7dab5 and ea66a3f.

📒 Files selected for processing (20)
  • ARCHITECTURE.md
  • CHANGELOG.md
  • DOCUMENTATION.md
  • docs/API_CONTRACT.md
  • docs/ERD.md
  • docs/OPERABILITY.md
  • docs/PRD.md
  • docs/SECURITY.md
  • docs/TEST_STRATEGY.md
  • docs/THREAT_MODEL.md
  • docs/TRACEABILITY.md
  • docs/TRD.md
  • docs/UML.md
  • docs/adr/0001-canonical-batch-oracle.md
  • docs/adr/0002-transport-neutral-core.md
  • docs/adr/0003-optional-subject-date-policies.md
  • docs/adr/0004-incremental-state-boundary.md
  • docs/adr/0005-automation-authority-separation.md
  • docs/adr/README.md
  • tests/test_architecture_documentation.py

Comment thread ARCHITECTURE.md Outdated
Comment thread docs/PRD.md Outdated
Comment thread docs/UML.md Outdated
Comment thread tests/test_architecture_documentation.py Outdated
Comment thread tests/test_architecture_documentation.py
Comment thread tests/test_architecture_documentation.py

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
docs/API_CONTRACT.md (1)

97-100: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

100% 커버리지 기준을 계약에 명시하세요.

현재 exact focused and full test coverage 문구는 owned production statement coverage와 branch coverage의 정확한 100% 기준을 보장하지 않습니다. 공개 API 변경 게이트에 이 기준을 명시하세요.

수정 예시
- - exact focused and full test coverage;
+ - exact focused verification and full verification, including 100% owned production statement and branch coverage;

As per coding guidelines, Python 변경은 100% owned production statement and branch coverage를 유지해야 합니다.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/API_CONTRACT.md` around lines 97 - 100, Update the “Public API changes
require” section in API_CONTRACT.md to explicitly require 100% owned production
statement coverage and 100% branch coverage, while preserving the existing
focused/full test coverage and README/API synchronization requirements.

Source: Coding guidelines

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@docs/API_CONTRACT.md`:
- Around line 97-100: Update the “Public API changes require” section in
API_CONTRACT.md to explicitly require 100% owned production statement coverage
and 100% branch coverage, while preserving the existing focused/full test
coverage and README/API synchronization requirements.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: f47ff999-cb06-4b7a-964a-70eaced3f546

📥 Commits

Reviewing files that changed from the base of the PR and between 73803ed and c1dd95b.

📒 Files selected for processing (7)
  • CHANGELOG.md
  • docs/API_CONTRACT.md
  • docs/DOCUMENTATION_AUDIT.md
  • docs/INCIDENT_RUNBOOK.md
  • docs/PRD.md
  • docs/TRACEABILITY.md
  • tests/test_architecture_documentation.py
🚧 Files skipped from review as they are similar to previous changes (3)
  • docs/TRACEABILITY.md
  • CHANGELOG.md
  • docs/PRD.md

@seonghobae
seonghobae enabled auto-merge (squash) August 10, 2026 04:03

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Aug 10, 2026

Copy link
Copy Markdown
⚠️ Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@seonghobae
seonghobae dismissed stale reviews from opencode-agent[bot] and opencode-agent[bot] August 10, 2026 04:06

Superseded by later contributor heads. This review evaluated f6a7be7 and blocked on coverage/documentation evidence that has since been corrected and re-proven by exact-head CI. Dismissal is not approval; current-head independent review remains required by live policy.

@seonghobae
seonghobae merged commit fe9b46f into main Aug 10, 2026
37 checks passed
@seonghobae
seonghobae deleted the docs/product-architecture-baseline-2026-08-09 branch August 10, 2026 04:06
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