marcus-castalk commited on
Commit
658667d
Β·
verified Β·
1 Parent(s): 4756f49

Upload folder using huggingface_hub

Browse files
config.json ADDED
@@ -0,0 +1,54 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "Qwen2ForCausalLM"
4
+ ],
5
+ "attention_dropout": 0.0,
6
+ "bos_token_id": 151643,
7
+ "eos_token_id": 151645,
8
+ "hidden_act": "silu",
9
+ "hidden_size": 896,
10
+ "initializer_range": 0.02,
11
+ "intermediate_size": 4864,
12
+ "layer_types": [
13
+ "full_attention",
14
+ "full_attention",
15
+ "full_attention",
16
+ "full_attention",
17
+ "full_attention",
18
+ "full_attention",
19
+ "full_attention",
20
+ "full_attention",
21
+ "full_attention",
22
+ "full_attention",
23
+ "full_attention",
24
+ "full_attention",
25
+ "full_attention",
26
+ "full_attention",
27
+ "full_attention",
28
+ "full_attention",
29
+ "full_attention",
30
+ "full_attention",
31
+ "full_attention",
32
+ "full_attention",
33
+ "full_attention",
34
+ "full_attention",
35
+ "full_attention",
36
+ "full_attention"
37
+ ],
38
+ "max_position_embeddings": 32768,
39
+ "max_window_layers": 21,
40
+ "model_type": "qwen2",
41
+ "num_attention_heads": 14,
42
+ "num_hidden_layers": 24,
43
+ "num_key_value_heads": 2,
44
+ "rms_norm_eps": 1e-06,
45
+ "rope_scaling": null,
46
+ "rope_theta": 1000000.0,
47
+ "sliding_window": null,
48
+ "tie_word_embeddings": true,
49
+ "torch_dtype": "bfloat16",
50
+ "transformers_version": "4.53.1",
51
+ "use_cache": true,
52
+ "use_sliding_window": false,
53
+ "vocab_size": 151936
54
+ }
format.txt ADDED
@@ -0,0 +1 @@
 
 
1
+ prompt = f"{PROMPT}{input_text}\n### **Romaji Output**\n"
generation_config.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token_id": 151643,
3
+ "do_sample": true,
4
+ "eos_token_id": [
5
+ 151645,
6
+ 151643
7
+ ],
8
+ "pad_token_id": 151643,
9
+ "repetition_penalty": 1.1,
10
+ "temperature": 0.7,
11
+ "top_k": 20,
12
+ "top_p": 0.8,
13
+ "transformers_version": "4.53.1"
14
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:eccb85380b3a542881a1411ed94874658dc52f943ff9da0eb652b583d5bd9f2b
3
+ size 988097824
prompt_v2.md ADDED
@@ -0,0 +1,66 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Japanese to Modified Hepburn Romaji Conversion
2
+
3
+ You are an expert linguist AI specializing in the precise romanization of the Japanese language. Your task is to convert any given Japanese text into Romaji using the **Modified Hepburn system**.
4
+
5
+ You must follow a strict, two-phase process for every conversion to ensure maximum accuracy.
6
+
7
+ ---
8
+
9
+ ## **Phase 1: Convert Input Text to a Standardized Kana String**
10
+
11
+ Before romanizing, you must first process the input text into a phonetically accurate string composed only of Hiragana and Katakana.
12
+
13
+ 1. **Kanji-to-Hiragana Conversion:**
14
+ * Convert all Kanji characters and compounds (*jukugo*) into their correct Hiragana readings.
15
+ * You must use contextual analysis to select the correct `on'yomi` or `kun'yomi`.
16
+ * Pay close attention to irregular readings for compounds like `今ζ—₯` (きょう) and `ε€§δΊΊ` (おとγͺ).
17
+
18
+ 2. **Apply Phonetic Rules:**
19
+ * **Rendaku (Sequential Voicing):** Apply voicing to the initial consonant of the second element in a compound where appropriate (e.g., `手紙` becomes `てがみ`).
20
+ * **Okurigana:** Correctly read the Kanji stem based on its accompanying Hiragana endings (e.g., `ι£ŸγΉγ‚‹` is `γŸγΉγ‚‹`, not `しょくべる`).
21
+
22
+ 3. **Preserve Katakana:**
23
+ * Do **not** convert existing Katakana to Hiragana.
24
+ * Maintain all Katakana used for foreign loanwords (`コンピγƒ₯γƒΌγ‚ΏγƒΌ`), onomatopoeia (`ドキドキ`), scientific terms, or emphasis.
25
+
26
+ The result of this phase should be an intermediate, phonetically pure Kana string.
27
+
28
+ ---
29
+
30
+ ## **Phase 2: Convert the Kana String to Modified Hepburn Romaji**
31
+
32
+ Using the standardized Kana string from Phase 1, apply the following rules precisely.
33
+
34
+ 1. **Standard Romanization:** Convert each Kana character based on the standard Hepburn table (`か` -> `ka`, `し` -> `shi`, `぀` -> `tsu`, etc.).
35
+
36
+ 2. **Long Vowels (Chōonpu):**
37
+ * Use a **macron** to indicate a long vowel.
38
+ * `γŠγ†` or `おお` β†’ `ō` (e.g., `とうきょう` β†’ `Tōkyō`)
39
+ * `うう` β†’ `Ε«` (e.g., `くうき` β†’ `kΕ«ki`)
40
+ * `ええ` β†’ `Δ“` (e.g., `ええ` β†’ `Δ“`)
41
+ * The Katakana long vowel mark `γƒΌ` also indicates a macron (e.g., `γ‚»γƒΌγ‚ΏγƒΌ` β†’ `sΔ“tā`).
42
+ * **Crucial Exception:** Romanize `γˆγ„` as `ei`, not `Δ“` (e.g., `せんせい` β†’ `sensei`).
43
+
44
+ 3. **Double Consonants (Sokuon `っ`):**
45
+ * Double the consonant of the following syllable (e.g., `きって` β†’ `kitte`).
46
+ * **Exception:** When preceding `け` (chi), use `tch` (e.g., `まっけゃ` β†’ `matcha`).
47
+
48
+ 4. **The Syllabic 'n' (`γ‚“`):**
49
+ * Before consonants, it is always `n` (e.g., `しんぢん` -> `shinbun`).
50
+ * **Before vowels or the letter 'y', you MUST use an apostrophe** to separate the sounds (e.g., `γ—γ‚“γ‚ˆγ†` β†’ `shin'yō`; `かんい` β†’ `kan'i`).
51
+
52
+ 5. **Special Particle Romanization:**
53
+ * The particle `は` must be romanized as `wa`.
54
+ * The particle `へ` must be romanized as `e`.
55
+ * The particle `γ‚’` must be romanized as `o`.
56
+
57
+ 6. **To lower case:**
58
+ * Convert all text to lower case.
59
+
60
+ ---
61
+
62
+ ### **Execution Task**
63
+
64
+ Now, apply this two-phase process to the following text. Provide only the final Romaji output.
65
+
66
+ ### **Japanese Input**
trainer_state.json ADDED
The diff for this file is too large to render. See raw diff
 
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:28af7cd5804fb4411da8a541d6770cc312addee0ea1e41536a579c0c2fb330c9
3
+ size 5368