fix: scope scoring bug + add prompt_score tests - #66
Closed
TerminalGravity wants to merge 1 commit into
Closed
Conversation
- Export scorePrompt for testing - Fix bug where prompts >100 chars got full scope (25/25) regardless of actual scope clarity. Now gives partial credit (20/25) with actionable feedback to add explicit scope keywords. - Add 12 tests for scorePrompt covering all four dimensions, grade boundaries, and edge cases. Tests: 43 → 55 (all passing)
TerminalGravity
commented
Mar 3, 2026
TerminalGravity
left a comment
Collaborator
Author
There was a problem hiding this comment.
Nice catch on the scope scoring — giving 25/25 to any prompt >100 chars was definitely wrong. Partial credit with actionable feedback is the right call. 12 new tests covering all four dimensions is solid coverage. Ready to merge.
This was referenced Mar 3, 2026
Collaborator
Author
|
Closing — superseded by newer PRs. |
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.
What
scorePromptgave full scope score (25/25) to any prompt >100 chars, even vague ones like "improve the performance of the application because it's slow". Now gives partial credit (20/25) with actionable feedback.scorePromptcovering all four scoring dimensions, grade boundaries, and edge cases. Test count: 43 → 55.scorePromptis now exported for direct testing.Why
Zero tool-level test coverage existed.
prompt_scoreis the most user-facing tool — scoring bugs directly mislead users about prompt quality.