Thanks for your interest! Here's how to get started.
git clone https://github.com/array2d/kvlang.git
cd kvlang
make buildPrerequisites: Go 1.24+, Redis (for integration tests).
# After making changes:
make vet # static analysis
make test # unit tests
python3 run.py # integration tests (requires Redis)cmd/kvlang/ CLI entry point
internal/
parser/ .kv source → AST
lower/ control flow lowering (if/while → block + branch)
layoutcode/ AST → KV path tree (opcodes at /vthread/*)
vthread/ virtual thread lifecycle
kvcpu/ 128-worker goroutine scheduler
kvspace/ KV storage abstraction (Redis backend)
vtype/ typed value system (int, float, bool, str, tensor)
op/
builtin/ native operators (arith, compare, logic, cast, call, io)
dispatch/ opcode → executor routing
device/ I/O device drivers (terminal, websocket)
tutorial/ step-by-step .kv programs (01-hello … 08-algo)
run.py integration test suite (~50 tests)
doc/ design documents, specs, drafts
- KV path addressing: code and data share one tree. Instructions are paths. Call = subtree copy.
- vthread: lightweight execution context. State stored as KV paths under
/vthread/<vtid>/. - typed values:
kvspace.Value{kind, raw}— kind maps directly tovtype.VType.Name().
feat:new featurefix:bug fixrefactor:code restructuringdocs:documentationtest:test additions
Open an issue or start a discussion.