## A SOCKS5 rotator config.
service: socks5-rotator
port: 20082
debug: true
upstreams: [
{ host: a.example, weight: 0.7 }
]
## dotted keys = flat nesting
node.host: a.example
## '::' forces a literal string
node.auth:: p@ss:word
| Feature | JSON | YAML | TOML | INI | Ktav |
|---|
✓ present · ~ partial · ✕ absent
$ cargo add ktav
$ npm i @ktav-lang/ktav
$ pip install ktav
$ go get github.com/ktav-lang/golang
$ composer require ktav-lang/ktav
$ implementation("io.github.ktav-lang:ktav:0.6.0")
$ dotnet add package Ktav
JSON is hostile to hand-edit — quotes, commas, no comments. YAML fixes the ergonomics but adds traps: significant indentation and silent type coercion (the infamous no → false “Norway” bug). TOML is solid but splits tables vs inline. Ktav keeps JSON's shape and drops the punctuation tax — without inheriting YAML's surprises.
Types are inferred by strict lexical form: only true/false/null and a strict number grammar are typed — everything else is a string, and :: forces a literal when you need it. No guessing. Plus dotted keys for flat edits, multi-line strings, and one small spec with one parser.
No — and that's the point. On day one Ktav ships official parsers for 7 languages over a single Rust core, a tree-sitter grammar, an LSP, VS Code / JetBrains plugins, and a language-agnostic conformance suite. Identical behaviour everywhere, verified by tests.
Ktav is a configuration language, not a data-interchange format — don't swap it for JSON in an API. If you need schemas, types and logic inside the config itself, tools like CUE or Dhall go further. Ktav deliberately stays small and readable.