feat: add value-free share disclosure preview core - #259
Open
harshitethic wants to merge 3 commits into
Open
harshitethic wants to merge 3 commits into
harshitethic wants to merge 3 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a small, dependency-free disclosure calculation layer for #252 so a future
agent-strace share SESSION --dry-runpath can report what would be exposed without printing the sensitive values themselves.New core
agent_trace.disclosure.build_disclosure_preview()reports only counts/metadata for:The preview is versioned and records either
minimizedor explicitinclude_contentmode.Privacy invariant
The preview never copies prompt text, tool payload values, command strings, paths, result text, or annotation text. The tests serialize the preview and assert representative secret values and private paths are absent.
Tests
tests/test_disclosure.pycovers:Documentation
docs/share-disclosure-preview.mddefines the trust boundary and makes clear that this PR does not yet change the currentshareoutput or claim perfect secret detection.Scope
This is a focused calculation-layer foundation for #252, not a claim to close the whole issue. Follow-up wiring can use this core for
share --dry-run, the minimized default share mode, the disclosure manifest embedded in HTML/stdout, and migration handling for existing full-content users.Validation
The implementation is stdlib-only and the tests use the existing
TraceEventmodel. I could not execute the suite locally because the connected development machine is offline; upstream CI is the verification gate for this branch.Refs #252.