supervertaler 1.9.205__py3-none-any.whl → 1.9.206__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.

Potentially problematic release.


This version of supervertaler might be problematic. Click here for more details.

@@ -3326,8 +3326,26 @@ If the text refers to figures (e.g., 'Figure 1A'), relevant images may be provid
3326
3326
 
3327
3327
  # Build context
3328
3328
  context = self._build_project_context()
3329
-
3330
- # Create analysis prompt
3329
+
3330
+ # Get actual project values for pre-filling the template
3331
+ source_lang = "Source Language"
3332
+ target_lang = "Target Language"
3333
+ segment_count = 0
3334
+
3335
+ if hasattr(self.parent_app, 'current_project') and self.parent_app.current_project:
3336
+ project = self.parent_app.current_project
3337
+ if hasattr(project, 'source_lang') and project.source_lang:
3338
+ source_lang = project.source_lang
3339
+ elif hasattr(project, 'source_language') and project.source_language:
3340
+ source_lang = project.source_language
3341
+ if hasattr(project, 'target_lang') and project.target_lang:
3342
+ target_lang = project.target_lang
3343
+ elif hasattr(project, 'target_language') and project.target_language:
3344
+ target_lang = project.target_language
3345
+ if hasattr(project, 'segments') and project.segments:
3346
+ segment_count = len(project.segments)
3347
+
3348
+ # Create analysis prompt with pre-filled values
3331
3349
  analysis_prompt = f"""Create a comprehensive translation prompt for this project and save it using the ACTION system.
3332
3350
 
3333
3351
  PROJECT CONTEXT:
@@ -3337,6 +3355,8 @@ PROJECT CONTEXT:
3337
3355
  1. You MUST output exactly ONE ACTION block in the following format
3338
3356
  2. The JSON MUST be valid and complete
3339
3357
  3. Both "name" and "content" are REQUIRED fields
3358
+ 4. Use the ACTUAL language pair: {source_lang} → {target_lang} (DO NOT use placeholders like [Source Language])
3359
+ 5. Fill in ALL terminology with actual translations for {target_lang} (DO NOT leave [Translation] placeholders)
3340
3360
 
3341
3361
  **EXACT FORMAT TO USE:**
3342
3362
 
@@ -3348,19 +3368,19 @@ ACTION:create_prompt PARAMS:{{"name": "Legal Translation EN-NL", "content": "You
3348
3368
  Prompt must include:
3349
3369
 
3350
3370
  # ROLE & EXPERTISE
3351
- You are an expert [domain] translator ([source][target]) with 10+ years experience.
3371
+ You are an expert [domain] translator ({source_lang}{target_lang}) with 10+ years experience.
3352
3372
 
3353
3373
  # DOCUMENT CONTEXT
3354
- **Type:** [type]
3355
- **Domain:** [domain]
3356
- **Language pair:** [source][target]
3357
- **Content:** [brief description]
3358
- **Number of segments:** [count]
3374
+ **Type:** [analyze and determine type]
3375
+ **Domain:** [analyze and determine domain]
3376
+ **Language pair:** {source_lang}{target_lang}
3377
+ **Content:** [brief description based on analysis]
3378
+ **Number of segments:** {segment_count}
3359
3379
 
3360
3380
  # KEY TERMINOLOGY
3361
- | [Source] | [Target] | Notes |
3381
+ | {source_lang} | {target_lang} | Notes |
3362
3382
  |----------|----------|-------|
3363
- [Extract 20+ key terms from termbases/document]
3383
+ [Extract 20+ key terms from termbases/document - FILL IN ACTUAL TRANSLATIONS, not placeholders]
3364
3384
 
3365
3385
  # TRANSLATION CONSTRAINTS
3366
3386
  **MUST:**
@@ -3374,7 +3394,7 @@ You are an expert [domain] translator ([source] → [target]) with 10+ years exp
3374
3394
  - Modify formatting, tags, numbering, brackets, or spacing
3375
3395
  - Merge or split segments
3376
3396
 
3377
- **CRITICAL:** Based on the language pair, include appropriate format localization rules:
3397
+ **CRITICAL:** Based on the language pair ({source_lang} → {target_lang}), include appropriate format localization rules:
3378
3398
 
3379
3399
  ### NUMBERS, DATES & LOCALISATION
3380
3400
  - If translating FROM Dutch/French/German/Spanish/Italian TO English: Include number format conversion (comma decimal → period decimal, e.g., 718.592,01 → 718,592.01)
@@ -3390,6 +3410,8 @@ You are an expert [domain] translator ([source] → [target]) with 10+ years exp
3390
3410
  # OUTPUT FORMAT
3391
3411
  Provide ONLY the translation, one segment per line, aligned 1:1 with the source lines.
3392
3412
 
3413
+ IMPORTANT: Do NOT use placeholders like [Source Language], [Target Language], or [Translation] in your output. Use the actual values: {source_lang} and {target_lang}.
3414
+
3393
3415
  Output complete ACTION."""
3394
3416
 
3395
3417
  # Send to AI (in thread to avoid blocking UI)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: supervertaler
3
- Version: 1.9.205
3
+ Version: 1.9.206
4
4
  Summary: Professional AI-enhanced translation workbench with multi-LLM support, glossary system, TM, spellcheck, voice commands, and PyQt6 interface. Batteries included (core).
5
5
  Home-page: https://supervertaler.com
6
6
  Author: Michael Beijer
@@ -76,13 +76,13 @@ modules/translation_memory.py,sha256=LnG8csZNL2GTHXT4zk0uecJEtvRc-MKwv7Pt7EX3s7s
76
76
  modules/translation_results_panel.py,sha256=HbYYjvRNqaJrJNLYLX-YanamMm6aRdLzLjn5rWIfk3U,92198
77
77
  modules/translation_services.py,sha256=lyVpWuZK1wtVtYZMDMdLoq1DHBoSaeAnp-Yejb0TlVQ,10530
78
78
  modules/unified_prompt_library.py,sha256=96u4WlMwnmmhD4uNJHZ-qVQj8v9_8dA2AVCWpBcwTrg,26006
79
- modules/unified_prompt_manager_qt.py,sha256=L96tgYpSLI0ZjD-R8eyxbwNYo_Vi1fyREFYriAR-Vlo,181992
79
+ modules/unified_prompt_manager_qt.py,sha256=_CBzqACxC6xPGxuq_wwE3VKBeDnq3b4W5-Py4vpenDA,183560
80
80
  modules/voice_commands.py,sha256=iBb-gjWxRMLhFH7-InSRjYJz1EIDBNA2Pog8V7TtJaY,38516
81
81
  modules/voice_dictation.py,sha256=7TlTTILSW4KwpTi1rDeKfvTwd5z3_XtNSzNIo35VAWU,16617
82
82
  modules/voice_dictation_lite.py,sha256=jorY0BmWE-8VczbtGrWwt1zbnOctMoSlWOsQrcufBcc,9423
83
- supervertaler-1.9.205.dist-info/licenses/LICENSE,sha256=m28u-4qL5nXIWnJ6xlQVw__H30rWFtRK3pCOais2OuY,1092
84
- supervertaler-1.9.205.dist-info/METADATA,sha256=hX2ysmA8ur00DXX7Ua21H9t4Ct620QB1vAH7iwqVILs,5725
85
- supervertaler-1.9.205.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
86
- supervertaler-1.9.205.dist-info/entry_points.txt,sha256=NP4hiCvx-_30YYKqgr-jfJYQvHr1qTYBMfoVmKIXSM8,53
87
- supervertaler-1.9.205.dist-info/top_level.txt,sha256=9tUHBYUSfaE4S2E4W3eavJsDyYymkwLfeWAHHAPT6Dk,22
88
- supervertaler-1.9.205.dist-info/RECORD,,
83
+ supervertaler-1.9.206.dist-info/licenses/LICENSE,sha256=m28u-4qL5nXIWnJ6xlQVw__H30rWFtRK3pCOais2OuY,1092
84
+ supervertaler-1.9.206.dist-info/METADATA,sha256=xbznbfBz1PwkaxWaQXLs9iuxeFf7CdXB-tsrjoei9gg,5725
85
+ supervertaler-1.9.206.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
86
+ supervertaler-1.9.206.dist-info/entry_points.txt,sha256=NP4hiCvx-_30YYKqgr-jfJYQvHr1qTYBMfoVmKIXSM8,53
87
+ supervertaler-1.9.206.dist-info/top_level.txt,sha256=9tUHBYUSfaE4S2E4W3eavJsDyYymkwLfeWAHHAPT6Dk,22
88
+ supervertaler-1.9.206.dist-info/RECORD,,