From 6e6c44156a58c7d9acdcf3dd9ecc2a464c5363d4 Mon Sep 17 00:00:00 2001 From: kuuuube Date: Fri, 2 Feb 2024 23:53:45 -0500 Subject: [PATCH 1/4] Add documentation for new frequency handlebars --- docs/anki-integration.md | 8 ++++++++ ext/settings.html | 30 ++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) diff --git a/docs/anki-integration.md b/docs/anki-integration.md index 151137d479..41860fa50c 100644 --- a/docs/anki-integration.md +++ b/docs/anki-integration.md @@ -36,6 +36,10 @@ Flashcard fields can be configured with the following steps: | `{document-title}` | Title of the web page that the term appeared in. | | `{expression}` | Term expressed as kanji (will be displayed in kana if kanji is not available). | | `{frequencies}` | Frequency information for the term. | + | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current term. Defaults to 9999999 when no frequency is found. | + | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current term. Defaults to 0 when no frequency is found. | + | `{frequency-average-rank}` | The average of frequency data for the current term. Defaults to 9999999 when no frequency is found. | + | `{frequency-average-occurrence}` | The average of frequency data for the current term. Defaults to 0 when no frequency is found. | | `{furigana}` | Term expressed as kanji with furigana displayed above it (e.g. 日本語にほんご). | | `{furigana-plain}` | Term expressed as kanji with furigana displayed next to it in brackets (e.g. 日本語[にほんご]). | | `{glossary}` | List of definitions for the term (output format depends on whether running in _grouped_ mode). | @@ -67,6 +71,10 @@ Flashcard fields can be configured with the following steps: | `{dictionary}` | Name of the dictionary from which the card is being created. | | `{document-title}` | Title of the web page that the kanji appeared in. | | `{frequencies}` | Frequency information for the kanji. | + | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current kanji. Defaults to 9999999 when no frequency is found. | + | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current kanji. Defaults to 0 when no frequency is found. | + | `{frequency-average-rank}` | The average of frequency data for the current kanji. Defaults to 9999999 when no frequency is found. | + | `{frequency-average-occurrence}` | The average of frequency data for the current kanji. Defaults to 0 when no frequency is found. | | `{glossary}` | List of definitions for the kanji. | | `{kunyomi}` | Kunyomi (Japanese reading) for the kanji expressed as katakana. | | `{onyomi}` | Onyomi (Chinese reading) for the kanji expressed as hiragana. | diff --git a/ext/settings.html b/ext/settings.html index f59041db36..fff6d62b82 100644 --- a/ext/settings.html +++ b/ext/settings.html @@ -3394,6 +3394,36 @@

Yomitan Settings

{document-title} Title of the web page that the term or kanji appeared in. + + {frequencies} + + Frequency information for the term or kanji. + + + + {frequency-harmonic-rank} + + The harmonic mean of frequency data for the current term or kanji. Defaults to 9999999 when no frequency is found. + + + + {frequency-harmonic-occurrence} + + The harmonic mean of frequency data for the current term or kanji. Defaults to 0 when no frequency is found. + + + + {frequency-average-rank} + + The average of frequency data for the current term or kanji. Defaults to 9999999 when no frequency is found. + + + + {frequency-average-occurrence} + + The average of frequency data for the current term or kanji. Defaults to 0 when no frequency is found. + + {screenshot} Screenshot of the web page taken at the time the term or kanji was added. From a3aabd652efeed5db33c45bff00b424cb3e14c29 Mon Sep 17 00:00:00 2001 From: kuuuube Date: Sat, 3 Feb 2024 00:13:25 -0500 Subject: [PATCH 2/4] Roughly mark default meanings --- docs/anki-integration.md | 16 ++++++++-------- ext/settings.html | 8 ++++---- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/docs/anki-integration.md b/docs/anki-integration.md index 41860fa50c..21c01c8092 100644 --- a/docs/anki-integration.md +++ b/docs/anki-integration.md @@ -36,10 +36,10 @@ Flashcard fields can be configured with the following steps: | `{document-title}` | Title of the web page that the term appeared in. | | `{expression}` | Term expressed as kanji (will be displayed in kana if kanji is not available). | | `{frequencies}` | Frequency information for the term. | - | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current term. Defaults to 9999999 when no frequency is found. | - | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current term. Defaults to 0 when no frequency is found. | - | `{frequency-average-rank}` | The average of frequency data for the current term. Defaults to 9999999 when no frequency is found. | - | `{frequency-average-occurrence}` | The average of frequency data for the current term. Defaults to 0 when no frequency is found. | + | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current term. Defaults to rank 9999999 when no frequency is found. | + | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current term. Defaults to 0 occurrences when no frequency is found. | + | `{frequency-average-rank}` | The average of frequency data for the current term. Defaults to rank 9999999 when no frequency is found. | + | `{frequency-average-occurrence}` | The average of frequency data for the current term. Defaults to 0 occurrences when no frequency is found. | | `{furigana}` | Term expressed as kanji with furigana displayed above it (e.g. 日本語にほんご). | | `{furigana-plain}` | Term expressed as kanji with furigana displayed next to it in brackets (e.g. 日本語[にほんご]). | | `{glossary}` | List of definitions for the term (output format depends on whether running in _grouped_ mode). | @@ -71,10 +71,10 @@ Flashcard fields can be configured with the following steps: | `{dictionary}` | Name of the dictionary from which the card is being created. | | `{document-title}` | Title of the web page that the kanji appeared in. | | `{frequencies}` | Frequency information for the kanji. | - | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current kanji. Defaults to 9999999 when no frequency is found. | - | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current kanji. Defaults to 0 when no frequency is found. | - | `{frequency-average-rank}` | The average of frequency data for the current kanji. Defaults to 9999999 when no frequency is found. | - | `{frequency-average-occurrence}` | The average of frequency data for the current kanji. Defaults to 0 when no frequency is found. | + | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current kanji. Defaults to rank 9999999 when no frequency is found. | + | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current kanji. Defaults to 0 occurrences when no frequency is found. | + | `{frequency-average-rank}` | The average of frequency data for the current kanji. Defaults to rank 9999999 when no frequency is found. | + | `{frequency-average-occurrence}` | The average of frequency data for the current kanji. Defaults to 0 occurrences when no frequency is found. | | `{glossary}` | List of definitions for the kanji. | | `{kunyomi}` | Kunyomi (Japanese reading) for the kanji expressed as katakana. | | `{onyomi}` | Onyomi (Chinese reading) for the kanji expressed as hiragana. | diff --git a/ext/settings.html b/ext/settings.html index fff6d62b82..ecebdb6c95 100644 --- a/ext/settings.html +++ b/ext/settings.html @@ -3403,25 +3403,25 @@

Yomitan Settings

{frequency-harmonic-rank} - The harmonic mean of frequency data for the current term or kanji. Defaults to 9999999 when no frequency is found. + The harmonic mean of frequency data for the current term or kanji. Defaults to rank 9999999 when no frequency is found. {frequency-harmonic-occurrence} - The harmonic mean of frequency data for the current term or kanji. Defaults to 0 when no frequency is found. + The harmonic mean of frequency data for the current term or kanji. Defaults to 0 occurrences when no frequency is found. {frequency-average-rank} - The average of frequency data for the current term or kanji. Defaults to 9999999 when no frequency is found. + The average of frequency data for the current term or kanji. Defaults to rank 9999999 when no frequency is found. {frequency-average-occurrence} - The average of frequency data for the current term or kanji. Defaults to 0 when no frequency is found. + The average of frequency data for the current term or kanji. Defaults to 0 occurrences when no frequency is found. From 9c58e8b5d93179d61cbfc89c0baf4b2d73ab8ba1 Mon Sep 17 00:00:00 2001 From: kuuuube Date: Sat, 3 Feb 2024 15:19:00 -0500 Subject: [PATCH 3/4] Reword explanations --- ext/settings.html | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/ext/settings.html b/ext/settings.html index ecebdb6c95..e156140940 100644 --- a/ext/settings.html +++ b/ext/settings.html @@ -3403,25 +3403,29 @@

Yomitan Settings

{frequency-harmonic-rank} - The harmonic mean of frequency data for the current term or kanji. Defaults to rank 9999999 when no frequency is found. + The harmonic mean of frequency data for the current term or kanji.
+ Defaults to rank 9999999 when frequency data is not found, indicating extremely low rank-based term or kanji usage. {frequency-harmonic-occurrence} - The harmonic mean of frequency data for the current term or kanji. Defaults to 0 occurrences when no frequency is found. + The harmonic mean of frequency data for the current term or kanji.
+ Defaults to 0 occurrences when frequency data is not found, the lowest possible occurrence-based term or kanji usage. {frequency-average-rank} - The average of frequency data for the current term or kanji. Defaults to rank 9999999 when no frequency is found. + The average of frequency data for the current term or kanji.
+ Defaults to rank 9999999 when frequency data is not found, indicating extremely low rank-based term or kanji usage. {frequency-average-occurrence} - The average of frequency data for the current term or kanji. Defaults to 0 occurrences when no frequency is found. + The average of frequency data for the current term or kanji.
+ Defaults to 0 occurrences when frequency data is not found, the lowest possible occurrence-based term or kanji usage. From cb40faaa134a08ee966315246bb5803830aa1c83 Mon Sep 17 00:00:00 2001 From: kuuuube Date: Sat, 3 Feb 2024 15:21:56 -0500 Subject: [PATCH 4/4] Reword explanation in other docs --- docs/anki-integration.md | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/docs/anki-integration.md b/docs/anki-integration.md index 21c01c8092..411e210984 100644 --- a/docs/anki-integration.md +++ b/docs/anki-integration.md @@ -36,10 +36,10 @@ Flashcard fields can be configured with the following steps: | `{document-title}` | Title of the web page that the term appeared in. | | `{expression}` | Term expressed as kanji (will be displayed in kana if kanji is not available). | | `{frequencies}` | Frequency information for the term. | - | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current term. Defaults to rank 9999999 when no frequency is found. | - | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current term. Defaults to 0 occurrences when no frequency is found. | - | `{frequency-average-rank}` | The average of frequency data for the current term. Defaults to rank 9999999 when no frequency is found. | - | `{frequency-average-occurrence}` | The average of frequency data for the current term. Defaults to 0 occurrences when no frequency is found. | + | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current term. Defaults to rank 9999999 when frequency data is not found, indicating extremely low rank-based term usage. | + | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current term. Defaults to 0 occurrences when frequency data is not found, the lowest possible occurrence-based term usage. | + | `{frequency-average-rank}` | The average of frequency data for the current term. Defaults to rank 9999999 when frequency data is not found, indicating extremely low rank-based term usage. | + | `{frequency-average-occurrence}` | The average of frequency data for the current term. Defaults to 0 occurrences when frequency data is not found, the lowest possible occurrence-based term usage. | | `{furigana}` | Term expressed as kanji with furigana displayed above it (e.g. 日本語にほんご). | | `{furigana-plain}` | Term expressed as kanji with furigana displayed next to it in brackets (e.g. 日本語[にほんご]). | | `{glossary}` | List of definitions for the term (output format depends on whether running in _grouped_ mode). | @@ -71,10 +71,10 @@ Flashcard fields can be configured with the following steps: | `{dictionary}` | Name of the dictionary from which the card is being created. | | `{document-title}` | Title of the web page that the kanji appeared in. | | `{frequencies}` | Frequency information for the kanji. | - | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current kanji. Defaults to rank 9999999 when no frequency is found. | - | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current kanji. Defaults to 0 occurrences when no frequency is found. | - | `{frequency-average-rank}` | The average of frequency data for the current kanji. Defaults to rank 9999999 when no frequency is found. | - | `{frequency-average-occurrence}` | The average of frequency data for the current kanji. Defaults to 0 occurrences when no frequency is found. | + | `{frequency-harmonic-rank}` | The harmonic mean of frequency data for the current kanji. Defaults to rank 9999999 when frequency data is not found, indicating extremely low rank-based kanji usage. | + | `{frequency-harmonic-occurrence}` | The harmonic mean of frequency data for the current kanji. Defaults to 0 occurrences when frequency data is not found, the lowest possible occurrence-based kanji usage. | + | `{frequency-average-rank}` | The average of frequency data for the current kanji. Defaults to rank 9999999 when frequency data is not found, indicating extremely low rank-based kanji usage. | + | `{frequency-average-occurrence}` | The average of frequency data for the current kanji. Defaults to 0 occurrences when frequency data is not found, the lowest possible occurrence-based kanji usage. | | `{glossary}` | List of definitions for the kanji. | | `{kunyomi}` | Kunyomi (Japanese reading) for the kanji expressed as katakana. | | `{onyomi}` | Onyomi (Chinese reading) for the kanji expressed as hiragana. |