GameSentenceMiner 2.14.4__py3-none-any.whl → 2.14.5__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/ai/ai_prompting.py +23 -22
- GameSentenceMiner/anki.py +8 -8
- GameSentenceMiner/config_gui.py +111 -49
- GameSentenceMiner/locales/en_us.json +1 -1
- GameSentenceMiner/obs.py +42 -5
- GameSentenceMiner/ocr/gsm_ocr_config.py +8 -2
- GameSentenceMiner/owocr/owocr/ocr.py +41 -9
- GameSentenceMiner/owocr/owocr/run.py +209 -26
- GameSentenceMiner/util/configuration.py +6 -0
- GameSentenceMiner/util/electron_config.py +2 -2
- GameSentenceMiner/web/templates/index.html +19 -19
- GameSentenceMiner/web/texthooking_page.py +30 -0
- {gamesentenceminer-2.14.4.dist-info → gamesentenceminer-2.14.5.dist-info}/METADATA +9 -4
- {gamesentenceminer-2.14.4.dist-info → gamesentenceminer-2.14.5.dist-info}/RECORD +18 -18
- {gamesentenceminer-2.14.4.dist-info → gamesentenceminer-2.14.5.dist-info}/WHEEL +0 -0
- {gamesentenceminer-2.14.4.dist-info → gamesentenceminer-2.14.5.dist-info}/entry_points.txt +0 -0
- {gamesentenceminer-2.14.4.dist-info → gamesentenceminer-2.14.5.dist-info}/licenses/LICENSE +0 -0
- {gamesentenceminer-2.14.4.dist-info → gamesentenceminer-2.14.5.dist-info}/top_level.txt +0 -0
@@ -1,4 +1,5 @@
|
|
1
1
|
import asyncio
|
2
|
+
from ctypes.util import test
|
2
3
|
import datetime
|
3
4
|
import json
|
4
5
|
import os
|
@@ -354,6 +355,35 @@ def translate_line():
|
|
354
355
|
line_to_translate.set_TL(translation)
|
355
356
|
return jsonify({'TL': translation}), 200
|
356
357
|
|
358
|
+
@app.route('/translate-multiple', methods=['POST'])
|
359
|
+
def translate_multiple():
|
360
|
+
data = request.get_json()
|
361
|
+
event_ids = data.get('ids', [])
|
362
|
+
if not event_ids:
|
363
|
+
return jsonify({'error': 'Missing ids'}), 400
|
364
|
+
|
365
|
+
lines = [get_line_by_id(event_id) for event_id in event_ids if get_line_by_id(event_id) is not None]
|
366
|
+
|
367
|
+
text = "\n".join(line.text for line in lines)
|
368
|
+
|
369
|
+
translate_multiple_lines_prompt = f"""
|
370
|
+
**Professional Game Localization Task**
|
371
|
+
Translate the following lines of game dialogue into natural-sounding, context-aware {get_config().general.get_native_language_name()}:
|
372
|
+
|
373
|
+
**Output Requirements**
|
374
|
+
- Maintain the original tone and style of the dialogue.
|
375
|
+
- Ensure that the translation is contextually appropriate for the game.
|
376
|
+
- Pay attention to character names and any specific terminology used in the game.
|
377
|
+
- Maintain Formatting and newline structure of the given lines. It should be very human readable as a dialogue.
|
378
|
+
- Do not include any notes, alternatives, explanations, or any other surrounding text. Absolutely nothing but the translated lines.
|
379
|
+
|
380
|
+
**Lines to Translate:**
|
381
|
+
"""
|
382
|
+
|
383
|
+
translation = get_ai_prompt_result(get_all_lines(), text,
|
384
|
+
lines[0], get_current_game(), custom_prompt=translate_multiple_lines_prompt)
|
385
|
+
|
386
|
+
return translation, 200
|
357
387
|
|
358
388
|
@app.route('/get_status', methods=['GET'])
|
359
389
|
def get_status():
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: GameSentenceMiner
|
3
|
-
Version: 2.14.
|
3
|
+
Version: 2.14.5
|
4
4
|
Summary: A tool for mining sentences from games. Update: Overlay?
|
5
5
|
Author-email: Beangate <bpwhelan95@gmail.com>
|
6
6
|
License: MIT License
|
@@ -23,7 +23,8 @@ Requires-Dist: rapidfuzz~=3.9.7
|
|
23
23
|
Requires-Dist: plyer~=2.1.0
|
24
24
|
Requires-Dist: keyboard~=0.13.5
|
25
25
|
Requires-Dist: websockets~=15.0.1
|
26
|
-
Requires-Dist: openai-whisper
|
26
|
+
Requires-Dist: openai-whisper==20240930; sys_platform == "win32"
|
27
|
+
Requires-Dist: openai-whisper; sys_platform != "win32"
|
27
28
|
Requires-Dist: stable-ts-whisperless
|
28
29
|
Requires-Dist: silero-vad~=5.1.2
|
29
30
|
Requires-Dist: ttkbootstrap~=1.10.1
|
@@ -35,12 +36,16 @@ Requires-Dist: pywin32; sys_platform == "win32"
|
|
35
36
|
Requires-Dist: pygetwindow; sys_platform == "win32"
|
36
37
|
Requires-Dist: flask
|
37
38
|
Requires-Dist: groq
|
38
|
-
Requires-Dist: obsws-python~=1.7.2
|
39
39
|
Requires-Dist: matplotlib
|
40
40
|
Requires-Dist: sounddevice
|
41
41
|
Requires-Dist: google-genai
|
42
42
|
Requires-Dist: owocr
|
43
|
-
Requires-Dist: betterproto==2.0.0b7
|
44
43
|
Requires-Dist: oneocr
|
45
44
|
Requires-Dist: openai
|
45
|
+
Requires-Dist: scikit-image
|
46
|
+
Requires-Dist: opencv-python
|
47
|
+
Requires-Dist: betterproto==2.0.0b7
|
48
|
+
Requires-Dist: obsws-python~=1.7.2
|
49
|
+
Requires-Dist: numpy==2.2.6
|
50
|
+
Requires-Dist: regex
|
46
51
|
Dynamic: license-file
|
@@ -1,12 +1,12 @@
|
|
1
1
|
GameSentenceMiner/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
-
GameSentenceMiner/anki.py,sha256=
|
3
|
-
GameSentenceMiner/config_gui.py,sha256=
|
2
|
+
GameSentenceMiner/anki.py,sha256=xTXCACDM_u9natCFnbqdxEX24F9bTsdoI7PoskWbdkk,23012
|
3
|
+
GameSentenceMiner/config_gui.py,sha256=dTYBe3ZI9tsOiOtT2WEMnodj3q5-U4Kj5l1l1qutlsw,137549
|
4
4
|
GameSentenceMiner/gametext.py,sha256=fgBgLchezpauWELE9Y5G3kVCLfAneD0X4lJFoI3FYbs,10351
|
5
5
|
GameSentenceMiner/gsm.py,sha256=GdqegZnKrTMVRvp43bK7oNlWj5OxLx2PNdVWyHL9Gc4,28282
|
6
|
-
GameSentenceMiner/obs.py,sha256=
|
6
|
+
GameSentenceMiner/obs.py,sha256=f1hSG7tHCJPBjY_eq6fbQnEiLtboik77Sd2YzDFD2cg,20662
|
7
7
|
GameSentenceMiner/vad.py,sha256=zFReBMvNEEaQ_YEozCTCaMdV-o40FwtlxYRb17cYZio,19125
|
8
8
|
GameSentenceMiner/ai/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
9
|
-
GameSentenceMiner/ai/ai_prompting.py,sha256=
|
9
|
+
GameSentenceMiner/ai/ai_prompting.py,sha256=D1KyHER_sj4jYvOKGRbp8FkKZSKWzAaXHbpmZLLFctg,23998
|
10
10
|
GameSentenceMiner/assets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
11
11
|
GameSentenceMiner/assets/icon.png,sha256=9GRL8uXUAgkUSlvbm9Pv9o2poFVRGdW6s2ub_DeUD9M,937624
|
12
12
|
GameSentenceMiner/assets/icon128.png,sha256=l90j7biwdz5ahwOd5wZ-406ryEV9Pan93dquJQ3e1CI,18395
|
@@ -15,11 +15,11 @@ GameSentenceMiner/assets/icon32.png,sha256=Kww0hU_qke9_22wBuO_Nq0Dv2SfnOLwMhCyGg
|
|
15
15
|
GameSentenceMiner/assets/icon512.png,sha256=HxUj2GHjyQsk8NV433256UxU9phPhtjCY-YB_7W4sqs,192487
|
16
16
|
GameSentenceMiner/assets/icon64.png,sha256=N8xgdZXvhqVQP9QUK3wX5iqxX9LxHljD7c-Bmgim6tM,9301
|
17
17
|
GameSentenceMiner/assets/pickaxe.png,sha256=VfIGyXyIZdzEnVcc4PmG3wszPMO1W4KCT7Q_nFK6eSE,1403829
|
18
|
-
GameSentenceMiner/locales/en_us.json,sha256=
|
18
|
+
GameSentenceMiner/locales/en_us.json,sha256=B3CF3VvJ1PVLP_2Xv34ZFNUVAF8SQ8qDlOD20EOOJmE,25948
|
19
19
|
GameSentenceMiner/locales/ja_jp.json,sha256=2I-aSs6KIbjJ7uNRA-dx_5oRP9JLTWWUIrMMZOkenlE,27520
|
20
20
|
GameSentenceMiner/locales/zh_cn.json,sha256=tx9Szm6KEMn_YaYDWS1ph4pGALYR3iguVru2Dfj7S3o,24047
|
21
21
|
GameSentenceMiner/ocr/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
22
|
-
GameSentenceMiner/ocr/gsm_ocr_config.py,sha256=
|
22
|
+
GameSentenceMiner/ocr/gsm_ocr_config.py,sha256=QyBarjb6Wjt-oyor1sIT9hG-KrGdi6wODLyCrHXun6E,6008
|
23
23
|
GameSentenceMiner/ocr/ocrconfig.py,sha256=_tY8mjnzHMJrLS8E5pHqYXZjMuLoGKYgJwdhYgN-ny4,6466
|
24
24
|
GameSentenceMiner/ocr/owocr_area_selector.py,sha256=Rm1_nuZotJhfOfoJ_3mesh9udtOBjYqKhnAvSief6fo,29181
|
25
25
|
GameSentenceMiner/ocr/owocr_helper.py,sha256=SkiAcyVDTQYo9Jvr0g1iy7L_xbqEL4oiovQJfz0hWnI,27874
|
@@ -28,17 +28,17 @@ GameSentenceMiner/owocr/owocr/__init__.py,sha256=87hfN5u_PbL_onLfMACbc0F5j4KyIK9
|
|
28
28
|
GameSentenceMiner/owocr/owocr/__main__.py,sha256=XQaqZY99EKoCpU-gWQjNbTs7Kg17HvBVE7JY8LqIE0o,157
|
29
29
|
GameSentenceMiner/owocr/owocr/config.py,sha256=qM7kISHdUhuygGXOxmgU6Ef2nwBShrZtdqu4InDCViE,8103
|
30
30
|
GameSentenceMiner/owocr/owocr/lens_betterproto.py,sha256=oNoISsPilVVRBBPVDtb4-roJtAhp8ZAuFTci3TGXtMc,39141
|
31
|
-
GameSentenceMiner/owocr/owocr/ocr.py,sha256=
|
32
|
-
GameSentenceMiner/owocr/owocr/run.py,sha256
|
31
|
+
GameSentenceMiner/owocr/owocr/ocr.py,sha256=oLySYDJz-OUCJTHDl6xe1BQ2NMDjaKgHc_SIHJ1Eca4,70607
|
32
|
+
GameSentenceMiner/owocr/owocr/run.py,sha256=-aRSIcwc-qIn2s-JVaAMGvzJHjvqw4LsLQKLtswEfcE,75570
|
33
33
|
GameSentenceMiner/owocr/owocr/screen_coordinate_picker.py,sha256=Na6XStbQBtpQUSdbN3QhEswtKuU1JjReFk_K8t5ezQE,3395
|
34
34
|
GameSentenceMiner/tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
35
35
|
GameSentenceMiner/tools/audio_offset_selector.py,sha256=8Stk3BP-XVIuzRv9nl9Eqd2D-1yD3JrgU-CamBywJmY,8542
|
36
36
|
GameSentenceMiner/tools/ss_selector.py,sha256=cbjMxiKOCuOfbRvLR_PCRlykBrGtm1LXd6u5czPqkmc,4793
|
37
37
|
GameSentenceMiner/tools/window_transparency.py,sha256=GtbxbmZg0-UYPXhfHff-7IKZyY2DKe4B9GdyovfmpeM,8166
|
38
38
|
GameSentenceMiner/util/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
39
|
-
GameSentenceMiner/util/configuration.py,sha256=
|
39
|
+
GameSentenceMiner/util/configuration.py,sha256=p595-YJUbmg5EwjYQlNYpjQ0m7iMIyxPSjMPEpvPfFg,40009
|
40
40
|
GameSentenceMiner/util/db.py,sha256=2bO0rD4i8A1hhsRBER-wgZy9IK17ibRbI8DHxdKvYsI,16598
|
41
|
-
GameSentenceMiner/util/electron_config.py,sha256=
|
41
|
+
GameSentenceMiner/util/electron_config.py,sha256=KfeJToeFFVw0IR5MKa-gBzpzaGrU-lyJbR9z-sDEHYU,8767
|
42
42
|
GameSentenceMiner/util/ffmpeg.py,sha256=iqsdp3TbBv6KMACJxkUF3e5VWak3jHPZdIEMrUdKFtE,23073
|
43
43
|
GameSentenceMiner/util/get_overlay_coords.py,sha256=h4ofCy16bWqs7omgPqqFi7EeYMkDO8gvePULoWTGiZE,13237
|
44
44
|
GameSentenceMiner/util/gsm_utils.py,sha256=Piwv88Q9av2LBeN7M6QDi0Mp0_R2lNbkcI6ekK5hd2o,11851
|
@@ -54,7 +54,7 @@ GameSentenceMiner/util/downloader/download_tools.py,sha256=zR-aEHiFVkyo-9oPoSx6n
|
|
54
54
|
GameSentenceMiner/util/downloader/oneocr_dl.py,sha256=l3s9Z-x1b57GX048o5h-MVv0UTZo4H-Q-zb-JREkMLI,10439
|
55
55
|
GameSentenceMiner/web/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
56
56
|
GameSentenceMiner/web/service.py,sha256=YZchmScTn7AX_GkwV1ULEK6qjdOnJcpc3qfMwDf7cUE,5363
|
57
|
-
GameSentenceMiner/web/texthooking_page.py,sha256=
|
57
|
+
GameSentenceMiner/web/texthooking_page.py,sha256=JhuApKUeQGwqGUO_92Z6yMY0_-kqHQceT4FGzhbGlGE,19269
|
58
58
|
GameSentenceMiner/web/static/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
59
59
|
GameSentenceMiner/web/static/apple-touch-icon.png,sha256=OcMI8af_68DA_tweOsQ5LytTyMwm7-hPW07IfrOVgEs,46132
|
60
60
|
GameSentenceMiner/web/static/favicon-96x96.png,sha256=lOePzjiKl1JY2J1kT_PMdyEnrlJmi5GWbmXJunM12B4,16502
|
@@ -65,13 +65,13 @@ GameSentenceMiner/web/static/style.css,sha256=bPZK0NVMuyRl5NNDuT7ZTzVLKlvSsdmeVH
|
|
65
65
|
GameSentenceMiner/web/static/web-app-manifest-192x192.png,sha256=EfSNnBmsSaLfESbkGfYwbKzcjKOdzuWo18ABADfN974,51117
|
66
66
|
GameSentenceMiner/web/static/web-app-manifest-512x512.png,sha256=wyqgCWCrLEUxSRXmaA3iJEESd-vM-ZmlTtZFBY4V8Pk,230819
|
67
67
|
GameSentenceMiner/web/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
68
|
-
GameSentenceMiner/web/templates/index.html,sha256=
|
68
|
+
GameSentenceMiner/web/templates/index.html,sha256=VrhrkQKcOAPuoWRcilFLDXjvNf6WTOY8s_Cjj3vYdWY,216505
|
69
69
|
GameSentenceMiner/web/templates/text_replacements.html,sha256=tV5c8mCaWSt_vKuUpbdbLAzXZ3ATZeDvQ9PnnAfqY0M,8598
|
70
70
|
GameSentenceMiner/web/templates/utility.html,sha256=3flZinKNqUJ7pvrZk6xu__v67z44rXnaK7UTZ303R-8,16946
|
71
71
|
GameSentenceMiner/wip/__init___.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
72
|
-
gamesentenceminer-2.14.
|
73
|
-
gamesentenceminer-2.14.
|
74
|
-
gamesentenceminer-2.14.
|
75
|
-
gamesentenceminer-2.14.
|
76
|
-
gamesentenceminer-2.14.
|
77
|
-
gamesentenceminer-2.14.
|
72
|
+
gamesentenceminer-2.14.5.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
73
|
+
gamesentenceminer-2.14.5.dist-info/METADATA,sha256=DBc75Ru8fnr9dN-TnSy0AtMotLh6nKwn2cubsyYwnOc,1760
|
74
|
+
gamesentenceminer-2.14.5.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
75
|
+
gamesentenceminer-2.14.5.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
|
76
|
+
gamesentenceminer-2.14.5.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
|
77
|
+
gamesentenceminer-2.14.5.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|