Skip to content

Replace Term Confusion Pairs with Review Events - #10

Merged
ehanahamed merged 1 commit into
mainfrom
replace-confusion-pairs-with-review-events-11668912116007394987
Jun 29, 2026
Merged

Replace Term Confusion Pairs with Review Events#10
ehanahamed merged 1 commit into
mainfrom
replace-confusion-pairs-with-review-events-11668912116007394987

Conversation

@google-labs-jules

Copy link
Copy Markdown
Contributor

This change replaces the old and inaccurate "term confusion pairs" tracking with a new reviewEvents system.

Key improvements:

  • Comprehensive Tracking: Every question in a practice test now generates a ReviewEvent record, capturing whether it was correct, the question type, the answer provided (term ID or string), and the activity type.
  • Improved Logic: The logic for identifying "confused terms" is now more accurate. For MCQs, it correctly maps the selected index to the corresponding term ID. For TFQs, it distinguishes between cases where a user confused the term with a distractor versus simply getting it wrong.
  • Database Cleanup: The obsolete term_confusion_pairs table is removed, and a new migration adds the reviewEvents table.
  • API Simplification: Removed several methods (recordConfusionPairs, getTopConfusionPairs, etc.) and cleaned up term resolution logic.
  • Maintenance: Deleted the confusion_pairs.spec.ts test file as it no longer applies. Verified that existing practice test functionality remains correct through automated tests.

PR created automatically by Jules for task 11668912116007394987 started by @ehanahamed

- Remove `termConfusionPairs` table and related API methods.
- Introduce `reviewEvents` table to record detailed data for every practice test question attempt.
- Implement logic to calculate `answeredTermId` for MCQ and TFQ questions.
- Ensure `reviewEvents` are updated when a practice test question is modified.
- Clean up the codebase by removing obsolete types, methods, and tests.
- Update database schema to version 19.
@google-labs-jules

Copy link
Copy Markdown
Contributor Author

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@ehanahamed
ehanahamed merged commit b07d0de into main Jun 29, 2026
1 check failed
@ehanahamed
ehanahamed deleted the replace-confusion-pairs-with-review-events-11668912116007394987 branch June 29, 2026 21:34
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