GameSentenceMiner 2.8.42__py3-none-any.whl → 2.8.44__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.
@@ -119,7 +119,10 @@ class GeminiAI(AIManager):
119
119
  try:
120
120
  prompt = self._build_prompt(lines, sentence, current_line, game_title)
121
121
  self.logger.debug(f"Generated prompt:\n{prompt}")
122
- response = self.model.generate_content(prompt)
122
+ response = self.model.generate_content(
123
+ prompt,
124
+ temperature=0.5,
125
+ )
123
126
  result = response.text.strip()
124
127
  self.logger.debug(f"Received response:\n{result}")
125
128
  return result
GameSentenceMiner/gsm.py CHANGED
@@ -1,4 +1,5 @@
1
1
  import asyncio
2
+ import sys
2
3
 
3
4
  from GameSentenceMiner.vad.result import VADResult
4
5
 
@@ -42,6 +43,7 @@ except Exception as e:
42
43
  logger.info("Something bad happened during import/initialization, closing in 5 seconds")
43
44
  logger.exception(e)
44
45
  time.sleep(5)
46
+ sys.exit(1)
45
47
 
46
48
  if is_windows():
47
49
  import win32api
@@ -2,7 +2,11 @@ import platform
2
2
 
3
3
  import requests
4
4
  from plyer import notification
5
- from win10toast import ToastNotifier
5
+
6
+ from GameSentenceMiner.util import is_windows
7
+
8
+ if is_windows():
9
+ from win10toast import ToastNotifier
6
10
 
7
11
  from GameSentenceMiner.configuration import logger
8
12
 
GameSentenceMiner/obs.py CHANGED
@@ -27,8 +27,8 @@ class OBSConnectionManager(threading.Thread):
27
27
 
28
28
  def run(self):
29
29
  while self.running:
30
- time.sleep(5)
31
- if not client.get_version():
30
+ time.sleep(1)
31
+ if not client or not client.get_version():
32
32
  logger.info("OBS WebSocket not connected. Attempting to reconnect...")
33
33
  connect_to_obs()
34
34
 
GameSentenceMiner/util.py CHANGED
@@ -11,7 +11,7 @@ from sys import platform
11
11
 
12
12
  from rapidfuzz import process
13
13
 
14
- from GameSentenceMiner.configuration import logger, get_config
14
+ from GameSentenceMiner.configuration import logger, get_config, get_app_directory
15
15
 
16
16
  SCRIPTS_DIR = r"E:\Japanese Stuff\agent-v0.1.4-win32-x64\data\scripts"
17
17
 
@@ -254,8 +254,8 @@ def do_text_replacements(text, replacements_json):
254
254
  return text
255
255
 
256
256
 
257
- TEXT_REPLACEMENTS_FILE = os.path.join(os.getenv('APPDATA'), 'GameSentenceMiner', 'config', 'text_replacements.json')
258
- OCR_REPLACEMENTS_FILE = os.path.join(os.getenv('APPDATA'), 'GameSentenceMiner', 'config', 'ocr_replacements.json')
257
+ TEXT_REPLACEMENTS_FILE = os.path.join(get_app_directory(), 'config', 'text_replacements.json')
258
+ OCR_REPLACEMENTS_FILE = os.path.join(get_app_directory(), 'config', 'ocr_replacements.json')
259
259
  os.makedirs(os.path.dirname(TEXT_REPLACEMENTS_FILE), exist_ok=True)
260
260
 
261
261
  import urllib.request
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: GameSentenceMiner
3
- Version: 2.8.42
3
+ Version: 2.8.44
4
4
  Summary: A tool for mining sentences from games. Update: Multi-Line Mining! Fixed!
5
5
  Author-email: Beangate <bpwhelan95@gmail.com>
6
6
  License: MIT License
@@ -29,7 +29,7 @@ Requires-Dist: stable-ts~=2.17.5
29
29
  Requires-Dist: silero-vad~=5.1.2
30
30
  Requires-Dist: ttkbootstrap~=1.10.1
31
31
  Requires-Dist: dataclasses_json~=0.6.7
32
- Requires-Dist: win10toast
32
+ Requires-Dist: win10toast; sys_platform == "win32"
33
33
  Requires-Dist: numpy
34
34
  Requires-Dist: pystray
35
35
  Requires-Dist: pywin32; sys_platform == "win32"
@@ -5,17 +5,17 @@ GameSentenceMiner/configuration.py,sha256=5XdL7ZBEouj6Rz8pHvWKyTmhdDNs5p6UkdNng5
5
5
  GameSentenceMiner/electron_config.py,sha256=dGcPYCISPehXubYSzsDuI2Gl092MYK0u3bTnkL9Jh1Y,9787
6
6
  GameSentenceMiner/ffmpeg.py,sha256=sf_Wz4ijFOYKRZI4qhRc32Y9E2zZuPscLv_VU8ZYCHU,18250
7
7
  GameSentenceMiner/gametext.py,sha256=hcyZQ69B7xB5ZG85wLzM5au7ZPKxmeUXsmUD26oyk_0,5660
8
- GameSentenceMiner/gsm.py,sha256=rXWuR6RfJknkwtqHLspkk1qDXKO6Tk6dJ8Nuk-i-HDA,27239
8
+ GameSentenceMiner/gsm.py,sha256=dZt2Gnwqwj-i-yRpGJWBmCBRaBjEUCzi3L3P-gcVkfA,27266
9
9
  GameSentenceMiner/model.py,sha256=1lRyJFf_LND_4O16h8CWVqDfosLgr0ZS6ufBZ3qJHpY,5699
10
- GameSentenceMiner/notification.py,sha256=FY39ChSRK0Y8TQ6lBGsLnpZUFPtFpSy2tweeXVoV7kc,2809
11
- GameSentenceMiner/obs.py,sha256=6P6sDjQ1uoFd7TsOgpJBF_nclVGtqkX32IufiEh_fco,14486
10
+ GameSentenceMiner/notification.py,sha256=vNmtZw2K-2PnYI4inY5G9nLw8LZMjY97s5Y-E08OZqM,2878
11
+ GameSentenceMiner/obs.py,sha256=a-zLd7FrfI8fBiv5IfR-3pZYwqRJI_hUElzlZauaL40,14500
12
12
  GameSentenceMiner/obs_back.py,sha256=_N_UV7Nh5cyy3mnH5lOUOzhgZwHMACeFEuBo1Z-bNzg,10894
13
13
  GameSentenceMiner/package.py,sha256=YlS6QRMuVlm6mdXx0rlXv9_3erTGS21jaP3PNNWfAH0,1250
14
14
  GameSentenceMiner/ss_selector.py,sha256=hS_p_7VljVkFDg_POsutLfXDv1hdF-NbVnQAW4X5qsQ,4441
15
15
  GameSentenceMiner/text_log.py,sha256=MD7LB5D-v4G0Bnm3uGvZQ0aV38Fcj4E0vgq7mmyQ7_4,5157
16
- GameSentenceMiner/util.py,sha256=Lvk6sjEVBGhgVkWkalXDus48BZOSSMRuxNA7n3SiBqA,9147
16
+ GameSentenceMiner/util.py,sha256=PrDNnxWiJZh1lGuwnp3DjWIlwbkVxweRTYWLtQk94Ao,9122
17
17
  GameSentenceMiner/ai/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
18
- GameSentenceMiner/ai/ai_prompting.py,sha256=O1QBgCL6AkkDyhzxZuW8FPCKgUDfkl_ZlKGcEUfbRnk,9508
18
+ GameSentenceMiner/ai/ai_prompting.py,sha256=_uWvwOg2YROVZV3MOKlx2THvAmg07ScwVyvBCtPrUzs,9572
19
19
  GameSentenceMiner/communication/__init__.py,sha256=_jGn9PJxtOAOPtJ2rI-Qu9hEHVZVpIvWlxKvqk91_zI,638
20
20
  GameSentenceMiner/communication/send.py,sha256=X0MytGv5hY-uUvkfvdCqQA_ljZFmV6UkJ6in1TA1bUE,217
21
21
  GameSentenceMiner/communication/websocket.py,sha256=pTcUe_ZZRp9REdSU4qalhPmbT_1DKa7w18j6RfFLELA,3074
@@ -54,9 +54,9 @@ GameSentenceMiner/web/static/web-app-manifest-512x512.png,sha256=wyqgCWCrLEUxSRX
54
54
  GameSentenceMiner/web/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
55
55
  GameSentenceMiner/web/templates/text_replacements.html,sha256=tV5c8mCaWSt_vKuUpbdbLAzXZ3ATZeDvQ9PnnAfqY0M,8598
56
56
  GameSentenceMiner/web/templates/utility.html,sha256=P659ZU2j7tcbJ5xPO3p7E_SQpkp3CrrFtSvvXJNNuLI,16330
57
- gamesentenceminer-2.8.42.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
58
- gamesentenceminer-2.8.42.dist-info/METADATA,sha256=iAircxCVc7FyK-fai3rpPKJK9rndmc6tzEzZO5WTKeA,7193
59
- gamesentenceminer-2.8.42.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
60
- gamesentenceminer-2.8.42.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
61
- gamesentenceminer-2.8.42.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
62
- gamesentenceminer-2.8.42.dist-info/RECORD,,
57
+ gamesentenceminer-2.8.44.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
58
+ gamesentenceminer-2.8.44.dist-info/METADATA,sha256=1MEsPlhCXRlSbYgaKoTTg9_EvknOUy-nIJIBr1NG-eg,7218
59
+ gamesentenceminer-2.8.44.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
60
+ gamesentenceminer-2.8.44.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
61
+ gamesentenceminer-2.8.44.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
62
+ gamesentenceminer-2.8.44.dist-info/RECORD,,