Skip to content

fix: preserve unknown insight materializer provenance - #5993

Merged
Sinity merged 1 commit into
masterfrom
codex/insight-provenance-unknown
Oct 5, 2026
Merged

Sinity merged 1 commit into
masterfrom
codex/insight-provenance-unknown

Conversation

@Sinity

@Sinity Sinity commented Oct 5, 2026

Copy link
Copy Markdown
Owner

Summary

Return unknown provenance when a public insight has no materialized session profile.

Problem

Original 42.F007 (polylogue-5gj19; #4649 (comment)) identified reads that stamped the current materializer version despite a missing profile. Available thread and latency rows consequently claimed a version without recorded evidence.

Solution

Make public materializer, inference, and enrichment versions nullable and advance the archive insight contract to 12. The shared missing-profile projection returns unknown; recorded versions remain unchanged. Profile reads retain their existing absence contract. Query-time projection versions remain independently meaningful. Update the generated rigor matrix and read-path documentation.

Verification

agentctl job start polylogue pytest_focused --workspace <isolated checkout> -- tests/unit/storage/test_insight_provenance.py tests/unit/insights/test_projection_contracts.py tests/unit/insights/test_rigor_audit.py tests/unit/insights/test_archive_rollups.py tests/unit/insights/test_session_analytics.py tests/unit/mcp/test_insight_projection_derivation.py — job 9109, 99/99 passed; receipt 20261005T035808Z-focused-test-2135751-7acb504a.

agentctl job start polylogue verify_quick --workspace <isolated checkout> — job 9110, all 12 gates passed; receipt 20261005T035825Z-quick-2137920-6ece2de9. Scoped Ruff, diff whitespace check and schema closure inspection passed.

Self-review

Reviewed the coherent DTO, canonical producer, public serialization, schema, registry, audit, render, export, and recorded-profile consumers. Nullable versions propagate through the shared inference/enrichment copies; stored record versions remain integers. Dynamic Pydantic schemas own these insight shapes; the generated CLI schema catalog does not contain these models. The existing rigor audit skips absent observed versions. Both changed production files are in the derived schema closure, so they must land before reconvergence; no archive operation was executed. Public-route controls distinguish recorded version 3 from absent evidence and retain available thread/latency rows and missing profile behavior.

Residuals

This change qualifies recorded version provenance, not whole-archive freshness. The original work-event insight was explicitly retired in dafcfc6; it is not resurrected. The broader polylogue-5gj19 group remains open, and the unrelated uncalled F022 predecessor is outside this delivery. Original failed test/static receipts are retained: 9106 (98/99, fixture alias corrected using canonical native_session_id) and 9107 (unused import and generated matrix drift corrected).

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for security reviews. Please try again later.

@Sinity
Sinity enabled auto-merge (squash) October 5, 2026 04:01
@Sinity
Sinity merged commit 17569e6 into master Oct 5, 2026
3 checks passed
@Sinity
Sinity deleted the codex/insight-provenance-unknown branch October 5, 2026 04:04
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