Progressive examples demonstrating VVM language and orchestration features with runnable programs.
Run any example:
/vvm-run examples/01-hello-world.vvmCompile/validate without running:
/vvm-compile examples/01-hello-world.vvmState mode examples:
/vvm-run examples/38-rlm-diff-time-machine.vvm --state=filesystem
/vvm-run examples/38-rlm-diff-time-machine.vvm --state=sqlite
/vvm-run examples/38-rlm-diff-time-machine.vvm --state=postgresCurrent runnable examples in this folder: 01-13, 15-39 (14 is intentionally unused).
| # | File | Focus |
|---|---|---|
| 01 | hello-world | Minimal agent definition and call |
| 02 | simple-agent-call | Input passing and interpolation |
| 03 | semantic-predicate | ? semantic predicates |
| 04 | match-statement | Semantic pattern matching |
| 05 | if-elif-else | Conditional branching |
| 06 | while-loop | Bounded iteration with while |
| 07 | for-loop | Collection iteration and range() |
| 08 | with-input | Scoped implicit input via it |
| 09 | agent-options | retry, timeout, backoff, call naming |
| 10 | code-council | Multi-perspective review council |
| 11 | parallel-pmap | Parallel map (pmap) |
| 12 | functions | def and reusable composition |
| 13 | skill-imports | Skill imports and permissions |
| 15 | error-values | Error values and graceful fallback |
| 16 | try-except-finally | Raised-error control flow |
| 17 | choose-statement | AI-routed branching with choose |
| 18 | constrain-require | Quality gates with constrain/require |
| 19 | refine-loop | Iterative optimize/evaluate loop |
| 20 | collection-helpers | map, filter, reduce, pmap |
| # | File | Focus |
|---|---|---|
| 21 | devils-advocate | Adversarial debate and synthesis |
| 22 | full-research-pipeline | End-to-end multi-agent PR review pipeline |
| 23 | ralph-wiggum-loop | Autonomous iterative shipping loop |
| 39 | pr-babysitter | Continuous autonomous PR maintenance until merge |
| # | File | Focus |
|---|---|---|
| 24 | agent-memory-basic | Basic persistent memory lifecycle |
| 25 | agent-memory-modes | continue vs dry_run vs fresh |
| 26 | agent-memory-multi-tenant | Per-key isolation and tenancy |
| 27 | agent-memory-parallel-safe | Parallel-safe memory workflow |
| # | File | Focus |
|---|---|---|
| 28 | ref-composition | Ref passing across calls |
| 29 | ref-loop-accumulation | Ref accumulation in loops |
| 30 | materializer-pattern | Controlled ref materialization |
| 31 | run-inspector | Inspecting run artifacts |
| # | File | Focus |
|---|---|---|
| 32 | ouroboros | Meta-programming and self-reference |
| 33 | wisdom-of-crowds | N-of-M parallel voting (join="any") |
| 34 | hydra | Resilient racing (join="first") |
| 35 | forge | Parallel work + sequential memory merge |
| # | File | Focus |
|---|---|---|
| 36 | inputs | Module input declarations + export contract |
| 37 | debate | Callable module composition (* as module) |
| # | File | Focus |
|---|---|---|
| 38 | rlm-diff-time-machine | Recursive git diff archaeology (default pydantic/pydantic) |
| File | Purpose |
|---|---|
| lib/position.vvm | Generates a position for a debate stance |
| lib/critique.vvm | Critiques an argument for composition workflows |
For callable modules, VVM derives workflow outputs from export declarations:
input ...declares required/optional inputsexport namedeclares contract output keysfrom "./x.vvm" import * as modandmod(...)returns an object keyed by exported names
Examples mapped to common agentic patterns:
| Pattern | Examples |
|---|---|
| Augmented LLM | 13 |
| Prompt Chaining | 22 |
| Routing | 04, 17 |
| Parallelization | 11, 20, 33, 34 |
| Orchestrator-Workers | 10, 21, 35 |
| Evaluator-Optimizer | 19 |
| Autonomous Agent | 23 |
| Memory-safe Parallelism | 27, 35 |
| Recursive Decomposition (RLM) | 38 |
| Autonomous PR Operations | 39 |