thai-interpreter

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Thai Interpreter

泰语解读器

Interpret Thai user intent with two explicit modes while preserving meaning.
Use this mode selector first:
  1. Literal Translation
    :
    • Translate Thai to natural English with high fidelity.
    • Preserve tone, nuance, and intent.
    • Do not compress unless requested.
  2. Execution Translation
    :
    • Translate Thai to compact, execution-ready English.
    • Optimize for fewer tokens and direct agent action.
    • Keep wording concise; do not force a fixed response template.
Default to
Execution Translation
unless the user asks for direct/literal translation.
Use this workflow:
  1. Extract user intent from Thai text.
  2. Select translation mode based on user instruction.
  3. Preserve key Thai domain terms, names, and literals exactly.
  4. Produce English output in the chosen mode.
  5. Validate any file write path for UTF-8 safety before finalizing.
通过两种明确的模式解读泰语用户意图,同时保留原意。
请先使用以下模式选择器:
  1. Literal Translation
    (直译模式):
    • 将泰语高保真地翻译成自然流畅的英语。
    • 保留语气、细微差别和意图。
    • 除非用户要求,否则不要压缩内容。
  2. Execution Translation
    (执行导向翻译模式):
    • 将泰语翻译成简洁、可直接执行的英语。
    • 优化以减少token使用,便于Agent直接执行操作。
    • 措辞保持简洁;不要强制使用固定的响应模板。
除非用户要求直接/直译,否则默认使用
Execution Translation
模式。
请遵循以下工作流程:
  1. 从泰语文本中提取用户意图。
  2. 根据用户指令选择翻译模式。
  3. 完全保留泰语领域术语、名称和字面内容。
  4. 生成所选模式的英语输出。
  5. 在最终确定前,验证所有文件写入路径的UTF-8安全性。

Prompt Compression Rules

提示词压缩规则

Apply these rules for
Execution Translation
:
  1. Convert long Thai narrative into concise, actionable instructions.
  2. Remove repetition, filler phrases, and polite particles that do not affect behavior.
  3. Preserve non-negotiable requirements exactly as written.
  4. Keep dates, numbers, IDs, file paths, and code literals unchanged.
  5. Keep the compressed instruction under 8 lines when possible.
针对
Execution Translation
模式应用以下规则:
  1. 将冗长的泰语叙述转换为简洁、可执行的指令。
  2. 删除不影响操作的重复内容、填充语和礼貌用语助词。
  3. 完全保留不可协商的要求。
  4. 日期、数字、ID、文件路径和代码字面内容保持不变。
  5. 尽可能将压缩后的指令控制在8行以内。

Literal Translation Rules

直译规则

Apply these rules for
Literal Translation
:
  1. Keep sentence-level meaning and pragmatic intent faithful to Thai source.
  2. Preserve ambiguity if the original Thai is ambiguous.
  3. Preserve names, domain terms, and quoted literals exactly.
  4. Do not add implementation assumptions unless requested.
  5. Keep formatting close to the source when practical.
针对
Literal Translation
模式应用以下规则:
  1. 忠实于泰语原文的句子层面含义和语用意图。
  2. 如果原文泰语存在歧义,保留歧义。
  3. 完全保留名称、领域术语和引用的字面内容。
  4. 除非用户要求,否则不要添加实现假设。
  5. 尽可能保持与原文相近的格式。

Thai Text Safety Rules

泰语文本安全规则

Always protect Thai text writes:
  1. Use UTF-8 explicitly when creating or updating files.
  2. Detect suspicious replacement characters (U+FFFD) before and after writing.
  3. If corruption appears, stop and rewrite from clean source text.
  4. Avoid lossy encoding conversions (for example ANSI/Windows-1252 fallback).
  5. Re-open written files and verify expected Thai snippets.
For deep checks and command recipes, read:
  • references/encoding-playbook.md
  • references/translation-rules.md
For automated checks and safe writes, use:
  • scripts/check-thai-encoding.ps1
  • scripts/write-utf8.ps1
始终保护泰语文本的写入操作:
  1. 创建或更新文件时明确使用UTF-8编码。
  2. 在写入前后检测可疑的替换字符(U+FFFD)。
  3. 如果出现损坏,停止操作并从干净的源文本重新写入。
  4. 避免有损编码转换(例如ANSI/Windows-1252降级)。
  5. 重新打开已写入的文件,验证预期的泰语片段是否正常。
如需深入检查和命令参考,请阅读:
  • references/encoding-playbook.md
  • references/translation-rules.md
如需自动检查和安全写入,请使用:
  • scripts/check-thai-encoding.ps1
  • scripts/write-utf8.ps1

Output Contract

输出约定

When handling Thai requests, produce:
  1. English translation in the selected mode.
  2. Natural, user-facing phrasing by default (no forced mode label or fixed headings).
  3. Only use explicit sections (for example
    Goal
    ,
    Inputs
    ,
    Constraints
    ,
    Output
    ) when the user asks for that format.
  4. The implementation result (if execution is requested).
  5. A brief encoding safety confirmation when files were changed.
处理泰语请求时,需生成:
  1. 所选模式的英语翻译结果。
  2. 默认使用自然、面向用户的措辞(无需强制添加模式标签或固定标题)。
  3. 仅当用户要求时,才使用明确的章节(例如
    Goal
    Inputs
    Constraints
    Output
    )。
  4. 实现结果(如果用户请求执行操作)。
  5. 当文件被修改时,提供简短的编码安全确认。