add-translations

add-translations is a skill for Claude Code, Codex from anoopsg/agent_rules. It costs 42 tokens per session (535 once invoked), scanned A, original, MIT.

A project guide for adding translated text and error messages in English and Arabic. Internationalization means preparing an app to show the same content in different languages.

In plain words
What is it for?
Use it when adding or changing labels, messages, dynamic text, or translated error codes, then run the project's translation command.
Why use it?
It prevents translation files from getting out of sync and gives new messages a consistent naming and placeholder format.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when adding or changing labels, messages, dynamic text, or translated error codes, then run the project's translation command.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/anoopsg/agent_rules/add-translations
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add anoopsg/agent_rules --skill add-translations
Clone the repo
git clone --depth 1 https://github.com/anoopsg/agent_rules

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for add-translations

README.md
[![agentmods](https://agentmods.dev/badge/skills/anoopsg/agent_rules/add-translations/github.svg)](https://agentmods.dev/skills/anoopsg/agent_rules/add-translations)
Your own site
<a href="https://agentmods.dev/skills/anoopsg/agent_rules/add-translations"><img src="https://agentmods.dev/badge/skills/anoopsg/agent_rules/add-translations/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for add-translations

Your own site · 80×15
<a href="https://agentmods.dev/skills/anoopsg/agent_rules/add-translations"><img src="https://agentmods.dev/badge/skills/anoopsg/agent_rules/add-translations.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 42 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 535 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00042 $0.00535
Opus 5 $0.00021 $0.00267
Sonnet 5 $0.00008 $0.00107
Haiku 4.5 $0.00004 $0.00053

Measured 8d ago against content hash 38c12e9f28fc, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

add-translations scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

src/exclusive/skills/add-translations/SKILL.md · 91 lines

What it actually says

Internationalization Skill

This skill defines the process for adding, modifying, and using localized strings in the project. The project uses slang for internationalization.

1. Directory Structure

Translation source files are located in lib/i18n/:

lib/i18n/
├── en.i18n.json         # English translations (source locale)
└── ar.i18n.json         # Arabic translations

2. Formatting Guidelines

Follow these rules when adding or modifying translations:

  • Key Naming: Use camelCase for translation keys.
  • Namespacing: Organize keys by features or common namespaces.
  • Sync: Ensure every key added to en.i18n.json is also added to ar.i18n.json to keep them in sync.
  • Placeholders: Use ${variableName} syntax for dynamic placeholders.

2.1 JSON Example

{
  "auth": {
    "login": "Login",
    "welcome": "Welcome, ${name}!"
  },
  "errors": {
    "myError": "Something went wrong."
  }
}

3. Registering Error Codes

When translating errors, the translation key must match the technical error code defined in Dart:

  1. Add the code to lib/src/infrastructure/error_codes.dart:
    enum AppErrorCode implements ErrorCode {
      myError('myError'),
    }
    
  2. Add the translation under the errors key in translation JSONs:
    "errors": {
      "myError": "A localized description of the error."
    }
    

4. Re-generating Translations

After modifying JSON files, run the translation tool to generate updated Dart types:

melos run translate

5. Usage in Code

To avoid repeated access overhead, assign context.$.tr to a local variable (e.g., tr) when accessing translations inside build methods:

final tr = context.$.tr;

// Basic usage
Text(tr.auth.login)

// With placeholders
Text(tr.auth.welcome(name: 'User'))

// For failure mapping
final message = failure.toError(tr);
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 91 lines · 42 tokens per session scan A 38c12e9f28fc

Subscribe to this mod's changes

add-translations is a skill published in the GitHub repository anoopsg/agent_rules (2 stars, last pushed 1mo ago), licensed MIT. It adds 42 tokens to every session and 535 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

prose-translation

A Japanese-to-English and English-to-Japanese translation tool for human-readable writing such as essays, research documents, READMEs, and architecture decision records.

shimo4228/claude-harness · 174 tokens

chinese-documentation

A Chinese technical-documentation style guide covering spacing, punctuation, numbers, terminology, and links when Chinese and English appear together.

jnMetaCode/superpowers-zh · 62 tokens

azure-ai-translation-text-py

Azure AI Text Translation SDK for real-time text translation, transliteration, language detection, and dictionary lookup. Use for translating text content in applications. Triggers: "text translation", "translator", "translate text", "transliterate", "TextTranslationClient".

microsoft/skills · 60 tokens

harden

Improve interface resilience through better error handling, i18n support, text overflow handling, and edge case management. Makes interfaces robust and production-ready. Use when the user asks to harden, make production-ready, handle edge cases, add error states, or fix overflow and i18n issues.

fengshao1227/ccg-workflow · 62 tokens

seedance-vocab-ja

This skill should be used when the user asks for Japanese Seedance 2.0 prompt wording, Japanese cinematic vocabulary, or translation of camera, lighting, action, VFX, audio, and production terms into Japanese.

Emily2040/seedance-2.0 · 50 tokens

asc-subscription-localization

Bulk-localize subscription, subscription-group, and in-app purchase display names across App Store locales using asc, including API 4.4.1 version-scoped v2 resources. Use when filling or updating subscription/IAP names and descriptions without App Store Connect UI work.

rorkai/app-store-connect-cli-skills · 60 tokens