Skip to main content

Translation

9 requirements · 13 scenarios

Long-Running Translation Tool

JR-translation-001
The system SHALL provide a translate tool that performs LLM-based translation and is marked is_long_running=True so the conversation loop can send an interim acknowledgement while translation is in progress.
1 test scenario
  • translate tool is registered as long-running JR-translation-001.1

Translation Scope For Body vs Attachments

JR-translation-002
The translate tool SHALL support scoping translation to the email body, attachments, or both.
3 test scenarios
  • Translate email body only JR-translation-002.1
  • Translate attachments only JR-translation-002.2
  • Translate both email body and attachments JR-translation-002.3

zh-CN Translation Prompt Pack

JR-translation-003
When translate executes with target_language=zh-CN, the tool SHALL use a zh-CN translation prompt pack to reduce output variability.
1 test scenario
  • Prompt pack applied JR-translation-003.1

zh-CN Quote Normalization

JR-translation-004
When translate executes with target_language=zh-CN, the tool SHALL normalize straight quotes (") into Chinese quotation marks (\u201c \u201d) outside code spans to better match zh-CN typographic conventions.
1 test scenario
  • Straight quotes normalized JR-translation-004.1

Attachment Translation Output Format

JR-translation-005
Translated attachments SHALL be returned in the same file format as the input, except non-editable formats which are converted to editable equivalents.
3 test scenarios
  • Editable input format preserved JR-translation-005.1
  • Non-editable input converted to editable output JR-translation-005.2
  • Unsupported attachment type JR-translation-005.3

Structure-Preserving Attachment Translation

JR-translation-006
For word-processing attachments (e.g., DOCX/DOC/RTF/ODT, and PDF after conversion), the system SHALL translate the document in a way that preserves the document's paragraph/table/list structure.
1 test scenario
  • Paragraph structure preserved for DOCX JR-translation-006.1

zh-CN Non-RMB “大写” Amount Handling

JR-translation-008
When translating to zh-CN, the system SHALL NOT instruct the model to add Chinese financial characters (“大写”) for non-RMB currencies by default.
1 test scenario
  • USD amounts remain numeric by default JR-translation-008.1

Output Validation

JR-translation-009
The translate tool SHALL perform basic output validation to catch translation anomalies.
1 test scenario
  • Length-ratio sanity check for EN->zh-CN JR-translation-009.1

Large Input Handling

JR-translation-010
The translate tool SHALL handle inputs that exceed practical size limits.
1 test scenario
  • Input exceeds size limit JR-translation-010.1