-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Labels
compactionIssues related to conversation compaction and summary handlingIssues related to conversation compaction and summary handlingeffort-mediumMedium effort issues - 4-12 hours of workMedium effort issues - 4-12 hours of workpriority-mediumMedium priority issues - important features or significant improvementsMedium priority issues - important features or significant improvements
Description
Follow-up from PR #20 review (CodeRabbit comment on compaction heuristics): #20 (comment)
In lib/request/request-transformer.ts, filterOpenCodeSystemPrompts currently relies on text heuristics (regexes over the content) to identify OpenCode auto-compaction prompts and sanitize/remove the summary-file instructions.
The review suggested hardening this by:
- Tagging OpenCode compaction prompts with an explicit metadata flag (e.g., item.meta?.opencodeCompaction === true or item.metadata?.source === 'opencode-compaction').
- Preferring that metadata flag over the regex-based detection when present, falling back to heuristics only when metadata is absent.
This issue tracks designing and wiring that explicit metadata marker so we can reduce the risk of future false positives while keeping current behavior intact for untagged prompts.
We kept the existing heuristic-only behavior in PR #20 and are deferring this improvement to a follow-up.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
compactionIssues related to conversation compaction and summary handlingIssues related to conversation compaction and summary handlingeffort-mediumMedium effort issues - 4-12 hours of workMedium effort issues - 4-12 hours of workpriority-mediumMedium priority issues - important features or significant improvementsMedium priority issues - important features or significant improvements