GameSentenceMiner 2.19.6__py3-none-any.whl → 2.19.7__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- GameSentenceMiner/anki.py +12 -3
- GameSentenceMiner/locales/en_us.json +4 -0
- GameSentenceMiner/locales/ja_jp.json +4 -0
- GameSentenceMiner/locales/zh_cn.json +4 -0
- GameSentenceMiner/obs.py +153 -17
- GameSentenceMiner/ocr/owocr_area_selector.py +5 -2
- GameSentenceMiner/ocr/owocr_helper.py +66 -17
- GameSentenceMiner/owocr/owocr/run.py +5 -2
- GameSentenceMiner/ui/config_gui.py +21 -0
- GameSentenceMiner/ui/screenshot_selector.py +29 -7
- GameSentenceMiner/util/configuration.py +29 -2
- GameSentenceMiner/util/ffmpeg.py +272 -17
- GameSentenceMiner/web/gsm_websocket.py +8 -6
- GameSentenceMiner/web/templates/index.html +17 -12
- GameSentenceMiner/web/texthooking_page.py +27 -22
- {gamesentenceminer-2.19.6.dist-info → gamesentenceminer-2.19.7.dist-info}/METADATA +1 -1
- {gamesentenceminer-2.19.6.dist-info → gamesentenceminer-2.19.7.dist-info}/RECORD +21 -21
- {gamesentenceminer-2.19.6.dist-info → gamesentenceminer-2.19.7.dist-info}/WHEEL +0 -0
- {gamesentenceminer-2.19.6.dist-info → gamesentenceminer-2.19.7.dist-info}/entry_points.txt +0 -0
- {gamesentenceminer-2.19.6.dist-info → gamesentenceminer-2.19.7.dist-info}/licenses/LICENSE +0 -0
- {gamesentenceminer-2.19.6.dist-info → gamesentenceminer-2.19.7.dist-info}/top_level.txt +0 -0
|
@@ -235,19 +235,23 @@ def translate_line():
|
|
|
235
235
|
if event_id is None:
|
|
236
236
|
return jsonify({'error': 'Missing id'}), 400
|
|
237
237
|
|
|
238
|
-
|
|
239
|
-
|
|
238
|
+
|
|
239
|
+
if get_config().ai.custom_texthooker_prompt:
|
|
240
|
+
prompt = get_config().ai.custom_texthooker_prompt.strip()
|
|
241
|
+
else:
|
|
242
|
+
prompt = f"""
|
|
243
|
+
**Professional Game Localization Task**
|
|
240
244
|
|
|
241
|
-
|
|
242
|
-
|
|
245
|
+
**Task Directive:**
|
|
246
|
+
Translate ONLY the provided line of game dialogue specified below into natural-sounding, context-aware {get_config().general.get_native_language_name()}. The translation must preserve the original tone and intent of the source.
|
|
243
247
|
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
+
**Output Requirements:**
|
|
249
|
+
- Provide only the single, best {get_config().general.get_native_language_name()} translation.
|
|
250
|
+
- Use expletives if they are natural for the context and enhance the translation's impact, but do not over-exaggerate.
|
|
251
|
+
- Do not include notes, alternatives, explanations, or any other surrounding text. Absolutely nothing but the translated line.
|
|
248
252
|
|
|
249
|
-
|
|
250
|
-
|
|
253
|
+
**Line to Translate:**
|
|
254
|
+
"""
|
|
251
255
|
|
|
252
256
|
if not get_config().ai.is_configured():
|
|
253
257
|
return jsonify({'error': 'AI translation is not properly configured. Please check your settings in the "AI" Tab.'}), 400
|
|
@@ -277,19 +281,20 @@ def translate_multiple():
|
|
|
277
281
|
|
|
278
282
|
language = get_config().general.get_native_language_name() if get_config().general.native_language else "English"
|
|
279
283
|
|
|
284
|
+
|
|
280
285
|
translate_multiple_lines_prompt = f"""
|
|
281
|
-
**Professional Game Localization Task**
|
|
282
|
-
Translate the following lines of game dialogue into natural-sounding, context-aware {language}:
|
|
283
|
-
|
|
284
|
-
**Output Requirements**
|
|
285
|
-
- Maintain the original tone and style of the dialogue.
|
|
286
|
-
- Ensure that the translation is contextually appropriate for the game.
|
|
287
|
-
- Pay attention to character names and any specific terminology used in the game.
|
|
288
|
-
- Maintain Formatting and newline structure of the given lines. It should be very human readable as a dialogue.
|
|
289
|
-
- Do not include any notes, alternatives, explanations, or any other surrounding text. Absolutely nothing but the translated lines.
|
|
290
|
-
|
|
291
|
-
**Lines to Translate:**
|
|
292
|
-
"""
|
|
286
|
+
**Professional Game Localization Task**
|
|
287
|
+
Translate the following lines of game dialogue into natural-sounding, context-aware {language}:
|
|
288
|
+
|
|
289
|
+
**Output Requirements**
|
|
290
|
+
- Maintain the original tone and style of the dialogue.
|
|
291
|
+
- Ensure that the translation is contextually appropriate for the game.
|
|
292
|
+
- Pay attention to character names and any specific terminology used in the game.
|
|
293
|
+
- Maintain Formatting and newline structure of the given lines. It should be very human readable as a dialogue.
|
|
294
|
+
- Do not include any notes, alternatives, explanations, or any other surrounding text. Absolutely nothing but the translated lines.
|
|
295
|
+
|
|
296
|
+
**Lines to Translate:**
|
|
297
|
+
"""
|
|
293
298
|
|
|
294
299
|
translation = get_ai_prompt_result(get_all_lines(), text,
|
|
295
300
|
lines[0], get_current_game(), custom_prompt=translate_multiple_lines_prompt)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: GameSentenceMiner
|
|
3
|
-
Version: 2.19.
|
|
3
|
+
Version: 2.19.7
|
|
4
4
|
Summary: A tool for mining sentences from games. Update: Dependencies, replay buffer based line searching, and bug fixes.
|
|
5
5
|
Author-email: Beangate <bpwhelan95@gmail.com>
|
|
6
6
|
License: MIT License
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
GameSentenceMiner/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
GameSentenceMiner/anki.py,sha256=
|
|
2
|
+
GameSentenceMiner/anki.py,sha256=5hp5WsNp7spazjQF9rZrNzOoQ2ZPFIl2sTdU5oDSWRE,29924
|
|
3
3
|
GameSentenceMiner/gametext.py,sha256=4PPm7QSWDmvsyooVjFANkd1Vnoy5ixbGRMHfYfhwGs0,13320
|
|
4
4
|
GameSentenceMiner/gsm.py,sha256=dg41VMDLzR3U8-Xm1oHGfU2JKL8cyH-WacqY6tLrWyM,36164
|
|
5
|
-
GameSentenceMiner/obs.py,sha256=
|
|
5
|
+
GameSentenceMiner/obs.py,sha256=2EmG2mwqGBFdPvmygrOFFX1qoms4-qCbZM2tcjEdjRA,43226
|
|
6
6
|
GameSentenceMiner/vad.py,sha256=iMSsoUZ7-aNoWKzDKfOHdB3Zk5U2hV7x5hqTny6rj08,21501
|
|
7
7
|
GameSentenceMiner/ai/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
8
8
|
GameSentenceMiner/ai/ai_prompting.py,sha256=mq9Odv_FpohXagU-OoSZbLWttdrEl1M1NiqnodeUpD8,29126
|
|
@@ -14,21 +14,21 @@ GameSentenceMiner/assets/icon32.png,sha256=Kww0hU_qke9_22wBuO_Nq0Dv2SfnOLwMhCyGg
|
|
|
14
14
|
GameSentenceMiner/assets/icon512.png,sha256=HxUj2GHjyQsk8NV433256UxU9phPhtjCY-YB_7W4sqs,192487
|
|
15
15
|
GameSentenceMiner/assets/icon64.png,sha256=N8xgdZXvhqVQP9QUK3wX5iqxX9LxHljD7c-Bmgim6tM,9301
|
|
16
16
|
GameSentenceMiner/assets/pickaxe.png,sha256=VfIGyXyIZdzEnVcc4PmG3wszPMO1W4KCT7Q_nFK6eSE,1403829
|
|
17
|
-
GameSentenceMiner/locales/en_us.json,sha256=
|
|
18
|
-
GameSentenceMiner/locales/ja_jp.json,sha256=
|
|
19
|
-
GameSentenceMiner/locales/zh_cn.json,sha256=
|
|
17
|
+
GameSentenceMiner/locales/en_us.json,sha256=V79_n1GGqDXOwTnNXPtsfD0Zvs4apMJTlZGUAGjnlBs,28989
|
|
18
|
+
GameSentenceMiner/locales/ja_jp.json,sha256=N_T6VtU8la2PAefUeZN3_sM88qxBIR4SPXA7ngRV4mk,31118
|
|
19
|
+
GameSentenceMiner/locales/zh_cn.json,sha256=Dx-CbeUa2hGfRl1st1O0j-jOCnITQ87tjQYZxdSUPOE,26853
|
|
20
20
|
GameSentenceMiner/ocr/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
21
21
|
GameSentenceMiner/ocr/gsm_ocr_config.py,sha256=Ov04c-nKzh3sADxO-5JyZWVe4DlrHM9edM9tc7-97Jo,5970
|
|
22
22
|
GameSentenceMiner/ocr/ocrconfig.py,sha256=_tY8mjnzHMJrLS8E5pHqYXZjMuLoGKYgJwdhYgN-ny4,6466
|
|
23
|
-
GameSentenceMiner/ocr/owocr_area_selector.py,sha256=
|
|
24
|
-
GameSentenceMiner/ocr/owocr_helper.py,sha256=
|
|
23
|
+
GameSentenceMiner/ocr/owocr_area_selector.py,sha256=1-PlCOpam8-D4tGQVuhxeVVQc9sy5Mfyvcyqgj2Vqyw,29587
|
|
24
|
+
GameSentenceMiner/ocr/owocr_helper.py,sha256=JljPwcMLqu6KJz3Q9unKLXAVNzSwZkhvJohJ0NccW-o,36879
|
|
25
25
|
GameSentenceMiner/ocr/ss_picker.py,sha256=0IhxUdaKruFpZyBL-8SpxWg7bPrlGpy3lhTcMMZ5rwo,5224
|
|
26
26
|
GameSentenceMiner/owocr/owocr/__init__.py,sha256=87hfN5u_PbL_onLfMACbc0F5j4KyIK9lKnRCj6oZgR0,49
|
|
27
27
|
GameSentenceMiner/owocr/owocr/__main__.py,sha256=XQaqZY99EKoCpU-gWQjNbTs7Kg17HvBVE7JY8LqIE0o,157
|
|
28
28
|
GameSentenceMiner/owocr/owocr/config.py,sha256=qM7kISHdUhuygGXOxmgU6Ef2nwBShrZtdqu4InDCViE,8103
|
|
29
29
|
GameSentenceMiner/owocr/owocr/lens_betterproto.py,sha256=oNoISsPilVVRBBPVDtb4-roJtAhp8ZAuFTci3TGXtMc,39141
|
|
30
30
|
GameSentenceMiner/owocr/owocr/ocr.py,sha256=yVrLr8nNgvLRB-pPvkyhw07zkAiWrCf85SvgfQBquEk,95309
|
|
31
|
-
GameSentenceMiner/owocr/owocr/run.py,sha256=
|
|
31
|
+
GameSentenceMiner/owocr/owocr/run.py,sha256=4fyA6r4LLOJWIehwNHPfnZOb_2ebDGtS9i5bhZ3DsNo,82779
|
|
32
32
|
GameSentenceMiner/owocr/owocr/screen_coordinate_picker.py,sha256=Na6XStbQBtpQUSdbN3QhEswtKuU1JjReFk_K8t5ezQE,3395
|
|
33
33
|
GameSentenceMiner/tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
34
34
|
GameSentenceMiner/tools/audio_offset_selector.py,sha256=8Stk3BP-XVIuzRv9nl9Eqd2D-1yD3JrgU-CamBywJmY,8542
|
|
@@ -37,15 +37,15 @@ GameSentenceMiner/tools/ss_selector.py,sha256=ob2oJdiYreDMMau7CvsglpnhZ1CDnJqop3
|
|
|
37
37
|
GameSentenceMiner/tools/window_transparency.py,sha256=GtbxbmZg0-UYPXhfHff-7IKZyY2DKe4B9GdyovfmpeM,8166
|
|
38
38
|
GameSentenceMiner/ui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
39
39
|
GameSentenceMiner/ui/anki_confirmation.py,sha256=krrT3q3anTtXNTPHz5ahXSd4genEnEvS07v1JYftBFg,15174
|
|
40
|
-
GameSentenceMiner/ui/config_gui.py,sha256=
|
|
40
|
+
GameSentenceMiner/ui/config_gui.py,sha256=EpxWuwrTBKOrsg4kf9w_iT5oybhtanlFG6XtH98W9Ng,159987
|
|
41
41
|
GameSentenceMiner/ui/furigana_filter_preview.py,sha256=DAT2-j6vSDHr9ufk6PiaLikEsbIp56B_OHIEeYLMwlk,17135
|
|
42
|
-
GameSentenceMiner/ui/screenshot_selector.py,sha256=
|
|
42
|
+
GameSentenceMiner/ui/screenshot_selector.py,sha256=MnR1MZWRUeHXCFTHc5ACK3WS08f9MUK5fJ6IQEGdCEY,9127
|
|
43
43
|
GameSentenceMiner/util/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
44
44
|
GameSentenceMiner/util/audio_player.py,sha256=-yFsf0qoTSS1ga5rCmEJZJGUSJzXCvfZHY3t0NxycDk,7896
|
|
45
|
-
GameSentenceMiner/util/configuration.py,sha256=
|
|
45
|
+
GameSentenceMiner/util/configuration.py,sha256=X6AFueDXi-HabDCGf8u44Z1rPO8XR6Wal3SvGz7hcbI,48806
|
|
46
46
|
GameSentenceMiner/util/db.py,sha256=iCHUzlgOJgNjQ5-oDa7gnDWmzdlEryOzbXfn9ToQPfY,33034
|
|
47
47
|
GameSentenceMiner/util/electron_config.py,sha256=KfeJToeFFVw0IR5MKa-gBzpzaGrU-lyJbR9z-sDEHYU,8767
|
|
48
|
-
GameSentenceMiner/util/ffmpeg.py,sha256=
|
|
48
|
+
GameSentenceMiner/util/ffmpeg.py,sha256=iJAo2GUF0B4SDhG9rp-xaA94VSAc00aY1SyRRZ-i_1w,39730
|
|
49
49
|
GameSentenceMiner/util/games_table.py,sha256=VM68MAsdyE6tpdwM4bDSk67qioBOvsEO8-TpnRmUnSo,12003
|
|
50
50
|
GameSentenceMiner/util/get_overlay_coords.py,sha256=jQ0hcrEh9CfvjlBRJez3Ly-er4MjBWC2zirA-hYz5hQ,26462
|
|
51
51
|
GameSentenceMiner/util/gsm_utils.py,sha256=mASECTmN10c2yPL4NEfLg0Y0YWwFso1i6r_hhJPR3MY,10974
|
|
@@ -65,10 +65,10 @@ GameSentenceMiner/web/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3h
|
|
|
65
65
|
GameSentenceMiner/web/anki_api_endpoints.py,sha256=r30OTT3YVfgbF6aJ-EGWZLF-j2D9L63jLkRXMycU0p8,23681
|
|
66
66
|
GameSentenceMiner/web/database_api.py,sha256=wJGFwrPbB7qQMIqwg0w6hn_henFhjAUCIpwjhdUNMGU,89903
|
|
67
67
|
GameSentenceMiner/web/events.py,sha256=RJ8tIK8WUn7Fbgny23UJWrZ1SlhYzzT5p55E1uXRwDs,2747
|
|
68
|
-
GameSentenceMiner/web/gsm_websocket.py,sha256=
|
|
68
|
+
GameSentenceMiner/web/gsm_websocket.py,sha256=HpY15wHSa80qoiYt2iA8m8Ay75ED1VNs2A2PO6iSufM,4085
|
|
69
69
|
GameSentenceMiner/web/service.py,sha256=6cgUmDgtp3ZKzuPFszowjPoq-BDtC1bS3ux6sykeaqo,6662
|
|
70
70
|
GameSentenceMiner/web/stats.py,sha256=LYMhekifcQo-cbfy2--b6vycKcu8RAoTnQA4TefcS6U,29037
|
|
71
|
-
GameSentenceMiner/web/texthooking_page.py,sha256=
|
|
71
|
+
GameSentenceMiner/web/texthooking_page.py,sha256=IJNvprv3crWzYE9pWQMI30XPTkdwOdhanBgnIqAWdYQ,15283
|
|
72
72
|
GameSentenceMiner/web/static/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
73
73
|
GameSentenceMiner/web/static/apple-touch-icon.png,sha256=OcMI8af_68DA_tweOsQ5LytTyMwm7-hPW07IfrOVgEs,46132
|
|
74
74
|
GameSentenceMiner/web/static/favicon-96x96.png,sha256=lOePzjiKl1JY2J1kT_PMdyEnrlJmi5GWbmXJunM12B4,16502
|
|
@@ -98,7 +98,7 @@ GameSentenceMiner/web/static/js/stats.js,sha256=zPhkdY3RXiQrhPmZyFyh6xwOn3DxQI8J
|
|
|
98
98
|
GameSentenceMiner/web/templates/anki_stats.html,sha256=nq0vcDbJzWNggybatYECs16OsqcBvb5viyJzSOBECwQ,18238
|
|
99
99
|
GameSentenceMiner/web/templates/database.html,sha256=5SE7cSYa-ZDVLm0ykb1T11Yd4Bm_E600EWaQi2UWip8,18577
|
|
100
100
|
GameSentenceMiner/web/templates/goals.html,sha256=X5ViEeUT3YnCVM_kofCJ6A0_Wn2TVQQdmBiblZN5Gpo,20909
|
|
101
|
-
GameSentenceMiner/web/templates/index.html,sha256=
|
|
101
|
+
GameSentenceMiner/web/templates/index.html,sha256=1jlf3r1f1_QDHiiXsXXpK6aMqtDjgciLAaBo8PPSOao,232125
|
|
102
102
|
GameSentenceMiner/web/templates/overview.html,sha256=7hX1rrFhwCWHo9mH-Ia_39FSD3ACCoWTXtVUl7gc1kM,13248
|
|
103
103
|
GameSentenceMiner/web/templates/search.html,sha256=34mv69GQXBGq-TdagyZ82QpXH9JYWGOXMDbCfoGUoGI,6150
|
|
104
104
|
GameSentenceMiner/web/templates/stats.html,sha256=RJhWQ1lyOGkYWrqxJNutnJs703IVdCQhBG9Cud0CMPs,5605
|
|
@@ -135,9 +135,9 @@ GameSentenceMiner/web/templates/components/kanji_grid/thousand_character_classic
|
|
|
135
135
|
GameSentenceMiner/web/templates/components/kanji_grid/wanikani_levels.json,sha256=8wjnnaYQqmho6t5tMxrIAc03512A2tYhQh5dfsQnfAM,11372
|
|
136
136
|
GameSentenceMiner/web/templates/components/kanji_grid/words_hk_frequency_list.json,sha256=wRkqZNPzz6DT9OTPHpXwfqW96Qb96stCQNNgOL-ZdKk,17535
|
|
137
137
|
GameSentenceMiner/wip/__init___.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
138
|
-
gamesentenceminer-2.19.
|
|
139
|
-
gamesentenceminer-2.19.
|
|
140
|
-
gamesentenceminer-2.19.
|
|
141
|
-
gamesentenceminer-2.19.
|
|
142
|
-
gamesentenceminer-2.19.
|
|
143
|
-
gamesentenceminer-2.19.
|
|
138
|
+
gamesentenceminer-2.19.7.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
|
139
|
+
gamesentenceminer-2.19.7.dist-info/METADATA,sha256=4VwJO-IfwJoXUm5koY208WrLaxGofdHdesPQuUd7MUA,8180
|
|
140
|
+
gamesentenceminer-2.19.7.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
141
|
+
gamesentenceminer-2.19.7.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
|
|
142
|
+
gamesentenceminer-2.19.7.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
|
|
143
|
+
gamesentenceminer-2.19.7.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|