feat(dictionary): bulk-add most-common-first + hnc-<band> tags #72
No reviewers
Labels
No labels
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority/Critical
Priority/High
Priority/Low
Priority/Medium
Reviewed/Confirmed
Reviewed/Duplicate
Reviewed/Invalid
Reviewed/Won't Fix
Status/Abandoned
Status/Blocked
Status/Need More Info
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
project-halkyon/halkyon-infra!72
Loading…
Reference in a new issue
No description provided.
Delete branch "refs/pull/72/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Makes
add_dictionary_vocabularyintroduce bulk-added cards most-common / most-elementary first and tag each with its frequency band.How
New-card introduction order in the app is driven solely by
cards.due_atASC (no tiebreak) — notordering, notcreated_at. Sodue_atis the only lever, staggered off a fixed far-past anchor keyed on an absolute rank/level (stable & global across separate adds):due_at = epoch + hnc_rank seconds→ rank 1 = oldest.due_at = epoch + (6 - jlpt) days→ N5 oldest … N1 newest (so adding N5+N4 makes N5 older).due_at = now()(unchanged).created_atstaysnow()(the real add time). All anchors are in the past, so cards are immediately eligible and the app's daily new-card limit introduces them in frequency order.Also emits a visible
hnc-<band>content tag (hnc-500,hnc-1000, …) — the Greek analogue ofjlpt-n*— derived fromhnc_rank(ceil to the next 500, capped at 23500), so a learner can filter/study "the most common 500 first."Only the FOR query (adds
e.hnc_rank+ frequencyORDER BY), thedue_atvalue, and the tag UNION change; everything else matches the repaired body. Same signature →CREATE OR REPLACE.Depends on
hnc_rankcolumn) + curator halkyon-curator#23 (populateshnc_rank; already backfilled on the live el entries, 24,087 ranked)Apply after #70/#71 in the SQL editor.