Conversation
Extends memory_fts with thinking, artifacts, attachments, and voice_notes columns
to enable full-text search across all Claude.ai conversation content types.
## Changes
**Schema Migration (src/db.ts)**
- Add migrateFTSToV2() to extend memory_fts with sidecar columns
- Uses GROUP_CONCAT to flatten multi-row sidecar content into indexed text
- Rebuilds FTS index from existing data; idempotent on re-runs
- Updates triggers to maintain sidecar columns on message insert/delete
**Search Filtering (src/search/index.ts)**
- Add content-type filters: includeThinking, includeArtifacts, includeAttachments, includeVoiceNotes
- Thinking blocks opt-in (privacy-first); artifacts/attachments/voice default enabled
- Uses FTS5 column filter syntax {col1 col2} : query to restrict search
- Weighted BM25 scoring: title=10.0, content=5.0, sidecar=4.0, thinking=3.0, role=1.0
**CLI Flags (src/index.ts)**
- --include-thinking: opt-in for thinking block search
- --no-artifacts, --no-attachments, --no-voice-notes: opt-out from sidecar search
- Applied to both search and recall commands
**Testing (test/search.test.ts)**
- 12 new tests covering artifact/thinking/attachment/voice search
- Tests content-type filtering and filter combinations
- Verifies migration is idempotent and data intact
- Tests that thinking blocks excluded by default
## Indexing
Now searchable:
- Artifact code/documents/diagrams: 434 in claude-web sessions
- Thinking blocks: 102 (opt-in only)
- Attachments with extracted content: 34
- Voice note transcripts: 17
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Add MODEL_PRICING map for Claude model families, estimateCost() for per-turn USD estimation, wire estimated_cost_usd into upsertSessionCosts, and add deleteSidecarRows() for force re-ingest cleanup. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Thread force option through all agent ingest paths. When enabled, deletes existing sidecar rows before re-processing to refresh tool usage, costs, errors, and file operations. Adds tool correlation map for linking tool calls to their results. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
New src/insights/ module with query functions for overview dashboard, session deep-dives, project analysis, cost breakdowns, error analysis, and tool reliability metrics. Wire CLI subcommands: smriti insights [session|project|costs|errors|tools]. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
Benchmark Scorecard (ci-small)Bench Scorecard (ci-small)threshold: 20.00%
Summary: WARN (4 metrics) |
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.
Release Summary
devmaindevtomainChanges Included
Validation
devNotes