the deterministic authoring path
media-asset-pack
Agents do not invent structure — they instantiate it. Each skeleton below is a complete, valid workflow with # SLOT: markers at every decision point: route your intent, copy, fill the slots, nika check, done. Machines read the same pack at /templates/catalog.json; the originals live in the spec, conformance- gated on every push.
- 10skeletonsroute · copy · fill
- 94slot markersthe only blanks
- validevery fileconformance-gated
- sha256every copypinned, re-proven
take data, produce words, save them
- deterministic gather
- one model job
- explicit persist
watch X, act when Y
- jq extraction
- CEL skip-gate
- often zero model calls
do this for EVERY item
- runtime collection
- the full leash (max_parallel
- fail_fast
- retry)
only what changed since last run · survive bad input
- state read→diff→write
- `on_error: recover:` quarantine
research / review / open-ended
- plan-then-execute
- default-deny tools
- budgets
- typed final message
anything irreversible (deploy · send · publish)
- parallel gates
- assert
- `nika:prompt` GO
- `on_finally` record
understand a site (domain · theme · assets) from a URL
- fetch `traverse:` crawl
- one typed infer
- explicit persist
- zero exec
generate image/audio assets from a brief
- `nika:image_generate`
- `nika:jq` manifest
- local/mock provider first
media-asset-pack.nika.yaml# SPDX-License-Identifier: Apache-2.0# yaml-language-server: $schema=https://nika.sh/spec/v1/workflow.schema.json## TEMPLATE · media-asset-pack · brief → generate assets → manifest.# The shape for « generate image (or audio) assets from a creative brief ».## Instantiate (agents · deterministic) ·# 1. Copy this file · rename per the job (kebab-case).# 2. Fill every `# SLOT:` line · delete slot comments when filled.# 3. Validate · `nika check <file>` (or conformance/runner.py validate).# 4. Repair using the error's fix line · re-check until valid.# Native-first · generation is `nika:image_generate` (no provider curl ·# no OpenAI helper script); the manifest is `nika:jq` + `nika:write`.nika: v1workflow: media-asset-pack-template # SLOT: kebab-case workflow iddescription: "brief → render → manifest" # SLOT: one honest sentencemodel: ollama/qwen3.5:4b # SLOT: provider/model · local · zero keyvars: subject: "a calm cosmic landing hero" # SLOT: what the asset is about out_dir: "./out/assets" # SLOT: where assets landtasks: - id: brief infer: max_tokens: 600 prompt: | # SLOT: the creative direction · style · constraints Write one vivid, concrete image prompt for: ${{ vars.subject }}. No text in the image · no watermark · a calm central zone. schema: type: object additionalProperties: false properties: image_prompt: { type: string } required: [image_prompt] - id: render depends_on: [brief] invoke: tool: "nika:image_generate" args: provider: mock # SLOT: local | openai | gemini | xai (local/mock first) prompt: "${{ tasks.brief.output.image_prompt }}" output_dir: "${{ vars.out_dir }}" filename_prefix: "asset" # SLOT: filename stem - id: manifest depends_on: [brief, render] invoke: tool: "nika:jq" args: expression: "{ brief: .[0], images: .[1].images }" input: - "${{ tasks.brief.output }}" - "${{ tasks.render.output }}" - id: persist depends_on: [manifest] invoke: tool: "nika:write" args: path: "${{ vars.out_dir }}/manifest.json" create_dirs: true content: "${{ tasks.manifest.output }}"outputs: manifest: ${{ tasks.manifest.output }} # SLOT: the callable contractsha256 05765547f12024ef… · conformance-gated upstream · source
call a product API: upload a file, then create from it
- fetch `multipart:` upload
- masked secrets header
- mode/jq extraction
read a system's state (docker · kubectl · gh), explain it, keep the report
- argv-array exec (provable allowlist)
- parallel reads
- exec ledger
- one artifact
The protocol is mechanical: route with the phrases above, instantiate, fill the slots, then nika check teaches anything you missed before anything runs. Try one in the playground, or install and start from a real file. Read the spec →