Skip to content

fix(classifier): prefer feature intent for ambiguous prompts#229

Open
ozymandiashh wants to merge 2 commits intogetagentseal:mainfrom
ozymandiashh:fix/activity-feature-classification
Open

fix(classifier): prefer feature intent for ambiguous prompts#229
ozymandiashh wants to merge 2 commits intogetagentseal:mainfrom
ozymandiashh:fix/activity-feature-classification

Conversation

@ozymandiashh
Copy link
Copy Markdown
Contributor

Summary

CodeBurn was over-counting normal feature work as Debugging because the classifier checked broad debug keywords before feature intent. Words like error, issue, and fix are not always bug work: users often ask agents to add error handling, create issue trackers, or adjust layout for a new feature.

This PR narrows that behavior for the specific feature-style contexts called out in #196. It keeps explicit bugs, failures, crashes, status-code errors, and broken behavior in Debugging, but lets feature construction win for ambiguous debug-like phrases.

What changed

  • Add a small feature-over-debug guard for error handling, issue tracker, and new feature contexts.
  • Apply the guard to edit-tool coding turns and conversation-only turns.
  • Preserve Debugging classification for explicit bug/failure prompts such as fix the login bug or fix the 500 error in the new feature.
  • Add regression tests for the examples discussed in Counting does not work at all #196.
  • Add an Unreleased changelog note.

Partially addresses #196.

Why this is safe

The change is limited to activity classification. It does not touch provider discovery, token parsing, pricing, session aggregation, or the separate provider-attribution/Zed gaps discussed in #196. Explicit debug signals still win when the prompt clearly describes a bug or failure.

Validation

  • npx tsc --noEmit
  • npx vitest run tests/classifier.test.ts
  • npx vitest run
  • npm run build

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant