Skip to main content
AI Pipeline Pre-translation logo
AI Pipeline Pre-translation FreeSystem

Runs AI Pipeline pre-translation and enriches string context until the ambiguity report is clean

SKILL.md

AI Pipeline Pre-translation

Copy link

AI Pipeline is a Crowdin App (not a generic workflow). This skill automates working with it: finding its prompt, running pre-translation, fetching the app's ambiguity report, and iteratively enriching string context until coverage is maximized.

Iterative workflow: find AI Pipeline prompt → run → fetch summary → ask user about ambiguous strings → update string context → re-run.

Workflow

Copy link
  1. Find the AI Pipeline prompt — call list_organization_ai_prompts with action: "pre_translate". Filter results to find prompts where config.mode === "external" AND config.identifier === "ai-pipeline". These are the only valid prompts for this workflow.

    • 1 found → use it automatically, no need to ask the user.
    • Multiple found → ask the user to choose via AskUserQuestion.
    • 0 found → stop and explain to the user (in plain language, without mentioning internal API fields) that the AI Pipeline app isn't configured as a prompt yet, and direct them to set it up at Crowdin → Organization Settings → AI → Prompts.
  2. Start pre-translationapply_pre_translation with the AI Pipeline prompt ID, languageIds, and fileIds (or branchIds for string-based projects). Poll pre_translation_status (Sleep between checks) until status === "finished".

  3. Fetch summaryget_application_data with:

    • applicationIdentifier: "ai-pipeline"
    • path: "pre-translation-summary?projectId={projectId}&preTranslationId={preTranslationId}"
  4. Check for ambiguities — if data.filteredStrings has no keys (the object is empty), announce completion with final stats and stop.

  5. Group and ask — analyze filteredStrings, group by language and pattern, ask up to 4 questions via AskUserQuestion.

  6. Update contextstring_batch_operations to append translation notes to each ambiguous string's context field (max 50 ops per call; split into sequential calls if needed).

  7. Re-runapply_pre_translation again with the same parameters → go to step 3.

Stop when: filteredStrings is empty, or user says stop. After 3 cycles ask: "Continue? Coverage is now X% (+Y% this round)." If coverage improvement < 5%, suggest manual review for remaining strings and ask whether to continue.

Summary Response Schema

Copy link
{
  "data": {
    "stringKeys": ["1711582", "1711584", "1711608", "1711634:one", "1711634:other"],
    "filteredStrings": {
      "1711608": "Reason why filtered — mentions which language is affected",
      "1711634:one": "Plural form 'one' ambiguous — same reason",
      "1711634:other": "Plural form 'other' ambiguous — same reason"
    },
    "translatedStrings": ["1711582", "1711584"]
  }
}

filteredStrings key formats:

  • Regular strings: "1711608" — use as-is for path: "/1711608/context"
  • Plural strings: "1711634:one", "1711634:other" — strip :pluralForm suffix → ID: 1711634path: "/1711634/context"
  • Deduplicate: if multiple plural forms of the same string are filtered, produce only one batch_patch operation for that string ID

Coverage ≈ translatedStrings.length / stringKeys.length × 100%

Question Rules (max 4 per round)

Copy link

Multi-language runs: filteredStrings aggregates ambiguities from all target languages. Each reason text names the affected language explicitly (e.g. "German requires formal/informal address", "Ukrainian requires ви/ти choice"). A single string may be filtered for one language but successfully translated for another. Group by language and pattern before forming questions.

Prioritize in this order:

  1. Cross-cutting decisions (formality, brand voice, tone) — affect the most strings
  2. UI element type conventions ("Are all 'Image' placeholders alt text or tooltip labels?")
  3. Recurring ambiguity patterns across multiple strings

Consolidate same-category issues into one question:

  • All formality strings across all languages → 1 question: "Formal or informal address?" — apply the answer per language (German: Sie/du, Ukrainian: ви/ти, etc.)
  • Multiple English technical abbreviations (AI, TM, API, UI) across strings → 1 question: "Keep technical terms in English or localize?"

Ask for SOURCE context clarification only. Never present target-language translation options — the user does not know the target language. Ask about the string's purpose, not its translation:

  • "Is this string a button label, tooltip, or page title?"
  • "Should the UI address users formally or informally throughout?"
  • "Is 'Welcome!' a greeting banner or a screen title?"
  • "What is the intended use of the 'Image' placeholder strings — alt text or tooltip?"

Each question must include: source string text (quoted), target language(s), file path, number of strings affected, and why the pipeline could not translate. Example format:

"The pipeline found 8 instances of 'Image' in en/ui.json → Ukrainian. Context unclear: alt text vs. tooltip label. String IDs: 1708970, 1708971… Which is it?"

Use AskUserQuestion for discrete-choice questions. Use plain text for free-form answers.

After collecting answers — update strings immediately without asking for confirmation. Announce what you are doing: "Updating 12 strings with formality context (formal address)…"

Context Update Format

Copy link

Before patching: fetch the current context for all ambiguous strings first, then build the updated values. Never discard existing context.

  • All strings from the same file → list_strings with fileId (single call, more efficient)
  • Strings from different files or single string → get_string per string
{
  "projectId": 130,
  "operations": [
    {
      "op": "replace",
      "path": "/1711634/context",
      "value": "<existing context>\nGerman note: Use formal Sie (not du/ihr)."
    },
    {
      "op": "replace",
      "path": "/1711608/context",
      "value": "<existing context>\nGerman note: Keep job title in English."
    }
  ]
}
  • path: /STRING_ID/context — numeric ID only (no :pluralForm suffix)
  • op: always "replace"
  • value: existing context + \n + new note (fetch first, then build the value)
  • Include the target language name in the note when multiple languages are in scope

Progress Reporting

Copy link

After each run: Coverage: X% (+Y%). Remaining: N ambiguous strings (M new patterns identified). [Per language if multi-language.]

After completion: total strings translated, number of iterations, all languages covered.

Works with
  • crowdin.com
  • Crowdin Enterprise
Details

Released on Sep 4, 2026

Updated on Sep 4, 2026

Published by Crowdin

Identifier:ai-pipeline-pretranslation

All product and company names are trademarks™ or registered® trademarks of their respective holders. Use of them does not imply any affiliation with or endorsement by them.