@yasaswy.nagavolu/agents 0.18.1 → 0.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/content/proxy/edit_videos_intent_hook.py +2 -1
  2. package/content/skills/code-is-law/lint_skill.py +90 -5
  3. package/content/skills/code-is-law/tests/conftest.py +4 -0
  4. package/content/skills/code-is-law/tests/test_lint_skill.py +125 -0
  5. package/content/skills/edit-videos/SKILL.md +38 -10
  6. package/content/skills/edit-videos/actions.json +1495 -0
  7. package/content/skills/edit-videos/engine/actions_catalog.py +197 -0
  8. package/content/skills/edit-videos/engine/cli.py +163 -4
  9. package/content/skills/edit-videos/engine/qa/__init__.py +5 -0
  10. package/content/skills/edit-videos/engine/qa/caption_probe.py +27 -0
  11. package/content/skills/edit-videos/engine/qa/context.py +106 -0
  12. package/content/skills/edit-videos/engine/qa/continuity.py +77 -0
  13. package/content/skills/edit-videos/engine/qa/coverage.py +103 -0
  14. package/content/skills/edit-videos/engine/qa/frames.py +49 -0
  15. package/content/skills/edit-videos/engine/qa/geometry.py +21 -0
  16. package/content/skills/edit-videos/engine/qa/imaging.py +58 -0
  17. package/content/skills/edit-videos/engine/qa/limits.py +97 -0
  18. package/content/skills/edit-videos/engine/qa/readability.py +68 -0
  19. package/content/skills/edit-videos/engine/qa/registry.py +41 -0
  20. package/content/skills/edit-videos/engine/qa/sampling.py +6 -0
  21. package/content/skills/edit-videos/engine/schema.py +41 -1
  22. package/content/skills/edit-videos/exit_codes.py +67 -0
  23. package/content/skills/edit-videos/pyproject.toml +1 -1
  24. package/content/skills/edit-videos/resolve_ui/guards.py +11 -10
  25. package/content/skills/edit-videos/tests/qa/conftest.py +21 -0
  26. package/content/skills/edit-videos/tests/qa/test_continuity.py +83 -0
  27. package/content/skills/edit-videos/tests/qa/test_coverage.py +135 -0
  28. package/content/skills/edit-videos/tests/qa/test_limits.py +103 -0
  29. package/content/skills/edit-videos/tests/qa/test_readability.py +82 -0
  30. package/content/skills/edit-videos/tests/qa/test_registry.py +42 -0
  31. package/content/skills/edit-videos/tests/test_actions_catalog.py +148 -0
  32. package/content/skills/edit-videos/tests/test_cli_qa.py +146 -0
  33. package/content/skills/edit-videos/tests/test_schema.py +30 -0
  34. package/content/skills/edit-videos/workspace.py +1 -1
  35. package/package.json +1 -1
@@ -18,7 +18,8 @@ _NUDGE = (
18
18
  "clicking — it edits video through a local engine (edit-spec driven "
19
19
  "cut/trim/blur/caption/export) and can drive Resolve's normal UI for "
20
20
  "timeline import/handoff. See ~/.claude/skills/edit-videos/SKILL.md for "
21
- "the full command table."
21
+ "the workflow, and ~/.claude/skills/edit-videos/actions.json for the "
22
+ "full generated, machine-readable command catalogue."
22
23
  )
23
24
 
24
25
  # Unambiguous: fire regardless of any negative match.
@@ -11,12 +11,97 @@ Exit: 0 = clean, 2 = warnings only, 1 = error (missing/broken frontmatter, or f
11
11
  """
12
12
  from __future__ import annotations
13
13
 
14
+ import json
15
+ import os
14
16
  import re
17
+ import shlex
18
+ import subprocess
15
19
  import sys
16
20
  from pathlib import Path
17
21
 
18
22
  MAX_LINES = 100 # CLAUDE.md: aim < 100 lines
19
23
  MAX_CODE_BLOCK = 20 # an inline fenced block longer than this should be a companion script
24
+ RENDER_TIMEOUT = 120
25
+
26
+ MARKER_RE = re.compile(
27
+ r"<!--\s*(?P<name>[\w-]+):begin[^\n]*-->\n(?P<body>.*?)\n?<!--\s*(?P=name):end\s*-->",
28
+ re.DOTALL,
29
+ )
30
+ GENERATED_RE = re.compile(r"^\s*generated:\s*(?P<json>\{.*\})\s*$", re.MULTILINE)
31
+
32
+
33
+ def _frontmatter(text: str) -> str | None:
34
+ m = re.match(r"^---\s*\n(.*?)\n---", text, re.DOTALL)
35
+ return m.group(1) if m else None
36
+
37
+
38
+ def _generated_map(frontmatter: str):
39
+ """None = no 'generated:' key (fine, no markers expected). {} on
40
+ malformed JSON, so callers can tell 'declared but broken' apart."""
41
+ m = GENERATED_RE.search(frontmatter)
42
+ if not m:
43
+ return None
44
+ try:
45
+ return json.loads(m.group("json"))
46
+ except json.JSONDecodeError:
47
+ return {}
48
+
49
+
50
+ def _resolve_renderer(skill_dir: Path, cmd: str) -> tuple[list[str] | None, str | None]:
51
+ """Split cmd with no shell and confirm argv[0] is an executable inside skill_dir.
52
+ Returns (argv, None) on success or (None, error message) on failure."""
53
+ try:
54
+ argv = shlex.split(cmd, posix=os.name != "nt")
55
+ except ValueError as e:
56
+ return None, f"renderer command could not be parsed: {e}"
57
+ if not argv:
58
+ return None, "renderer command is empty"
59
+ exe = (skill_dir / argv[0]).resolve()
60
+ try:
61
+ exe.relative_to(skill_dir.resolve())
62
+ except ValueError:
63
+ return None, "renderer must be an executable inside the skill directory"
64
+ if not exe.is_file():
65
+ return None, (f"renderer executable not found: {exe} - "
66
+ f"run `uv sync` in {skill_dir}")
67
+ return [str(exe), *argv[1:]], None
68
+
69
+
70
+ def _check_generated_blocks(path: Path, text: str, frontmatter: str) -> list[tuple[str, str]]:
71
+ markers = list(MARKER_RE.finditer(text))
72
+ if not markers:
73
+ return []
74
+ generated = _generated_map(frontmatter)
75
+ if generated is None:
76
+ return [("E", "has generated blocks but frontmatter has no 'generated:' map")]
77
+ skill_dir = path.parent.resolve()
78
+ out: list[tuple[str, str]] = []
79
+ for m in markers:
80
+ name = m.group("name")
81
+ cmd = generated.get(name)
82
+ if not cmd:
83
+ out.append(("W", f"marker '{name}' has no renderer in frontmatter 'generated:'"))
84
+ continue
85
+ argv, err = _resolve_renderer(skill_dir, cmd)
86
+ if err:
87
+ out.append(("E", f"marker '{name}' {err}"))
88
+ continue
89
+ try:
90
+ proc = subprocess.run(argv, shell=False, cwd=skill_dir,
91
+ capture_output=True, text=True, timeout=RENDER_TIMEOUT)
92
+ except Exception as e:
93
+ out.append(("E", f"marker '{name}' renderer crashed: {e}"))
94
+ continue
95
+ if proc.returncode != 0:
96
+ out.append(("E", f"marker '{name}' renderer failed (exit {proc.returncode}): "
97
+ f"{proc.stderr.strip()[:300]}"))
98
+ continue
99
+ rendered = proc.stdout.replace("\r\n", "\n").strip("\n")
100
+ committed = m.group("body").replace("\r\n", "\n").strip("\n")
101
+ if rendered != committed:
102
+ out.append(("E", f"marker '{name}' is out of sync with its renderer - "
103
+ f"run it and commit the result: {cmd}"))
104
+ return out
20
105
 
21
106
 
22
107
  def lint(path: Path) -> list[tuple[str, str]]:
@@ -25,15 +110,15 @@ def lint(path: Path) -> list[tuple[str, str]]:
25
110
  lines = text.splitlines()
26
111
  out: list[tuple[str, str]] = []
27
112
 
28
- m = re.match(r"^---\s*\n(.*?)\n---", text, re.DOTALL)
29
- if not m:
113
+ frontmatter = _frontmatter(text)
114
+ if frontmatter is None:
30
115
  out.append(("E", "missing YAML frontmatter (--- ... ---)"))
31
116
  else:
32
- fm = m.group(1)
33
- if not re.search(r"^\s*name:\s*\S", fm, re.MULTILINE):
117
+ if not re.search(r"^\s*name:\s*\S", frontmatter, re.MULTILINE):
34
118
  out.append(("E", "frontmatter missing 'name:'"))
35
- if not re.search(r"^\s*description:\s*\S", fm, re.MULTILINE):
119
+ if not re.search(r"^\s*description:\s*\S", frontmatter, re.MULTILINE):
36
120
  out.append(("E", "frontmatter missing 'description:'"))
121
+ out.extend(_check_generated_blocks(path, text, frontmatter))
37
122
 
38
123
  if len(lines) > MAX_LINES:
39
124
  out.append(("W", f"{len(lines)} lines > {MAX_LINES} — move HOW into a companion script"))
@@ -0,0 +1,4 @@
1
+ import sys
2
+ from pathlib import Path
3
+
4
+ sys.path.insert(0, str(Path(__file__).resolve().parent.parent))
@@ -0,0 +1,125 @@
1
+ import json
2
+ import os
3
+ import shutil
4
+ import sys
5
+ from pathlib import Path
6
+
7
+ import lint_skill
8
+
9
+ FRONTMATTER = """---
10
+ name: t
11
+ description: d
12
+ """
13
+
14
+
15
+ def _write(tmp_path, body, generated=None):
16
+ fm = FRONTMATTER
17
+ if generated is not None:
18
+ fm += f"generated: {generated}\n"
19
+ fm += "---\n\n" + body
20
+ path = tmp_path / "SKILL.md"
21
+ path.write_text(fm, encoding="utf-8")
22
+ return path
23
+
24
+
25
+ def _python_inside(tmp_path):
26
+ """Hardlink (or copy) the real interpreter into tmp_path so a renderer
27
+ command can point at an executable that legitimately lives inside the
28
+ skill directory, the way `.venv\\Scripts\\python.exe` does for real."""
29
+ dest = tmp_path / Path(sys.executable).name
30
+ if not dest.exists():
31
+ try:
32
+ os.link(sys.executable, dest)
33
+ except OSError:
34
+ shutil.copy2(sys.executable, dest)
35
+ return dest
36
+
37
+
38
+ def _renderer_cmd(tmp_path, name, script_body):
39
+ python = _python_inside(tmp_path)
40
+ script = tmp_path / f"{name}.py"
41
+ script.write_text(script_body, encoding="utf-8")
42
+ return json.dumps(f"{python.name} {script.name}")
43
+
44
+
45
+ def test_no_markers_unchanged_behaviour(tmp_path):
46
+ path = _write(tmp_path, "# t\n\nno markers here\n")
47
+ findings = lint_skill.lint(path)
48
+ assert findings == []
49
+
50
+
51
+ def test_in_sync_block_passes(tmp_path):
52
+ cmd = _renderer_cmd(tmp_path, "render_ok", "print('hello')")
53
+ generated = "{" + f'"x": {cmd}' + "}"
54
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
55
+ path = _write(tmp_path, body, generated=generated)
56
+ findings = lint_skill.lint(path)
57
+ assert findings == [], findings
58
+
59
+
60
+ def test_drifted_block_fails(tmp_path):
61
+ cmd = _renderer_cmd(tmp_path, "render_ok", "print('hello')")
62
+ generated = "{" + f'"x": {cmd}' + "}"
63
+ body = "<!-- x:begin source=s.json -->\nSTALE\n<!-- x:end -->\n"
64
+ path = _write(tmp_path, body, generated=generated)
65
+ findings = lint_skill.lint(path)
66
+ assert any(sev == "E" and "out of sync" in msg for sev, msg in findings), findings
67
+
68
+
69
+ def test_renderer_failure_fails_loudly(tmp_path):
70
+ cmd = _renderer_cmd(tmp_path, "render_fail", "import sys; sys.exit(3)")
71
+ generated = "{" + f'"x": {cmd}' + "}"
72
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
73
+ path = _write(tmp_path, body, generated=generated)
74
+ findings = lint_skill.lint(path)
75
+ assert any(sev == "E" and "renderer failed" in msg for sev, msg in findings), findings
76
+
77
+
78
+ def test_marker_without_generated_map_errors(tmp_path):
79
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
80
+ path = _write(tmp_path, body, generated=None)
81
+ findings = lint_skill.lint(path)
82
+ assert any(sev == "E" and "no 'generated:' map" in msg for sev, msg in findings)
83
+
84
+
85
+ def test_marker_with_no_renderer_entry_warns(tmp_path):
86
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
87
+ path = _write(tmp_path, body, generated="{}")
88
+ findings = lint_skill.lint(path)
89
+ assert any(sev == "W" and "no renderer" in msg for sev, msg in findings)
90
+
91
+
92
+ def test_renderer_outside_skill_dir_is_error(tmp_path):
93
+ generated = "{" + f'"x": {json.dumps(sys.executable)}' + "}"
94
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
95
+ path = _write(tmp_path, body, generated=generated)
96
+ findings = lint_skill.lint(path)
97
+ assert any(sev == "E" and "inside the skill directory" in msg for sev, msg in findings), findings
98
+
99
+
100
+ def test_bare_python_is_error(tmp_path):
101
+ generated = "{" + '"x": "python script.py"' + "}"
102
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
103
+ path = _write(tmp_path, body, generated=generated)
104
+ findings = lint_skill.lint(path)
105
+ assert any(sev == "E" and "not found" in msg for sev, msg in findings), findings
106
+
107
+
108
+ def test_missing_executable_gives_uv_sync_hint(tmp_path):
109
+ generated = "{" + '"x": ".venv/Scripts/python.exe script.py"' + "}"
110
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
111
+ path = _write(tmp_path, body, generated=generated)
112
+ findings = lint_skill.lint(path)
113
+ assert any(sev == "E" and "not found" in msg and "uv sync" in msg
114
+ for sev, msg in findings), findings
115
+
116
+
117
+ def test_path_traversal_renderer_is_error(tmp_path):
118
+ outside = tmp_path.parent / Path(sys.executable).name
119
+ if not outside.exists():
120
+ shutil.copy2(sys.executable, outside)
121
+ generated = "{" + f'"x": "../{outside.name}"' + "}"
122
+ body = "<!-- x:begin source=s.json -->\nhello\n<!-- x:end -->\n"
123
+ path = _write(tmp_path, body, generated=generated)
124
+ findings = lint_skill.lint(path)
125
+ assert any(sev == "E" and "inside the skill directory" in msg for sev, msg in findings), findings
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: edit-videos
3
3
  description: Edit videos end to end on this machine — cut/trim, speed up idle stretches, crop, blur private areas (fixed or tracked), add captions/titles, export an H.264 MP4 under a size limit (e.g. ≤50 MB for TikTok), review with contact sheets, and put the edit into DaVinci Resolve (project "claude-space"). Use when the user says "edit videos", "edit this video/recording/footage", "cut/trim/blur/caption this video", "make a tiktok/reel from this recording", "export under N MB", "use davinci resolve", "open it in resolve", or invokes /edit-videos.
4
+ generated: {"actions": ".venv\\Scripts\\python.exe -m engine actions --print-block actions", "exit-codes": ".venv\\Scripts\\python.exe -m engine actions --print-block exit-codes"}
4
5
  ---
5
6
 
6
7
  # edit-videos
@@ -15,14 +16,40 @@ $PY = "$HOME\.claude\skills\edit-videos\.venv\Scripts\python.exe"
15
16
 
16
17
  Every command prints exactly one JSON object on stdout; pass `--job <slug>` to every command (accepted even where unused). Read the JSON; do not parse free text. A usage error is also JSON, on stdout, non-zero exit. Add `--verbose` (before the subcommand) to see the underlying ffmpeg/ffprobe commands on stderr; omit it for a clean pipe.
17
18
 
19
+ ## Commands (generated from argparse; full detail in `actions.json`)
20
+ <!-- actions:begin source=actions.json -->
21
+ | Tool | Verb | Help | Key args |
22
+ |---|---|---|---|
23
+ | `engine` | `contact-sheet` | build a contact sheet PNG for a video | [<video>] |
24
+ | `engine` | `detect-idle` | find idle/frozen stretches and propose a speed array | [<video>] |
25
+ | `engine` | `export-timeline` | write a Resolve-importable timeline (FCPXML or OTIO) | <spec> --format |
26
+ | `engine` | `gc` | garbage-collect stale/expired jobs | - |
27
+ | `engine` | `job list` | list all jobs and their lifecycle state | - |
28
+ | `engine` | `job set-state` | set a job's lifecycle state | <slug> <state> |
29
+ | `engine` | `job show` | show one job's lifecycle state | <slug> |
30
+ | `engine` | `map-time` | convert a time between source/edit-timeline/render-timeline seconds | --spec |
31
+ | `engine` | `probe` | print an ffprobe summary as JSON | [<video>] |
32
+ | `engine` | `qa` | prove a rendered MP4 honours its spec via the check registry | [<spec>] |
33
+ | `engine` | `render` | render an edit-spec to a final MP4 | <spec> |
34
+ | `engine` | `validate` | validate an edit-spec JSON file | <spec> |
35
+ | `resolve_ui` | `gc` | delete Resolve bins/timelines the workspace gc has flagged | - |
36
+ | `resolve_ui` | `import-subtitle` | import an SRT into an existing job's timeline | <job> <srt> |
37
+ | `resolve_ui` | `import-timeline` | import an FCPXML/OTIO/EDL into the current bin | <file> |
38
+ | `resolve_ui` | `launch` | start Resolve if not running, wait until ready | - |
39
+ | `resolve_ui` | `new-job` | new bin+timeline <job> inside claude-space, import fcpxml into it | <job> <fcpxml> |
40
+ | `resolve_ui` | `open-page` | switch to a Resolve page | <page> |
41
+ | `resolve_ui` | `open-project` | open (or create once) the claude-space project | - |
42
+ | `resolve_ui` | `screenshot` | capture the Resolve window | - |
43
+ | `resolve_ui` | `status` | report whether Resolve is running and on claude-space | - |
44
+ <!-- actions:end -->
45
+
18
46
  ## Workflow
19
47
 
20
48
  1. **Job.** Pick a short slug for the job (e.g. `tiktok-audit-demo`). All files land in `D:\davinci\claude-space\<job>\` (`spec\`, `work\`, `handoff\`, `renders\`, `contact-sheets\`, `screenshots\`). Two commands sharing a job's `work\` wait for each other; a stale lock from a crashed run clears itself after an hour.
21
49
  2. **Look before you cut.** `probe <video>` each source; a `"vfr": true` result carries a `hint` (e.g. adb screenrecord) — set `fps` explicitly in the spec if you don't want the average rate. Build a first spec with `sources` + `segments`, and mark every stretch whose text the viewer must read (URLs, settings, consent lines) as `keep_1x`. `detect-idle --spec <spec> --edit-timeline` proposes idle ranges at the default 2x factor (`--factor` to change it) — start there instead of guessing. Then `contact-sheet --spec <spec> --edit-timeline --frames 24` (add `--from/--to`, edit-timeline seconds, to zoom into one stretch; a low-res proxy is built once per job and reused) and Read the PNG; `probe --spec <spec> --edit-timeline --from/--to` gives exact numbers for that window. Pick every time and box from the sheet; if a time comes from the *source* clip instead, convert it with `map-time --spec <spec> --source <id> --t <sec>` (`--edit-t <sec>` or `--render-t <sec>`, from a rendered MP4, the other way).
22
50
  3. **Write the spec** (JSON) to `D:\davinci\claude-space\<job>\spec\draft.json` with the Write tool — never a shell heredoc or `echo` — then `validate` it.
23
- 4. **Render.** `render <spec> --job <slug> --contact-sheet`. Each render/sheet auto-versions (`<spec>-v1.mp4`, `-v2.mp4`, ...) so nothing is silently overwritten; the JSON reports the `version`. Pass `--out` for an explicit path (`--overwrite` to replace it). Read the output contact sheet and check that every blur box covers what it must and every caption reads correctly. Re-verify every splice/cut with `contact-sheet --from/--to` on the **rendered MP4**, not only on the spec's edit timeline — a correct spec can still render wrong. Fix the spec and re-render until correct.
24
- 5. **Resolve** (only when the user wants the edit in Resolve):
25
- `export-timeline <spec> --format fcpxml --job <slug>` → `resolve_ui status` → `resolve_ui open-project` → `resolve_ui new-job <slug> <fcpxml> [--srt <srt>]` (creates the `<slug>` bin+timeline inside claude-space, imports, saves in one call) → `resolve_ui screenshot --job <slug>` and Read it to confirm. If the JSON has `"subtitles": "failed: ..."` (exit 0, timeline already created), retry just that step with `resolve_ui import-subtitle <slug> <srt>` - do not re-run `new-job`.
51
+ 4. **Render.** `render <spec> --job <slug> --contact-sheet`. Each render/sheet auto-versions (`<spec>-v1.mp4`, `-v2.mp4`, ...; `--out`/`--overwrite` for an explicit path). Render also runs `qa` by default (`--no-qa` to skip); read `qa.failed`, fix the spec, and re-render. Still read the output contact sheet and re-verify every splice/cut with `contact-sheet --from/--to` on the **rendered MP4**, not only the spec's edit timeline.
52
+ 5. **Resolve** (only when the user wants the edit in Resolve): `export-timeline <spec> --format fcpxml --job <slug>` → `resolve_ui status` → `resolve_ui open-project` → `resolve_ui new-job <slug> <fcpxml> [--srt <srt>]` (creates the `<slug>` bin+timeline inside claude-space, imports, saves in one call) → `resolve_ui screenshot --job <slug>` and Read it to confirm. If the JSON has `"subtitles": "failed: ..."` (exit 0, timeline already created), retry just that step with `resolve_ui import-subtitle <slug> <srt>` - do not re-run `new-job`.
26
53
  6. **Report** the absolute paths: final MP4 (size MB, duration), contact sheet, Resolve screenshot, and every `warnings` entry.
27
54
 
28
55
  ## Spec contract
@@ -45,11 +72,11 @@ Every command prints exactly one JSON object on stdout; pass `--job <slug>` to e
45
72
  - Blur privacy data generously: pad boxes ~10% and start/end them ~0.3 s outside the moment the data is on screen.
46
73
 
47
74
  ## Exit codes you must handle
48
-
75
+ <!-- exit-codes:begin source=actions.json -->
49
76
  | Code | Meaning | Do |
50
77
  |---|---|---|
51
78
  | 0 | ok | continue |
52
- | 2 | output over `max_size_mb` | lower `target_width`, or trim, and re-render |
79
+ | 2 (`engine`) | output over `max_size_mb` | lower `target_width`, or trim, and re-render |
53
80
  | 3 | path outside the claude-space workspace | use the default paths; never work around it |
54
81
  | 4 (`resolve_ui`) | blocked dialog (upgrade/database/licence/activation/studio/purchase) | report the screenshot path to the user and stop; never click it yourself |
55
82
  | 5 (`resolve_ui`) | wrong Resolve project open (not `claude-space`) | run `resolve_ui open-project` first |
@@ -59,14 +86,15 @@ Every command prints exactly one JSON object on stdout; pass `--job <slug>` to e
59
86
  | 9 (`resolve_ui`) | the operator used the mouse/keyboard during the run | tell the user the step was aborted safely; re-run when they are done |
60
87
  | 10 (`resolve_ui`) | Resolve was not the foreground window/target point right before a click - refused rather than risk hitting the wrong app | check the screenshot path in the JSON; re-run once Resolve is frontmost |
61
88
  | 11 (`resolve_ui`) | a flow step failed - a bin/tile navigation did not land, or Resolve's own popup (e.g. "New Timeline Backup") was unrecognized/would not close - screenshot path always included | check the screenshot path in the JSON; report to the user and stop |
89
+ | 12 (`engine`) | at least one qa check failed | read `failed` in the JSON, fix the spec, and re-render |
90
+ | 13 (`engine`) | `--expect-sha` given and the report's `body_sha256` didn't match | the render isn't reproducible against the expected run; investigate before trusting it |
62
91
  | other non-zero | see the JSON `error` | fix the cause; for `resolve_ui` guard codes, report to the user and stop |
63
-
64
- `resolve_ui` refuses to act on any Resolve project except `claude-space`, never clicks upgrade/licence/activation dialogs, asks for Go (toast + banner, noting if Resolve is on another virtual desktop so Go will switch to it for the burst and back) before touching the mouse/keyboard - reusing that ack for `--ack-grace` seconds (default 300) across the next commands instead of a new card each time, until an abort (exit 9/10) - and shows an orange frame around the Resolve window while driving it, stopping at the next step if the operator touches the mouse/keyboard.
92
+ <!-- exit-codes:end -->
65
93
 
66
94
  ## Limits
67
95
 
96
+ - `resolve_ui` only acts on the `claude-space` project, never clicks a denylisted dialog, and asks for Go (toast + banner, noting a virtual-desktop switch) before touching input; the ack holds for `--ack-grace` seconds (default 300) across later commands until an abort. An orange frame marks the window while it drives; it stops if the operator touches the mouse/keyboard.
68
97
  - Jobs have a state (`active`|`complete`|`stale`, `engine job set-state`); the skill sweeps stale jobs at every invocation and complete jobs after 30 days (`engine gc`), which flags their Resolve bin/timeline for cleanup; `resolve_ui gc` (no `--apply`, read-only) shows that list, `resolve_ui gc --apply [--extra <name> ...]` deletes each one's bin and timeline with a named confirm before ever confirming a delete; mark your job complete when the user accepted the output, stale when you abandon it.
69
- - Resolve 21.1 free has no scripting API (Studio-only). The skill uses only the normal UI and File > Import > Timeline. Never write scripts into Resolve's Scripts folders (a guard hook blocks it).
98
+ - Resolve 21.1 free has no scripting API (Studio-only): the skill uses only the normal UI and File > Import > Timeline (a guard hook blocks writing scripts into Resolve's Scripts folders), and Studio-only features (Magic Mask, AI transcription, optical flow) are not used.
70
99
  - Live Resolve driving is beta: `new-job` can leave the new bin unnamed (DR-65). On any non-zero `resolve_ui` exit, do not retry more than once; tell the user the supported path: in Resolve (project claude-space) File > Import > Timeline > `<job>\handoff\timeline.fcpxml`, then File > Import > Subtitle > `<job>\handoff\<job>.srt`.
71
- - Tracked blur uses template matching: fine for slow or moderate motion. For fast motion, split the range into several fixed boxes.
72
- - Studio-only features (Magic Mask, AI transcription, optical flow) are not used.
100
+ - Tracked blur uses template matching: fine for slow or moderate motion; for fast motion, split the range into several fixed boxes.