Introduction
Lutra is a statically typed language for querying data and describing data structures.
It is designed around a few ideas:
- values have clear, explicit types,
- programs are built from expressions,
- pipelines make data flow easy to read,
- the same Lutra program can target different execution backends.
A small Lutra program looks like this:
const my_ints: [Int32] = [1, 2, 3]
func main() -> my_ints | map(x -> x * 2)
When you run it, Lutra evaluates the main function and prints the result:
$ lutra run --project example.lt --runner interpreter
const output = [
2,
4,
6,
]
A typical Lutra program combines:
- types such as tuples, arrays, and enums,
- functions that transform values,
- pipelines that keep transformations readable,
- modules that organize code into projects.
How to read the docs¶
Use the docs by intent:
- Start with Learn / Basics if you want your first runnable examples.
- Go to Usage if you want task-oriented guides for the CLI, Python, or Rust.
- Go to the Reference if you want exact information about the language, runners, or internals.
Learning path¶
The recommended order is: