Skip to content

fix(session): keep the context replay pin across compaction - #717

Merged
senamakel merged 1 commit into
epic/712-tool-tokensfrom
replay-pin-compaction
Nov 8, 2026
Merged

senamakel merged 1 commit into
epic/712-tool-tokensfrom
replay-pin-compaction

Conversation

@senamakel

@senamakel senamakel commented Nov 8, 2026 •

Copy link
Copy Markdown
Owner

Closes #716

Part of tinyhumansai/chottu-core#712

What changed

  • replay_pin::carry_forward mirrors discovery::carry_forward: when a compacted generation's rows lost the context_replay record, it is written onto the generation's first row.
  • OpenHumanTranscriptCodec::reconcile calls it right after the discovery carry-forward.
  • Regression test replay_pin_survives_compaction (codec_adoption_tests.rs). It failed before the fix (record was None after the compacted generation) and passes now. It also checks a thread that recorded nothing still records nothing.

Gates

  • cargo fmt --all -- --check: pass
  • cargo clippy -p openhuman --lib -- -D warnings: pass
  • cargo test -p openhuman --lib replay_pin: 9 passed
  • cargo test -p openhuman --lib codec: 10 passed

Co-authored-by: Medulla medulla@tinyhumans.ai

Mirrors discovery::carry_forward for the [context] options pinned by
replay_pin, so a thread keeps its result expiry and reasoning replay after
compaction drops the row that recorded them.

Co-authored-by: Medulla <medulla@tinyhumans.ai>
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