kairo.toml.
Application vs Library packages
Every package declares akind in its manifest. There are two kinds:
application
A runnable program. Applications declare an entrypoint that Pulse invokes
at startup. An application package cannot be listed as a dependency of
another package — it is a terminal node in the build graph.
library
A reusable unit of code. Libraries expose a public API and can be
declared as dependencies by other packages — both other libraries and
applications. Only libraries may appear in a
[dependencies] section.Only
library packages can be used as dependencies. If you attempt to add an
application package as a dependency, Forge will report an error at restore
time.Standard project layout
Every Kairo package follows the same top-level directory structure. Forge and Studio both expect this layout, so keeping to it avoids configuration overhead and ensures tooling works correctly out of the box.Module-to-file mapping
Kairo uses module declarations as the authoritative source of identity — not the filesystem path. A module’s fully qualified name (e.g.,Astra.Customers.Orders) is what the compiler and other packages use to refer to it. The file path is a hint, not a contract.
That said, you should keep your filesystem layout aligned with your module names. The conventional mapping is:
- Use lowercase kebab-case for file names (e.g.,
customer-service.ak,order-line.ak). - Place one module declaration per file.
- A single module may span multiple files, as long as all those files live in the same directory.
- Transitive dependencies are not implicit source imports — you must explicitly import every module your code depends on, even if it comes from a package you depend on indirectly.
Next steps
Manifest
Learn every field in
kairo.toml — package identity, versioning,
entrypoints, and runtime configuration.Dependencies
Declare and lock your dependencies with
[dependencies] and forge.lock.