Open
Conversation
Research and design for adding OpenCode session support to claude-karma. Covers data model mapping (SQLite → Pydantic), SessionSource abstraction layer, module structure, and frontend source filter/badge components. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Rewrote the design document based on actual OpenCode database analysis: - Corrected schema from 4 tables to 8 (added todo, permission, session_share, control_account) - Documented JSON blob architecture (message.data, part.data) with real examples - Expanded part types from 7 to 11 (added step-start/finish, patch, compaction, agent, retry) - Added feature parity matrix: 13 full, 7 partial, 10 Claude-Code-only, 6 OpenCode-only - Added field-level data mappings for all models - Added timeline event mapping for all 11 part types - Added SQLite metadata DB integration strategy - Resolved data_source vs session_source naming conflict - Added 5-phase implementation plan with acceptance criteria Passed Critic re-review (all 12 original gaps addressed). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add complete Router Classification table (17/17 routers classified) - Add Verified Data Gaps section with real DB findings (git branches, cost always $0, 6/12 part types exist, plan mode is message-level) - Expand Feature Parity Matrix with 7 new rows (plans, agent analytics, subagent detail, archived prompts, skills browser, live sub-statuses) - Add Derived Metrics with verified SQL formulas and NULLIF guards - Correct Timeline Event Mapping with verification status column - Update Module Structure with all 17 routers - Fix part type count (11 → 12), reconcile plans.py terminology, note SCHEMA_VERSION bump for metadata DB migration Co-Authored-By: Claude Opus 4.6 <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.
Summary
opencode.db) with 4 core tables (Session, Message, Part, Project) vs Claude Code's JSONL filesSessionSourceabstraction layer so both Claude Code and OpenCode parsers conform to a common protocolKey Design Decisions
sqlite3(read-only)opencode.dbdoesn't exist, OpenCode features silently disabledsource="claude_code"References
Test plan
opencode.dbon a machine with OpenCode installed🤖 Generated with Claude Code