Index of every page on this site: llms.txt
All skills
devolutions avatar

/translation-diff-translate

@bb42035
by devolutionsdevolutions/unigetui27k stars
991
Run it yourself

Translates a sparse UniGetUI JSON language patch, writes completed entries into the working copy, preserves placeholders and terminology, and prepares the patch for merge-back. Use when the user asks to translate or localize i18n strings, localization JSON, or language-file patches.

  • 2 files
  • 7.3 KB
  • Updated 7 months ago
  • GitHub
Use this Skill: https://skilld.dev/gh/devolutions/unigetui/translation-diff-translate

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈78 tokens for metadata: the name and description. ≈849 when used: this file.

Description uses 3.9% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈312 characters, or 3.9%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

translation diff translate

Use this skill after translation-diff-export produced a .source.json, .translated.json, and .reference.json set and you want to update the sparse translated working copy.

It translates only the active patch keys, keeps .translated.json as the sole writable file, preserves placeholders and formatting, and hands the completed working copy to translation-diff-import for merge-back.

Execution Expectations

  1. Edit .translated.json directly. Do not create helper scripts, temporary reports, or coverage probes.
  2. Do not install packages or search for external translation services unless the user explicitly asks for automation.
  3. If .translated.json is empty, that is expected. Translate from .source.json into .translated.json.
  4. Use .reference.json only as terminology guidance, not as a reason to pause and analyze the rest of the repository.
  5. If the patch is too large to finish reasonably in one pass, report that constraint to the user instead of creating automation on your own.

Script

  • scripts/write-translation-handoff.ps1: Writes a small .prompt.md file that points an agent at this skill with the concrete patch paths created by the export skill.

Usage

Generate a handoff prompt for a translated French working copy:

pwsh ./.agents/skills/translation-diff-translate/scripts/write-translation-handoff.ps1 \
  -BaseName lang \
  -Language fr \
  -SourcePatch ./generated/translation-diff-export/lang.diff.fr.source.json \
  -TranslatedPatch ./generated/translation-diff-export/lang.diff.fr.translated.json \
  -ReferencePatch ./generated/translation-diff-export/lang.diff.fr.reference.json \
  -TargetJson ./src/Languages/lang_fr.json \
  -NeutralJson ./src/Languages/lang_en.json \
  -MergedTargetJson ./src/Languages/lang_fr.merged.json \
  -ValidationScript ./.agents/skills/translation-diff-import/scripts/validate-language-file.ps1 \
  -OutputPrompt ./generated/translation-diff-export/lang.diff.fr.prompt.md

Translation Rules

  1. Do not edit .source.json.
  2. Write completed translations only into .translated.json.
  3. If a key is not translated yet, omit it from .translated.json instead of copying the English source value.
  4. Preserve key names exactly as-is.
  5. Preserve placeholders, named tokens, HTML-like fragments, escape sequences, and line breaks.
  6. Keep translated entries in the same key order as .source.json when adding new entries.
  7. Use .reference.json to match existing terminology and tone in the destination language.
  8. Do not introduce keys that are not present in the source patch.

After Translation

Merge the sparse working copy back into the full destination-language file:

pwsh ./.agents/skills/translation-diff-import/scripts/import-translation-diff.ps1 \
  -TranslatedPatch ./generated/translation-diff-export/lang.diff.fr.translated.json \
  -SourcePatch ./generated/translation-diff-export/lang.diff.fr.source.json \
  -TargetJson ./src/Languages/lang_fr.json \
  -NeutralJson ./src/Languages/lang_en.json \
  -OutputJson ./src/Languages/lang_fr.merged.json

pwsh ./.agents/skills/translation-diff-import/scripts/validate-language-file.ps1 \
  -NeutralJson ./src/Languages/lang_en.json \
  -TargetJson ./src/Languages/lang_fr.merged.json \
  -PatchJson ./generated/translation-diff-export/lang.diff.fr.source.json

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No third-party reports yet.

Signed by skilld at bb42035. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 days ago.

Activeupdated 7 months ago

README badge

README badge for devolutions/unigetui/translation-diff-translate