|
32 | 32 | text_to_translate = original_text |
33 | 33 |
|
34 | 34 | prompt = f"""<|START_OF_TURN_TOKEN|><|SYSTEM_TOKEN|> |
35 | | -You are a professional technical {target_lang_name} translator. Translate the provided README into professional developer-level {target_lang_name}. |
| 35 | +You are a professional technical {target_lang_name} translator. |
| 36 | +Task: Translate the README content into {target_lang_name} while preserving the exact layout, HTML, and badges. |
36 | 37 |
|
37 | | -CRITICAL RULES: |
38 | | -1. **Navigation Bar**: The top HTML block (`<div align="center">...</div>`) containing language links MUST remain EXACTLY the same. Do NOT translate the filenames or language names inside it. |
39 | | -2. **Badges**: Do NOT translate the text inside badge links (e.g., `![License]`, `![Python]`). Keep the URLs exactly as is. |
40 | | -3. **Logo**: Keep the logo HTML block (`<div style="text-align:center...`) exactly as is. |
41 | | -4. **Formatting**: Preserve all emojis and HTML/Markdown tags exactly. |
42 | | -5. **Terminology**: Keep technical terms (GPU, CLI, VRAM, SSH, Docker, API, CUDA) in English. |
43 | | -6. **No Talk**: Output ONLY the translated text. Do not wrap the output in markdown code fences (```). |
| 38 | +STRICT RULES: |
| 39 | +1. **Navigation Bar**: The first block `<div align="center">...</div>` is IMMUTABLE. Copy it exactly. Do NOT translate "English", "Deutsch", etc. |
| 40 | +2. **Logo**: The block `<div style="text-align:center...` is IMMUTABLE. Copy it exactly. |
| 41 | +3. **Badges**: Lines starting with `![` (e.g., `![License]...`) are IMMUTABLE CODE. Copy them character-for-character. Do NOT translate "License", "Python", "Version". |
| 42 | +4. **Structure**: The output MUST start with the Navigation Bar, followed by the Logo, then the Quote, then Badges. |
| 43 | +5. **Formatting**: Keep all HTML tags, markdown links, and emojis exactly as is. |
| 44 | +6. **Terminology**: Keep technical terms (GPU, CLI, VRAM, SSH, Docker, API, CUDA) in English. |
| 45 | +7. **No Talk**: Output ONLY the translated README. No code fences. |
44 | 46 | <|END_OF_TURN_TOKEN|> |
45 | 47 | <|START_OF_TURN_TOKEN|><|USER_TOKEN|> |
46 | 48 | {text_to_translate}<|END_OF_TURN_TOKEN|> |
|
0 commit comments