AGPL-3.0-or-later · forever.

project policy · live

Make precedence visible.

Resolve spend, retention and provenance through explicit ladders so a constructor, environment and project file never fight silently.

Each project knob has one precedence law. Invocation intent can narrow a run, environment can govern operational retention, and the project can raise a provenance floor but never lower the operator policy.

The closest explicit run ceiling wins.

LocalNika maxCostUsd becomes the per-invocation engine flag. Without it, the project ceiling applies. Without either, the engine falls to its built-in posture. An armed beat still names plafond because scheduling money cannot inherit an ambiguous default.

LocalNika maxCostUsd / CLI flag
              ↓ wins
nika.yaml ceiling
              ↓ else
engine built-in default

arm[].plafond  = required per tick

Let deployment own trace retention.

The trace environment family overrides its matching project knob, then traces.keep supplies the project rung. This lets one immutable repo run under different retention obligations without editing the file on each host.

nika: my-project
traces:
  keep: 30d

A project can only raise the registry floor.

The project registry.floor max-composes with the operator policy under ~/.nika. A repository can demand stronger provenance, but it cannot weaken the machine owner policy. This rung is live for direct workflow operations and not yet accepted by the current arm and serve reader.

operator floor  ─┐
                 ├── MAX ── admitted artifact tier
project floor ───┘

Bind the SDK to the same project root.

Construct LocalNika once with the service cwd and pass only invocation-specific decisions per call. Do not duplicate project policy inside a second application configuration object.

export const nika = new LocalNika({ cwd: PROJECT_ROOT })

await nika.runToEnd('workflows/release.nika.yaml', {
  maxCostUsd: requestBudget,
  signal: request.signal,
})