feat: fidelis sessions — searchable, purge-able session memory#2
Open
roli-lpci wants to merge 6 commits into
Open
feat: fidelis sessions — searchable, purge-able session memory#2roli-lpci wants to merge 6 commits into
roli-lpci wants to merge 6 commits into
Conversation
…y-list
MVP-A: searchable, purge-able Claude Code session memory.
- fidelis sessions {ingest,search,list,purge,stats} wrapping existing
query_sessions() + ingest(); ~80 lines new surface, no new deps.
- purge (the CTO blocker): index-only deletion, never touches source
~/.claude/projects or ~/Backups/claude-sessions; logs to purge_log.jsonl;
default-N confirm; collects ingest_hash for ledger cleanup.
- ingest deny-list (FIDELIS_SESSIONS_EXCLUDE / exclude=) — honest pre-ingest
privacy lever; chmod 700 ~/.cogito defensively.
- honesty: no retrieval-benchmark numbers in product strings (gate-tested).
- 11 new pure-logic gate tests (no services needed); full suite 111 passed.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Honesty/polish fix from CLEAN-bar review: the dry-run/confirm summary now reports the date span of the sessions that WILL be deleted, not the entire corpus span. Regression-guarded by a new test. Full suite 111 passed. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Caught by local CI simulation before push — ruff F401 would have failed CI. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sub-agent authored, verified against real --help (no invented flags), honesty rules enforced (no benchmark numbers, purge boundary stated, deny-list documented). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…X, deny-list discoverability From simulated user-interview panel (FIX-FIRST verdict): - SECURITY.md + README privacy block: honest plaintext-at-rest disclosure (chmod 700 + FileVault, purge=index-only, deny-list lever). Facts verified in code. - ingest prints 'Indexing N sessions…' before the loop (no silent-hang on large history). - first-run nudge to --all when default 7-day window would miss older history. - FIDELIS_SESSIONS_EXCLUDE documented in 'sessions ingest --help' epilog. - 6 new tests lock the first-run/count behavior. Suite: 118 passed. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Each user picks their own privacy posture once (env FIDELIS_SESSIONS_MODE or ~/.cogito/config.json sessions_mode; default opt-out, behavior-preserving): - opt-out: index all except FIDELIS_SESSIONS_EXCLUDE deny-list (existing behavior) - opt-in: index nothing except FIDELIS_SESSIONS_INCLUDE allow-list - opt-in + empty allow-list: prints onboarding guidance, indexes nothing (no silent no-op) Mirrors the existing exclude mechanism; touches only ingest logic + help/docs + tests. purge/search/list/stats untouched. 17 new tests; suite 135 passed; ruff clean. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
fidelis sessions — searchable, purge-able Claude Code session memory
Claude Code deletes sessions after 30 days. fidelis can now keep them locally and make them searchable.
Commands
fidelis sessions search <query>— find past conversations (best on multi-turn queries)fidelis sessions list/stats— browse + summarize indexed sessionsfidelis sessions ingest— index sessions (default: last 7 days;--allfor full history)fidelis sessions purge— delete from the search index (NEVER touches ~/.claude/projects or backups)Privacy posture (user-chosen)
FIDELIS_SESSIONS_MODE=opt-in|opt-out(default opt-out). opt-in indexes onlyFIDELIS_SESSIONS_INCLUDEprojects; opt-out indexes all exceptFIDELIS_SESSIONS_EXCLUDE.Verification
pip installexposes the command; purge is index-only and audited.