Gå til hovedinnhold

Architecture Decisions — neokapi Framework

This directory contains the Architecture Decisions for the neokapi framework — the open localization engine. All content here is Apache-2.0 licensed and describes modules at the repository root (github.com/neokapi/neokapi), the shared CLI base (github.com/neokapi/neokapi/cli), the kapi CLI (github.com/neokapi/neokapi/kapi), and Kapi Desktop (github.com/neokapi/neokapi/kapi-desktop).

Tactical implementation details (SQL schemas, wire protocols, algorithm pseudocode) are separated into Implementation Notes.

Foundation

ADTitleScope
001Vision and ModulesGo modules, go.work, dependency boundaries, license gradient
002Content ModelPart/Resource, Block, Run, Overlay, semantic vocabulary, Layers
003IdentityBase62 IDs, dual block identity

Processing

ADTitleScope
004Processing EngineChannel-based streaming, Executor, parallel block tools, collectors
005Format SystemDataFormatReader/Writer, detection, registries, skeleton strategies
006Tool SystemBaseTool, locale cardinality, annotations, side effects, schemas
007Plugin Systemmanifest-driven out-of-process plugins, gRPC, presets, Okapi bridge
021SaT Segmenter Pluginin-process ONNX SaT model, stdin/stdout protocol, native-stack isolation, sat engine
026Flow I/O Bindingsource/sink bindings, file·store·klz·import/export, process-only runs, ingest vs run transforms
028PDF Reader & Structure TiersPDFium native plugin + browser WASM, geometry/glyphs, tagged + geometric structure tiers
029Vision & Image Localizationimage as localizable asset; kapi-vision OCR (PP-OCRv5) + layout (PP-DocLayoutV3), path-based, localization modes

Project Model

ADTitleScope
008Project Model.kapi recipe, .kapi/ state, BlockStore interface, ProjectContext

Intelligence

ADTitleScope
009Translation MemorySievepen, tiered matching, generalized matching with entities
010TerminologyConcept model, TermBase, tiered lookup
011AI ProvidersLLMProvider, streaming, batching, worker pool
012MT ProvidersMTProvider interface, built-in backends
022Brand VoiceVoiceProfile, starter packs, vocab/voice checks, scoring, command + MCP surface

Applications

ADTitleScope
013Kapi CLIStandalone CLI, output formats, credential store, MCP server
014Kapi DesktopWails v3 app, flow editor, runner, plugin manager
019Kapi ReactReact i18n runtime, build-time extraction, __tx re-attach
023Toolbox Utilitieskcat/kgrep/ksed busybox multi-call, block-text projection, exit codes
024Agent Skillsembedded SKILL.md routers, .claude/skills install, kapi-/bowrain- split
027Visual EditorContentTree→RenderDoc projection, vocabulary/overlay rendering, shared preview kit, edit→commit round-trip

Cross-Cutting

ADTitleScope
015Testing and DocumentationTest pyramid, Docusaurus, screenshots, recordings
016Metadata i18nTool/format/plugin metadata translation via MO catalogs
017Bilingual Format InteropXLIFF/PO/TMX bilingual round-trip, target alignment
018Parity TestingOkapi parity harness, test-comparison dashboard, faithful%
020Content RedactionPlaceholder model, local vault, rule/entity detection, secure-translate, extract/merge