Skip to content

feat(atlas): record chunk source occurrences (#3125) - #13216

Merged
dezren39 merged 3 commits into
mainfrom
code-f/3125-provenance-slice-2
Nov 23, 2026
Merged

dezren39 merged 3 commits into
mainfrom
code-f/3125-provenance-slice-2

Conversation

@dezren39

@dezren39 dezren39 commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

Summary

CREATE TABLE chunks (...)
+CREATE TABLE chunk_occurrences (chunk id, canonical hash, source, byte span, observed_at)
+promotion writes one provenance row for every promoted chunk

This is the first observable registry slice; historical occurrence backfill and CAS registry remain follow-up work.

Evidence

  • Before: cargo test -p atlas-core --test aggregate promotion_records_chunk_occurrences_for_identical_text failed: no such table: chunk_occurrences.
    After: cargo test --manifest-path pkgs/atlas-search/Cargo.toml -p atlas-core --test aggregate — 7 passed, including 32 proptest cases; duplicate content shares a canonical SHA-256 while retaining distinct source rows, and split-piece spans cover the original staged bytes. Ran on laptop at 2bcc4a9f69d.

Merge Danger

Door: two-way. The occurrence table is additive and rollback is a code revert.

Blast Radius: low — newly generated local core shards only; existing readers do not query the table.

{
  "direct_parent": null,
  "links": [],
  "lineage": {
    "design": null,
    "roadmap_item": null,
    "priority": null
  },
  "pm_meta": 1,
  "provenance": {
    "queue_id": null,
    "scheduled_start": null,
    "picked_up_at": null,
    "work_started_at": null,
    "created_at": "2026-11-23T11:04:26Z",
    "session_id": "ses_e5df82679caffeQrelOya3XMDA",
    "lane": null,
    "host": "amd",
    "worktree": "/home/user/git/code-worktrees/code-f/3125-provenance-slice-2",
    "model": null,
    "lane_start_issues": [],
    "workspace_ref": {
      "kind": "worktree",
      "id": "/home/user/git/code-worktrees/code-f/3125-provenance-slice-2",
      "repo": "developing-today/code",
      "branch": "code-f/3125-provenance-slice-2",
      "sha": "2bcc4a9f69d849bde53aba86fd4e284c11ab494f"
    },
    "auth_subject": "oc-code-01",
    "stamped_by": "fleet 0.1.0 (native)"
  }
}

Run Proof
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@coderabbitai

coderabbitai Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

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

Next included review available in 56 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5d2eb614-8086-4e17-a93c-520909e8a375
Commits

Reviewing files that changed from the base of the PR and between 52d0d4d and 2bcc4a9.

Files selected for processing: 2

  • pkgs/atlas-search/crates/atlas-core/src/aggregate.rs
  • pkgs/atlas-search/crates/atlas-core/tests/aggregate.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-23T12:58:48.952927Z 2bcc4a9 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1b15f4a2e0

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

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