Welcome to Kiroha¶
Kiroha 0.8 uses .as[...] and .as(schema) for validation. If you are
upgrading from 0.7, see the migration guide.
Start with something small. Read a little data, write a clear function, and build from there. We'll take it one step at a time.
Kiroha is a small language for working with JSON, web services and databases. Its values are immutable, its decimal arithmetic is exact, and its functions have a clear beginning and a matching named end.
Write your first program Install Kiroha
fun greet(name:str)
"Hello, " + name + "!"
end fun greet
greet("Kiroha")
// "Hello, Kiroha!"
A comfortable place to begin¶
- Install Kiroha. One command installs a ready-to-run binary. You don't need Rust or a compiler.
- Write your first program. Save a file, run it, and learn how to read the result.
- Get to know functions. Give a piece of work a name, use local values, and try a callback.
- Work with a little data. Filter a list, transform its records, and add up exact decimal values.
Already have a task in mind?¶
- Read JSON from a web service, with a complete local example.
- Find help with an error. A small typo is a normal part of learning; the error message can help you find the next step.
- Look up a built-in function, its arguments and result.
- Explore the complete language guide at your own pace.
Writing Kiroha with an AI assistant¶
Kiroha is also designed for generated programs. To give an assistant the language's compact syntax and API guide, run:
kiroha spec --compact
Share that output along with your task, data shapes and any host configuration.
The compact guide describes the language; your task supplies the context.
You can check a generated file with kiroha check program.kiroha --json
before you run it.
A few things you can rely on¶
0.1 + 0.2 is exactly 0.3. A name keeps its value once it is bound.
External operations, such as HTTP requests or file writes, need permissions
that you choose in a host file.
You don't need to learn all of that at once. Start with the first program; the reference will be here when you need it.
You can also view and download the Kiroha icon and favicons.