Skip to content

Match custom vocabulary cards to lesson practice - #130

Merged
pirajoke merged 1 commit into
mainfrom
codex/custom-vocabulary-card-parity
Sep 9, 2026
Merged

Match custom vocabulary cards to lesson practice#130
pirajoke merged 1 commit into
mainfrom
codex/custom-vocabulary-card-parity

Conversation

@pirajoke

@pirajoke pirajoke commented Sep 9, 2026

Copy link
Copy Markdown
Owner

What changed

  • match custom-vocabulary flashcards to the main lesson hierarchy and localized labels
  • automatically pronounce every custom word using the active language pack voice
  • advance the next custom card in the same Telegram message
  • keep deterministic SRS rating and Forvo native-pronunciation access

Verification

  • python -m unittest tests.test_custom_vocabulary_v1 (25 passed)
  • python -m unittest tests.test_learning_blocks (45 passed)
  • python -m unittest tests.test_voice_handlers (13 passed)
  • python -m unittest discover -s tests (1049 passed, 3 skipped)
  • python -m compileall -q bot.py tests/test_custom_vocabulary_v1.py
  • git diff --check

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 9, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-09T10:21:20.083843Z a156597 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@pirajoke
pirajoke merged commit 464b0f3 into main Sep 9, 2026
1 check passed

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a156597dc6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread bot.py
Comment on lines +4635 to +4636
audio = await get_audio(
target,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Make custom pronunciation artifacts erasable

When a learner practices a custom entry, get_audio writes an MP3 derived from the learner-supplied target into the persistent global DATA_DIR/audio_cache (tts.py:38-50). The cache key contains no user or entry handle, and erase_user_learning_data deletes only database rows, so /privacy can report successful deletion while audio conveying the personal vocabulary remains indefinitely and cannot be attributed for cleanup. Use nonpersistent rendering or an erasable per-user cache for custom terms.

AGENTS.md reference: AGENTS.md:L70-L74

Useful? React with 👍 / 👎.

Comment thread bot.py
Comment on lines +4579 to +4582
label = str(word.get("target") or "").strip()
if transcription:
label = f"{label} {transcription}"
return f"{flag} *{escape_markdown(label)}*"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Respect pack-specific transcription layout

For Japanese, Chinese, Russian, and Arabic custom entries with transcriptions, this always renders target transcription, although those packs declare transcription_position="before"; Arabic also needs the bidi isolation performed by _directional_text. The standard lesson renderer handles both rules in format_target_word, so these custom cards do not actually match lesson practice and mixed Arabic/transcription text can display in the wrong visual order.

Useful? React with 👍 / 👎.

@pirajoke
pirajoke deleted the codex/custom-vocabulary-card-parity branch September 9, 2026 10:28
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