VIEW THIS AS

Auto mode follows the Route Engine until you choose a viewpoint.

YOU ARE HERE

ROUTE CHECK

CONNECTED TO

WHAT NEXT

Use the canonical route for this room, or HELP if you are unsure.

Translate Like a Pro | 9450 — Python Cappa Localization, Typed Commands, Help Inference, Backends, Completion and Unicode QA

A smiling student in a blue pinafore holds a pencil over an open book at a classroom desk, with textbooks, a whiteboard and a sunlit window nearby.

Python Cappa localization is the practical job of making typed Python command-line tools understandable in different languages while keeping arguments, option names, subcommands and execution rules predictable. If you are searching for Cappa multilingual CLI help, cappa.Arg descriptions, dataclass argument parsing, cappa.parse versus cappa.invoke, rich terminal help or translated completion prompts, the essential distinction is between human-facing explanation and the syntax a working command accepts.

Cappa can infer a command-line interface from Python classes, function signatures and type information, and it supports both parsing into an object and invoking a command. Those conveniences do not eliminate the need to select a language, supply carefully written strings, test fallback messages and verify how an installed parser backend formats errors. A translation that reads beautifully but changes a flag or misstates the default is still a broken interface.

This guide works through a fictional, read-only program called archiveview, used to inspect catalogue metadata without editing it. A team in Nairobi, Montreal, São Paulo or Osaka should be able to consult its help, copy a working example and recover from a mistake while automated callers continue using stable machine tokens. The explanations are relevant to multilingual command-line utilities worldwide; examples should be adapted and tested against the actual Cappa release and Python environment used by each project.

Quick answer: the safe order for localizing a Cappa program

  1. Inventory each positional argument, named option, type, default and subcommand before changing copy.
  2. Keep the invocation grammar stable; translate descriptions and explanatory messages rather than changing public flags inadvertently.
  3. Decide how the application chooses locale and what happens when a translation is missing.
  4. Test root help, each subcommand help, successful parsing, invalid values and help at narrow widths.
  5. Compare Cappa’s native and argparse backends if your product supports both.
  6. Check copy-and-paste commands, Unicode paths, right-to-left context, terminal colours and shell completion.
  7. Review the installed distribution, not merely source files on a developer’s laptop.

A complete mental model: declaration, interpretation and presentation

When a programmer writes a Cappa command, three different layers meet. A declaration supplies types, default values, option identities, names and descriptions. A parser interprets the actual argument vector supplied by the operating system. Finally, a renderer shows help, errors and completion suggestions to a human reader. The first layer expresses the contract; the second decides what the program does; the third helps the user understand it. Localization should concentrate on the third while auditing any effects on the first two. That division prevents a common failure: translating an option label in a way that alters an integration script.

Imagine the invocation archiveview inspect "Café records/東京.json" --limit 12. The file path is user data. The word inspect and the spelling --limit are program syntax. The number is a typed value. Only the surrounding instructions can ordinarily be translated without a compatibility decision. If a translated help page uses a curved dash instead of the two ASCII hyphens of --limit, the example may look graceful but fail when pasted into a shell. Likewise, a translated command name is a feature request, not a copy edit.

Cappa’s documentation describes class-based and function-based interfaces and explains that it derives parts of the command line from type annotations. It also documents two execution styles: parse into data, and invoke handlers, with dependency injection available for invoked functions. Use this flexibility deliberately. Every extra declaration style gives the project another place where a user-visible description may originate. A catalog that changes one message but leaves the same sentence in a class docstring is only partly localized.

A harmless reference exercise that reveals the contract

Build a miniature inspection command before touching a real archive. It should accept a positional path, an optional integer limit and a boolean flag for showing more context. Have it print a summary of the parsed values without opening or changing any file. Run it once with plain ASCII text, once with a path containing spaces, once with a non-Latin path and once with an invalid number. Capture stdout, stderr and the process exit status separately. This creates a baseline that can be compared across locales without exposing production records.

Describe expected behaviour in ordinary language. A missing optional limit should take the documented default; an invalid integer should trigger an intelligible error rather than becoming a guessed value. If the command invokes a handler, an argument parsing failure should not accidentally reach that handler. If output is intended for scripts, keep structured fields such as record_id and status stable even when a human display line is translated. These are separate acceptance tests, not vague editorial preferences.

Detailed practical decisions: from first declaration to international release

How to use the casebook: every investigation begins with a precise technical distinction and then names a common source of reader confusion. The checks intentionally use harmless invocations, captured argument vectors and reproducible output. You do not need to implement every optional Cappa feature to benefit from the method; only claim features actually enabled in the application’s release.

Each case should be read from the perspective of two people. A first-time reader needs one successful command and a meaningful next step after an error. A maintainer needs to know where a string came from and which test can reveal a regression. Good localization respects both without letting a translated sentence override the defined parser contract.

1. Typed dataclass fields

A dataclass field annotated as an integer is a promise about accepted input, not just a hint for the help screen. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translator may rewrite the word ‘number’ into a culturally ambiguous phrase suggesting decimals when the parser expects an integer. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Use a valid positive integer, zero, a decimal string and an alphabetic string in two locales; observe the same parsed values and failures. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Translate ‘whole number’ naturally while documenting the exact accepted syntax and any application-level range rule. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

2. Positional versus named values

Cappa generally infers ordinary non-boolean fields as positional values unless a declaration specifies different argument behaviour. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Help that calls the required file path an option may make readers try a nonexistent flag, or place the operand after the wrong token. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Compare the generated usage order to the actual invocation with and without the path; test names containing spaces. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Identify a positional input as a value supplied in order and reserve ‘option’ for declared switches. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

3. Explicit long option names

The Arg(long=True) form can expose a field as a named long option instead of an inferred positional. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Translating the option spelling inside a suggested command without defining an alias can break shell scripts and support material. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Capture the parser-accepted long spelling, including hyphens, then replay exactly that spelling under every locale. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Keep the accepted flag unchanged and write the translated sentence around a code-formatted token. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

4. Short aliases and collisions

Short option names are valuable in terminals but scarce; two translated words can begin with the same letter. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A reviewer may suggest using the first letter of each translated description as the short flag, silently creating collisions. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Compare every registered short flag in root and nested help, including flags from extensions and plugins. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Preserve existing short aliases; introduce new aliases only through a deliberate versioned API decision and tests. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

5. Boolean fields

Cappa can infer boolean arguments as flags, making presence or absence part of the syntax. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A sentence saying ‘set this to true’ can encourage users to type a value that the declared flag does not expect. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Try the flag alone, the flag followed by a literal boolean word, and the omitted flag against a print-only fixture. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Explain whether the switch is activated by presence, and separate the displayed state from parsed syntax. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

6. Defaults printed in help

A class default can become visible help metadata; a default is an operational promise. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A localized sentence may claim a translated default even though code still uses the original numeric or string value. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Inspect help, parse with no supplied value and compare the resulting object in every supported language. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Keep actual defaults in one implementation source and translate only their explanatory context. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

7. Optional None values

A typed optional argument may differ meaningfully between omission and a supplied empty string. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Translation that says ‘leave blank’ might conceal whether omission uses None or an explicit empty value. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Test omission, an empty quoted operand and an ordinary value, keeping the original argument vector in the log. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Describe the exact missing-value rule; avoid implying that all forms of blankness are equivalent. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

8. Lists and repeated options

Cappa supports list-shaped input declarations, so the help needs to explain repetition and collection size. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translator may turn ‘repeat the option’ into an instruction to pass comma-separated text, changing the input form. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Supply two separate occurrences, one comma-containing value and an omitted list, then inspect the parsed structure. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Provide a complete invocation showing repetition and the correct quoting conventions. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

9. Tuples and fixed arity

Tuple annotations can describe a fixed number of values with potentially different types. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A concise translated label can hide the fact that the final item is an integer while earlier items are strings. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Try one too few values, exactly enough values and one extra value with a harmless command. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Write a fully worked sample that marks each required position and explain why order matters. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

10. Literal choices

A Literal type can constrain acceptable values such as json or text. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Translating these values casually changes machine syntax and may make readers supply rejected tokens. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Run every advertised choice and a near miss; compare usage and parse errors for stable accepted tokens. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Leave literal tokens in code form and localize their meaning in the adjacent descriptions. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

11. Enum choices

Enum-backed options can make a stable set of values feel like ordinary vocabulary even when they are interface identifiers. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: An editor may substitute a translated synonym for an enum member without changing its parser mapping. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: List the emitted choices and run all of them before and after the text change; record any display-value distinction. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Distinguish the user-facing explanation from the exact accepted identifier, especially where case matters. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

12. Argument custom parsing

An Arg declaration may define custom conversion or action behaviour beyond basic Python type inference. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translator may describe a unit or format that the custom converter does not actually accept. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Use accepted and rejected sample values including punctuation, whitespace and signs; keep failures visible. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Write the accepted grammar in the help and add an example drawn from the tested converter. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

13. Help text precedence

Cappa’s help documentation prioritizes explicit help= before some inferred documentation sources. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Updating only a docstring may appear ineffective because a higher-priority explicit string is still being displayed. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Render help from the packaged command and trace the displayed sentence back to the source declaration. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Use an explicit catalog-backed help string where that is appropriate, and remove conflicting duplicate copy. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

14. PEP-727 style documentation

The documented help inference route can use a Doc annotation from typing extensions. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A project may assume the annotation is automatically localized when it is still a fixed Python string. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Test the same command with and without the explicit help override and compare installed help output. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Treat annotation-based copy as translatable source content with a clear ownership and fallback decision. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

15. Attribute docstrings

Cappa documents attribute-docstring inference, which relies on reading Python source structure. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Packaging that strips or transforms source information can make help disappear or differ from development output. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Install a wheel into a clean environment, run help and compare it with the development invocation. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Prefer explicit help where distribution reliability matters; test source-dependent inference as a packaging risk. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

16. Class docstrings

Cappa can parse class docstrings for command descriptions and parameter explanations, with optional dependencies involved. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Translators may improve the class description but miss individual fields inherited from annotations or explicit help. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Generate help for the root and each child and identify which lines come from docstrings. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Check optional docstring parsing dependencies in the deployed build and avoid accidental English fallback. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

17. Help formatter choices

Cappa exposes a HelpFormatter path for controlling aspects of displayed defaults, choices and rich text. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A single elegant English layout may overflow when the translation is longer or uses wider glyphs. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Render at several terminal widths and in plain output, capturing spacing and visibility of defaults. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Keep readable groupings, permit line wrapping and avoid alignment that depends on English word lengths. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

18. Default wording templates

The help formatter can customize default-value wording using formatting placeholders. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translation may break a placeholder by changing braces or treating it as a normal noun. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Check that rendered help shows the exact same default across languages and never leaves raw placeholders. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Lock placeholders in the localization workflow and give translators an example of the rendered result. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

19. Markdown and styled fragments

Help rendering may combine formatted segments, so style markup becomes part of what a translator encounters. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A catalog entry that contains unbalanced formatting can obscure a warning or create an unreadable line. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Render plain and styled help, including Windows-like terminals and redirected output. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Separate semantic content from style instructions where possible and retain a plain-text fallback. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

20. Command names inferred from classes

A class name can become a dashed command name through Cappa’s naming conventions. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Renaming a Python class for translation may alter the CLI entry point and external scripts. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Print the public command tree, then run the original names and aliases on both versions. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Choose explicit stable names where public compatibility matters, keeping descriptions language-dependent. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

21. Subcommands as unions

A typed subcommand union identifies a controlled set of child commands. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A parent help page can be localized while a child help page remains English or has incomplete argument descriptions. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Traverse every child listed in root help and check the help text and a valid invocation for each. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Treat the entire command tree as the review unit, not just the landing help screen. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

22. Method-based commands

Cappa documents a method-oriented pattern in which class fields and methods participate in command invocation. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: The apparent proximity of an argument to a method can hide whether it belongs to the parent or child syntax. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Run parent help and child help separately; deliberately place a parameter on the wrong side of the subcommand. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Write examples that preserve the actual argument placement and explain the parent-child relationship. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

23. Parse versus invoke

cappa.parse produces command data whereas cappa.invoke routes to execution. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Documentation may promise a harmless parse preview while the implemented entry point invokes a mutating handler. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: For a fixture, use a side-effect counter and verify whether the handler runs after successful parsing. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Explain the chosen entry point honestly, and keep tutorials read-only unless an action is explicitly intended. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

24. Dependency injection

Cappa’s invoke mode can supply resources beyond user arguments, such as services used by a handler. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Readers may confuse injected resources with command-line parameters and look for flags that do not exist. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Compare handler signatures with generated usage and print the actual parsed values before injection. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Describe which inputs users control and which resources are supplied by the application. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

25. Native parser backend

Cappa’s native backend is documented as its default and supports features including completion. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: It is unsafe to assume that every error message and formatting detail is identical to the argparse backend. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Run the same known-good and deliberately bad argument vector through the native backend. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Write backend-aware test expectations and localize application-owned errors consistently. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

26. Argparse backend

The documented argparse backend provides another route through argument parsing with potentially different error text. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A test snapshot approved against one backend may conceal an untranslated error generated by the other. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Run invalid flags, missing required values and malformed typed inputs through both supported backends. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Treat equivalence of accepted inputs as the goal while auditing language and presentation separately. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

27. Custom backend expectations

A project may wrap a backend or use one for compatibility rather than for language selection itself. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A rushed translator can promise a backend feature without knowing the release’s parser configuration. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Inspect the deployed backend binding and record which test suite exercises it. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Keep implementation claims version-specific, and do not claim that changing backends automatically translates messages. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

28. Completion generation

Cappa advertises dynamic completion in its native backend, but installed shell support is a separate integration. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translated screenshot can be correct while pressing Tab inserts an invalid localized token. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Install the completion script in a disposable shell and check candidate insertion and escaping. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Translate display descriptions only where supported, preserving accepted machine-facing values. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

29. Unicode paths

A typed string argument can carry Unicode even when the library has no special localization setting. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Copy-pasted commands can fail because of shell quoting, normalization or filesystem behaviour rather than translation. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Test accented names, CJK characters, spaces and combining marks on files that exist in the fixture. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Keep the exact path distinct from help prose and document shell-specific quotation accurately. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

30. Right-to-left presentation

Arabic or Hebrew descriptions can appear near ASCII hyphens and left-to-right option names. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Visual order can mislead a reader into copying punctuation with the wrong token boundaries. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Inspect a real terminal or faithful capture and paste every example back into the shell. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Present option tokens in isolated code formatting and check actual text order, not only appearance. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

31. CJK help widths

Characters can occupy different display widths than their string length suggests. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A line wrapping algorithm based on character counts may overlap columns or truncate a required value. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Capture help under 40-, 60- and 80-column settings using representative Japanese and Chinese strings. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Favor robust wrapping over rigid columns and permit longer descriptions on their own lines. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

32. Plural and grammatical agreement

Messages about one file, two files and zero files can require different grammar across languages. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: Replacing one word in a fixed English template can produce ungrammatical or misleading instructions. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Test zero, one and many results with translated complete sentences. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Use a plural-aware message catalog at the application layer where such messages are emitted. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

33. Error recovery instructions

A parser can report an invalid option, but the application should tell readers what to do next. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: An error translation may say ‘file not found’ when the real problem is an unknown flag. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Record the exact error source and provide a truthful next action such as invoking a child help command. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Keep errors precise and explain whether a safe retry is possible without modifying data. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

34. Exit status and output streams

Internationalization should not accidentally alter exit codes or move machine output to an explanatory channel. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A script that watches stderr can fail when translated errors are printed to stdout. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Capture status, stdout and stderr separately for success, help and validation failures. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Treat these observable behaviours as release contracts and review language changes against them. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

35. Security and invisible characters

An option that accepts strings may receive bidirectional control marks or shell-special characters. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: An editor may assume the string displayed on screen matches the bytes supplied to the parser. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Use escaped diagnostic representations in a safe test fixture and compare the actual argument values. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Do not silently normalize security-sensitive identifiers; explain sanitization and validation where implemented. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

36. Environment-derived locale

A command may choose language from environment variables, a configuration file or a flag managed by its own code. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A guide that says ‘it automatically detects language’ may mislead users on systems with different environment settings. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Run with explicit language settings and an unknown setting, documenting the fallback priority. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Specify the source of locale selection for the actual application instead of attributing it to Cappa by default. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

37. Installed wheels and optional extras

Local tests may run with dependencies that are absent from a minimal deployed package. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translated help message can disappear in production when an optional parsing or rich-text capability is missing. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Install the built wheel in an empty virtual environment and run the same help and error scenarios. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Document required extras, lock tested versions and make fallback output intelligible. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

38. Documentation examples

Examples in a long guide are executable promises about accepted flags and the absence of side effects. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translated sentence can be correct while a copied command uses an obsolete option or unsupported shell syntax. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Replay every published example against the packaged binary and keep harmless input fixtures. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Provide one reliable example before complex combinations, with notes when quoting differs by shell. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

39. Translator context

A word such as ‘record’, ‘run’ or ‘default’ may refer to a noun, a button label or a program state. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A translator without context may make inconsistent choices that change a technical instruction’s meaning. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Supply screenshots or rendered excerpts, placeholder notes and a glossary with program-specific definitions. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Review complete messages in context, not isolated tokens in a spreadsheet. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

40. Release acceptance

A multilingual CLI release must work for readers and for scripts that automate it. In an international tool, that detail matters because newcomers often infer executable behaviour from ordinary words. Help text should narrow uncertainty instead of introducing another interpretation.

A frequent failure is this: A green translation review can hide runtime errors, missing messages, wrong exit codes or stale help. That creates friction for anyone following instructions in a second language, and it can be especially costly when commands are embedded in tutorials or team procedures. The proper comparison is always between the written instruction and the argument vector the program truly accepts.

Try this controlled check: Test clean installations for each target locale, both parser backends when supported, and every child command. Record the invocation, resulting values, displayed message and exit status. If results differ from the advertised behaviour, correct the guide or implementation before changing more translations.

A practical editorial decision is to Sign off only after comparison of exact syntax, visible wording, real error recovery and machine-stable behaviour. Then invite a reader unfamiliar with the original English wording to complete the same task. Have that person explain the result in their own words: the goal is operational understanding, not merely a fluent-looking message.

Worked reader journeys

First encounter at a shared terminal

A technician installs archiveview on a shared workstation and starts with the root help. A good translation shows the one safe inspection path first, distinguishes a positional path from a named limit and says what the program does not change. The technician copies the sample using a file with accented characters. Help is useful only if that invocation succeeds and the output matches the description. A reviewer should watch the whole journey rather than approve isolated strings.

A maintainer investigating a translated error

An engineer sees a complaint that a French message mentions a missing file, while a trace shows an invalid integer for –limit. The next step is not to polish the sentence. Capture the exact argv, confirm which backend emitted the message, reproduce it in English and French, and identify whether the text is parser-owned or application-owned. Once the source is known, update the correct resource and create a regression test for this particular error class.

A release engineer testing a clean environment

A release passes locally but its packaged wheel displays English field descriptions on another machine. Inspect installed extras, the selected backend and the actual resource files. Test source-based help inference and explicit help values separately. A clean build may differ from a development checkout in ways a translation platform cannot detect. The acceptance test should install the artifact into a fresh environment, not simply import an editable project.

An automation author who depends on stable syntax

A scheduling script calls archiveview with –limit and reads a stable result structure. New multilingual help should not change the accepted flag, a JSON key or the meaning of a zero exit status. If product managers want translated aliases, treat that as an added public feature with compatibility testing, not an editorial correction. Human-facing sentences and machine-facing identifiers have different stability requirements.

Frequently asked questions

Is Cappa itself a translation platform?

No automatic end-to-end translation service should be assumed. Cappa provides argument declaration, parsing, help generation, backends and related facilities. A multilingual application still needs a language policy, message resources, review and behavioural tests.

Can I translate the actual option names?

Only deliberately. The option spelling is part of the executable interface. A localized alias may be possible if the parser is configured to accept it, but that is a software design decision that needs collision checks, backwards compatibility and consistent examples.

Why do docstring edits sometimes fail to appear?

Cappa’s documented inference has a precedence order. An explicit help value can outrank inferred documentation. Packaging and optional dependencies can also affect some inference paths. Render the installed help and inspect the exact source of each sentence.

Do the two Cappa backends format errors identically?

The documentation warns that error messages need not match precisely across backends. Test valid parsing separately from presentation, and do not use one backend’s screenshots as proof of the other’s user experience.

How should I translate a list of allowed choices?

Keep values that the program actually accepts in their exact form. Write nearby explanations in the target language. For intentionally translated values, extend parsing deliberately and test the accepted input list as a versioned contract.

Is Unicode support the same as localization?

No. A Unicode path may reach the program correctly while its help remains English. Conversely, beautiful Arabic help can accompany a shell-quoting error. Test encoding, direction, file handling, typography and language as separate properties.

Should a help example show a live modifying command?

Prefer a read-only fixture. If an action changes data, describe it plainly and require explicit safe test conditions. Translation work should not create ambiguous instructions that could damage a reader’s records.

What proves the release is ready?

A clean installation in each supported environment; readable root and child help; valid and invalid typed arguments; correct fallback language; stable invocation tokens, output streams and exit codes; and successful reader testing with copyable examples.

Further reading and technical references

For exact APIs and installed-release details consult the Cappa documentation, help inference and formatting guide, parser backend guide and upstream project. Compare principles with the Master Art of Translation and browse the Translate Like a Pro series index. This chapter concerns Cappa’s typed Python command interfaces, not general translation techniques or another Python CLI framework.

The strongest result is modest and concrete: a new reader understands a real command, an error points toward a safe correction, and scripts behave exactly as they did before the interface became multilingual. When those outcomes survive a packaged release, the translation is performing useful technical work.