Skip to Content
kusaw docsv1.0.0

Factories

A [factory](glossary.md#factory) is one `kusaw.yaml` plus one data directory. The registry only stores where those files live. `KUSAW_HOME` overrides the registry folder. The default is the user config directory, in a `kusaw` folder. [Triggers](glossary.md#trigger) (schedules and an [inbox](glossary.md#inbox) folder) queue task files while serve runs.

A factory is one kusaw.yaml plus one data directory. The registry only stores where those files live. KUSAW_HOME overrides the registry folder. The default is the user config directory, in a kusaw folder. Triggers (schedules and an inbox folder) queue task files while serve runs.

Commands

kusaw new <name> creates a folder, writes a version 2 kusaw.yaml, and registers it. --dir chooses the folder. --repo <label>=<path> points at a local git checkout. The first factory you create becomes the default.

kusaw list prints the registered factories.

kusaw use <name> changes the default.

kusaw forget <name> drops the registry entry and leaves the files. It refuses while that factory is being served.

kusaw register <path> adds an existing kusaw.yaml.

kusaw serve with no factory flag runs every healthy registered factory, each with its own queue. One stuck factory does not take the others' run slots.

How many factories

Put repositories that ship together in one factory. A change that has to land in the UI and the API at the same time belongs in one run, with both checkouts.

Keep separate products in separate factories. They get their own queue, budget, and data directory.

Do not split the same repositories into two factories by team or by kind of task. Specialize with steps, MCP servers, and skills on the one factory that owns those repositories.

The same checkout may be registered in two factories. kusaw new and kusaw validate warn when that happens, and both factories still run. Two factories on one checkout can publish conflicting branches, so keep one factory for a group of repositories that ship together.

On this page