@kbediako/codex-orchestrator 0.1.2 → 0.1.3

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 (55) hide show
  1. package/README.md +9 -7
  2. package/dist/bin/codex-orchestrator.js +214 -121
  3. package/dist/orchestrator/src/cli/config/userConfig.js +86 -12
  4. package/dist/orchestrator/src/cli/exec/context.js +5 -2
  5. package/dist/orchestrator/src/cli/exec/learning.js +5 -3
  6. package/dist/orchestrator/src/cli/exec/stageRunner.js +1 -1
  7. package/dist/orchestrator/src/cli/exec/summary.js +1 -1
  8. package/dist/orchestrator/src/cli/orchestrator.js +16 -7
  9. package/dist/orchestrator/src/cli/pipelines/index.js +13 -24
  10. package/dist/orchestrator/src/cli/rlm/prompt.js +31 -0
  11. package/dist/orchestrator/src/cli/rlm/runner.js +177 -0
  12. package/dist/orchestrator/src/cli/rlm/types.js +1 -0
  13. package/dist/orchestrator/src/cli/rlm/validator.js +159 -0
  14. package/dist/orchestrator/src/cli/rlmRunner.js +417 -0
  15. package/dist/orchestrator/src/cli/run/environment.js +4 -11
  16. package/dist/orchestrator/src/cli/run/manifest.js +7 -1
  17. package/dist/orchestrator/src/cli/services/commandRunner.js +1 -1
  18. package/dist/orchestrator/src/cli/services/controlPlaneService.js +3 -1
  19. package/dist/orchestrator/src/cli/services/execRuntime.js +1 -2
  20. package/dist/orchestrator/src/cli/services/pipelineResolver.js +33 -2
  21. package/dist/orchestrator/src/cli/services/runPreparation.js +7 -1
  22. package/dist/orchestrator/src/cli/services/schedulerService.js +1 -1
  23. package/dist/orchestrator/src/cli/utils/specGuardRunner.js +3 -1
  24. package/dist/orchestrator/src/cli/utils/strings.js +8 -6
  25. package/dist/orchestrator/src/persistence/ExperienceStore.js +6 -16
  26. package/dist/orchestrator/src/persistence/TaskStateStore.js +1 -1
  27. package/dist/orchestrator/src/persistence/sanitizeIdentifier.js +1 -1
  28. package/dist/packages/orchestrator/src/exec/stdio.js +112 -0
  29. package/dist/packages/orchestrator/src/exec/unified-exec.js +1 -1
  30. package/dist/packages/orchestrator/src/index.js +1 -0
  31. package/dist/packages/shared/design-artifacts/writer.js +4 -14
  32. package/dist/packages/shared/streams/stdio.js +2 -112
  33. package/dist/packages/shared/utils/strings.js +17 -0
  34. package/dist/scripts/design/pipeline/advanced-assets.js +1 -1
  35. package/dist/scripts/design/pipeline/context.js +5 -5
  36. package/dist/scripts/design/pipeline/extract.js +9 -6
  37. package/dist/scripts/design/pipeline/{optionalDeps.js → optional-deps.js} +49 -38
  38. package/dist/scripts/design/pipeline/permit.js +59 -0
  39. package/dist/scripts/design/pipeline/toolkit/common.js +18 -32
  40. package/dist/scripts/design/pipeline/toolkit/reference.js +1 -1
  41. package/dist/scripts/design/pipeline/toolkit/snapshot.js +1 -1
  42. package/dist/scripts/design/pipeline/visual-regression.js +2 -11
  43. package/dist/scripts/lib/cli-args.js +53 -0
  44. package/dist/scripts/lib/docs-helpers.js +111 -0
  45. package/dist/scripts/lib/npm-pack.js +20 -0
  46. package/dist/scripts/lib/run-manifests.js +160 -0
  47. package/package.json +5 -2
  48. package/dist/orchestrator/src/cli/pipelines/defaultDiagnostics.js +0 -32
  49. package/dist/orchestrator/src/cli/pipelines/designReference.js +0 -72
  50. package/dist/orchestrator/src/cli/pipelines/hiFiDesignToolkit.js +0 -71
  51. package/dist/orchestrator/src/cli/utils/jsonlWriter.js +0 -10
  52. package/dist/orchestrator/src/control-plane/index.js +0 -3
  53. package/dist/orchestrator/src/persistence/identifierGuards.js +0 -1
  54. package/dist/orchestrator/src/persistence/writeAtomicFile.js +0 -4
  55. package/dist/orchestrator/src/scheduler/index.js +0 -1
@@ -0,0 +1,53 @@
1
+ export function parseArgs(argv) {
2
+ const args = {};
3
+ const positionals = [];
4
+ const entries = [];
5
+ for (let index = 0; index < argv.length; index += 1) {
6
+ const raw = argv[index];
7
+ if (!raw) {
8
+ continue;
9
+ }
10
+ if (raw === '--') {
11
+ positionals.push(...argv.slice(index + 1));
12
+ break;
13
+ }
14
+ if (!raw.startsWith('-')) {
15
+ positionals.push(raw);
16
+ continue;
17
+ }
18
+ const cleaned = raw.replace(/^--?/, '');
19
+ if (!cleaned) {
20
+ continue;
21
+ }
22
+ const [key, inlineValue] = cleaned.split('=');
23
+ if (inlineValue !== undefined) {
24
+ args[key] = inlineValue;
25
+ entries.push({ key, value: inlineValue });
26
+ continue;
27
+ }
28
+ const next = argv[index + 1];
29
+ if (next && !next.startsWith('-')) {
30
+ args[key] = next;
31
+ entries.push({ key, value: next });
32
+ index += 1;
33
+ }
34
+ else {
35
+ args[key] = true;
36
+ entries.push({ key, value: true });
37
+ }
38
+ }
39
+ return { args, positionals, entries };
40
+ }
41
+ export function hasFlag(args, key) {
42
+ const value = args[key];
43
+ if (value === undefined) {
44
+ return false;
45
+ }
46
+ if (value === false) {
47
+ return false;
48
+ }
49
+ if (value === 'false' || value === '0') {
50
+ return false;
51
+ }
52
+ return true;
53
+ }
@@ -0,0 +1,111 @@
1
+ import { access, readdir } from 'node:fs/promises';
2
+ import path from 'node:path';
3
+ const DOC_ROOTS = ['.agent', '.ai-dev-tasks', 'docs', 'tasks'];
4
+ const DOC_ROOT_FILES = ['README.md', 'AGENTS.md'];
5
+ const EXCLUDED_DIR_NAMES = new Set(['.runs', 'out', 'archives', 'node_modules', 'dist']);
6
+ export async function pathExists(target, options = {}) {
7
+ const { allowMissingOnly = false } = options;
8
+ try {
9
+ await access(target);
10
+ return true;
11
+ }
12
+ catch (error) {
13
+ if (allowMissingOnly && error?.code !== 'ENOENT') {
14
+ throw error;
15
+ }
16
+ return false;
17
+ }
18
+ }
19
+ export function toPosixPath(value) {
20
+ return value.split(path.sep).join('/');
21
+ }
22
+ export async function collectMarkdownFiles(repoRoot, relativeDir) {
23
+ const absDir = path.join(repoRoot, relativeDir);
24
+ const entries = await readdir(absDir, { withFileTypes: true });
25
+ const results = [];
26
+ for (const entry of entries) {
27
+ const relPath = path.join(relativeDir, entry.name);
28
+ if (entry.isDirectory()) {
29
+ if (EXCLUDED_DIR_NAMES.has(entry.name)) {
30
+ continue;
31
+ }
32
+ results.push(...(await collectMarkdownFiles(repoRoot, relPath)));
33
+ continue;
34
+ }
35
+ if (entry.isFile() && entry.name.toLowerCase().endsWith('.md')) {
36
+ results.push(toPosixPath(relPath));
37
+ }
38
+ }
39
+ return results;
40
+ }
41
+ export async function collectDocFiles(repoRoot) {
42
+ const results = [];
43
+ for (const file of DOC_ROOT_FILES) {
44
+ const abs = path.join(repoRoot, file);
45
+ if (await pathExists(abs)) {
46
+ results.push(toPosixPath(file));
47
+ }
48
+ }
49
+ for (const dir of DOC_ROOTS) {
50
+ const abs = path.join(repoRoot, dir);
51
+ if (await pathExists(abs)) {
52
+ results.push(...(await collectMarkdownFiles(repoRoot, dir)));
53
+ }
54
+ }
55
+ results.sort();
56
+ return results;
57
+ }
58
+ export function normalizeTaskKey(item) {
59
+ if (!item || typeof item !== 'object') {
60
+ return null;
61
+ }
62
+ const id = typeof item.id === 'string' ? item.id.trim() : '';
63
+ const slug = typeof item.slug === 'string' ? item.slug.trim() : '';
64
+ if (slug && id && slug.startsWith(`${id}-`)) {
65
+ return slug;
66
+ }
67
+ if (id && slug) {
68
+ return `${id}-${slug}`;
69
+ }
70
+ if (slug) {
71
+ return slug;
72
+ }
73
+ if (id) {
74
+ return id;
75
+ }
76
+ return null;
77
+ }
78
+ export function parseDateString(value) {
79
+ if (typeof value !== 'string') {
80
+ return null;
81
+ }
82
+ const match = value.match(/^(\d{4})-(\d{2})-(\d{2})$/);
83
+ if (!match) {
84
+ return null;
85
+ }
86
+ return value;
87
+ }
88
+ export function parseIsoDate(raw) {
89
+ const normalized = parseDateString(raw);
90
+ if (!normalized) {
91
+ return null;
92
+ }
93
+ const [yearStr, monthStr, dayStr] = normalized.split('-');
94
+ const year = Number(yearStr);
95
+ const month = Number(monthStr) - 1;
96
+ const day = Number(dayStr);
97
+ const date = new Date(Date.UTC(year, month, day));
98
+ if (Number.isNaN(date.getTime())) {
99
+ return null;
100
+ }
101
+ if (date.getUTCFullYear() !== year ||
102
+ date.getUTCMonth() !== month ||
103
+ date.getUTCDate() !== day) {
104
+ return null;
105
+ }
106
+ return date;
107
+ }
108
+ export function computeAgeInDays(from, to) {
109
+ const msPerDay = 24 * 60 * 60 * 1000;
110
+ return Math.floor((to.getTime() - from.getTime()) / msPerDay);
111
+ }
@@ -0,0 +1,20 @@
1
+ import { execFile } from 'node:child_process';
2
+ import process from 'node:process';
3
+ import { promisify } from 'node:util';
4
+ const execFileAsync = promisify(execFile);
5
+ export async function runPack() {
6
+ const { stdout } = await execFileAsync('npm', ['pack', '--json', '--ignore-scripts'], {
7
+ env: { ...process.env, npm_config_ignore_scripts: 'true' },
8
+ maxBuffer: 10 * 1024 * 1024
9
+ });
10
+ const trimmed = String(stdout ?? '').trim();
11
+ if (!trimmed) {
12
+ throw new Error('npm pack produced no output');
13
+ }
14
+ const parsed = JSON.parse(trimmed);
15
+ const record = Array.isArray(parsed) ? parsed[0] : parsed;
16
+ if (!record || typeof record !== 'object') {
17
+ throw new Error('npm pack output did not include a record');
18
+ }
19
+ return record;
20
+ }
@@ -0,0 +1,160 @@
1
+ import { access, readdir } from 'node:fs/promises';
2
+ import { isAbsolute, join, resolve } from 'node:path';
3
+ import process from 'node:process';
4
+ const DEFAULT_TASK_ID = '0101';
5
+ function resolveRepoRoot() {
6
+ const configured = process.env.CODEX_ORCHESTRATOR_ROOT;
7
+ if (!configured) {
8
+ return process.cwd();
9
+ }
10
+ if (isAbsolute(configured)) {
11
+ return configured;
12
+ }
13
+ return resolve(process.cwd(), configured);
14
+ }
15
+ function resolveRunsDir(repoRoot) {
16
+ const configured = process.env.CODEX_ORCHESTRATOR_RUNS_DIR || '.runs';
17
+ if (isAbsolute(configured)) {
18
+ return configured;
19
+ }
20
+ return resolve(repoRoot, configured);
21
+ }
22
+ function resolveOutDir(repoRoot) {
23
+ const configured = process.env.CODEX_ORCHESTRATOR_OUT_DIR || 'out';
24
+ if (isAbsolute(configured)) {
25
+ return configured;
26
+ }
27
+ return resolve(repoRoot, configured);
28
+ }
29
+ export function resolveEnvironmentPaths() {
30
+ const repoRoot = resolveRepoRoot();
31
+ const runsRoot = resolveRunsDir(repoRoot);
32
+ const outRoot = resolveOutDir(repoRoot);
33
+ const taskId = process.env.MCP_RUNNER_TASK_ID ?? DEFAULT_TASK_ID;
34
+ return { repoRoot, runsRoot, outRoot, taskId };
35
+ }
36
+ export async function listDirectories(dirPath) {
37
+ try {
38
+ const entries = await readdir(dirPath, { withFileTypes: true });
39
+ return entries.filter((entry) => entry.isDirectory()).map((entry) => entry.name);
40
+ }
41
+ catch (error) {
42
+ if (error?.code === 'ENOENT') {
43
+ return [];
44
+ }
45
+ throw error;
46
+ }
47
+ }
48
+ export function parseRunIdTimestamp(runId) {
49
+ if (typeof runId !== 'string') {
50
+ return null;
51
+ }
52
+ const match = runId.match(/^(\d{4}-\d{2}-\d{2})T(\d{2})-(\d{2})-(\d{2})-(\d{3})Z/);
53
+ if (!match) {
54
+ return null;
55
+ }
56
+ const [, date, hours, minutes, seconds, ms] = match;
57
+ const iso = `${date}T${hours}:${minutes}:${seconds}.${ms}Z`;
58
+ const parsed = new Date(iso);
59
+ return Number.isNaN(parsed.getTime()) ? null : parsed;
60
+ }
61
+ export function pickLatestRunId(runIds) {
62
+ if (!Array.isArray(runIds) || runIds.length === 0) {
63
+ return null;
64
+ }
65
+ const sorted = [...runIds].sort((a, b) => {
66
+ const aTimestamp = parseRunIdTimestamp(a)?.getTime();
67
+ const bTimestamp = parseRunIdTimestamp(b)?.getTime();
68
+ if (aTimestamp != null && bTimestamp != null && aTimestamp !== bTimestamp) {
69
+ return bTimestamp - aTimestamp;
70
+ }
71
+ return String(b ?? '').localeCompare(String(a ?? ''));
72
+ });
73
+ return sorted[0] ?? null;
74
+ }
75
+ export async function collectManifests(runsDir, taskFilter) {
76
+ const results = [];
77
+ let taskIds = [];
78
+ try {
79
+ taskIds = await readdir(runsDir);
80
+ }
81
+ catch (error) {
82
+ if (error?.code === 'ENOENT') {
83
+ return results;
84
+ }
85
+ throw error;
86
+ }
87
+ for (const taskId of taskIds) {
88
+ if (taskFilter && taskFilter !== taskId) {
89
+ continue;
90
+ }
91
+ const taskPath = join(runsDir, taskId);
92
+ const cliPath = join(taskPath, 'cli');
93
+ const legacyPath = taskPath;
94
+ const candidates = [];
95
+ try {
96
+ const cliRunIds = await readdir(cliPath);
97
+ candidates.push({ root: cliPath, runIds: cliRunIds });
98
+ }
99
+ catch {
100
+ // Ignore missing CLI directory; fall back to legacy layout.
101
+ }
102
+ if (candidates.length === 0) {
103
+ try {
104
+ const legacyRunIds = await readdir(legacyPath);
105
+ candidates.push({ root: legacyPath, runIds: legacyRunIds });
106
+ }
107
+ catch {
108
+ continue;
109
+ }
110
+ }
111
+ for (const candidate of candidates) {
112
+ for (const runId of candidate.runIds) {
113
+ const manifestPath = join(candidate.root, runId, 'manifest.json');
114
+ results.push(manifestPath);
115
+ }
116
+ }
117
+ }
118
+ return results;
119
+ }
120
+ export async function findSubagentManifests(runsDir, taskId) {
121
+ let entries;
122
+ try {
123
+ entries = await readdir(runsDir, { withFileTypes: true });
124
+ }
125
+ catch (error) {
126
+ const message = error && typeof error === 'object' && error !== null && 'message' in error
127
+ ? error.message
128
+ : String(error);
129
+ return { found: [], error: `Unable to read runs directory (${message})` };
130
+ }
131
+ const prefix = `${taskId}-`;
132
+ const found = [];
133
+ for (const entry of entries) {
134
+ if (!entry.isDirectory() || !entry.name.startsWith(prefix)) {
135
+ continue;
136
+ }
137
+ const cliDir = join(runsDir, entry.name, 'cli');
138
+ let runDirs;
139
+ try {
140
+ runDirs = await readdir(cliDir, { withFileTypes: true });
141
+ }
142
+ catch {
143
+ continue;
144
+ }
145
+ for (const runDir of runDirs) {
146
+ if (!runDir.isDirectory()) {
147
+ continue;
148
+ }
149
+ const manifestPath = join(cliDir, runDir.name, 'manifest.json');
150
+ try {
151
+ await access(manifestPath);
152
+ found.push(manifestPath);
153
+ }
154
+ catch {
155
+ // ignore missing manifest
156
+ }
157
+ }
158
+ }
159
+ return { found, error: null };
160
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kbediako/codex-orchestrator",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "license": "SEE LICENSE IN LICENSE",
5
5
  "type": "module",
6
6
  "bin": {
@@ -11,6 +11,7 @@
11
11
  "dist/orchestrator/**",
12
12
  "dist/packages/**",
13
13
  "dist/scripts/design/pipeline/**",
14
+ "dist/scripts/lib/**",
14
15
  "dist/types/**",
15
16
  "schemas/**",
16
17
  "templates/**",
@@ -32,12 +33,14 @@
32
33
  "build:patterns": "tsc -p patterns/tsconfig.json",
33
34
  "clean:dist": "node scripts/clean-dist.mjs",
34
35
  "docs:check": "node --loader ts-node/esm scripts/docs-hygiene.ts --check",
36
+ "docs:archive-implementation": "node scripts/implementation-docs-archive.mjs",
37
+ "docs:archive-tasks": "node scripts/tasks-archive.mjs",
38
+ "docs:freshness": "node scripts/docs-freshness.mjs --check",
35
39
  "docs:sync": "node --loader ts-node/esm scripts/docs-hygiene.ts --sync",
36
40
  "prelint": "node scripts/build-patterns-if-needed.mjs",
37
41
  "lint": "eslint orchestrator/src orchestrator/tests packages/orchestrator/src packages/orchestrator/tests packages/shared adapters evaluation/harness evaluation/tests --ext .ts,.tsx",
38
42
  "pack:audit": "node scripts/pack-audit.mjs",
39
43
  "pack:smoke": "node scripts/pack-smoke.mjs",
40
- "parallel:goals": "node --loader ts-node/esm scripts/run-parallel-goals.ts",
41
44
  "prepack": "npm run clean:dist && npm run build && npm run pack:audit",
42
45
  "setup:design-tools": "node --loader ts-node/esm scripts/setup-design-tools.ts",
43
46
  "test": "npm run test:orchestrator",
@@ -1,32 +0,0 @@
1
- export const defaultDiagnosticsPipeline = {
2
- id: 'diagnostics',
3
- title: 'Diagnostics Pipeline',
4
- description: 'Build, lint, test, and optionally run spec-guard for the repository.',
5
- tags: ['diagnostics-primary', 'diagnostics-secondary'],
6
- stages: [
7
- {
8
- kind: 'command',
9
- id: 'build',
10
- title: 'npm run build',
11
- command: 'npm run build'
12
- },
13
- {
14
- kind: 'command',
15
- id: 'lint',
16
- title: 'npm run lint',
17
- command: 'npm run lint'
18
- },
19
- {
20
- kind: 'command',
21
- id: 'test',
22
- title: 'npm run test',
23
- command: 'npm run test'
24
- },
25
- {
26
- kind: 'command',
27
- id: 'spec-guard',
28
- title: 'Optional spec-guard (if scripts/spec-guard.mjs exists)',
29
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/orchestrator/src/cli/utils/specGuardRunner.js" --dry-run'
30
- }
31
- ]
32
- };
@@ -1,72 +0,0 @@
1
- const DESIGN_PIPELINE_ENV = {
2
- DESIGN_PIPELINE: '1'
3
- };
4
- export const designReferencePipeline = {
5
- id: 'design-reference',
6
- title: 'Design Reference Pipeline',
7
- description: 'Extracts design reference assets, stages Storybook-ready components, and records manifest evidence.',
8
- tags: ['design', 'reference'],
9
- stages: [
10
- {
11
- kind: 'command',
12
- id: 'design-config',
13
- title: 'Resolve design configuration',
14
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/prepare.js"',
15
- env: { ...DESIGN_PIPELINE_ENV }
16
- },
17
- {
18
- kind: 'command',
19
- id: 'design-extract',
20
- title: 'Run Playwright design extractor',
21
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/extract.js"',
22
- env: { ...DESIGN_PIPELINE_ENV }
23
- },
24
- {
25
- kind: 'command',
26
- id: 'design-reference',
27
- title: 'Build motherduck reference page',
28
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/reference.js"',
29
- env: { ...DESIGN_PIPELINE_ENV }
30
- },
31
- {
32
- kind: 'command',
33
- id: 'design-componentize',
34
- title: 'Componentize artifacts via packages/design-system',
35
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/componentize.js"',
36
- env: { ...DESIGN_PIPELINE_ENV }
37
- },
38
- {
39
- kind: 'command',
40
- id: 'design-advanced-assets',
41
- title: 'Generate advanced design assets',
42
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/advanced-assets.js"',
43
- env: { ...DESIGN_PIPELINE_ENV },
44
- allowFailure: true,
45
- summaryHint: 'Optional Framer Motion and FFmpeg assets'
46
- },
47
- {
48
- kind: 'command',
49
- id: 'design-visual-regression',
50
- title: 'Run visual regression tests',
51
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/visual-regression.js"',
52
- env: { ...DESIGN_PIPELINE_ENV },
53
- allowFailure: true,
54
- summaryHint: 'Visual regression diffs stored under design/visual-regression/'
55
- },
56
- {
57
- kind: 'command',
58
- id: 'design-spec-guard',
59
- title: 'Optional spec-guard (if scripts/spec-guard.mjs exists)',
60
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/orchestrator/src/cli/utils/specGuardRunner.js" --dry-run',
61
- env: { ...DESIGN_PIPELINE_ENV },
62
- summaryHint: 'Ensures design specs are fresh before artifact write'
63
- },
64
- {
65
- kind: 'command',
66
- id: 'design-artifact-writer',
67
- title: 'Persist design artifact manifests',
68
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/write-artifacts.js"',
69
- env: { ...DESIGN_PIPELINE_ENV }
70
- }
71
- ]
72
- };
@@ -1,71 +0,0 @@
1
- const DESIGN_TOOLKIT_ENV = {
2
- DESIGN_PIPELINE: '1',
3
- DESIGN_TOOLKIT: '1'
4
- };
5
- export const hiFiDesignToolkitPipeline = {
6
- id: 'hi-fi-design-toolkit',
7
- title: 'Hi-Fi Design Toolkit',
8
- description: 'Runs the hi-fi design toolkit pipeline to extract, tokenize, self-correct, and publish design artifacts.',
9
- tags: ['design', 'hi-fi'],
10
- stages: [
11
- {
12
- kind: 'command',
13
- id: 'design-config',
14
- title: 'Resolve design configuration',
15
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/prepare.js"',
16
- env: { ...DESIGN_TOOLKIT_ENV }
17
- },
18
- {
19
- kind: 'command',
20
- id: 'design-toolkit-extract',
21
- title: 'Wrap external toolkit extractor',
22
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/toolkit/extract.js"',
23
- env: { ...DESIGN_TOOLKIT_ENV }
24
- },
25
- {
26
- kind: 'command',
27
- id: 'design-toolkit-tokens',
28
- title: 'Generate tokens and style guides',
29
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/toolkit/tokens.js"',
30
- env: { ...DESIGN_TOOLKIT_ENV }
31
- },
32
- {
33
- kind: 'command',
34
- id: 'design-toolkit-reference',
35
- title: 'Build reference pages + self-correction',
36
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/toolkit/reference.js"',
37
- env: { ...DESIGN_TOOLKIT_ENV }
38
- },
39
- {
40
- kind: 'command',
41
- id: 'design-advanced-assets',
42
- title: 'Generate advanced design assets',
43
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/advanced-assets.js"',
44
- env: { ...DESIGN_TOOLKIT_ENV },
45
- allowFailure: true,
46
- summaryHint: 'Optional motion capture via Framer Motion + FFmpeg'
47
- },
48
- {
49
- kind: 'command',
50
- id: 'design-toolkit-publish',
51
- title: 'Publish toolkit outputs to packages/design-system',
52
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/toolkit/publish.js"',
53
- env: { ...DESIGN_TOOLKIT_ENV }
54
- },
55
- {
56
- kind: 'command',
57
- id: 'design-spec-guard',
58
- title: 'Optional spec-guard (if scripts/spec-guard.mjs exists)',
59
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/orchestrator/src/cli/utils/specGuardRunner.js" --dry-run',
60
- env: { ...DESIGN_TOOLKIT_ENV },
61
- summaryHint: 'Ensures HI-FI design specs are current before artifact write'
62
- },
63
- {
64
- kind: 'command',
65
- id: 'design-artifact-writer',
66
- title: 'Persist design manifests',
67
- command: 'node "$CODEX_ORCHESTRATOR_PACKAGE_ROOT/dist/scripts/design/pipeline/write-artifacts.js"',
68
- env: { ...DESIGN_TOOLKIT_ENV }
69
- }
70
- ]
71
- };
@@ -1,10 +0,0 @@
1
- export class JsonlWriter {
2
- stream;
3
- constructor(stream = process.stdout) {
4
- this.stream = stream;
5
- }
6
- write(event) {
7
- const payload = `${JSON.stringify(event)}\n`;
8
- this.stream.write(payload);
9
- }
10
- }
@@ -1,3 +0,0 @@
1
- export { buildRunRequestV2 } from './request-builder.js';
2
- export { ControlPlaneDriftReporter } from './drift-reporter.js';
3
- export { ControlPlaneValidator, ControlPlaneValidationError } from './validator.js';
@@ -1 +0,0 @@
1
- export const WINDOWS_FORBIDDEN_CHARACTERS = new Set(['<', '>', ':', '"', '|', '?', '*']);
@@ -1,4 +0,0 @@
1
- import { writeAtomicFile as writeAtomicFileInternal } from '../utils/atomicWrite.js';
2
- export async function writeAtomicFile(destination, contents) {
3
- await writeAtomicFileInternal(destination, contents, { ensureDir: false, encoding: 'utf-8' });
4
- }
@@ -1 +0,0 @@
1
- export { createSchedulerPlan, finalizeSchedulerPlan, serializeSchedulerPlan, buildSchedulerRunSummary } from './plan.js';