# Configuration and files

Every key of `lamino.jsonc`, how a project is laid out, GLSL shader nodes, the camera file and the render job.

## lamino.jsonc

`lamino schema --config` prints this template: every key with its meaning and its default.

```jsonc
// lamino.jsonc: the project settings. Put it at the root of the project repository; it is shared by
// Windows, macOS and Linux. Print this template with `lamino schema --config` and save it as
// lamino.jsonc, UTF-8 (Laminolith never writes lamino.jsonc itself), then edit it.
//
// The format is JSON with comments (// and /* */) and trailing commas. Every key is listed below with
// its default; keys are camelCase. Unknown keys are errors (E_CONFIG names the key, the keys allowed
// there and the line), so a misspelt key never falls back to a default silently.
// Absolute paths are allowed only inside "roots"; every other path is project-relative or $ALIAS/...
{
  // For editors (completion, hover text, validation). Write the schema this points at with
  // `lamino schema --config-schema` (save it as lamino.schema.json next to this file, and again
  // after updating lamino). Laminolith itself does not read this key.
  "$schema": "./lamino.schema.json",

  // Project code (e.g. SHOW: upper-case letters, digits, "_"). Prefix of comp ids (SHOW_010) and of
  // output folder names. Required; empty is E_CONFIG.
  "project": "SHOW",

  // ---------------------------------------------------------------------------
  // Root aliases (the sandbox)
  // Every asset path in a comp is written $ALIAS/...; absolute paths and ".." are refused
  // (E_PATH_ABSOLUTE / E_PATH_PARENT). A root is "NAME": { ... } (NAME: upper case, digits, "_")
  // with these keys only:
  //   "windows":  "..."   the root's path on Windows   (e.g. "W:/PROJECTS/SHOW" or "//nas/projects")
  //   "macos":    "..."   the root's path on macOS
  //   "linux":    "..."   the root's path on Linux
  //   "readonly": true    plates and renders are read-only (default false)
  // A root without a path for the current OS is not declared on that OS (using it is
  // E_PATH_UNKNOWN_ALIAS, also reported by `lamino check`). A relative path is resolved against the
  // folder of this file (a submodule folder, a self-contained fixture). There is no "path" key.
  // Write "/" in Windows paths ("W:/PROJECTS"); a "\" must be doubled in JSON ("W:\\PROJECTS").
  // ---------------------------------------------------------------------------
  "roots": {
    // The project's assets (plates, renders, mattes, ST maps). Read-only.
    "SHOTS": {
      "windows": "//nas/projects",
      "macos": "/Volumes/projects",
      "linux": "/mnt/projects",
      "readonly": true
    },
    // Output. Written only inside versioned folders (..._v001/); existing frames are never overwritten.
    "OUT": {
      "windows": "//nas/projects/SHOW/out",
      "macos": "/Volumes/projects/SHOW/out",
      "linux": "/mnt/projects/SHOW/out"
    },
    // Studio-wide assets (glows, clouds, textures). Read-only.
    "ASSETS": {
      "windows": "//nas/library/assets",
      "macos": "/Volumes/library/assets",
      "readonly": true
    },
    // Fonts live inside the project (a font elsewhere is L_SYSTEM_FONT). A relative path into a submodule.
    "FONTS": {
      "windows": "common/fonts",
      "macos": "common/fonts",
      "linux": "common/fonts",
      "readonly": true
    },
    // Repo-local data read by json() / table() / readText() / values() (cue sheets, subtitles, beat tables).
    // A relative path resolves from this file's directory, so the files travel with the repository.
    // "DATA": {
    //   "windows": "data",
    //   "macos": "data",
    //   "linux": "data",
    //   "readonly": true
    // },
    // A local SSD, used by "cache" "dir" below as $CACHE/... Point it at a NAS share for a shared cache.
    "CACHE": {
      "windows": "D:/lamino-cache",
      "macos": "/Volumes/Scratch/lamino-cache",
      "linux": "/var/tmp/lamino-cache"
    }
  },

  // ---------------------------------------------------------------------------
  // Colour
  // ---------------------------------------------------------------------------
  "color": {
    // The OCIO config: a built-in one (builtin:aces-1.3 / builtin:aces-2.0) or a project-relative .ocio
    // (e.g. "common/ocio/studio.ocio"). Its hash is pinned in lamino.lock (L_LOCK_CONFIG_MISMATCH when it differs).
    "config": "builtin:aces-1.3",
    // The working space, as a role or name (scene_linear = ACEScg in the ACES configs). Every node computes in it.
    "working": "scene_linear"
    // Default display / view of `preview` and the review window. Omitted: the config's default.
    // , "display": "sRGB - Display"
    // , "view": "ACES 1.0 - SDR Video"
  },

  // ---------------------------------------------------------------------------
  // Proxies
  // ---------------------------------------------------------------------------
  "proxy": {
    // Long edge in pixels of the evaluation proxy the agent loop uses (4K becomes 1/4, HD 1/2).
    "longEdge": 960,
    // Scale-down of the source proxies `lamino proxy build` writes (1, 2, 4 or 8).
    "factor": 4,
    // EXR compression of source proxies: "none", "zip", "piz", "b44", "dwaa", ... Every build writes
    // dwaa / dwab; "htj2k32" / "htj2k256" need the OpenImageIO build (E_IMAGE_FORMAT otherwise).
    "compression": "dwaa"
  },

  // ---------------------------------------------------------------------------
  // Cache
  // ---------------------------------------------------------------------------
  "cache": {
    // Disk cache. Relative: under each shot's .lamino/; $ALIAS/...: under that root. Absolute is E_CONFIG.
    "dir": "$CACHE/SHOW",
    // Memory cache budget as a fraction of physical RAM (0.05 to 0.95).
    "ramFraction": 0.5,
    // Absolute cap of the memory cache in GiB (> 0). Omitted: no cap, the budget is RAM x ramFraction;
    // set, it is min(RAM x ramFraction, ramGib). One budget per process: set a cap on a machine that
    // runs several lamino processes or other heavy software.
    // "ramGib": 32,
    // Cap of the disk cache in GiB; the least recently used files go first. 0 = unlimited.
    "diskGib": 0
  },

  // ---------------------------------------------------------------------------
  // Directories `import` and GLSL `#include` may reach (project-relative). The shot's own folder is always
  // reachable. Put shared effects in common/ as a git submodule.
  // ---------------------------------------------------------------------------
  "lib": {
    "roots": ["lib", "common"]
  },

  // ---------------------------------------------------------------------------
  // Limits. Going over one is a structured error; nothing is scaled down silently.
  // ---------------------------------------------------------------------------
  "limits": {
    // Wall-clock limit of one frame (E_RESOURCE_LIMIT).
    "frameMs": 30000,
    // Target for one proxy frame; a node over half of it is L_SLOW_NODE.
    "proxyFrameMs": 1000,
    // Budget of one node at proxy level. Over it: E_COST_BUDGET (make it outside, or bake() it).
    "nodeMs": 500,
    // GPU memory budget in MiB. A frame over it is E_RESOURCE_LIMIT; a render runs fewer frames at once to stay
    // inside it. Omitted: automatic, decided when the device is created and when this file is reloaded. On a
    // hardware GPU (Windows): 75% of the video memory the OS lets the process use at that moment (less while
    // other software holds the card), never under 40% of the card. Where the OS reports none: 8192.
    // "gpuMb": 8192,
    // Run time of the comp file (E_SCRIPT_LIMIT).
    "scriptMs": 5000,
    // Heap of the comp file.
    "scriptMb": 256,
    // Timeout of one GLSL pass (against the Windows GPU watchdog).
    "shaderPassMs": 2000
  },

  // ---------------------------------------------------------------------------
  // Review window (`lamino review`)
  // ---------------------------------------------------------------------------
  "review": {
    // Playback cache (display-resolution 8-bit frames) in GiB. Omitted: automatic, a quarter of the memory the
    // frames live in: the video memory budget (see limits.gpuMb) with the window on a hardware GPU, the "cache"
    // RAM budget on the software adapter (taken out of that budget, not added to it).
    // "displayCacheGib": 2.0
  },

  // ---------------------------------------------------------------------------
  // Evaluation defaults
  // ---------------------------------------------------------------------------
  "eval": {
    // Backend when the command line (CLI or `lamino mcp`) passes no --backend:
    // "auto" | "cpu" | "gpu" | "gpu-software". Precedence: --backend > this > "auto":
    // the hardware GPU, else the CPU reference (LAMINO_GPU=software starts at the
    // software adapter, WARP; LAMINO_GPU=hardware insists on the hardware GPU). Read once per process.
    "backend": "auto"
  }
}
```

## Starting a project

`lamino schema --setup` prints this text.

```text
Starting a project (`lamino schema --setup` prints this section alone)

Laminolith writes no project file. It prints each starting file on stdout; you save it as UTF-8. In sh,
PowerShell 7 and cmd `>` does that. In Windows PowerShell 5 `>` writes UTF-16, which lamino refuses: use
`| Out-File -Encoding utf8 <file>` there, or write the text with your own file tool.

One project is one git repository named after the project code. In its root:

  lamino schema --config                  > lamino.jsonc        the settings: set "project" and the paths under "roots"
  lamino schema --config-schema           > lamino.schema.json  what "$schema" in lamino.jsonc points at (editors)
  lamino schema --dts                     > lamino.d.ts         types of the `lamino` modules (editors)
  lamino schema --template tsconfig.json  > tsconfig.json       editor setup for the comp files
  lamino schema --template glsl.d.ts      > glsl.d.ts           types `import src from "./x.glsl"`
  lamino schema --template .gitignore     > .gitignore          keeps .lamino/ and out/ out of git
  lamino schema --template CLAUDE.md      > CLAUDE.md           the working rules for the agent: replace <PROJECT>
                                                                in its heading, then read it

For each shot, make the folder shots/<shot>/ first (a redirect does not create it), then:

  lamino schema --template shot.comp.ts   > shots/<shot>/<shot>.comp.ts
                                          change the comp() id, res, fps, frames and the asset paths
  lamino check shots/<shot>/<shot>.comp.ts --json
                                          fix every diagnostic it reports, then work with `lamino dev <file>`

lamino.schema.json and lamino.d.ts are generated: print them again after updating lamino.

Required by lamino:
- lamino.jsonc at the project root. Every command finds the project by walking up from the comp file or the
  current directory (E_CONFIG_NOT_FOUND).
- Assets are read through the root aliases of lamino.jsonc ($SHOTS/...). Absolute paths and `..` are refused.
- A comp file imports, and a shader includes, only from its own folder and the folders of `lib.roots`.
- Renders go only into a versioned folder under $OUT ($OUT/<name>_v001/).
- git is needed by `render --job` (it renders a pinned commit) and by `git:<rev>` targets (`compare`,
  `preview --compare-with`); nothing else checks for a repository.

Conventions (not enforced, but CLAUDE.md, tsconfig.json and .gitignore are written for them):
- shots/<shot>/<shot>.comp.ts, one folder per shot. lamino writes .lamino/ next to the comp file and
  lamino.lock in the root.
- lib/ holds the project's own effects and common/ the shared ones (a git submodule: effects, fonts, LUTs,
  the OCIO config). Both are in `lib.roots` of the template.
- edit/<name>.otio holds timelines; data/ holds tables and text read by json() / table() / readText().

Commit lamino.jsonc, lamino.schema.json, lamino.d.ts, lamino.lock, tsconfig.json, glsl.d.ts, .gitignore,
CLAUDE.md and the comp files. Do not commit .lamino/ or out/.
```

## GLSL shader nodes

```text
GLSL shader nodes (Vulkan GLSL 450 via naga)

Write `void main()` that assigns `fragColor` (vec4, premultiplied, working space). Provided: `vec2 p` (pixel
centre in width units: x 0..1, y 0..H/W), `vec2 uv` (texture coords 0..1 on both axes), `vec2 resolution`
(display pixels at this proxy level), `int frame`, `float time`, `int seed`, and one uniform per declared param.
Read inputs with `texture(srcN, uv)` (bilinear, deterministic) or `texelFetch(srcN, ivec2)` (pixel coordinates at
this proxy level: `ivec2(floor(uv * resolution))` is the current pixel); with `temporal`,
`texture(srcN_prev, uv)` / `texture(srcN_next, uv)`. No sampler2D, no loose uniforms, no atomics.

Declarations (one per line):
  #pragma lamino param <name> <float|int|bool|vec2|vec3|vec4|color|enum(a,b,c)> [default=..] [min=..] [max=..] [unit=width|degrees|frames|stops|factor|meters]
  #pragma lamino inputs <n> [src<i>=data ...]   (0 for a generator; default 1; inputs x (1+before+after) <= 8)
  #pragma lamino padding <width units>   (how far the shader reads around a pixel)
  #pragma lamino temporal <before> <after>
  #pragma lamino hint pointwise      (one output pixel from the same input pixel: fusable, no padding needed)
  #pragma lamino version <n>         (bump when the output changes)
  #include "lib/noise.glsl"          (resolved inside the project / library roots)
Without `padding` or `hint pointwise` the node reads the whole input (lint L_SHADER_NO_MARGIN).

Data inputs: `src<i>=data` declares input i a data port; connect an aov() output to it (depth in metres from the
camera plane, +inf far; position / normal; motion; uv). The values arrive in the same `srcN` texture exactly as
aov() normalised them: no colour conversion, not premultiplied. Read them with texelFetch at the pixel: bilinear
`texture()` blends across depth edges and with +inf. An image cannot feed a data input, nor data an image input
(E_IR_PORT_TYPE). Example:

// Depth fog: src0 = the beauty (image), src1 = depth from aov() (data: metres, +inf where nothing was hit)
#pragma lamino inputs 2 src1=data
#pragma lamino param density float default=0.1 min=0
#pragma lamino param fogColor color default=[0.5,0.6,0.7,1]
#pragma lamino hint pointwise
void main() {
  ivec2 px = ivec2(floor(uv * resolution));   // this pixel, in pixels at the current proxy level
  vec4 c = texelFetch(src0, px);
  float z = texelFetch(src1, px).r;           // the exact depth: no blending across edges or with +inf
  float f = 1.0 - exp(-density * z);          // z = +inf gives f = 1
  fragColor = vec4(mix(c.rgb, fogColor.rgb * c.a, f), c.a);
}

Backends: shaders have no CPU kernel. With --backend cpu they alone run on the software adapter (WARP on Windows,
lavapipe on Linux); every other node stays on the CPU.
```

## The camera file

`lamino schema --camera` prints this JSON Schema of the file the `camera` node reads.

```json
{
 "$defs": {
  "CameraFileFrameV1": {
   "additionalProperties": false,
   "description": "One frame record of [`CameraFileV1`].",
   "properties": {
    "cameraToWorld": {
     "description": "16 numbers, column-major (see [`Mat4`]), translation in file units.",
     "items": {
      "format": "double",
      "type": "number"
     },
     "type": "array"
    },
    "far": {
     "description": "Perspective camera: far plane in file units (default 10000 m).",
     "format": "double",
     "type": [
      "number",
      "null"
     ]
    },
    "fit": {
     "anyOf": [
      {
       "$ref": "#/$defs/Fit"
      },
      {
       "type": "null"
      }
     ],
     "description": "Perspective camera: gate fit (default horizontal)."
    },
    "focalLengthMm": {
     "description": "Perspective camera: focal length in mm.",
     "format": "double",
     "type": [
      "number",
      "null"
     ]
    },
    "lensShift": {
     "description": "Perspective camera: lens shift (default `[0, 0]`).",
     "items": {
      "format": "double",
      "type": "number"
     },
     "maxItems": 2,
     "minItems": 2,
     "type": [
      "array",
      "null"
     ]
    },
    "near": {
     "description": "Perspective camera: near plane in file units (default 0.01 m).",
     "format": "double",
     "type": [
      "number",
      "null"
     ]
    },
    "sensorMm": {
     "description": "Perspective camera: sensor `[width, height]` in mm.",
     "items": {
      "format": "double",
      "type": "number"
     },
     "maxItems": 2,
     "minItems": 2,
     "type": [
      "array",
      "null"
     ]
    },
    "worldToNdc": {
     "description": "Matrix camera: 16 numbers, world → OpenGL clip.",
     "items": {
      "format": "double",
      "type": "number"
     },
     "type": [
      "array",
      "null"
     ]
    }
   },
   "required": [
    "cameraToWorld"
   ],
   "type": "object"
  },
  "Fit": {
   "description": "How the sensor is fitted to the render frame (see the module doc for the\nformulas). Default `horizontal` (Blender `AUTO` for landscape frames,\nMaya `Horizontal`, C4D's default).",
   "oneOf": [
    {
     "const": "horizontal",
     "description": "The sensor width maps to the render width.",
     "type": "string"
    },
    {
     "const": "vertical",
     "description": "The sensor height maps to the render height.",
     "type": "string"
    },
    {
     "const": "fill",
     "description": "The larger of the two scales: the frame is filled, the sensor is cropped.",
     "type": "string"
    },
    {
     "const": "overscan",
     "description": "The smaller of the two scales: the whole sensor is visible.",
     "type": "string"
    }
   ]
  }
 },
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "additionalProperties": false,
 "description": "Wire form of a `lamino-camera-v1` file (`lamino schema --camera` prints\nthis schema with a minimal example). The exporter scripts for Blender and\nCinema 4D (`blender_export_camera.py`, `c4d_export_camera.py`, shipped in\n`contrib/` next to the lamino executable) convert handedness, up axis and\nthe forward axis to the module conventions (right-handed, Y up, the camera\nlooking down −Z); the only unit conversion Laminolith does is\n`metersPerUnit` / `unit`.\n\n```json\n{\n  \"schema\": \"lamino-camera-v1\",\n  \"unit\": \"cm\",\n  \"renderAspect\": 1.7777778,\n  \"par\": 1.0,\n  \"frames\": {\n    \"1001\": {\n      \"cameraToWorld\": [1,0,0,0, 0,1,0,0, 0,0,1,0, 0,120,500,1],\n      \"focalLengthMm\": 35, \"sensorMm\": [36, 24], \"fit\": \"horizontal\",\n      \"lensShift\": [0, 0], \"near\": 1, \"far\": 100000\n    },\n    \"1002\": {\n      \"cameraToWorld\": [1,0,0,0, 0,1,0,0, 0,0,1,0, 0,120,480,1],\n      \"worldToNdc\": [1,0,0,0, 0,1,0,0, 0,0,-1,-1, 0,0,-0.2,0]\n    }\n  },\n  \"points\": {\n    \"launch_01\": { \"1001\": [12, 0, -340], \"1002\": [12, 4, -340] },\n    \"tower_top\": { \"1001\": [-80, 210, -900] }\n  }\n}\n```\n\nFrame keys are frame numbers (as JSON object keys they are strings); a frame\nrecord is `cameraToWorld` plus either the perspective fields or `worldToNdc`\n(never both). Unknown keys are errors.\n\n`points` (optional) holds named world-space positions — nulls,\nempties, locators — as `name → frame → [x, y, z]` in the **same** axes and\nlength unit as `cameraToWorld`'s translation; `metersPerUnit` / `unit` is\napplied to them once, like the translation. A file may hold camera frames,\npoints or both, but not neither: a points-only file (`frames` omitted) is\nvalid and needs no `renderAspect`. A file with one camera frame is a static\ncamera and a point with one frame a static point (see the module doc).",
 "examples": [
  {
   "frames": {
    "1001": {
     "cameraToWorld": [
      1,
      0,
      0,
      0,
      0,
      1,
      0,
      0,
      0,
      0,
      1,
      0,
      0,
      1.7,
      5,
      1
     ],
     "far": 10000,
     "fit": "horizontal",
     "focalLengthMm": 35,
     "lensShift": [
      0,
      0
     ],
     "near": 0.1,
     "sensorMm": [
      36,
      24
     ]
    }
   },
   "par": 1,
   "renderAspect": 1.7777778,
   "schema": "lamino-camera-v1",
   "unit": "m"
  }
 ],
 "properties": {
  "frames": {
   "additionalProperties": {
    "$ref": "#/$defs/CameraFileFrameV1"
   },
   "description": "Frame number → camera. May be omitted when the file has `points`.",
   "type": "object"
  },
  "metersPerUnit": {
   "description": "Metres per file length unit (default 1). Exclusive with `unit`.",
   "format": "double",
   "type": [
    "number",
    "null"
   ]
  },
  "par": {
   "description": "Pixel aspect ratio (default 1).",
   "format": "double",
   "type": [
    "number",
    "null"
   ]
  },
  "points": {
   "additionalProperties": {
    "additionalProperties": {
     "items": {
      "format": "double",
      "type": "number"
     },
     "maxItems": 3,
     "minItems": 3,
     "type": "array"
    },
    "type": "object"
   },
   "description": "Point name → frame number → `[x, y, z]` in file units.",
   "type": "object"
  },
  "renderAspect": {
   "description": "Pixel-count aspect W / H of the render the camera was set up for.\nRequired when the file has camera frames; optional for a points-only file.",
   "format": "double",
   "type": [
    "number",
    "null"
   ]
  },
  "schema": {
   "description": "Must be `\"lamino-camera-v1\"`.",
   "type": "string"
  },
  "unit": {
   "description": "Length unit shorthand: `m`, `cm` or `mm`. Exclusive with `metersPerUnit`.",
   "type": [
    "string",
    "null"
   ]
  }
 },
 "required": [
  "schema"
 ],
 "title": "CameraFileV1",
 "type": "object"
}
```

## The render job

`lamino schema --job-schema` prints this JSON Schema.

```json
{
 "$defs": {
  "ExrCompression": {
   "oneOf": [
    {
     "enum": [
      "none",
      "rle",
      "zips",
      "zip",
      "piz",
      "pxr24",
      "b44",
      "b44a",
      "dwaa",
      "dwab"
     ],
     "type": "string"
    },
    {
     "const": "htj2k32",
     "description": "OpenEXR 3.4 HT-JPEG 2000 (32-scanline chunks).",
     "type": "string"
    },
    {
     "const": "htj2k256",
     "description": "OpenEXR 3.4 HT-JPEG 2000 (256-scanline chunks).",
     "type": "string"
    }
   ]
  },
  "ExrPixelType": {
   "oneOf": [
    {
     "enum": [
      "half"
     ],
     "type": "string"
    },
    {
     "const": "float",
     "description": "Default for deliverables and the disk cache.",
     "type": "string"
    }
   ]
  },
  "ExrWriteOptions": {
   "additionalProperties": false,
   "properties": {
    "attributes": {
     "additionalProperties": {
      "type": "string"
     },
     "description": "String attributes added to the header (comp id, IR hash, engine version, …).",
     "type": "object"
    },
    "compression": {
     "$ref": "#/$defs/ExrCompression",
     "default": "zip"
    },
    "dwaLevel": {
     "description": "DWA quantisation level (OpenEXR `dwaCompressionLevel`, default 45 when\nunset; higher = smaller and lossier). Only valid with `dwaa` / `dwab`;\nfinite and `>= 0` (OpenEXR defines no maximum); see\n[`ExrWriteOptions::effective_dwa_level`]. This field is the only way to\nset the level: `dwaCompressionLevel` in `attributes` is refused like any\nother typed header attribute.\nBoth writers honour it (pure: exr 1.74 `Compression::DWAA(Some(level))`;\nOIIO: `compression = \"dwaa:<level>\"`). A writer that cannot honour an\nexplicit level must fail with `E_IMAGE_FORMAT`, never ignore it.",
     "format": "float",
     "type": [
      "number",
      "null"
     ]
    },
    "fps": {
     "anyOf": [
      {
       "$ref": "#/$defs/Rational"
      },
      {
       "type": "null"
      }
     ],
     "description": "Frame rate written to the typed `framesPerSecond` header attribute."
    },
    "pixelType": {
     "$ref": "#/$defs/ExrPixelType",
     "default": "float"
    },
    "rgbOnly": {
     "default": false,
     "description": "Write only RGB (drop alpha).",
     "type": "boolean"
    }
   },
   "type": "object"
  },
  "JobBackend": {
   "description": "Execution backend of a job. Same wire names as `--backend`; the default is\n`cpu` because managed renders run in containers without a verified Vulkan\nICD.",
   "enum": [
    "auto",
    "cpu",
    "gpu",
    "gpu-software"
   ],
   "type": "string"
  },
  "JobOptions": {
   "additionalProperties": false,
   "description": "Output options of a job.",
   "properties": {
    "exr": {
     "$ref": "#/$defs/ExrWriteOptions",
     "default": {
      "compression": "zip",
      "pixelType": "float",
      "rgbOnly": false
     },
     "description": "EXR write options (compression, pixel type, …). Default: the `render` defaults."
    },
    "keepOverscan": {
     "default": false,
     "description": "Keep the data window (overscan) in the written frames (`--keep-overscan`).\nOff by default: frames are cropped to the display window.",
     "type": "boolean"
    }
   },
   "type": "object"
  },
  "ProxyLevel": {
   "description": "Proxy factor: 1 (full), 2, 4 or 8.",
   "format": "uint32",
   "minimum": 0,
   "type": "integer"
  },
  "Rational": {
   "description": "A positive rational `num/den`. Serialized as `[num, den]`.",
   "maxItems": 2,
   "minItems": 2,
   "prefixItems": [
    {
     "format": "int64",
     "type": "integer"
    },
    {
     "format": "int64",
     "type": "integer"
    }
   ],
   "type": "array"
  }
 },
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "additionalProperties": false,
 "description": "Input of `lamino render --job <file>` (schemaVersion 1).",
 "properties": {
  "backend": {
   "$ref": "#/$defs/JobBackend",
   "default": "cpu"
  },
  "commit": {
   "description": "Full 40-hex commit SHA. The working tree's `HEAD` must equal it.",
   "pattern": "^[0-9a-f]{40}$",
   "type": "string"
  },
  "comp": {
   "description": "Comp file, relative to the repository root, forward slashes (`shots/010/010.comp.ts`).",
   "pattern": "^[^/\\\\].*\\.comp\\.ts$",
   "type": "string"
  },
  "env": {
   "additionalProperties": {
    "type": "string"
   },
   "description": "Environment the render runs with; only the names in the allowlist\n(`LAMINO_GPU`, `RAYON_NUM_THREADS`, `RUST_LOG`).",
   "type": "object"
  },
  "expectedLockHash": {
   "description": "`xxh3-<16 hex>` of the bytes of `lamino.lock` at `commit` (the engine\nwrites the lock canonically, so the committed bytes are the hashed text).\nWhen given, a different lock refuses the job before anything is rendered.",
   "pattern": "^xxh3-[0-9a-f]{16}$",
   "type": [
    "string",
    "null"
   ]
  },
  "frames": {
   "description": "Frames: `1001-1120`, `1,3,5-9`, `1-9x2` (the `--frames` syntax).",
   "minLength": 1,
   "type": "string"
  },
  "id": {
   "description": "Job id assigned by whoever queued the job; echoed in the result.",
   "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
   "type": "string"
  },
  "options": {
   "$ref": "#/$defs/JobOptions",
   "default": {
    "exr": {
     "compression": "zip",
     "pixelType": "float",
     "rgbOnly": false
    },
    "keepOverscan": false
   }
  },
  "out": {
   "description": "Output pattern in `$OUT` alias form with a version folder (`$OUT/<name>_v001/<name>.####.exr`).",
   "pattern": "^\\$OUT/",
   "type": "string"
  },
  "proxy": {
   "$ref": "#/$defs/ProxyLevel",
   "default": 1,
   "description": "Proxy factor (1 = full resolution)."
  },
  "repo": {
   "description": "Repository the runner clones (URL or `owner/name`). `lamino` itself does not read it.",
   "minLength": 1,
   "type": "string"
  },
  "schemaVersion": {
   "description": "Always 1 for this schema.",
   "format": "uint32",
   "minimum": 0,
   "type": "integer"
  }
 },
 "required": [
  "schemaVersion",
  "id",
  "repo",
  "commit",
  "comp",
  "frames",
  "out"
 ],
 "title": "Laminolith render job",
 "type": "object"
}
```
