Gå til hovedinnhold

kapi verify

kapi verify [files...]

Run a localization project's bound quality gates in a single shot and return a single structured pass/fail plus actionable findings.

Gates (each runs only when the project binds the resource it needs):

brand If a brand voice is bound (defaults.brand_voice), score the source-language content against it. Fails when the score is below the threshold (default 80, override with --min-score). terminology If a termbase is bound (defaults.termbase), check that target files use the required translations from the project glossary. qa For translated target files, check placeholder/tag integrity against the source and flag untranslated/empty targets.

With no file arguments, verify inspects the project's content: brand on the source files, terminology and QA on the target files derived from each content item's target template and the project target languages.

Pass file paths to verify just those files instead.

Selecting gates (--brand/--terms/--qa) and missing bindings: with no gate flag, every gate runs and a gate whose binding is missing (no defaults.brand_voice, no defaults.termbase) is skipped silently — there is nothing to check. But when you explicitly request a gate whose binding is missing, verify does not skip it: it fails the gate with a clear "misconfigured" finding, so a CI run that asked for --brand or --terms cannot pass by silently doing nothing. Bind the resource in the .kapi project, drop the flag, or pass --no-fail to keep it report-only.

Exit codes: 0 pass, 3 when any gate fails (including a requested-but-unbound gate), 1 for operational errors. Exit 3 means "not on-spec yet", not a crash — in an assistant fix-loop, read the findings and fix. Pass --no-fail to always exit 0 (report mode) when looping; omit it for CI gating.

Commandverify
Groupquality
Watch it
verify needs network access, an API key, or local system access, so it can’t run in the browser playground.See the guides for a recorded run, or try it locally with the installed CLI.
Flags
FlagTypeDefaultDescription
--brandboolfalserun only the brand gate (combine with --terms/--qa to select several)
--jsonboolfalseoutput the structured result as JSON
--localestringscope terminology and QA to a single target locale (e.g. fr)
--min-scoreint80brand compliance score below which the brand gate fails
--no-failboolfalsereport only: exit 0 even when a gate fails (verdict is in the output/--json). Use inside an assistant fix-loop; omit for CI gating.
--project, -pstringpath to a .kapi project recipe (auto-discovered from cwd if omitted)
--qaboolfalserun only the QA gate
--source-langstringsource language (overrides the project's source_language)
--termbasestringnamed termbase or path to a glossary (defaults to the project termbase)
--termsboolfalserun only the terminology gate

← Back to the Command Reference