The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.
TypeScript 3d-modelingagent-frameworkagent-harnessai-agentscadclaude-codecodexcoding-agentsdeveloper-toolsesp32game-developmentmcp-servermulti-agentopen-hardwareopencodeopenharnesspcbroboticsterminaltmux
test: reach full orchestrator coverage and document verified live CAD project
Dee7aa478151444
diff --git a/cli/package.json b/cli/package.jsonindex 254a08be5..b0a3bdf03 100644--- a/cli/package.json+++ b/cli/package.json@@ -12,6 +12,7 @@"typecheck": "tsc --noEmit","start": "node dist/cli.js","test": "vitest run",+ "test:orchestrator": "vitest run src/orchestrator --maxWorkers=1 --coverage --coverage.include='src/orchestrator/**' --coverage.thresholds.lines=100 --coverage.thresholds.statements=100 --coverage.thresholds.functions=100 --coverage.thresholds.branches=100 --coverage.reporter=text --coverage.reporter=json --coverage.reportsDirectory=coverage/orchestrator","test:cursor-e2e": "RUN_CURSOR_E2E=1 vitest run src/engines/cursor/localE2e.spec.ts","test:tmux-real": "RUN_REAL_TMUX_DISCOVERY=1 vitest run src/lib/tmuxAgentDiscovery.real.spec.ts --reporter=verbose","test:herdr-real": "RUN_REAL_HERDR=1 vitest run src/lib/herdrBackend.real.spec.ts --reporter=verbose",diff --git a/cli/scripts/render-orchestrator-live-cad.py b/cli/scripts/render-orchestrator-live-cad.pynew file mode 100644index 000000000..77055ae0a--- /dev/null+++ b/cli/scripts/render-orchestrator-live-cad.py@@ -0,0 +1,66 @@+"""Scripted Blender preview of independently verified CAD, not a live Blender agent.++Usage: installed-blender-python this-script.py exported-mesh-directory output-directory+"""+import sys+from pathlib import Path+import bpy+from mathutils import Vector++meshes, output = map(Path, sys.argv[1:3])+output.mkdir(parents=True, exist_ok=True)+bpy.ops.object.select_all(action="SELECT")+bpy.ops.object.delete(use_global=False)+parts = []+for name, color in [("holder", (0.10, 0.13, 0.16, 1)), ("token", (0.84, 0.18, 0.09, 1))]:+ bpy.ops.wm.stl_import(filepath=str(meshes / f"{name}.stl"))+ part = bpy.context.object+ part.name = name+ part.scale = (0.001,) * 3 # STL source units are explicitly millimeters.+ material = bpy.data.materials.new(name)+ material.diffuse_color = color+ material.use_nodes = True+ shader = material.node_tree.nodes.get("Principled BSDF")+ shader.inputs["Base Color"].default_value = color+ shader.inputs["Roughness"].default_value = 0.32+ part.data.materials.append(material)+ parts.append(part)++# Only the actual parts go into the portable model; lighting is presentation-only.+bpy.ops.object.select_all(action="DESELECT")+for part in parts:+ part.select_set(True)+bpy.ops.export_scene.gltf(filepath=str(output / "assembly.glb"), export_format="GLB", use_selection=True)++bpy.ops.mesh.primitive_plane_add(size=0.4, location=(0, 0, -0.00002))+floor = bpy.context.object+mat = bpy.data.materials.new("warm matte floor")+mat.diffuse_color = (0.34, 0.30, 0.26, 1)+floor.data.materials.append(mat)++bpy.ops.object.camera_add(location=(0.046, -0.058, 0.062))+camera = bpy.context.object+camera.rotation_euler = (Vector((0, 0, 0.003)) - camera.location).to_track_quat("-Z", "Y").to_euler()+camera.data.type = "ORTHO"+camera.data.ortho_scale = 0.055+camera.data.clip_start = 0.0001+camera.data.clip_end = 10+bpy.context.scene.camera = camera+for position, energy, size in [((0.025, -0.025, 0.075), 0.12, 0.045), ((-0.04, -0.005, 0.045), 0.06, 0.05), ((0.02, 0.04, 0.06), 0.16, 0.03)]:+ bpy.ops.object.light_add(type="AREA", location=position)+ light = bpy.context.object+ light.data.energy, light.data.shape, light.data.size = energy, "DISK", size+ light.rotation_euler = (-light.location).to_track_quat("-Z", "Y").to_euler()++scene = bpy.context.scene+scene.render.engine = "CYCLES"+scene.cycles.device = "CPU"+scene.cycles.samples = 16+scene.cycles.max_bounces = 4+scene.cycles.use_denoising = True+scene.world.color = (0.15, 0.15, 0.15)+scene.render.resolution_x, scene.render.resolution_y = 1024, 768+scene.render.resolution_percentage = 100+scene.render.image_settings.file_format = "PNG"+scene.render.filepath = str(output / "preview.png")+bpy.ops.render.render(write_still=True)diff --git a/cli/scripts/verify-orchestrator-live-cad.py b/cli/scripts/verify-orchestrator-live-cad.pynew file mode 100644index 000000000..29eff4388--- /dev/null+++ b/cli/scripts/verify-orchestrator-live-cad.py@@ -0,0 +1,75 @@+"""Independent reimport checks on live-test deliverables, not worker reports.++Run with an already-installed Solid/Workshop Python. No model calls or installs.+The optional mesh exports are derived from the verified STEP for a review image.+"""+import argparse+import json+import math+from pathlib import Path++from build123d import GeomType, Pos, export_stl, import_step+from OCP.BRepAdaptor import BRepAdaptor_Surface+from OCP.BRepAlgoAPI import BRepAlgoAPI_Common, BRepAlgoAPI_Cut+from OCP.BRepCheck import BRepCheck_Analyzer+from OCP.BRepGProp import BRepGProp+from OCP.GProp import GProp_GProps++parser = argparse.ArgumentParser()+parser.add_argument("token", type=Path)+parser.add_argument("assembly", type=Path)+parser.add_argument("--meshes", type=Path)+args = parser.parse_args()+++def boolean_volume(operation, left, right):+ result = operation(left.wrapped, right.wrapped)+ result.Build()+ assert result.IsDone(), "CAD-kernel Boolean operation did not finish"+ properties = GProp_GProps()+ BRepGProp.VolumeProperties_s(result.Shape(), properties)+ return abs(properties.Mass())+++token = import_step(args.token)+assembly = import_step(args.assembly)+solids = sorted(assembly.solids(), key=lambda solid: solid.bounding_box().size.X)+assert len(solids) == 2, "Assembly must contain exactly two independent solids"+placed_token, holder = solids+holder_radii = sorted({+ round(BRepAdaptor_Surface(face.wrapped).Cylinder().Radius(), 8)+ for face in holder.faces() if face.geom_type == GeomType.CYLINDER+})+token_size = list(token.bounding_box().size)+radial_clearance = min(holder_radii) - token_size[0] / 2+overlap = boolean_volume(BRepAlgoAPI_Common, placed_token, holder)+unplaced = Pos(0, 0, -2) * placed_token+identity_removed = boolean_volume(BRepAlgoAPI_Cut, token, unplaced)+identity_added = boolean_volume(BRepAlgoAPI_Cut, unplaced, token)+checks = {+ "one_upstream_solid": len(token.solids()) == 1,+ "two_assembly_solids": len(solids) == 2,+ "valid_upstream_brep": BRepCheck_Analyzer(token.wrapped, True).IsValid(),+ "valid_assembly_brep": BRepCheck_Analyzer(assembly.wrapped, True).IsValid(),+ "positive_volumes": all(solid.volume > 0 for solid in solids),+ "token_24_by_24_by_5_mm": all(abs(a - b) < 1e-6 for a, b in zip(token_size, [24, 24, 5])),+ "token_volume_700_pi_mm3": abs(token.volume - 700 * math.pi) < 1e-6,+ "holder_32_by_32_by_7_mm": all(abs(a - b) < 1e-6 for a, b in zip(holder.bounding_box().size, [32, 32, 7])),+ "holder_cylinder_radii": holder_radii == [12.3, 16.0],+ "radial_clearance_0_3_mm": abs(radial_clearance - 0.3) < 1e-6,+ "no_geometric_intersection": overlap < 1e-7,+ "upstream_token_geometry_preserved": identity_added < 1e-7 and identity_removed < 1e-7,+}+assert all(checks.values()), json.dumps(checks)+if args.meshes:+ args.meshes.mkdir(parents=True, exist_ok=True)+ for name, solid in [("holder.stl", holder), ("token.stl", placed_token)]:+ assert export_stl(solid, args.meshes / name, tolerance=0.01, angular_tolerance=0.05)+print(json.dumps({+ "method": "Independent STEP reimport; no worker Python executed",+ "units": "mm", "checks": checks, "all_checks_passed": all(checks.values()),+ "token_volume_mm3": token.volume, "holder_volume_mm3": holder.volume,+ "radial_clearance_mm": radial_clearance, "intersection_volume_mm3": overlap,+ "identity_removed_volume_mm3": identity_removed, "identity_added_volume_mm3": identity_added,+ "limitations": ["Numerical geometry only; no physical printing, insertion, or manufacturing tolerance verification"],+}, indent=2))diff --git a/cli/src/orchestrator/command.spec.ts b/cli/src/orchestrator/command.spec.tsindex a8226e993..bea23ef98 100644--- a/cli/src/orchestrator/command.spec.ts+++ b/cli/src/orchestrator/command.spec.ts@@ -1,5 +1,6 @@import { afterEach, describe, expect, it, vi } from 'vitest'import { WebSocketServer } from 'ws'+import * as authSession from '../lib/authSession.js'import { summarizeOrchestratorReply, parseOrchestratorArgs, localOrchestratorRequest, orchestratorCommand } from './command.js'describe('orchestrator tool output', () => {@@ -32,6 +33,7 @@ describe('orchestrator tool output', () => {})describe('orchestrator argument validation', () => {+ afterEach(() => vi.restoreAllMocks())const parse = (...args: string[]) => parseOrchestratorArgs(['--port', '1234', '--machine', 'local-test', ...args]).payloadit.each(['list', 'catalog', 'status', 'resume'])('parses %s without changing its identity', action => {expect(parse(action, 'project')).toEqual({ action, id: 'project' })@@ -55,6 +57,14 @@ describe('orchestrator argument validation', () => {for (const port of ['0', '65536', '1.1', 'no']) expect(() => parseOrchestratorArgs(['--port', port, '--machine', 'local', 'list'])).toThrow(/running local daemon/)expect(() => parseOrchestratorArgs(['--port', '1234', '--machine'])).toThrow(/identity/)})+ it('uses a saved local identity and safely formats untyped configuration failures', async () => {+ vi.spyOn(authSession, 'readAuthSession').mockReturnValue({ machineId: 'saved-machine' } as ReturnType<typeof authSession.readAuthSession>)+ expect(parseOrchestratorArgs(['--port', '1234', 'list']).machineId).toBe('saved-machine')+ vi.spyOn(authSession, 'readAuthSession').mockImplementation(() => { throw 'untyped configuration failure' })+ const error = vi.spyOn(console, 'error').mockImplementation(() => {})+ expect(await orchestratorCommand(['list'])).toBe(1)+ expect(error).toHaveBeenCalledWith('Orchestrator request failed.')+ })})describe('real loopback orchestrator transport', () => {diff --git a/cli/src/orchestrator/prompts.spec.ts b/cli/src/orchestrator/prompts.spec.tsnew file mode 100644index 000000000..dc860a21d--- /dev/null+++ b/cli/src/orchestrator/prompts.spec.ts@@ -0,0 +1,21 @@+import { execFileSync } from 'node:child_process'+import { describe, expect, it } from 'vitest'+import { directorPrompt, shellQuote, workerPrompt } from './prompts.js'+import type { Run, Task } from './model.js'++describe('self-contained orchestration briefs', () => {+ it('quotes executable paths without expanding shell metacharacters', () => {+ const value = `/project/a'b $(printf unexpected) \"workspace\"`+ expect(execFileSync('/bin/sh', ['-c', `printf %s ${shellQuote(value)}`], { encoding: 'utf8' })).toBe(value)+ })+ it.each([true, false])('keeps the explicit unattended setting at %s', bypassPermission => {+ const run = { id: 'a'.repeat(32), root: '/project', prompt: 'Make it', parallelism: 2, engine: 'codex', bypassPermission, tasks: [] } as unknown as Run+ const brief = directorPrompt(run, [], 'harness orchestrator')+ expect(brief).toContain(bypassPermission ? 'explicitly enabled by the user' : 'NOT enabled; normal engine permission prompts')+ expect(brief).toContain('An idle worker or a viewer is NOT evidence of completion')+ expect(brief).toContain('Successful work is immutable')+ const task = { id: 'one', attempt: 2, cwd: '/project/one', prompt: 'Verify dimensions', dependsOn: [] } as unknown as Task+ expect(workerPrompt(run, task, 'harness orchestrator')).toContain(`finish ${run.id} one 2`)+ expect(workerPrompt(run, task, 'harness orchestrator')).toContain(`fail ${run.id} one 2`)+ })+})diff --git a/cli/src/orchestrator/service.spec.ts b/cli/src/orchestrator/service.spec.tsindex 1eeb7c3c7..21e7e3c38 100644--- a/cli/src/orchestrator/service.spec.ts+++ b/cli/src/orchestrator/service.spec.ts@@ -1,11 +1,18 @@import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'-import { mkdtempSync, mkdirSync, readFileSync, rmSync, symlinkSync, writeFileSync } from 'node:fs'+import { mkdtempSync, mkdirSync, readFileSync, realpathSync, renameSync, rmSync, symlinkSync, unlinkSync, writeFileSync } from 'node:fs'import { tmpdir } from 'node:os'import { join } from 'node:path'+import * as filesystem from 'node:fs/promises'+import * as privateState from '../lib/secureState.js'import { OrchestratorService, type OrchestratorDependencies } from './service.js'import { OrchestratorError, type Task } from './model.js'import { orchestratorRequest } from './wire.js'+vi.mock('node:fs/promises', async importOriginal => {+ const actual = await importOriginal<typeof import('node:fs/promises')>()+ return { ...actual, rm: vi.fn(actual.rm) }+})+const id = '0123456789abcdef0123456789abcdef'const task = (id: string, dependsOn: string[] = [], harness = 'test/cad') => ({ id, title: id, harness, prompt: `Build ${id} and verify it`, dependsOn })describe('durable orchestrator lifecycle', () => {@@ -32,7 +39,7 @@ describe('durable orchestrator lifecycle', () => {}service = new OrchestratorService(deps)})- afterEach(() => { service.stop(); rmSync(root, { recursive: true, force: true }) })+ afterEach(() => { service.stop(); vi.restoreAllMocks(); rmSync(root, { recursive: true, force: true }) })it('starts once, preserves permissions, and rejects a conflicting creation retry', async () => {await Promise.all([start(), start()]); await active()@@ -247,4 +254,203 @@ describe('durable orchestrator lifecycle', () => {expect(await orchestratorRequest(service, { action: 'status', id })).toMatchObject({ error: 'PROJECT_NOT_FOUND' })expect(await orchestratorRequest(service, { action: 'install' })).toMatchObject({ error: 'INVALID_REQUEST' })})+ it('deduplicates simultaneous creation after asynchronous folder validation', async () => {+ const spec = { id, engine: 'claude', prompt: 'Use this existing folder', cwd: root }+ await Promise.all([service.start(spec), service.start(spec)]); await active()+ expect(launches).toHaveLength(1)+ expect(launches[0].cwd).toBe(join(realpathSync(root), '.harness-projects', id))+ })+ it('lists recent projects in order without exposing their full briefs', async () => {+ await start(); await active()+ const second = 'f'.repeat(32)+ await service.start({ id: second, engine: 'claude', prompt: 'A'.repeat(500) })+ await vi.waitFor(() => expect(service.snapshot(second).state).toBe('active'))+ service.chat(second, '1'.repeat(32), 'More detail')+ expect(service.list().map(r => r.id)).toEqual([second, id])+ expect(String(service.list()[0].prompt)).toHaveLength(160)+ })+ it('preserves corrupt state and refuses to overwrite its identity', async () => {+ mkdirSync(deps.stateDir, { recursive: true })+ const file = join(deps.stateDir, `${id}.json`)+ writeFileSync(file, '{not valid JSON')+ vi.spyOn(console, 'warn').mockImplementation(() => {})+ expect(service.list()).toEqual([])+ await expect(start()).rejects.toMatchObject({ code: 'CORRUPT_STATE' })+ expect(readFileSync(file, 'utf8')).toBe('{not valid JSON')+ expect(launches).toHaveLength(0)+ })+ it('recovers interrupted director and worker launches conservatively', async () => {+ await start(); await active(); service.plan(id, [task('a')]); await running('a'); service.stop()+ const file = join(deps.stateDir, `${id}.json`), saved = JSON.parse(readFileSync(file, 'utf8'))+ saved.state = 'starting'; saved.directorId = null; saved.tasks[0].state = 'launching'+ writeFileSync(file, JSON.stringify(saved)); service = new OrchestratorService(deps)+ expect(service.snapshot(id)).toMatchObject({ state: 'paused', directorAvailable: false, tasks: [{ state: 'blocked', uncertain: true }] })+ expect(() => service.resume(id)).toThrow(/original director/)+ expect(launches).toHaveLength(2)+ })+ it.each([new Error('Engine not authenticated'), 'unknown process refusal'])('records a director creation failure without hiding it: %s', async failure => {+ deps.create = async () => { throw failure }+ await start()+ await vi.waitFor(() => expect(service.snapshot(id).state).toBe('failed'))+ expect(service.snapshot(id).error).toBe(failure instanceof Error ? failure.message : 'Director launch failed.')+ })+ it('never overwrites an existing workspace, even without a saved run', async () => {+ mkdirSync(join(deps.workspaceDir, id), { recursive: true })+ await expect(start()).rejects.toMatchObject({ code: 'WORKSPACE_EXISTS' })+ expect(launches).toHaveLength(0)+ })+ it('refuses unsupported engines and invalid folder forms before creation', async () => {+ await expect(service.start({ id, engine: 'codex', prompt: 'Test' })).rejects.toMatchObject({ code: 'ENGINE_UNSUPPORTED' })+ const file = join(root, 'file'); writeFileSync(file, 'not a directory')+ for (const cwd of ['relative/path', `${root}\n`, file]) await expect(service.start({ id, engine: 'claude', prompt: 'Test', cwd })).rejects.toMatchObject({ code: 'INVALID_CWD' })+ expect(launches).toHaveLength(0)+ })+ it('does not start cancelled work while its folder is being prepared', async () => {+ await start(); await active(); service.plan(id, [task('a')]); service.cancel(id, 'a')+ await new Promise(resolve => setTimeout(resolve, 30))+ expect(tasks()[0].state).toBe('cancelled'); expect(launches).toHaveLength(1)+ })+ it('handles a removed harness without mistaking it for an uncertain spawn', async () => {+ await start(); await active(); service.plan(id, [task('a')]); deps.catalog = () => []+ await vi.waitFor(() => expect(tasks()[0].state).toBe('failed'))+ expect(tasks()[0]).toMatchObject({ uncertain: false, error: expect.stringContaining('no longer installed') })+ expect(launches).toHaveLength(1)+ })+ it('can run general-purpose work, resume, and add a new revision after completion', async () => {+ await start(); await active(); service.plan(id, [task('notes', [], 'engine:claude')]); await running('notes')+ expect(launches[1].dsh).toBeNull()+ await service.finish(id, 'notes', 1, 'Verified notes', [])+ await service.finish(id, 'notes', 1, 'Same completed result', [])+ service.complete(id, 'Done'); service.chat(id, '2'.repeat(32), 'Create a revision')+ expect(service.snapshot(id).state).toBe('active')+ service.plan(id, [task('revision', ['notes'], 'engine:claude')]); await running('revision')+ service.cancel(id); service.resume(id)+ expect(service.snapshot(id).state).toBe('active')+ expect(tasks()[0].state).toBe('succeeded'); expect(tasks()[1].state).toBe('cancelled')+ expect(launches).toHaveLength(3)+ })+ it('reports the same failure only once and rejects overlapping result commits', async () => {+ await start(); await active(); service.plan(id, [task('a'), task('b')]); await running('a'); await running('b')+ await service.finish(id, 'a', 1, 'Missing tool', [], true)+ await service.finish(id, 'a', 1, 'Missing tool', [], true)+ expect(sent).toHaveLength(1)+ const first = service.finish(id, 'b', 1, 'Verified', [])+ await expect(service.finish(id, 'b', 1, 'Verified', [])).rejects.toMatchObject({ code: 'FINISH_IN_PROGRESS' })+ await first+ })+ it.each([new Error('Input route disappeared'), 'unknown dispatch failure'])('retains uncertain guidance instead of resending: %s', async failure => {+ await start(); await active(); deps.send = vi.fn(() => { throw failure })+ service.chat(id, '3'.repeat(32), 'Make it taller')+ service.chat(id, '3'.repeat(32), 'Make it taller')+ expect(deps.send).toHaveBeenCalledTimes(1)+ expect(service.snapshot(id).messages).toEqual(expect.arrayContaining([expect.objectContaining({ delivery: 'unknown', deliveryReason: failure instanceof Error ? failure.message : 'Message delivery could not be confirmed.' })]))+ })+ it('leaves a recovered pending receipt pending when no director was recorded', async () => {+ await start(); await active(); service.stop()+ const file = join(deps.stateDir, `${id}.json`), saved = JSON.parse(readFileSync(file, 'utf8'))+ saved.directorId = null; saved.messages.push({ id: '4'.repeat(32), role: 'system', text: 'Saved result', at: Date.now(), delivery: 'pending' })+ writeFileSync(file, JSON.stringify(saved)); service = new OrchestratorService(deps)+ expect(service.snapshot(id).messages).toEqual(expect.arrayContaining([expect.objectContaining({ delivery: 'pending' })]))+ expect(sent).toHaveLength(0)+ })+ it('flushes coalesced transcript changes and bounds retained messages', async () => {+ await start(); await active()+ for (let i = 0; i < 205; i++) {+ service.ingest({ type: 'turn_started', agentId: 'agent-1' })+ service.ingest({ type: 'text_delta', agentId: 'agent-1', payload: { content: `Reply ${i}` } })+ }+ service.ingest({ type: 'error', agentId: 'agent-1', payload: { message: 'Connection lost' } })+ service.ingest({ type: 'unknown', agentId: 'agent-1' })+ service.ingest({ type: 'text_delta', agentId: 'agent-1', replay: true, payload: { content: 'duplicate replay' } })+ await vi.waitFor(() => expect(JSON.parse(readFileSync(join(deps.stateDir, `${id}.json`), 'utf8')).error).toBe('Connection lost'))+ expect(service.snapshot(id).messages).toHaveLength(200)+ service.delivery({ deliveryId: 'missing', sessionId: 'not-this-project', state: 'rejected' })+ service.stop()+ const before = service.snapshot(id)+ service.delivery({ deliveryId: 'missing', sessionId: 'agent-1', state: 'started' })+ service.ingest({ type: 'error', agentId: 'agent-1', payload: { message: 'ignored after shutdown' } })+ expect(service.snapshot(id)).toEqual(before)+ })+ it('pauses after a real background storage failure without duplicating the agent', async () => {+ vi.spyOn(console, 'error').mockImplementation(() => {})+ let resolve!: (value: { agentId: string }) => void+ deps.create = () => new Promise(r => { resolve = r })+ await start()+ const backup = join(root, 'state-backup')+ renameSync(deps.stateDir, backup); writeFileSync(deps.stateDir, 'blocked directory')+ try {+ resolve({ agentId: 'created-before-storage-failure' })+ await vi.waitFor(() => expect(service.snapshot(id).state).toBe('paused'))+ expect(service.snapshot(id).error).toMatch(/background error/)+ } finally { unlinkSync(deps.stateDir); renameSync(backup, deps.stateDir) }+ service.stop(); service = new OrchestratorService(deps)+ expect(service.snapshot(id).directorId).toBe('created-before-storage-failure')+ })+ it('keeps cancellation authoritative when director creation later rejects', async () => {+ let reject!: (error: Error) => void+ deps.create = () => new Promise((_resolve, r) => { reject = r })+ await start(); service.plan(id, [task('queued-before-director')]); service.cancel(id)+ reject(new Error('Spawn rejected after cancellation'))+ await vi.waitFor(() => expect(service.snapshot(id).error).toBe('Spawn rejected after cancellation'))+ expect(service.snapshot(id).state).toBe('cancelled')+ expect(tasks()[0].state).toBe('cancelled')+ })+ it('keeps cancellation authoritative when worker creation later rejects', async () => {+ await start(); await active()+ let reject!: (error: Error) => void+ deps.create = () => new Promise((_resolve, r) => { reject = r })+ service.plan(id, [task('a')]); await vi.waitFor(() => expect(reject).toBeTypeOf('function'))+ service.cancel(id, 'a'); reject(new Error('Late spawn refusal'))+ await new Promise(resolve => setTimeout(resolve, 20))+ expect(tasks()[0]).toMatchObject({ state: 'cancelled', uncertain: false })+ })+ it('does not downgrade a very fast worker result while creation is returning', async () => {+ await start(); await active()+ deps.create = async () => {+ await service.finish(id, 'fast', 1, 'Already verified', [])+ return { agentId: 'fast-worker' }+ }+ service.plan(id, [task('fast')])+ await vi.waitFor(() => expect(tasks()[0].agentId).toBe('fast-worker'))+ expect(tasks()[0].state).toBe('succeeded')+ })+ it('normalizes non-Error worker failures and explicit input rejection', async () => {+ await start(); await active()+ deps.create = async () => { throw 'untyped refusal' }+ service.plan(id, [task('a')]); await vi.waitFor(() => expect(tasks()[0].state).toBe('blocked'))+ expect(tasks()[0].error).toBe('Could not start this specialist.')+ const receipt = '9'.repeat(32)+ service.chat(id, receipt, 'Explain the blocker')+ service.delivery({ deliveryId: receipt, sessionId: 'agent-1', state: 'rejected', reason: 'Input route closed' })+ expect(service.snapshot(id).messages).toEqual(expect.arrayContaining([expect.objectContaining({ id: receipt, delivery: 'failed', deliveryReason: 'Input route closed' })]))+ })+ it('preserves orphaned worker results without inventing a director', async () => {+ await start(); await active(); service.plan(id, [task('a')]); await running('a'); service.stop()+ const file = join(deps.stateDir, `${id}.json`), saved = JSON.parse(readFileSync(file, 'utf8'))+ saved.directorId = null; writeFileSync(file, JSON.stringify(saved)); service = new OrchestratorService(deps)+ await service.finish(id, 'a', 1, 'Verified despite disconnected director', [])+ expect(tasks()[0].state).toBe('succeeded'); expect(sent).toHaveLength(0)+ expect(service.snapshot(id).messages).toEqual(expect.arrayContaining([expect.objectContaining({ delivery: 'pending' })]))+ })+ it('does not lose a committed result if staging cleanup itself fails', async () => {+ await start(); await active(); service.plan(id, [task('a')]); await running('a')+ vi.mocked(filesystem.rm).mockRejectedValueOnce(new Error('Cleanup refused'))+ await service.finish(id, 'a', 1, 'Verified', [])+ expect(tasks()[0].state).toBe('succeeded')+ })+ it('normalizes untyped private-state and background notification failures', async () => {+ await start(); await active(); service.stop()+ vi.spyOn(console, 'warn').mockImplementation(() => {})+ vi.spyOn(privateState, 'readPrivateStateFile').mockImplementationOnce(() => { throw 'untyped state failure' })+ service = new OrchestratorService(deps); expect(service.list()).toEqual([])+ expect(console.warn).toHaveBeenCalledWith(expect.stringContaining('invalid state'))+ service.stop(); service = new OrchestratorService(deps)+ let failOnce = true+ deps.changed = () => { if (failOnce) { failOnce = false; throw 'untyped observer failure' } }+ vi.spyOn(console, 'error').mockImplementation(() => {})+ const other = 'e'.repeat(32)+ await service.start({ id: other, engine: 'claude', prompt: 'Another project' })+ await vi.waitFor(() => expect(service.snapshot(other).state).toBe('paused'))+ expect(service.snapshot(other).error).toContain('unknown error')+ })})diff --git a/cli/vitest.setup.ts b/cli/vitest.setup.tsindex 009876eb2..513307f35 100644--- a/cli/vitest.setup.ts+++ b/cli/vitest.setup.ts@@ -17,6 +17,9 @@ import { join } from 'node:path'process.env.ADAPTER_DATA_DIR = mkdtempSync(join(tmpdir(), 'adapter-test-data-'))process.env.ADAPTER_RUNTIME_DIR = mkdtempSync(join(tmpdir(), 'adapter-test-runtime-'))+// Auth is stored outside ADAPTER_DATA_DIR in production. Never let a spec+// discover, refresh, or replace the developer's real Harness account session.+process.env.HARNESS_AUTH_DIR = join(process.env.ADAPTER_DATA_DIR, 'auth')process.env.DSH_DIR = join(process.env.ADAPTER_DATA_DIR, 'dsh')// The Store catalog is fetched from GitHub by dsh_list; a test must never depend on what that branch// holds today (a published catalog turned a fixture registry of two into the live shelf of 23).diff --git a/desktop/lib/terminal/terminal_session.dart b/desktop/lib/terminal/terminal_session.dartindex 834a6d052..6bdc14da2 100644--- a/desktop/lib/terminal/terminal_session.dart+++ b/desktop/lib/terminal/terminal_session.dart@@ -79,6 +79,8 @@ class TerminalSession extends ChangeNotifier {final TerminalFrameSender send;final TerminalBinarySender sendBinary;final Duration resyncTimeout;+ // A controllable clock keeps coalescing tests independent of host scheduling.+ final DateTime Function() _now;/// Forces a fresh transport dial (see `WsConn.forceReconnect`) — called once when the very first/// `terminal_open` never gets a `terminal_ready` back within [resyncTimeout]. Covers the relay@@ -96,7 +98,8 @@ class TerminalSession extends ChangeNotifier {required this.sendBinary,this.onOpenStalled,this.resyncTimeout = const Duration(seconds: 4),- }) {+ DateTime Function()? now,+ }) : _now = now ?? DateTime.now {terminal = _newTerminal();}@@ -1027,8 +1030,7 @@ class TerminalSession extends ChangeNotifier {// the window still rides the trailing timer, so the frame rate stays bounded.final last = _lastInputFlushAt;final idle =- last == null ||- DateTime.now().difference(last) >= _inputCoalesceWindow;+ last == null || _now().difference(last) >= _inputCoalesceWindow;if (_inputTimer == null && idle) {unawaited(_flushInput());} else {@@ -1049,7 +1051,7 @@ class TerminalSession extends ChangeNotifier {}final bytes = List<int>.from(_inputBytes);_inputBytes.clear();- _lastInputFlushAt = DateTime.now();+ _lastInputFlushAt = _now();final currentStreamId = streamId;if (currentStreamId == null) return;final generation = _generation;@@ -1131,8 +1133,7 @@ class TerminalSession extends ChangeNotifier {_pendingRows = _clampRows(height);final last = _lastResizeFlushAt;final idle =- last == null ||- DateTime.now().difference(last) >= _resizeCoalesceWindow;+ last == null || _now().difference(last) >= _resizeCoalesceWindow;if (_resizeTimer == null && idle) {unawaited(_flushResize());return;@@ -1158,7 +1159,7 @@ class TerminalSession extends ChangeNotifier {if (nextCols == cols && nextRows == rows) return;cols = nextCols;rows = nextRows;- _lastResizeFlushAt = DateTime.now();+ _lastResizeFlushAt = _now();final generation = _generation;final sent = await send('terminal_resize', {'streamId': streamId,diff --git a/desktop/test/orchestrator_controls_test.dart b/desktop/test/orchestrator_controls_test.dartnew file mode 100644index 000000000..e8c85b703--- /dev/null+++ b/desktop/test/orchestrator_controls_test.dart@@ -0,0 +1,615 @@+import 'dart:async';++import 'package:flutter/material.dart';+import 'package:flutter/services.dart';+import 'package:flutter_test/flutter_test.dart';+import 'package:harness/orchestrator/orchestrator_controller.dart';+import 'package:harness/orchestrator/orchestrator_launcher.dart';+import 'package:harness/orchestrator/orchestrator_workspace.dart';+import 'package:harness/state/pending_question.dart';+import 'package:harness/widgets/web_pane_panel.dart';+import 'package:harness/ws/ws_conn.dart';++import 'orchestrator_test.dart' show project, projectId, task;+import 'swarm_state_test.dart' show createApp;++class _Connection extends WsConn {+ _Connection(this.reply)+ : super(+ wsBaseUrl: 'ws://fixture.invalid',+ autonomousEnv: 'test',+ machineId: 'm',+ accessTokenProvider: (_, _) async => '',+ onAuthFailure: (_) {},+ onEvent: (_) {},+ onStatus: (_) {},+ );+ final OrchestratorRequest reply;+ @override+ Future<Map<String, dynamic>> request(+ String type, {+ Map<String, dynamic> payload = const {},+ Duration timeout = const Duration(seconds: 20),+ }) => reply(payload);+}++void largeSurface(WidgetTester tester) {+ tester.view.devicePixelRatio = 1;+ tester.view.physicalSize = const Size(1400, 1000);+ addTearDown(tester.view.resetDevicePixelRatio);+ addTearDown(tester.view.resetPhysicalSize);+}++void main() {+ test(+ 'refresh failures remain visible and a later refresh recovers',+ () async {+ var fail = true;+ final model = OrchestratorController(+ id: projectId,+ request: (_) async {+ if (fail) throw StateError('Transport unavailable');+ return {'project': project()};+ },+ );+ addTearDown(model.dispose);+ await model.refresh();+ expect(model.error, contains('Transport unavailable'));+ fail = false;+ await model.refresh();+ expect(model.error, isNull);+ },+ );++ testWidgets(+ 'launcher uses the preferred engine and displays list and launch errors',+ (tester) async {+ largeSurface(tester);+ final app = createApp(+ connectionForTest: (_) => _Connection((p) async {+ if (p['action'] == 'list') throw StateError('Saved projects offline');+ return {+ 'error': 'DECLINED',+ 'detail': 'The server refused this launch',+ };+ }),+ );+ app.machineStates['m']!.localOnly = true;+ app.agentPreference.value = 'codex';+ addTearDown(app.dispose);+ await tester.pumpWidget(+ MaterialApp(+ home: Builder(+ builder: (context) => TextButton(+ onPressed: () => showOrchestratorLauncher(context, app),+ child: const Text('Launch'),+ ),+ ),+ ),+ );+ await tester.tap(find.text('Launch'));+ await tester.pumpAndSettle();+ expect(find.text('Codex director'), findsOneWidget);+ expect(find.textContaining('Saved projects offline'), findsOneWidget);+ await tester.enterText(+ find.byKey(const ValueKey('orchestrator-prompt')),+ 'Test project',+ );+ await tester.pump();+ await tester.tap(find.byKey(const ValueKey('orchestrator-start')));+ await tester.pumpAndSettle();+ expect(+ find.textContaining('The server refused this launch'),+ findsOneWidget,+ );+ await tester.tap(find.byTooltip('Close'));+ await tester.pumpAndSettle();+ expect(find.byType(OrchestratorLauncher), findsNothing);+ },+ );++ testWidgets(+ 'normal workspace uses its cached controller and only opens terminals on Inspect',+ (tester) async {+ largeSurface(tester);+ final app = createApp(+ connectionForTest: (_) => _Connection(+ (p) async => p['action'] == 'list'+ ? {'projects': []}+ : {+ 'project': {+ ...project(+ tasks: [+ {...task('cad'), 'agentId': 'a1'},+ ],+ ),+ 'directorId': 'a0',+ },+ },+ ),+ );+ app.machineStates['m']!.localOnly = true;+ var disposed = false;+ addTearDown(() {+ if (!disposed) app.dispose();+ });+ await tester.pumpWidget(+ MaterialApp(+ home: Scaffold(+ body: OrchestratorWorkspace(+ notifier: app,+ machineId: 'm',+ projectId: projectId,+ ),+ ),+ ),+ );+ await tester.pump();+ expect(app.panes, isEmpty);+ await tester.tap(find.byTooltip('Inspect cad'));+ await tester.pump();+ expect(app.activeSwarm.panes.any((p) => p.agentId == 'a1'), isTrue);+ await tester.tap(find.byTooltip('Inspect director'));+ await tester.pump();+ expect(app.activeSwarm.panes.any((p) => p.agentId == 'a0'), isTrue);+ await tester.tap(find.byTooltip('New project (⌘P)'));+ await tester.pumpAndSettle();+ expect(find.byType(OrchestratorLauncher), findsOneWidget);+ await tester.tap(find.byTooltip('Close'));+ await tester.pumpAndSettle();+ await tester.pumpWidget(const SizedBox());+ app.dispose();+ disposed = true;+ },+ );+ test('task projection tolerates optional fields and ignores malformed artifact rows', () {+ final minimal = OrchestratorTask({+ 'id': 'research',+ 'artifacts': [+ null,+ {},+ {'path': 'notes.md'},+ ],+ });+ expect(minimal.title, 'research');+ expect(minimal.state, 'queued');+ expect(minimal.harness, '');+ expect(minimal.attempt, 1);+ expect(minimal.summary, '');+ expect(minimal.viewerName, 'research');+ expect(minimal.artifacts, ['notes.md']);+ expect(minimal.agentId, isNull);+ expect(minimal.runtime, isNull);+ expect(minimal.uncertain, isFalse);+ expect(minimal.hasViewer, isTrue);+ expect(+ OrchestratorTask({+ 'id': 'x',+ 'runtime': {'error': 'Viewer stopped'},+ }).error,+ 'Viewer stopped',+ );+ });++ testWidgets(+ 'subscriptions coalesce, refcount and stop polling when the tab closes',+ (tester) async {+ var reads = 0;+ final model = OrchestratorController(+ id: projectId,+ pollInterval: const Duration(seconds: 1),+ request: (_) async {+ reads++;+ return {'project': project(revision: reads)};+ },+ );+ model.changed();+ model.watch();+ model.watch();+ await tester.pump();+ expect(reads, 1);+ model.changed();+ model.changed();+ await tester.pump(const Duration(milliseconds: 180));+ expect(reads, 2);+ model.unwatch();+ await tester.pump(const Duration(seconds: 1));+ expect(reads, 3);+ model.changed();+ model.unwatch();+ await tester.pump(const Duration(seconds: 2));+ expect(reads, 3);+ model.dispose();+ model.watch();+ model.changed();+ model.unwatch();+ },+ );++ test('coalesces in-flight reads and ignores other projects and late disposed replies', () async {+ final response = Completer<Map<String, dynamic>>();+ var calls = 0;+ final model = OrchestratorController(+ id: projectId,+ request: (_) {+ calls++;+ return response.future;+ },+ );+ final first = model.refresh(), second = model.refresh();+ expect(calls, 1);+ expect(identical(first, second), isTrue);+ response.complete({+ 'project': {...project(), 'id': 'different'},+ });+ await first;+ expect(model.project, isNull);+ model.dispose();+ expect(await model.perform('cancel'), isFalse);+ expect(await model.send('hello'), isFalse);+ await model.refresh(); // An outstanding caller cannot revive a disposed projection.+ });++ test(+ 'action and send locks prevent double dispatch and preserve a newer draft',+ () async {+ var response = Completer<Map<String, dynamic>>();+ final model = OrchestratorController(+ id: projectId,+ request: (_) => response.future,+ );+ addTearDown(model.dispose);+ final operation = model.perform('retry', taskId: 'cad');+ expect(await model.perform('retry', taskId: 'cad'), isFalse);+ response.complete({+ 'error': 'REFUSED',+ 'detail': 'Inspect the original worker',+ });+ expect(await operation, isFalse);+ expect(model.error, contains('Inspect the original worker'));+ expect(model.operating, isFalse);+ expect(await model.send(' '), isFalse);+ response = Completer<Map<String, dynamic>>();+ model.draft = 'First message';+ final send = model.send(model.draft);+ expect(await model.send('Duplicate'), isFalse);+ model.draft = 'Newer unsent draft';+ response.complete({'project': project()});+ expect(await send, isTrue);+ expect(model.draft, 'Newer unsent draft');+ },+ );++ testWidgets(+ 'launcher submits explicit options with Cmd-Enter and opens one project tab',+ (tester) async {+ largeSurface(tester);+ final requests = <Map<String, dynamic>>[];+ final connection = _Connection((p) async {+ requests.add(p);+ return p['action'] == 'list'+ ? {'projects': []}+ : {+ 'project': {...project(), 'prompt': p['prompt']},+ };+ });+ final app = createApp(connectionForTest: (_) => connection);+ app.machineStates['m']!.localOnly = true;+ addTearDown(app.dispose);+ await tester.pumpWidget(+ MaterialApp(+ home: Builder(+ builder: (context) => TextButton(+ onPressed: () => showOrchestratorLauncher(context, app),+ child: const Text('Launch'),+ ),+ ),+ ),+ );+ await tester.tap(find.text('Launch'));+ await tester.pumpAndSettle();+ expect(+ tester+ .widget<FilledButton>(+ find.byKey(const ValueKey('orchestrator-start')),+ )+ .onPressed,+ isNull,+ );+ await tester.enterText(+ find.byKey(const ValueKey('orchestrator-prompt')),+ ' A fitted enclosure ',+ );+ await tester.tap(find.text('Claude director'));+ await tester.pumpAndSettle();+ await tester.tap(find.text('Codex director').last);+ await tester.pumpAndSettle();+ await tester.tap(find.text('Project options'));+ await tester.pumpAndSettle();+ final folder = find.byWidgetPredicate(+ (w) =>+ w is TextField &&+ w.decoration?.labelText == 'Project folder (optional)',+ );+ await tester.ensureVisible(folder);+ await tester.enterText(folder, ' /tmp/fixture-project ');+ expect(+ tester.widget<CheckboxListTile>(find.byType(CheckboxListTile)).value,+ isFalse,+ );+ await tester.ensureVisible(find.byType(CheckboxListTile));+ await tester.tap(find.byType(CheckboxListTile));+ await tester.pump();+ await tester.tap(folder);+ await tester.sendKeyDownEvent(LogicalKeyboardKey.metaLeft);+ await tester.sendKeyEvent(LogicalKeyboardKey.enter);+ await tester.sendKeyUpEvent(LogicalKeyboardKey.metaLeft);+ await tester.pumpAndSettle();+ final start = requests.singleWhere((p) => p['action'] == 'start');+ expect(start['engine'], 'codex');+ expect(start['cwd'], '/tmp/fixture-project');+ expect(start['bypassPermission'], isTrue);+ expect(start['prompt'], 'A fitted enclosure');+ expect(app.activeSwarm.orchestratorId, projectId);+ expect(find.byType(OrchestratorLauncher), findsNothing);+ expect(tester.takeException(), isNull);+ },+ );++ testWidgets('recent project opens without starting a new director', (+ tester,+ ) async {+ largeSurface(tester);+ final requests = <String>[];+ final app = createApp(+ connectionForTest: (_) => _Connection((p) async {+ requests.add(p['action'] as String);+ return {+ 'projects': [+ {'id': projectId, 'prompt': 'Existing lamp', 'state': 'completed'},+ ],+ };+ }),+ );+ app.machineStates['m']!.localOnly = true;+ addTearDown(app.dispose);+ await tester.pumpWidget(+ MaterialApp(+ home: Builder(+ builder: (context) => TextButton(+ onPressed: () => showOrchestratorLauncher(context, app),+ child: const Text('Launch'),+ ),+ ),+ ),+ );+ await tester.tap(find.text('Launch'));+ await tester.pumpAndSettle();+ await tester.ensureVisible(find.text('Existing lamp'));+ await tester.tap(find.text('Existing lamp'));+ await tester.pumpAndSettle();+ expect(requests, ['list']);+ expect(app.activeSwarm.orchestratorId, projectId);+ });++ testWidgets(+ 'disconnected launcher explains how to connect without creating a project',+ (tester) async {+ largeSurface(tester);+ final app = createApp();+ app.machineStates.clear();+ addTearDown(app.dispose);+ await tester.pumpWidget(+ MaterialApp(home: OrchestratorLauncher(notifier: app)),+ );+ await tester.enterText(+ find.byKey(const ValueKey('orchestrator-prompt')),+ 'A lamp',+ );+ await tester.pump();+ await tester.tap(find.byKey(const ValueKey('orchestrator-start')));+ await tester.pump();+ expect(+ find.text('Connect this computer’s Harness daemon first.'),+ findsOneWidget,+ );+ await tester.pumpWidget(const SizedBox());+ },+ );++ testWidgets(+ 'workspace confirms scoped stopping and exposes safe retry and resume',+ (tester) async {+ largeSurface(tester);+ final app = createApp();+ addTearDown(app.dispose);+ var current = project(+ tasks: [+ {+ ...task('cad', state: 'failed'),+ 'error': 'Missing tool',+ 'attempt': 2,+ },+ {...task('unknown', state: 'blocked'), 'uncertain': true},+ {+ ...task('notes', state: 'succeeded'),+ 'hasViewer': false,+ 'summary': 'Verified notes',+ 'artifacts': [+ {'path': 'notes.md'},+ ],+ },+ ],+ );+ final requests = <Map<String, dynamic>>[];+ final model = OrchestratorController(+ id: projectId,+ request: (p) async {+ requests.add(p);+ if (p['action'] == 'cancel')+ current = {...current, 'state': 'cancelled', 'revision': 2};+ if (p['action'] == 'resume')+ current = {...current, 'state': 'active', 'revision': 3};+ return {'project': current};+ },+ );+ addTearDown(model.dispose);+ await tester.pumpWidget(+ MaterialApp(+ home: Scaffold(+ body: OrchestratorWorkspace(+ notifier: app,+ machineId: 'm',+ projectId: projectId,+ controller: model,+ ),+ ),+ ),+ );+ await tester.pump();+ expect(find.byTooltip('Retry task'), findsOneWidget);+ await tester.tap(find.byTooltip('Retry task'));+ await tester.pump();+ expect(requests.last, {+ 'action': 'retry',+ 'id': projectId,+ 'taskId': 'cad',+ });+ expect(find.text('notes.md'), findsOneWidget);+ await tester.tap(find.text('Stop'));+ await tester.pumpAndSettle();+ await tester.tap(find.text('Keep working'));+ await tester.pumpAndSettle();+ expect(requests.any((p) => p['action'] == 'cancel'), isFalse);+ await tester.tap(find.text('Stop'));+ await tester.pumpAndSettle();+ await tester.tap(find.text('Stop project'));+ await tester.pumpAndSettle();+ expect(requests.last, {'action': 'cancel', 'id': projectId});+ expect(+ tester+ .widget<TextField>(+ find.byKey(const ValueKey('orchestrator-composer')),+ )+ .enabled,+ isFalse,+ );+ await tester.tap(find.text('Resume'));+ await tester.pump();+ expect(requests.last['action'], 'resume');+ await tester.pumpWidget(const SizedBox());+ },+ );++ testWidgets(+ 'viewer zoom, runtime errors, delivery receipts and director questions stay visible',+ (tester) async {+ largeSurface(tester);+ final app = createApp();+ addTearDown(app.dispose);+ app.machineStates['m']!.blockedAgents['director'] = PendingQuestion(+ machineId: 'm',+ agentId: 'director',+ requestId: 'q',+ answerKey: 'Continue?',+ prompt: 'Material?',+ options: const ['Metal'],+ multi: false,+ since: DateTime.now(),+ );+ var current = {+ ...project(+ tasks: [+ {+ ...task('cad', url: 'http://127.0.0.1:9999/'),+ 'error': 'Viewer is reconnecting',+ },+ {...task('research'), 'hasViewer': false},+ ],+ ),+ 'directorWorking': true,+ 'error': 'Transport lost',+ 'messages': [+ {'id': '1', 'role': 'user', 'text': 'First', 'delivery': 'unknown'},+ {+ 'id': '2',+ 'role': 'system',+ 'text': 'Second',+ 'delivery': 'failed',+ 'deliveryReason': 'Cancelled',+ },+ {'id': '3', 'role': 'user', 'text': 'Third', 'delivery': 'queued'},+ ],+ };+ final requests = <Map<String, dynamic>>[];+ final model = OrchestratorController(+ id: projectId,+ request: (p) async {+ requests.add(p);+ return {'project': current};+ },+ );+ addTearDown(model.dispose);+ await tester.pumpWidget(+ MaterialApp(+ home: Scaffold(+ body: OrchestratorWorkspace(+ notifier: app,+ machineId: 'm',+ projectId: projectId,+ controller: model,+ ),+ ),+ ),+ );+ await tester.pump();+ expect(find.text('Viewer is reconnecting'), findsOneWidget);+ expect(find.textContaining('Delivery unconfirmed.'), findsOneWidget);+ expect(+ find.textContaining('Message not delivered. Cancelled'),+ findsOneWidget,+ );+ expect(find.text('Queued for the agent'), findsOneWidget);+ expect(find.text('Director is working…'), findsOneWidget);+ expect(+ find.textContaining('The director needs your input'),+ findsOneWidget,+ );+ expect(+ find.textContaining('This specialist works in the background.'),+ findsOneWidget,+ );+ tester.widget<WebPanePanel>(find.byType(WebPanePanel)).onToggleZoom!();+ await tester.pump();+ expect(find.text('All views'), findsOneWidget);+ expect(find.text('research'), findsNothing);+ await tester.tap(find.text('All views'));+ await tester.pump();+ expect(find.text('research'), findsOneWidget);+ await tester.tap(find.text('Reconnect'));+ await tester.pump();+ expect(requests.last['action'], 'status');+ final composer = find.byKey(const ValueKey('orchestrator-composer'));+ await tester.enterText(composer, 'Draft');+ await tester.sendKeyDownEvent(LogicalKeyboardKey.shiftLeft);+ await tester.sendKeyEvent(LogicalKeyboardKey.enter);+ await tester.sendKeyUpEvent(LogicalKeyboardKey.shiftLeft);+ await tester.pump();+ expect(requests.any((p) => p['action'] == 'message'), isFalse);+ await tester.tap(find.byTooltip('Send to director'));+ await tester.pump();+ expect(requests.last['action'], 'message');+ current = {+ ...current,+ 'revision': 2,+ 'state': 'starting',+ 'tasks': [],+ 'directorId': null,+ };+ await model.refresh();+ await tester.pump();+ expect(find.text('Starting your director…'), findsOneWidget);+ await tester.pumpWidget(const SizedBox());+ },+ );+}diff --git a/desktop/test/terminal_session_test.dart b/desktop/test/terminal_session_test.dartindex d0c937fed..9dee6e9e7 100644--- a/desktop/test/terminal_session_test.dart+++ b/desktop/test/terminal_session_test.dart@@ -12,8 +12,10 @@ void main() {late List<({String type, Map<String, dynamic> payload})> sent;late List<TerminalBinaryFrame> binarySent;late TerminalSession session;+ DateTime? controlledNow;setUp(() {+ controlledNow = null;sent = [];binarySent = [];session = TerminalSession(@@ -21,6 +23,7 @@ void main() {agentId: 'agent-1',agentName: 'backend-api',engineId: 'codex',+ now: () => controlledNow ?? DateTime.now(),send: (type, payload) async {sent.add((type: type, payload: Map<String, dynamic>.from(payload)));return true;@@ -281,6 +284,9 @@ void main() {test('terminal input batches, preserves Enter boundary and is never retried',() async {+ // Keep all typed characters inside the 4 ms logical batching window,+ // even when a loaded CI host takes longer to schedule the test itself.+ controlledNow = DateTime(2026, 9, 18);await ready();await session.handleBinary(output(0, utf8.encode(r'prompt> '), keyframe: true, cols: 80, rows: 24),diff --git a/desktop/tool/check_orchestrator_coverage.mjs b/desktop/tool/check_orchestrator_coverage.mjsnew file mode 100644index 000000000..2a182436c--- /dev/null+++ b/desktop/tool/check_orchestrator_coverage.mjs@@ -0,0 +1,16 @@+/** Check the new feature's line coverage without disguising whole-app coverage.+ * Run flutter test --coverage test/orchestrator_test.dart test/orchestrator_controls_test.dart first. */+import { readFileSync } from 'node:fs'+const expected = new Set(['orchestrator_controller.dart', 'orchestrator_launcher.dart', 'orchestrator_workspace.dart'])+let covered = 0, total = 0+for (const record of readFileSync(process.argv[2] ?? 'coverage/lcov.info', 'utf8').split('end_of_record')) {+ const path = record.match(/SF:(.*)/)?.[1]+ if (!path?.includes('/orchestrator/')) continue+ const name = path.split('/').at(-1)+ if (!expected.delete(name)) continue+ const found = Number(record.match(/LF:(\d+)/)?.[1]), hit = Number(record.match(/LH:(\d+)/)?.[1])+ if (!found || hit !== found) throw new Error(`${name}: ${hit}/${found} lines, expected 100%`)+ total += found; covered += hit+}+if (expected.size) throw new Error(`Missing feature coverage: ${[...expected].join(', ')}`)+console.log(`Orchestrator desktop: ${covered}/${total} lines (100%) across 3 feature files. This is not whole-app coverage.`)diff --git a/desktop/tool/swarm_titlebar_checks.swift b/desktop/tool/swarm_titlebar_checks.swiftindex d1fae3978..ef83977e5 100644--- a/desktop/tool/swarm_titlebar_checks.swift+++ b/desktop/tool/swarm_titlebar_checks.swift@@ -90,8 +90,10 @@ private extension SwarmTabButton {func checkCloseVisibility(_ visible: Bool) throws {try checkTitlebar(closeButton.showsGlyph == visible,"A tab reveals its close mark only for hover or keyboard focus")- try checkTitlebar(!closeButton.isHidden && closeButton.accessibilityLabel() == "Close \(name)",- "A quiet close mark remains an accessible action")+ try checkTitlebar(closeButton.isHidden == compact,+ "Only compact icon-only tabs hide the close control")+ try checkTitlebar(closeButton.accessibilityLabel() == "Close \(name)",+ "The close action retains its accessible label")}func clickBothActions() {@@ -186,7 +188,7 @@ private extension SwarmTabStrip {try checkTitlebar(tabs[0].showsDivider && tabs[1].showsDivider, "Separators return when the pointer leaves")try checkTitlebar(!tabs[10].showsDivider && !tabs[11].showsDivider, "Selected tab remains joined without neighboring separators")try checkTitlebar(tabs.count == 24, "All overflow tabs exist")- try checkTitlebar(!newButton.isEnabled, "New Harness is disabled at capacity")+ try checkTitlebar(newButton.isEnabled, "New Tab remains available with overflow tabs")for (index, tab) in tabs.enumerated() {try tab.checkAccessibility(expectedName: "Swarm \(index)", active: index == 11)}@@ -232,8 +234,8 @@ private extension SwarmTabStrip {"New Tab can reveal an existing starter at the tab limit")fullWithStarter["canOpenNewTab"] = falseupdate(fullWithStarter)- try checkTitlebar(!newButton.isEnabled,- "New Tab respects the workspace's availability")+ try checkTitlebar(newButton.isEnabled,+ "The retired canOpenNewTab capacity flag no longer disables New Tab")update(state([["id": "swarm-0", "name": "Renamed tab"]], active: "swarm-0"))try checkTitlebar(newButton.toolTip == nil && openButton.toolTip == nil,"Titlebar actions add no hover hints")@@ -525,7 +527,7 @@ private extension SwarmTitlebar {try checkTitlebar(strip.newButton.accessibilityLabel() == "New Tab", "The plus announces New Tab")try checkTitlebar(main.defersToInput(event("n", 45, .command)) && main.defersToInput(event("o", 31, .command)),"Command-N and Command-O reach their separate New and Open actions")- try checkTitlebar(!main.defersToInput(event("p", 35, .command)), "Command-P no longer opens Navigate")+ try checkTitlebar(main.defersToInput(event("p", 35, .command)), "Command-P reaches the Orchestrator launcher")try checkTitlebar(main.defersToInput(event("p", 35, [.command, .shift])), "Command-Shift-P reaches command search")flutterKeyContext = "picker"syncMenuKeys()diff --git a/docs/orchestrator-combinations.md b/docs/orchestrator-combinations.mdnew file mode 100644index 000000000..2adc77333--- /dev/null+++ b/docs/orchestrator-combinations.md@@ -0,0 +1,53 @@+# Creative harness combinations++The director should build a graph, not pick one fixed pipeline. Each edge is an explicit contract: filenames, units, coordinate system, version, and acceptance checks. The installed harness determines the specialist's engine; choosing a Codex director does not silently change a Claude-based harness into Codex.++Current local inventory: Solid, Autonomous Workshop, Blender, Copper, plus CAD Viewer and Model Viewer. The two viewers are viewer packages, not extra agents. Generic `engine:<director-engine>` tasks can research, write code, or validate data but do not automatically gain a domain viewer. Remotion and other unlisted packages require installation; the director never silently installs them.++## Recipes and readiness++| Project | Combination | Handoff and decisive check | Readiness |+| --- | --- | --- | --- |+| A token and its fitted home | Solid → Workshop | STEP + dimensions; import the same solid, 0.3 mm clearance, zero overlap | **Live completed**, independently reimported |+| A manufactured object becomes a hero shot | Solid → Blender | STL in mm → scene in meters; mesh hash, exact scale, camera framing, PNG + GLB | Scripted Blender preview verified; **live Blender blocked by Claude auth** |+| A tiny computer with an honest enclosure | Copper → Solid → Blender | Board outline, mounting holes and connector keep-outs as mm JSON; cavity clearance and connector accessibility | Proposed; PCB/electrical validity requires separate checks |+| Three concepts, one evidence-backed choice | Parallel Solid variants + general reviewer → Blender comparison | Same target envelope and a shared criteria JSON; compare dimensions/volume before aesthetic ranking | Scheduler fan-out/join tested with fixtures; live recipe untested |+| A product launch in three formats | Solid → Blender → Remotion | STEP/STL → transparent PNG/GLB → timed composition and MP4; dimensions, frame count, aspect ratio | Proposed; Remotion not installed |+| Turn personal data into an object | General data preparation → Solid → Blender | User-provided data → normalized JSON → parametric relief/sculpture; preserve data-to-height mapping | Proposed; no external data access assumed |+| A repair part with an assembly explanation | General measurements → Solid → Workshop → Blender | Measurement sheet → replacement part → original/repair assembly → exploded view; mating faces and units | Proposed; no physical-fit or safety certification |+| A reusable motion identity | Blender → Remotion + general copywriter | Shared palette/type/timing JSON; GLB or PNG sequence; typography safe areas and frame-accurate beats | Proposed; requires Remotion and usable Claude auth |+| A design change propagates without destroying history | Solid v1 → Workshop v1; then Solid v2 → Workshop v2 → comparison | New task IDs and pinned attempt hashes; old outputs remain unchanged | Revision/copy invariants automated; live revision sequence untested |+| A stress-test dossier, not just a pretty render | Parallel geometry checks, documentation and visual review → general synthesis | Independent evidence JSON + artifact hashes; unresolved checks block completion | Scheduling/artifact contracts tested; domain claims require real validators |+| A kit with a consistent family resemblance | Parallel CAD accessories → Workshop assembly + Blender scene | Shared hole spacing, tolerances and palette; verify every part against the same interface spec | Proposed |+| A project that can honestly say “blocked” | Deliberately unavailable upstream → dependent render; independent notes continue | Explicit fail result; dependent never starts, independent branch still works; retry gets a new folder | Automated dependency/retry/cancellation tests |++These are project designs, not claims that every harness already provides every export command. Workers must inspect their actual installed instructions/tools and report missing capabilities. A proposed recipe does not authorize installing packages, publishing assets, or buying services.++## Copy-ready prompts++### 1. Object → scene → launch film++> Make a small desk lamp with a manufacturable CAD base, a warm studio scene, and a 10-second 1080p launch film. First inspect installed harnesses. Use CAD for geometry, Blender for the actual imported model and lighting, and a video harness only if installed. Make geometry checks independent from copywriting, then join both in the film. Specify mm-to-meter conversion, color palette, FPS, duration, and artifact names in every relevant brief. Preserve all v1 outputs; revisions must use new task IDs. If video tools or accounts are unavailable, complete the usable artifact branches and explain the exact remaining gap—do not claim the whole project is finished.++### 2. Enclosure driven by the circuit, not guessed around it++> Design a conceptual sensor enclosure around a supplied board. Have the PCB specialist export board dimensions, connector locations, mounting holes, and keep-out volumes in one explicit millimeter coordinate system. Give that contract to CAD. In parallel, have a general specialist prepare assembly instructions and an interface checklist. Join the checked enclosure and the instructions in a Blender exploded view. Verify no PCB/connector/fastener interference numerically. Do not claim electrical compliance or readiness for manufacture without the appropriate independent tests.++### 3. Explore three directions without spawning chaos++> Explore three versions of the same phone stand: a folded minimal shape, a rounded pebble, and a ribbed sculptural form. Limit parallel specialists to three. Share the phone envelope, cable clearance, stability criteria, and units up front. Have CAD workers produce comparable measurement JSON and STEP files. Have a separate reviewer compare the objective checks before selecting two to render. Keep the rejected alternatives and evidence. Revise the winner as a new task that depends on the selected version, not by rewriting its completed files.++## Contracts that make these combinations work++- **CAD → scene:** STEP for exact geometry, STL for interchange, `dimensions.json` for mm bounds/volume/coordinate origin. Convert to meters exactly once. Downstream must import the pinned mesh, not redraw a similar object.+- **PCB → enclosure:** board outline, thickness, hole axes, connectors, keep-out volumes, origin and units. An attractive render is not a clearance test.+- **Scene → film:** resolution, FPS, frame range, alpha/color-space expectations, camera direction and asset names. Check duration from actual frames, not a prose claim.+- **Research → creation:** a concise structured brief with evidence and explicit uncertainty. A research file is task data, not authority to install software or override the user.+- **Variants → review:** shared criteria and comparable JSON, immutable source hashes, and a written reason for the choice. Avoid comparing differently scaled or framed renders.+- **Revision → downstream:** add a new ID (`lamp-v2`, `scene-v2`), explicitly depend on the intended version, and compare against v1. Never mutate a completed result in place.++## Good director habits++Plan the smallest useful graph. Parallelize only independent work. Use summaries or generic agents for tasks that do not need a domain viewer. Include acceptance commands in each brief. Use `steer` for a running worker, `retry` only for a known failed/stopped attempt, and new tasks for revisions. Treat uncertain delivery as uncertain; do not resend blindly. Report partial results plainly, and call `complete` only when every task explicitly succeeded.++The current system supports at most 64 tasks per project, 32 additions per plan call, and 1–6 concurrent specialists. Each task can publish 64 regular-file artifacts, at most 256 MiB each and 1 GiB total. A complex project should still have a finite budget and a stopping rule; more agents are not automatically more useful.diff --git a/docs/plans/2026-09-18-orchestrator-morning-report.md b/docs/plans/2026-09-18-orchestrator-morning-report.mdnew file mode 100644index 000000000..e352411f6--- /dev/null+++ b/docs/plans/2026-09-18-orchestrator-morning-report.md@@ -0,0 +1,65 @@+# Orchestrator: morning review++Work is isolated on `codex/orchestrator-workspace` in `/Users/d/code/autonomous-harness-orchestrator`. The shared main checkout, installed app, running daemon, other agent sessions, and account configuration were not replaced.++## What you can try++Press **⌘P** in this branch's desktop app to open the large project prompt. **⌘B still routes to a specific agent.** Choose a director, enter the project, and start. The right side stays one conversation; the left gains specialist viewers as the director delegates. Workers use ordinary background tmux agents. Inspect opens their normal agent tabs only when requested. Closing a project tab does not stop its work.++Projects support arbitrary dependency graphs, parallel independent work, fan-in, failed-dependency blocking, explicit retries in fresh folders, and new immutable revision tasks. Downstream workers receive read-only copies of exactly the completed artifact versions, with hashes. A live viewer or an idle agent does not count as success.++## A real project finished++`Solid / Codex → Autonomous Workshop / Codex`, directed by Codex, completed in **515 seconds**. The director chose and submitted the plan through the same local orchestration tools used by the app. No worker output was predetermined.++1. Solid made a 24 mm diameter, 5 mm thick token with a 4 mm off-center through-hole.+2. Workshop imported that exact pinned STEP, made a 32 mm holder with a 24.6 mm recess, and placed the token on its 2 mm base.+3. The director checked the results and explicitly completed the project.++The live run passed seven external transport/artifact checks. Workers reported 34 geometry checks. An additional independent STEP reimport—without executing their Python—passed **12 checks**, including positive volumes, valid solids, 0.3 mm radial clearance, zero overlap, and unchanged upstream-token geometry.++++Review the [portable GLB](../../output/orchestrator-live/assembly.glb), [assembly STEP](../../output/orchestrator-live/holder/model.step), [token STEP](../../output/orchestrator-live/token/model.step), and [independent measurements](../../output/orchestrator-live/independent-checks.json). The PNG/GLB above were generated afterward by a deterministic Blender script from the verified CAD; they are **not** evidence of a successful live Blender agent.++The initially attempted Claude → Solid → Blender run stopped before delegation because Claude reported an expired OAuth session it could not refresh ($0 reported model cost). The installed Codex account worked. Remotion is not installed. Neither a live Claude/Blender combination nor a live Remotion movie is claimed as tested.++## Verification and scope++Measured coverage refers to the new orchestrator modules, **not the entire repository or every possible model behavior**:++| Scope | Result |+| --- | --- |+| Six CLI orchestrator modules | 79 tests; **430/430 lines, 568/568 statements, 313/313 branches, 88/88 functions** |+| Three desktop orchestrator modules | 20 tests; **529/529 executable lines** |+| Timing-sensitive install/terminal regressions | 68 tests passed after removing host-scheduling assumptions |+| Independent live geometry check | 12/12 passed |++Reproducible gates: `npm run test:orchestrator` in `cli/`; in `desktop/`, `flutter test --coverage test/orchestrator_test.dart test/orchestrator_controls_test.dart` followed by `node tool/check_orchestrator_coverage.mjs`. No feature coverage exclusions were added to achieve these results.++- CLI: real loopback transport, all RPC actions, graph scheduling, immutable artifacts, delivery receipts, concurrent creation, scoped cancellation, restart recovery, storage failures, and fast-worker races.+- Desktop: launcher options, ⌘P/⌘B separation, recent projects, chat drafts/focus, reconnect, delayed replies, narrow layout, unsafe URL refusal, viewer zoom, explicit inspection, stop confirmation, and restoration.+- Deterministic end-to-end: actual desktop connection → daemon → dedicated tmux agents → real harness materialization → real HTTP viewers, with a parallel fan-out/join project, restart/reconnect, follow-up chat, and cross-project cancellation isolation.+- Native macOS: debug build and a test with three real WKWebViews whose DOMs were read through JavaScript; chat draft/focus survived viewer updates. Native shortcut mapping checks also ran.+- Live: real model-generated two-harness project, real tmux sessions, real CAD toolchains and viewer servers, pinned artifact handoff, and independent geometry verification.++The live test uses a **bounded headless bridge**, not the production interactive engine TUI. Production input coordination has separate regression tests. Physical keyboard delivery through a focused live production viewer was not manually tested. The live test stopped its own tmux server and viewers and retained its files; other sessions were untouched.++The Codex test needed command-network access to its loopback daemon. OpenAI Docs guided a **per-process** `sandbox_workspace_write.network_access=true` override while retaining workspace-write and approval review; no global settings were edited. See [official network-access documentation](https://learn.chatgpt.com/docs/agent-approvals-security#network-access).++## What remains worth improving++- Reauthenticate Claude interactively, then rerun `cad-blender`; install/authorize a Remotion harness separately before claiming video support has been live-tested.+- Add an explicit, user-reviewed way to adopt an uncertain launch after a crash. Current behavior refuses blind retries to avoid duplicate agents.+- Keep monitoring large-project state limits and long-history receipt retention. The state reader is bounded to 8 MiB and the visible transcript to 200 messages; those are not unlimited project memory.+- A vanished worker remains inspectable/manual-recovery work; absence or idleness never fabricates a successful result.+- Artifact ownership and read-only copies prevent accidental cross-task edits; they are not a security sandbox against an agent running as the same OS user.+- CAD checks are mathematical only: physical printing, insertion, material behavior, and manufacturing tolerances remain unverified.++For creative project ideas, exact handoff contracts, and honest readiness labels, see the [harness combination cookbook](../orchestrator-combinations.md).++## Reproduce safely++From this worktree's `cli/` directory, `HARNESS_ORCHESTRATOR_LIVE=1 HARNESS_ORCHESTRATOR_LIVE_SCENARIO=cad-fit node --import tsx scripts/orchestrator-live-project.ts` runs the account-backed test. It may consume model credits. Omitting the scenario selects the Claude/Blender test. Limits: six total agents, twelve headless turns, four turns per agent, twelve minutes; Claude print calls additionally have a $1 per-turn limit. Codex account usage is not dollar-capped by this adapter.++The deterministic peer and desktop tests do not use model accounts. Do not replace the running daemon just to inspect this report.diff --git a/output/orchestrator-live/assembly.glb b/output/orchestrator-live/assembly.glbnew file mode 100644index 000000000..d7e2076d6Binary files /dev/null and b/output/orchestrator-live/assembly.glb differdiff --git a/output/orchestrator-live/holder/fit.json b/output/orchestrator-live/holder/fit.jsonnew file mode 100644index 000000000..19f364595--- /dev/null+++ b/output/orchestrator-live/holder/fit.json@@ -0,0 +1,227 @@+{+ "units": "mm",+ "solid_count": 2,+ "input_solid_count": 1,+ "reimported_step_solid_count": 2,+ "dimensions": {+ "holder_od_mm": 32,+ "recess_diameter_mm": 24.6,+ "base_mm": 2,+ "recess_depth_mm": 5,+ "overall_height_mm": 7,+ "token_diameter_mm": 24,+ "token_thickness_mm": 5+ },+ "radial_clearance_mm": 0.3000000000000007,+ "solids": [+ {+ "role": "holder",+ "volume_mm3": 3253.2762724249546,+ "bounds_mm": {+ "min": [+ -16.0,+ -16.0,+ 0.0+ ],+ "max": [+ 16.0,+ 16.0,+ 7.0+ ],+ "size": [+ 32.0,+ 32.0,+ 7.0+ ]+ },+ "kernel_valid": true,+ "kernel_check": "BRepCheck_Analyzer(shape, GeomControls=True).IsValid()",+ "cylindrical_surfaces": [+ {+ "radius_mm": 16.0,+ "axis_point_mm": [+ 0.0,+ 0.0,+ 0.0+ ],+ "axis_direction": [+ 0.0,+ 0.0,+ 1.0+ ],+ "z_range_mm": [+ 0.0,+ 7.0+ ]+ },+ {+ "radius_mm": 12.3,+ "axis_point_mm": [+ 0.0,+ 0.0,+ 2.0+ ],+ "axis_direction": [+ 0.0,+ 0.0,+ 1.0+ ],+ "z_range_mm": [+ 2.0,+ 7.0+ ]+ }+ ]+ },+ {+ "role": "token",+ "volume_mm3": 2199.114857512874,+ "bounds_mm": {+ "min": [+ -12.0,+ -12.0,+ 2.0+ ],+ "max": [+ 12.0,+ 12.0,+ 7.0+ ],+ "size": [+ 24.0,+ 24.0,+ 5.0+ ]+ },+ "kernel_valid": true,+ "kernel_check": "BRepCheck_Analyzer(shape, GeomControls=True).IsValid()",+ "cylindrical_surfaces": [+ {+ "radius_mm": 12.0,+ "axis_point_mm": [+ 0.0,+ 0.0,+ 2.0+ ],+ "axis_direction": [+ 0.0,+ 0.0,+ 1.0+ ],+ "z_range_mm": [+ 2.0,+ 7.0+ ]+ },+ {+ "radius_mm": 2.0,+ "axis_point_mm": [+ 6.0,+ 0.0,+ 1.0+ ],+ "axis_direction": [+ 0.0,+ 0.0,+ 1.0+ ],+ "z_range_mm": [+ 2.0,+ 7.0+ ]+ }+ ]+ }+ ],+ "bounds_mm": {+ "min": [+ -16.0,+ -16.0,+ 0.0+ ],+ "max": [+ 16.0,+ 16.0,+ 7.0+ ],+ "size": [+ 32.0,+ 32.0,+ 7.0+ ]+ },+ "intersection_volume_mm3": 0.0,+ "intersection_tolerance_mm3": 1e-07,+ "dimension_tolerance_mm": 1e-06,+ "token_placement": {+ "translation_mm": [+ 0,+ 0,+ 2+ ],+ "rotation_degrees": [+ 0,+ 0,+ 0+ ]+ },+ "token_identity": {+ "removed_volume_mm3": 0.0,+ "added_volume_mm3": 0.0,+ "comparison": "Inverse-translate reimported assembly token; bidirectional kernel Boolean differences against exact pinned input"+ },+ "input_provenance": {+ "inputs/token/model.step": {+ "expected_sha256": "30401ab1c8cda7baf9bcf1e6b176461ff9d323cb7f2769693a4c1094bdff3ca6",+ "actual_sha256": "30401ab1c8cda7baf9bcf1e6b176461ff9d323cb7f2769693a4c1094bdff3ca6",+ "matches": true+ },+ "inputs/token/dimensions.json": {+ "expected_sha256": "c95078b0e155eee26de5b6a99573532d6d6f7ab4d79fd04b1410ac4b9c48753b",+ "actual_sha256": "c95078b0e155eee26de5b6a99573532d6d6f7ab4d79fd04b1410ac4b9c48753b",+ "matches": true+ }+ },+ "checks": {+ "pinned_input_hashes": true,+ "exported_step_reimport_two_solids": true,+ "input_one_valid_solid": true,+ "assembly_kernel_valid": true,+ "holder_kernel_geometric_valid": true,+ "holder_positive_volume": true,+ "token_kernel_geometric_valid": true,+ "token_positive_volume": true,+ "holder_bounds": true,+ "token_placed_bounds": true,+ "assembly_bounds": true,+ "recess_diameter_depth_base": true,+ "holder_volume": true,+ "token_volume_matches_pinned_dimensions": true,+ "radial_clearance_0_3_mm": true,+ "zero_overlap_within_tolerance": true,+ "token_unchanged_except_translation": true,+ "token_hole_preserved": true,+ "stl_binary_complete": true,+ "stl_closed_edges": true,+ "stl_consistent_winding": true,+ "stl_volume_within_0_1_percent": true+ },+ "all_checks_passed": true,+ "stl": {+ "contains": "Both solids in assembled positions",+ "triangle_count": 4028,+ "volume_mm3": 5451.826175502112+ },+ "limitations": [+ "No render or blind review under live assignment",+ "Print readiness, insertion motion and physical fit unverified"+ ],+ "artifact_sha256": {+ "model.step": "81beac506f8ec3434ef0979bb4836d2378e04f9eeacf76f535fc09b71940d633",+ "model.stl": "6c44152370cf10bdd5550d92cf9a0976fc916f11a4c009e5e7e8ad83dfa91bfc",+ "model.step.py": "c7c80890d71a4a594ef44bb862e0f4b8c1368af6f807a277ec4e6fb17b475ff9",+ "model_lib.py": "392c8440f880d88a61db487755e06b6f80c4828c2d475c3c2123fe71f0975c69",+ "part_holder.step": "1cd312596e73a8b67650d4eebf172fcb90389075daed0653a293154cc95f064e",+ "part_token.step": "832999a6454b94f1fc5eaa59b92311fb24f3db1828a24045070d5509b43bf8ea"+ }+}diff --git a/output/orchestrator-live/holder/model.step b/output/orchestrator-live/holder/model.stepnew file mode 100644index 000000000..5412c7255--- /dev/null+++ b/output/orchestrator-live/holder/model.step@@ -0,0 +1,532 @@+ISO-10303-21;+HEADER;+FILE_DESCRIPTION(('Open CASCADE Model'),'2;1');+FILE_NAME('holder_and_token','1970-01-01T00:00:00',('Author'),(+ 'Open CASCADE'),'Open CASCADE STEP processor 7.9','cadgen','Unknown'+ );+FILE_SCHEMA(('AUTOMOTIVE_DESIGN { 1 0 10303 214 1 1 1 1 }'));+ENDSEC;+DATA;+#1 = APPLICATION_PROTOCOL_DEFINITION('international standard',+ 'automotive_design',2000,#2);+#2 = APPLICATION_CONTEXT(+ 'core data for automotive mechanical design processes');+#3 = SHAPE_DEFINITION_REPRESENTATION(#4,#10);+#4 = PRODUCT_DEFINITION_SHAPE('','',#5);+#5 = PRODUCT_DEFINITION('design','',#6,#9);+#6 = PRODUCT_DEFINITION_FORMATION('','',#7);+#7 = PRODUCT('holder_and_token','holder_and_token','',(#8));+#8 = PRODUCT_CONTEXT('',#2,'mechanical');+#9 = PRODUCT_DEFINITION_CONTEXT('part definition',#2,'design');+#10 = SHAPE_REPRESENTATION('',(#11,#15,#19),#23);+#11 = AXIS2_PLACEMENT_3D('',#12,#13,#14);+#12 = CARTESIAN_POINT('',(0.,0.,0.));+#13 = DIRECTION('',(0.,0.,1.));+#14 = DIRECTION('',(1.,0.,-0.));+#15 = AXIS2_PLACEMENT_3D('',#16,#17,#18);+#16 = CARTESIAN_POINT('',(0.,0.,0.));+#17 = DIRECTION('',(0.,0.,1.));+#18 = DIRECTION('',(1.,0.,-0.));+#19 = AXIS2_PLACEMENT_3D('',#20,#21,#22);+#20 = CARTESIAN_POINT('',(0.,0.,2.));+#21 = DIRECTION('',(0.,0.,1.));+#22 = DIRECTION('',(1.,0.,-0.));+#23 = ( GEOMETRIC_REPRESENTATION_CONTEXT(3)+GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#27)) GLOBAL_UNIT_ASSIGNED_CONTEXT(+(#24,#25,#26)) REPRESENTATION_CONTEXT('Context #1',+ '3D Context with UNIT and UNCERTAINTY') );+#24 = ( LENGTH_UNIT() NAMED_UNIT(*) SI_UNIT(.MILLI.,.METRE.) );+#25 = ( NAMED_UNIT(*) PLANE_ANGLE_UNIT() SI_UNIT($,.RADIAN.) );+#26 = ( NAMED_UNIT(*) SI_UNIT($,.STERADIAN.) SOLID_ANGLE_UNIT() );+#27 = UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.E-07),#24,+ 'distance_accuracy_value','confusion accuracy');+#28 = PRODUCT_RELATED_PRODUCT_CATEGORY('part',$,(#7));+#29 = SHAPE_DEFINITION_REPRESENTATION(#30,#36);+#30 = PRODUCT_DEFINITION_SHAPE('','',#31);+#31 = PRODUCT_DEFINITION('design','',#32,#35);+#32 = PRODUCT_DEFINITION_FORMATION('','',#33);+#33 = PRODUCT('holder','holder','',(#34));+#34 = PRODUCT_CONTEXT('',#2,'mechanical');+#35 = PRODUCT_DEFINITION_CONTEXT('part definition',#2,'design');+#36 = ADVANCED_BREP_SHAPE_REPRESENTATION('',(#11,#37),#225);+#37 = MANIFOLD_SOLID_BREP('',#38);+#38 = CLOSED_SHELL('',(#39,#127,#162,#166,#221));+#39 = ADVANCED_FACE('',(#40),#53,.T.);+#40 = FACE_BOUND('',#41,.T.);+#41 = EDGE_LOOP('',(#42,#76,#99,#126));+#42 = ORIENTED_EDGE('',*,*,#43,.F.);+#43 = EDGE_CURVE('',#44,#44,#46,.T.);+#44 = VERTEX_POINT('',#45);+#45 = CARTESIAN_POINT('',(16.,-3.918869757272E-15,7.));+#46 = SURFACE_CURVE('',#47,(#52,#64),.PCURVE_S1.);+#47 = CIRCLE('',#48,16.);+#48 = AXIS2_PLACEMENT_3D('',#49,#50,#51);+#49 = CARTESIAN_POINT('',(0.,0.,7.));+#50 = DIRECTION('',(0.,0.,1.));+#51 = DIRECTION('',(1.,0.,-0.));+#52 = PCURVE('',#53,#58);+#53 = CYLINDRICAL_SURFACE('',#54,16.);+#54 = AXIS2_PLACEMENT_3D('',#55,#56,#57);+#55 = CARTESIAN_POINT('',(0.,0.,0.));+#56 = DIRECTION('',(0.,0.,1.));+#57 = DIRECTION('',(1.,0.,-0.));+#58 = DEFINITIONAL_REPRESENTATION('',(#59),#63);+#59 = LINE('',#60,#61);+#60 = CARTESIAN_POINT('',(0.,7.));+#61 = VECTOR('',#62,1.);+#62 = DIRECTION('',(1.,0.));+#63 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#64 = PCURVE('',#65,#70);+#65 = PLANE('',#66);+#66 = AXIS2_PLACEMENT_3D('',#67,#68,#69);+#67 = CARTESIAN_POINT('',(0.,0.,7.));+#68 = DIRECTION('',(0.,0.,1.));+#69 = DIRECTION('',(1.,0.,-0.));+#70 = DEFINITIONAL_REPRESENTATION('',(#71),#75);+#71 = CIRCLE('',#72,16.);+#72 = AXIS2_PLACEMENT_2D('',#73,#74);+#73 = CARTESIAN_POINT('',(0.,0.));+#74 = DIRECTION('',(1.,0.));+#75 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#76 = ORIENTED_EDGE('',*,*,#77,.F.);+#77 = EDGE_CURVE('',#78,#44,#80,.T.);+#78 = VERTEX_POINT('',#79);+#79 = CARTESIAN_POINT('',(16.,-3.918869757272E-15,0.));+#80 = SEAM_CURVE('',#81,(#85,#92),.PCURVE_S1.);+#81 = LINE('',#82,#83);+#82 = CARTESIAN_POINT('',(16.,-3.918869757272E-15,0.));+#83 = VECTOR('',#84,1.);+#84 = DIRECTION('',(0.,0.,1.));+#85 = PCURVE('',#53,#86);+#86 = DEFINITIONAL_REPRESENTATION('',(#87),#91);+#87 = LINE('',#88,#89);+#88 = CARTESIAN_POINT('',(6.28318530718,-0.));+#89 = VECTOR('',#90,1.);+#90 = DIRECTION('',(0.,1.));+#91 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#92 = PCURVE('',#53,#93);+#93 = DEFINITIONAL_REPRESENTATION('',(#94),#98);+#94 = LINE('',#95,#96);+#95 = CARTESIAN_POINT('',(0.,-0.));+#96 = VECTOR('',#97,1.);+#97 = DIRECTION('',(0.,1.));+#98 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#99 = ORIENTED_EDGE('',*,*,#100,.T.);+#100 = EDGE_CURVE('',#78,#78,#101,.T.);+#101 = SURFACE_CURVE('',#102,(#107,#114),.PCURVE_S1.);+#102 = CIRCLE('',#103,16.);+#103 = AXIS2_PLACEMENT_3D('',#104,#105,#106);+#104 = CARTESIAN_POINT('',(0.,0.,0.));+#105 = DIRECTION('',(0.,0.,1.));+#106 = DIRECTION('',(1.,0.,-0.));+#107 = PCURVE('',#53,#108);+#108 = DEFINITIONAL_REPRESENTATION('',(#109),#113);+#109 = LINE('',#110,#111);+#110 = CARTESIAN_POINT('',(0.,0.));+#111 = VECTOR('',#112,1.);+#112 = DIRECTION('',(1.,0.));+#113 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#114 = PCURVE('',#115,#120);+#115 = PLANE('',#116);+#116 = AXIS2_PLACEMENT_3D('',#117,#118,#119);+#117 = CARTESIAN_POINT('',(0.,0.,0.));+#118 = DIRECTION('',(0.,0.,1.));+#119 = DIRECTION('',(1.,0.,-0.));+#120 = DEFINITIONAL_REPRESENTATION('',(#121),#125);+#121 = CIRCLE('',#122,16.);+#122 = AXIS2_PLACEMENT_2D('',#123,#124);+#123 = CARTESIAN_POINT('',(0.,0.));+#124 = DIRECTION('',(1.,0.));+#125 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#126 = ORIENTED_EDGE('',*,*,#77,.T.);+#127 = ADVANCED_FACE('',(#128,#131),#65,.T.);+#128 = FACE_BOUND('',#129,.T.);+#129 = EDGE_LOOP('',(#130));+#130 = ORIENTED_EDGE('',*,*,#43,.T.);+#131 = FACE_BOUND('',#132,.T.);+#132 = EDGE_LOOP('',(#133));+#133 = ORIENTED_EDGE('',*,*,#134,.F.);+#134 = EDGE_CURVE('',#135,#135,#137,.T.);+#135 = VERTEX_POINT('',#136);+#136 = CARTESIAN_POINT('',(12.3,-3.012631125902E-15,7.));+#137 = SURFACE_CURVE('',#138,(#143,#150),.PCURVE_S1.);+#138 = CIRCLE('',#139,12.3);+#139 = AXIS2_PLACEMENT_3D('',#140,#141,#142);+#140 = CARTESIAN_POINT('',(0.,0.,7.));+#141 = DIRECTION('',(0.,0.,1.));+#142 = DIRECTION('',(1.,0.,-0.));+#143 = PCURVE('',#65,#144);+#144 = DEFINITIONAL_REPRESENTATION('',(#145),#149);+#145 = CIRCLE('',#146,12.3);+#146 = AXIS2_PLACEMENT_2D('',#147,#148);+#147 = CARTESIAN_POINT('',(0.,0.));+#148 = DIRECTION('',(1.,0.));+#149 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#150 = PCURVE('',#151,#156);+#151 = CYLINDRICAL_SURFACE('',#152,12.3);+#152 = AXIS2_PLACEMENT_3D('',#153,#154,#155);+#153 = CARTESIAN_POINT('',(0.,0.,2.));+#154 = DIRECTION('',(0.,0.,1.));+#155 = DIRECTION('',(1.,0.,-0.));+#156 = DEFINITIONAL_REPRESENTATION('',(#157),#161);+#157 = LINE('',#158,#159);+#158 = CARTESIAN_POINT('',(0.,5.));+#159 = VECTOR('',#160,1.);+#160 = DIRECTION('',(1.,0.));+#161 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#162 = ADVANCED_FACE('',(#163),#115,.F.);+#163 = FACE_BOUND('',#164,.T.);+#164 = EDGE_LOOP('',(#165));+#165 = ORIENTED_EDGE('',*,*,#100,.F.);+#166 = ADVANCED_FACE('',(#167),#151,.F.);+#167 = FACE_BOUND('',#168,.F.);+#168 = EDGE_LOOP('',(#169,#170,#193,#220));+#169 = ORIENTED_EDGE('',*,*,#134,.F.);+#170 = ORIENTED_EDGE('',*,*,#171,.F.);+#171 = EDGE_CURVE('',#172,#135,#174,.T.);+#172 = VERTEX_POINT('',#173);+#173 = CARTESIAN_POINT('',(12.3,-3.012631125902E-15,2.));+#174 = SEAM_CURVE('',#175,(#179,#186),.PCURVE_S1.);+#175 = LINE('',#176,#177);+#176 = CARTESIAN_POINT('',(12.3,-3.012631125902E-15,2.));+#177 = VECTOR('',#178,1.);+#178 = DIRECTION('',(0.,0.,1.));+#179 = PCURVE('',#151,#180);+#180 = DEFINITIONAL_REPRESENTATION('',(#181),#185);+#181 = LINE('',#182,#183);+#182 = CARTESIAN_POINT('',(6.28318530718,-0.));+#183 = VECTOR('',#184,1.);+#184 = DIRECTION('',(0.,1.));+#185 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#186 = PCURVE('',#151,#187);+#187 = DEFINITIONAL_REPRESENTATION('',(#188),#192);+#188 = LINE('',#189,#190);+#189 = CARTESIAN_POINT('',(0.,-0.));+#190 = VECTOR('',#191,1.);+#191 = DIRECTION('',(0.,1.));+#192 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#193 = ORIENTED_EDGE('',*,*,#194,.T.);+#194 = EDGE_CURVE('',#172,#172,#195,.T.);+#195 = SURFACE_CURVE('',#196,(#201,#208),.PCURVE_S1.);+#196 = CIRCLE('',#197,12.3);+#197 = AXIS2_PLACEMENT_3D('',#198,#199,#200);+#198 = CARTESIAN_POINT('',(0.,0.,2.));+#199 = DIRECTION('',(0.,0.,1.));+#200 = DIRECTION('',(1.,0.,-0.));+#201 = PCURVE('',#151,#202);+#202 = DEFINITIONAL_REPRESENTATION('',(#203),#207);+#203 = LINE('',#204,#205);+#204 = CARTESIAN_POINT('',(0.,0.));+#205 = VECTOR('',#206,1.);+#206 = DIRECTION('',(1.,0.));+#207 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#208 = PCURVE('',#209,#214);+#209 = PLANE('',#210);+#210 = AXIS2_PLACEMENT_3D('',#211,#212,#213);+#211 = CARTESIAN_POINT('',(0.,0.,2.));+#212 = DIRECTION('',(0.,0.,1.));+#213 = DIRECTION('',(1.,0.,-0.));+#214 = DEFINITIONAL_REPRESENTATION('',(#215),#219);+#215 = CIRCLE('',#216,12.3);+#216 = AXIS2_PLACEMENT_2D('',#217,#218);+#217 = CARTESIAN_POINT('',(0.,0.));+#218 = DIRECTION('',(1.,0.));+#219 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#220 = ORIENTED_EDGE('',*,*,#171,.T.);+#221 = ADVANCED_FACE('',(#222),#209,.T.);+#222 = FACE_BOUND('',#223,.F.);+#223 = EDGE_LOOP('',(#224));+#224 = ORIENTED_EDGE('',*,*,#194,.F.);+#225 = ( GEOMETRIC_REPRESENTATION_CONTEXT(3)+GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#229)) GLOBAL_UNIT_ASSIGNED_CONTEXT+((#226,#227,#228)) REPRESENTATION_CONTEXT('Context #1',+ '3D Context with UNIT and UNCERTAINTY') );+#226 = ( LENGTH_UNIT() NAMED_UNIT(*) SI_UNIT(.MILLI.,.METRE.) );+#227 = ( NAMED_UNIT(*) PLANE_ANGLE_UNIT() SI_UNIT($,.RADIAN.) );+#228 = ( NAMED_UNIT(*) SI_UNIT($,.STERADIAN.) SOLID_ANGLE_UNIT() );+#229 = UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.E-07),#226,+ 'distance_accuracy_value','confusion accuracy');+#230 = CONTEXT_DEPENDENT_SHAPE_REPRESENTATION(#231,#233);+#231 = ( REPRESENTATION_RELATIONSHIP('','',#36,#10)+REPRESENTATION_RELATIONSHIP_WITH_TRANSFORMATION(#232)+SHAPE_REPRESENTATION_RELATIONSHIP() );+#232 = ITEM_DEFINED_TRANSFORMATION('','',#11,#15);+#233 = PRODUCT_DEFINITION_SHAPE('Placement','Placement of an item',#234+ );+#234 = NEXT_ASSEMBLY_USAGE_OCCURRENCE('1','holder','',#5,#31,$);+#235 = PRODUCT_RELATED_PRODUCT_CATEGORY('part',$,(#33));+#236 = SHAPE_DEFINITION_REPRESENTATION(#237,#243);+#237 = PRODUCT_DEFINITION_SHAPE('','',#238);+#238 = PRODUCT_DEFINITION('design','',#239,#242);+#239 = PRODUCT_DEFINITION_FORMATION('','',#240);+#240 = PRODUCT('pinned_token','pinned_token','',(#241));+#241 = PRODUCT_CONTEXT('',#2,'mechanical');+#242 = PRODUCT_DEFINITION_CONTEXT('part definition',#2,'design');+#243 = ADVANCED_BREP_SHAPE_REPRESENTATION('',(#11,#244),#426);+#244 = MANIFOLD_SOLID_BREP('',#245);+#245 = CLOSED_SHELL('',(#246,#334,#369,#399));+#246 = ADVANCED_FACE('',(#247),#260,.T.);+#247 = FACE_BOUND('',#248,.T.);+#248 = EDGE_LOOP('',(#249,#283,#306,#333));+#249 = ORIENTED_EDGE('',*,*,#250,.F.);+#250 = EDGE_CURVE('',#251,#251,#253,.T.);+#251 = VERTEX_POINT('',#252);+#252 = CARTESIAN_POINT('',(12.,-2.939152317954E-15,5.));+#253 = SURFACE_CURVE('',#254,(#259,#271),.PCURVE_S1.);+#254 = CIRCLE('',#255,12.);+#255 = AXIS2_PLACEMENT_3D('',#256,#257,#258);+#256 = CARTESIAN_POINT('',(0.,0.,5.));+#257 = DIRECTION('',(0.,0.,1.));+#258 = DIRECTION('',(1.,0.,-0.));+#259 = PCURVE('',#260,#265);+#260 = CYLINDRICAL_SURFACE('',#261,12.);+#261 = AXIS2_PLACEMENT_3D('',#262,#263,#264);+#262 = CARTESIAN_POINT('',(0.,0.,0.));+#263 = DIRECTION('',(0.,0.,1.));+#264 = DIRECTION('',(1.,0.,-0.));+#265 = DEFINITIONAL_REPRESENTATION('',(#266),#270);+#266 = LINE('',#267,#268);+#267 = CARTESIAN_POINT('',(0.,5.));+#268 = VECTOR('',#269,1.);+#269 = DIRECTION('',(1.,0.));+#270 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#271 = PCURVE('',#272,#277);+#272 = PLANE('',#273);+#273 = AXIS2_PLACEMENT_3D('',#274,#275,#276);+#274 = CARTESIAN_POINT('',(0.,0.,5.));+#275 = DIRECTION('',(0.,0.,1.));+#276 = DIRECTION('',(1.,0.,-0.));+#277 = DEFINITIONAL_REPRESENTATION('',(#278),#282);+#278 = CIRCLE('',#279,12.);+#279 = AXIS2_PLACEMENT_2D('',#280,#281);+#280 = CARTESIAN_POINT('',(0.,0.));+#281 = DIRECTION('',(1.,0.));+#282 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#283 = ORIENTED_EDGE('',*,*,#284,.F.);+#284 = EDGE_CURVE('',#285,#251,#287,.T.);+#285 = VERTEX_POINT('',#286);+#286 = CARTESIAN_POINT('',(12.,-2.939152317954E-15,0.));+#287 = SEAM_CURVE('',#288,(#292,#299),.PCURVE_S1.);+#288 = LINE('',#289,#290);+#289 = CARTESIAN_POINT('',(12.,-2.939152317954E-15,0.));+#290 = VECTOR('',#291,1.);+#291 = DIRECTION('',(0.,0.,1.));+#292 = PCURVE('',#260,#293);+#293 = DEFINITIONAL_REPRESENTATION('',(#294),#298);+#294 = LINE('',#295,#296);+#295 = CARTESIAN_POINT('',(0.,-0.));+#296 = VECTOR('',#297,1.);+#297 = DIRECTION('',(0.,1.));+#298 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#299 = PCURVE('',#260,#300);+#300 = DEFINITIONAL_REPRESENTATION('',(#301),#305);+#301 = LINE('',#302,#303);+#302 = CARTESIAN_POINT('',(6.28318530718,-0.));+#303 = VECTOR('',#304,1.);+#304 = DIRECTION('',(0.,1.));+#305 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#306 = ORIENTED_EDGE('',*,*,#307,.T.);+#307 = EDGE_CURVE('',#285,#285,#308,.T.);+#308 = SURFACE_CURVE('',#309,(#314,#321),.PCURVE_S1.);+#309 = CIRCLE('',#310,12.);+#310 = AXIS2_PLACEMENT_3D('',#311,#312,#313);+#311 = CARTESIAN_POINT('',(0.,0.,0.));+#312 = DIRECTION('',(0.,0.,1.));+#313 = DIRECTION('',(1.,0.,-0.));+#314 = PCURVE('',#260,#315);+#315 = DEFINITIONAL_REPRESENTATION('',(#316),#320);+#316 = LINE('',#317,#318);+#317 = CARTESIAN_POINT('',(0.,0.));+#318 = VECTOR('',#319,1.);+#319 = DIRECTION('',(1.,0.));+#320 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#321 = PCURVE('',#322,#327);+#322 = PLANE('',#323);+#323 = AXIS2_PLACEMENT_3D('',#324,#325,#326);+#324 = CARTESIAN_POINT('',(0.,0.,0.));+#325 = DIRECTION('',(0.,0.,1.));+#326 = DIRECTION('',(1.,0.,-0.));+#327 = DEFINITIONAL_REPRESENTATION('',(#328),#332);+#328 = CIRCLE('',#329,12.);+#329 = AXIS2_PLACEMENT_2D('',#330,#331);+#330 = CARTESIAN_POINT('',(0.,0.));+#331 = DIRECTION('',(1.,0.));+#332 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#333 = ORIENTED_EDGE('',*,*,#284,.T.);+#334 = ADVANCED_FACE('',(#335,#338),#272,.T.);+#335 = FACE_BOUND('',#336,.T.);+#336 = EDGE_LOOP('',(#337));+#337 = ORIENTED_EDGE('',*,*,#250,.T.);+#338 = FACE_BOUND('',#339,.T.);+#339 = EDGE_LOOP('',(#340));+#340 = ORIENTED_EDGE('',*,*,#341,.F.);+#341 = EDGE_CURVE('',#342,#342,#344,.T.);+#342 = VERTEX_POINT('',#343);+#343 = CARTESIAN_POINT('',(8.,-4.898587196589E-16,5.));+#344 = SURFACE_CURVE('',#345,(#350,#357),.PCURVE_S1.);+#345 = CIRCLE('',#346,2.);+#346 = AXIS2_PLACEMENT_3D('',#347,#348,#349);+#347 = CARTESIAN_POINT('',(6.,0.,5.));+#348 = DIRECTION('',(0.,0.,1.));+#349 = DIRECTION('',(1.,0.,-0.));+#350 = PCURVE('',#272,#351);+#351 = DEFINITIONAL_REPRESENTATION('',(#352),#356);+#352 = CIRCLE('',#353,2.);+#353 = AXIS2_PLACEMENT_2D('',#354,#355);+#354 = CARTESIAN_POINT('',(6.,0.));+#355 = DIRECTION('',(1.,0.));+#356 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#357 = PCURVE('',#358,#363);+#358 = CYLINDRICAL_SURFACE('',#359,2.);+#359 = AXIS2_PLACEMENT_3D('',#360,#361,#362);+#360 = CARTESIAN_POINT('',(6.,0.,-1.));+#361 = DIRECTION('',(0.,0.,1.));+#362 = DIRECTION('',(1.,0.,-0.));+#363 = DEFINITIONAL_REPRESENTATION('',(#364),#368);+#364 = LINE('',#365,#366);+#365 = CARTESIAN_POINT('',(0.,6.));+#366 = VECTOR('',#367,1.);+#367 = DIRECTION('',(1.,0.));+#368 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#369 = ADVANCED_FACE('',(#370,#373),#322,.F.);+#370 = FACE_BOUND('',#371,.F.);+#371 = EDGE_LOOP('',(#372));+#372 = ORIENTED_EDGE('',*,*,#307,.T.);+#373 = FACE_BOUND('',#374,.F.);+#374 = EDGE_LOOP('',(#375));+#375 = ORIENTED_EDGE('',*,*,#376,.F.);+#376 = EDGE_CURVE('',#377,#377,#379,.T.);+#377 = VERTEX_POINT('',#378);+#378 = CARTESIAN_POINT('',(8.,-4.898587196589E-16,0.));+#379 = SURFACE_CURVE('',#380,(#385,#392),.PCURVE_S1.);+#380 = CIRCLE('',#381,2.);+#381 = AXIS2_PLACEMENT_3D('',#382,#383,#384);+#382 = CARTESIAN_POINT('',(6.,0.,0.));+#383 = DIRECTION('',(0.,0.,1.));+#384 = DIRECTION('',(1.,0.,-0.));+#385 = PCURVE('',#322,#386);+#386 = DEFINITIONAL_REPRESENTATION('',(#387),#391);+#387 = CIRCLE('',#388,2.);+#388 = AXIS2_PLACEMENT_2D('',#389,#390);+#389 = CARTESIAN_POINT('',(6.,0.));+#390 = DIRECTION('',(1.,0.));+#391 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#392 = PCURVE('',#358,#393);+#393 = DEFINITIONAL_REPRESENTATION('',(#394),#398);+#394 = LINE('',#395,#396);+#395 = CARTESIAN_POINT('',(0.,1.));+#396 = VECTOR('',#397,1.);+#397 = DIRECTION('',(1.,0.));+#398 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#399 = ADVANCED_FACE('',(#400),#358,.F.);+#400 = FACE_BOUND('',#401,.F.);+#401 = EDGE_LOOP('',(#402,#403,#424,#425));+#402 = ORIENTED_EDGE('',*,*,#341,.F.);+#403 = ORIENTED_EDGE('',*,*,#404,.F.);+#404 = EDGE_CURVE('',#377,#342,#405,.T.);+#405 = SEAM_CURVE('',#406,(#410,#417),.PCURVE_S1.);+#406 = LINE('',#407,#408);+#407 = CARTESIAN_POINT('',(8.,-4.898587196589E-16,-1.));+#408 = VECTOR('',#409,1.);+#409 = DIRECTION('',(0.,0.,1.));+#410 = PCURVE('',#358,#411);+#411 = DEFINITIONAL_REPRESENTATION('',(#412),#416);+#412 = LINE('',#413,#414);+#413 = CARTESIAN_POINT('',(0.,-0.));+#414 = VECTOR('',#415,1.);+#415 = DIRECTION('',(0.,1.));+#416 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#417 = PCURVE('',#358,#418);+#418 = DEFINITIONAL_REPRESENTATION('',(#419),#423);+#419 = LINE('',#420,#421);+#420 = CARTESIAN_POINT('',(6.28318530718,-0.));+#421 = VECTOR('',#422,1.);+#422 = DIRECTION('',(0.,1.));+#423 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#424 = ORIENTED_EDGE('',*,*,#376,.T.);+#425 = ORIENTED_EDGE('',*,*,#404,.T.);+#426 = ( GEOMETRIC_REPRESENTATION_CONTEXT(3)+GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#430)) GLOBAL_UNIT_ASSIGNED_CONTEXT+((#427,#428,#429)) REPRESENTATION_CONTEXT('Context #1',+ '3D Context with UNIT and UNCERTAINTY') );+#427 = ( LENGTH_UNIT() NAMED_UNIT(*) SI_UNIT(.MILLI.,.METRE.) );+#428 = ( NAMED_UNIT(*) PLANE_ANGLE_UNIT() SI_UNIT($,.RADIAN.) );+#429 = ( NAMED_UNIT(*) SI_UNIT($,.STERADIAN.) SOLID_ANGLE_UNIT() );+#430 = UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.E-07),#427,+ 'distance_accuracy_value','confusion accuracy');+#431 = CONTEXT_DEPENDENT_SHAPE_REPRESENTATION(#432,#434);+#432 = ( REPRESENTATION_RELATIONSHIP('','',#243,#10)+REPRESENTATION_RELATIONSHIP_WITH_TRANSFORMATION(#433)+SHAPE_REPRESENTATION_RELATIONSHIP() );+#433 = ITEM_DEFINED_TRANSFORMATION('','',#11,#19);+#434 = PRODUCT_DEFINITION_SHAPE('Placement','Placement of an item',#435+ );+#435 = NEXT_ASSEMBLY_USAGE_OCCURRENCE('2','pinned_token','',#5,#238,$);+#436 = PRODUCT_RELATED_PRODUCT_CATEGORY('part',$,(#240));++#437=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:generator','cadgen');+#438=REPRESENTATION('cadgen:generator',(#437),#23);+#439=PROPERTY_DEFINITION('cadgen metadata','cadgen:generator',#5);+#440=PROPERTY_DEFINITION_REPRESENTATION(#439,#438);+#441=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:entryKind','assembly');+#442=REPRESENTATION('cadgen:entryKind',(#441),#23);+#443=PROPERTY_DEFINITION('cadgen metadata','cadgen:entryKind',#5);+#444=PROPERTY_DEFINITION_REPRESENTATION(#443,#442);+#445=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:sourcePath','model.step.py');+#446=REPRESENTATION('cadgen:sourcePath',(#445),#23);+#447=PROPERTY_DEFINITION('cadgen metadata','cadgen:sourcePath',#5);+#448=PROPERTY_DEFINITION_REPRESENTATION(#447,#446);+#449=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:sourceHash','c7c80890d71a4a594ef44bb862e0f4b8c1368af6f807a277ec4e6fb17b475ff9');+#450=REPRESENTATION('cadgen:sourceHash',(#449),#23);+#451=PROPERTY_DEFINITION('cadgen metadata','cadgen:sourceHash',#5);+#452=PROPERTY_DEFINITION_REPRESENTATION(#451,#450);+ENDSEC;+END-ISO-10303-21;diff --git a/output/orchestrator-live/holder/model.stl b/output/orchestrator-live/holder/model.stlnew file mode 100644index 000000000..ad3ac6a84Binary files /dev/null and b/output/orchestrator-live/holder/model.stl differdiff --git a/output/orchestrator-live/independent-checks.json b/output/orchestrator-live/independent-checks.jsonnew file mode 100644index 000000000..7d5c214c0--- /dev/null+++ b/output/orchestrator-live/independent-checks.json@@ -0,0 +1,28 @@+{+ "method": "Independent STEP reimport; no worker Python executed",+ "units": "mm",+ "checks": {+ "one_upstream_solid": true,+ "two_assembly_solids": true,+ "valid_upstream_brep": true,+ "valid_assembly_brep": true,+ "positive_volumes": true,+ "token_24_by_24_by_5_mm": true,+ "token_volume_700_pi_mm3": true,+ "holder_32_by_32_by_7_mm": true,+ "holder_cylinder_radii": true,+ "radial_clearance_0_3_mm": true,+ "no_geometric_intersection": true,+ "upstream_token_geometry_preserved": true+ },+ "all_checks_passed": true,+ "token_volume_mm3": 2199.114857512874,+ "holder_volume_mm3": 3253.2762724249546,+ "radial_clearance_mm": 0.3000000000000007,+ "intersection_volume_mm3": 0.0,+ "identity_removed_volume_mm3": 0.0,+ "identity_added_volume_mm3": 0.0,+ "limitations": [+ "Numerical geometry only; no physical printing, insertion, or manufacturing tolerance verification"+ ]+}diff --git a/output/orchestrator-live/preview.png b/output/orchestrator-live/preview.pngnew file mode 100644index 000000000..5e09345f0Binary files /dev/null and b/output/orchestrator-live/preview.png differdiff --git a/output/orchestrator-live/token/dimensions.json b/output/orchestrator-live/token/dimensions.jsonnew file mode 100644index 000000000..aa2674d6b--- /dev/null+++ b/output/orchestrator-live/token/dimensions.json@@ -0,0 +1,91 @@+{+ "units": "mm",+ "cad_tool": "build123d 0.11.1 / Open CASCADE (OCP)",+ "volume_mm3": 2199.114857512874,+ "expected_volume_mm3": 2199.114857512855,+ "bounds_mm": {+ "min": [+ -12.0,+ -12.0,+ 0.0+ ],+ "max": [+ 12.0,+ 12.0,+ 5.0+ ],+ "size": [+ 24.0,+ 24.0,+ 5.0+ ]+ },+ "dimensions": {+ "diameter_mm": 24,+ "thickness_mm": 5,+ "hole_diameter_mm": 4,+ "hole_axis_xy_mm": [+ 6,+ 0+ ]+ },+ "solid_count": 1,+ "tolerance_mm": 1e-06,+ "volume_tolerance_mm3": 1e-06,+ "cylindrical_surfaces": [+ {+ "radius_mm": 12.0,+ "axis_point_mm": [+ 0.0,+ 0.0,+ 0.0+ ],+ "axis_direction": [+ 0.0,+ 0.0,+ 1.0+ ],+ "z_range_mm": [+ 0.0,+ 5.0+ ]+ },+ {+ "radius_mm": 2.0,+ "axis_point_mm": [+ 6.0,+ 0.0,+ -1.0+ ],+ "axis_direction": [+ 0.0,+ 0.0,+ 1.0+ ],+ "z_range_mm": [+ 0.0,+ 5.0+ ]+ }+ ],+ "checks": {+ "one_solid": true,+ "valid_brep": true,+ "bounds_24x24x5": true,+ "datum_bounds": true,+ "positive_volume": true,+ "volume_700_pi": true,+ "through_hole_cylindrical_surface": true,+ "hole_axis_empty_full_height": true,+ "material_surrounds_hole": true,+ "stl_watertight_edges": true,+ "stl_consistent_winding": true,+ "stl_volume_within_0_1_percent": true+ },+ "all_checks_passed": true,+ "stl_volume_mm3": 2198.887010324058,+ "sha256": {+ "model.step": "30401ab1c8cda7baf9bcf1e6b176461ff9d323cb7f2769693a4c1094bdff3ca6",+ "model.stl": "7b8bb1dc252367597fb0c08cce20cd12d7688bd05a4ded690a3459f6658bc3cc"+ }+}diff --git a/output/orchestrator-live/token/model.step b/output/orchestrator-live/token/model.stepnew file mode 100644index 000000000..d558fce7d--- /dev/null+++ b/output/orchestrator-live/token/model.step@@ -0,0 +1,261 @@+ISO-10303-21;+HEADER;+FILE_DESCRIPTION(('Open CASCADE Model'),'2;1');+FILE_NAME('desk_token_offset_through_hole','1970-01-01T00:00:00',(+ 'Author'),('Open CASCADE'),'Open CASCADE STEP processor 7.9',+ 'cadgen','Unknown');+FILE_SCHEMA(('AUTOMOTIVE_DESIGN { 1 0 10303 214 1 1 1 1 }'));+ENDSEC;+DATA;+#1 = APPLICATION_PROTOCOL_DEFINITION('international standard',+ 'automotive_design',2000,#2);+#2 = APPLICATION_CONTEXT(+ 'core data for automotive mechanical design processes');+#3 = SHAPE_DEFINITION_REPRESENTATION(#4,#10);+#4 = PRODUCT_DEFINITION_SHAPE('','',#5);+#5 = PRODUCT_DEFINITION('design','',#6,#9);+#6 = PRODUCT_DEFINITION_FORMATION('','',#7);+#7 = PRODUCT('desk_token_offset_through_hole',+ 'desk_token_offset_through_hole','',(#8));+#8 = PRODUCT_CONTEXT('',#2,'mechanical');+#9 = PRODUCT_DEFINITION_CONTEXT('part definition',#2,'design');+#10 = ADVANCED_BREP_SHAPE_REPRESENTATION('',(#11,#15),#197);+#11 = AXIS2_PLACEMENT_3D('',#12,#13,#14);+#12 = CARTESIAN_POINT('',(0.,0.,0.));+#13 = DIRECTION('',(0.,0.,1.));+#14 = DIRECTION('',(1.,0.,-0.));+#15 = MANIFOLD_SOLID_BREP('',#16);+#16 = CLOSED_SHELL('',(#17,#105,#140,#170));+#17 = ADVANCED_FACE('',(#18),#31,.T.);+#18 = FACE_BOUND('',#19,.T.);+#19 = EDGE_LOOP('',(#20,#54,#77,#104));+#20 = ORIENTED_EDGE('',*,*,#21,.F.);+#21 = EDGE_CURVE('',#22,#22,#24,.T.);+#22 = VERTEX_POINT('',#23);+#23 = CARTESIAN_POINT('',(12.,-2.939152317954E-15,5.));+#24 = SURFACE_CURVE('',#25,(#30,#42),.PCURVE_S1.);+#25 = CIRCLE('',#26,12.);+#26 = AXIS2_PLACEMENT_3D('',#27,#28,#29);+#27 = CARTESIAN_POINT('',(0.,0.,5.));+#28 = DIRECTION('',(0.,0.,1.));+#29 = DIRECTION('',(1.,0.,-0.));+#30 = PCURVE('',#31,#36);+#31 = CYLINDRICAL_SURFACE('',#32,12.);+#32 = AXIS2_PLACEMENT_3D('',#33,#34,#35);+#33 = CARTESIAN_POINT('',(0.,0.,0.));+#34 = DIRECTION('',(0.,0.,1.));+#35 = DIRECTION('',(1.,0.,-0.));+#36 = DEFINITIONAL_REPRESENTATION('',(#37),#41);+#37 = LINE('',#38,#39);+#38 = CARTESIAN_POINT('',(0.,5.));+#39 = VECTOR('',#40,1.);+#40 = DIRECTION('',(1.,0.));+#41 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#42 = PCURVE('',#43,#48);+#43 = PLANE('',#44);+#44 = AXIS2_PLACEMENT_3D('',#45,#46,#47);+#45 = CARTESIAN_POINT('',(0.,0.,5.));+#46 = DIRECTION('',(0.,0.,1.));+#47 = DIRECTION('',(1.,0.,-0.));+#48 = DEFINITIONAL_REPRESENTATION('',(#49),#53);+#49 = CIRCLE('',#50,12.);+#50 = AXIS2_PLACEMENT_2D('',#51,#52);+#51 = CARTESIAN_POINT('',(0.,0.));+#52 = DIRECTION('',(1.,0.));+#53 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#54 = ORIENTED_EDGE('',*,*,#55,.F.);+#55 = EDGE_CURVE('',#56,#22,#58,.T.);+#56 = VERTEX_POINT('',#57);+#57 = CARTESIAN_POINT('',(12.,-2.939152317954E-15,0.));+#58 = SEAM_CURVE('',#59,(#63,#70),.PCURVE_S1.);+#59 = LINE('',#60,#61);+#60 = CARTESIAN_POINT('',(12.,-2.939152317954E-15,0.));+#61 = VECTOR('',#62,1.);+#62 = DIRECTION('',(0.,0.,1.));+#63 = PCURVE('',#31,#64);+#64 = DEFINITIONAL_REPRESENTATION('',(#65),#69);+#65 = LINE('',#66,#67);+#66 = CARTESIAN_POINT('',(6.28318530718,-0.));+#67 = VECTOR('',#68,1.);+#68 = DIRECTION('',(0.,1.));+#69 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#70 = PCURVE('',#31,#71);+#71 = DEFINITIONAL_REPRESENTATION('',(#72),#76);+#72 = LINE('',#73,#74);+#73 = CARTESIAN_POINT('',(0.,-0.));+#74 = VECTOR('',#75,1.);+#75 = DIRECTION('',(0.,1.));+#76 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#77 = ORIENTED_EDGE('',*,*,#78,.T.);+#78 = EDGE_CURVE('',#56,#56,#79,.T.);+#79 = SURFACE_CURVE('',#80,(#85,#92),.PCURVE_S1.);+#80 = CIRCLE('',#81,12.);+#81 = AXIS2_PLACEMENT_3D('',#82,#83,#84);+#82 = CARTESIAN_POINT('',(0.,0.,0.));+#83 = DIRECTION('',(0.,0.,1.));+#84 = DIRECTION('',(1.,0.,-0.));+#85 = PCURVE('',#31,#86);+#86 = DEFINITIONAL_REPRESENTATION('',(#87),#91);+#87 = LINE('',#88,#89);+#88 = CARTESIAN_POINT('',(0.,0.));+#89 = VECTOR('',#90,1.);+#90 = DIRECTION('',(1.,0.));+#91 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#92 = PCURVE('',#93,#98);+#93 = PLANE('',#94);+#94 = AXIS2_PLACEMENT_3D('',#95,#96,#97);+#95 = CARTESIAN_POINT('',(0.,0.,0.));+#96 = DIRECTION('',(0.,0.,1.));+#97 = DIRECTION('',(1.,0.,-0.));+#98 = DEFINITIONAL_REPRESENTATION('',(#99),#103);+#99 = CIRCLE('',#100,12.);+#100 = AXIS2_PLACEMENT_2D('',#101,#102);+#101 = CARTESIAN_POINT('',(0.,0.));+#102 = DIRECTION('',(1.,0.));+#103 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#104 = ORIENTED_EDGE('',*,*,#55,.T.);+#105 = ADVANCED_FACE('',(#106,#109),#43,.T.);+#106 = FACE_BOUND('',#107,.T.);+#107 = EDGE_LOOP('',(#108));+#108 = ORIENTED_EDGE('',*,*,#21,.T.);+#109 = FACE_BOUND('',#110,.T.);+#110 = EDGE_LOOP('',(#111));+#111 = ORIENTED_EDGE('',*,*,#112,.F.);+#112 = EDGE_CURVE('',#113,#113,#115,.T.);+#113 = VERTEX_POINT('',#114);+#114 = CARTESIAN_POINT('',(8.,-4.898587196589E-16,5.));+#115 = SURFACE_CURVE('',#116,(#121,#128),.PCURVE_S1.);+#116 = CIRCLE('',#117,2.);+#117 = AXIS2_PLACEMENT_3D('',#118,#119,#120);+#118 = CARTESIAN_POINT('',(6.,0.,5.));+#119 = DIRECTION('',(0.,0.,1.));+#120 = DIRECTION('',(1.,0.,-0.));+#121 = PCURVE('',#43,#122);+#122 = DEFINITIONAL_REPRESENTATION('',(#123),#127);+#123 = CIRCLE('',#124,2.);+#124 = AXIS2_PLACEMENT_2D('',#125,#126);+#125 = CARTESIAN_POINT('',(6.,0.));+#126 = DIRECTION('',(1.,0.));+#127 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#128 = PCURVE('',#129,#134);+#129 = CYLINDRICAL_SURFACE('',#130,2.);+#130 = AXIS2_PLACEMENT_3D('',#131,#132,#133);+#131 = CARTESIAN_POINT('',(6.,0.,-1.));+#132 = DIRECTION('',(0.,0.,1.));+#133 = DIRECTION('',(1.,0.,-0.));+#134 = DEFINITIONAL_REPRESENTATION('',(#135),#139);+#135 = LINE('',#136,#137);+#136 = CARTESIAN_POINT('',(0.,6.));+#137 = VECTOR('',#138,1.);+#138 = DIRECTION('',(1.,0.));+#139 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#140 = ADVANCED_FACE('',(#141,#144),#93,.F.);+#141 = FACE_BOUND('',#142,.F.);+#142 = EDGE_LOOP('',(#143));+#143 = ORIENTED_EDGE('',*,*,#78,.T.);+#144 = FACE_BOUND('',#145,.F.);+#145 = EDGE_LOOP('',(#146));+#146 = ORIENTED_EDGE('',*,*,#147,.F.);+#147 = EDGE_CURVE('',#148,#148,#150,.T.);+#148 = VERTEX_POINT('',#149);+#149 = CARTESIAN_POINT('',(8.,-4.898587196589E-16,0.));+#150 = SURFACE_CURVE('',#151,(#156,#163),.PCURVE_S1.);+#151 = CIRCLE('',#152,2.);+#152 = AXIS2_PLACEMENT_3D('',#153,#154,#155);+#153 = CARTESIAN_POINT('',(6.,0.,0.));+#154 = DIRECTION('',(0.,0.,1.));+#155 = DIRECTION('',(1.,0.,-0.));+#156 = PCURVE('',#93,#157);+#157 = DEFINITIONAL_REPRESENTATION('',(#158),#162);+#158 = CIRCLE('',#159,2.);+#159 = AXIS2_PLACEMENT_2D('',#160,#161);+#160 = CARTESIAN_POINT('',(6.,0.));+#161 = DIRECTION('',(1.,0.));+#162 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#163 = PCURVE('',#129,#164);+#164 = DEFINITIONAL_REPRESENTATION('',(#165),#169);+#165 = LINE('',#166,#167);+#166 = CARTESIAN_POINT('',(0.,1.));+#167 = VECTOR('',#168,1.);+#168 = DIRECTION('',(1.,0.));+#169 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#170 = ADVANCED_FACE('',(#171),#129,.F.);+#171 = FACE_BOUND('',#172,.F.);+#172 = EDGE_LOOP('',(#173,#174,#195,#196));+#173 = ORIENTED_EDGE('',*,*,#112,.F.);+#174 = ORIENTED_EDGE('',*,*,#175,.F.);+#175 = EDGE_CURVE('',#148,#113,#176,.T.);+#176 = SEAM_CURVE('',#177,(#181,#188),.PCURVE_S1.);+#177 = LINE('',#178,#179);+#178 = CARTESIAN_POINT('',(8.,-4.898587196589E-16,-1.));+#179 = VECTOR('',#180,1.);+#180 = DIRECTION('',(0.,0.,1.));+#181 = PCURVE('',#129,#182);+#182 = DEFINITIONAL_REPRESENTATION('',(#183),#187);+#183 = LINE('',#184,#185);+#184 = CARTESIAN_POINT('',(6.28318530718,-0.));+#185 = VECTOR('',#186,1.);+#186 = DIRECTION('',(0.,1.));+#187 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#188 = PCURVE('',#129,#189);+#189 = DEFINITIONAL_REPRESENTATION('',(#190),#194);+#190 = LINE('',#191,#192);+#191 = CARTESIAN_POINT('',(0.,-0.));+#192 = VECTOR('',#193,1.);+#193 = DIRECTION('',(0.,1.));+#194 = ( GEOMETRIC_REPRESENTATION_CONTEXT(2)+PARAMETRIC_REPRESENTATION_CONTEXT() REPRESENTATION_CONTEXT('2D SPACE',''+ ) );+#195 = ORIENTED_EDGE('',*,*,#147,.T.);+#196 = ORIENTED_EDGE('',*,*,#175,.T.);+#197 = ( GEOMETRIC_REPRESENTATION_CONTEXT(3)+GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#201)) GLOBAL_UNIT_ASSIGNED_CONTEXT+((#198,#199,#200)) REPRESENTATION_CONTEXT('Context #1',+ '3D Context with UNIT and UNCERTAINTY') );+#198 = ( LENGTH_UNIT() NAMED_UNIT(*) SI_UNIT(.MILLI.,.METRE.) );+#199 = ( NAMED_UNIT(*) PLANE_ANGLE_UNIT() SI_UNIT($,.RADIAN.) );+#200 = ( NAMED_UNIT(*) SI_UNIT($,.STERADIAN.) SOLID_ANGLE_UNIT() );+#201 = UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.E-07),#198,+ 'distance_accuracy_value','confusion accuracy');+#202 = PRODUCT_RELATED_PRODUCT_CATEGORY('part',$,(#7));++#203=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:generator','cadgen');+#204=REPRESENTATION('cadgen:generator',(#203),#197);+#205=PROPERTY_DEFINITION('cadgen metadata','cadgen:generator',#5);+#206=PROPERTY_DEFINITION_REPRESENTATION(#205,#204);+#207=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:entryKind','part');+#208=REPRESENTATION('cadgen:entryKind',(#207),#197);+#209=PROPERTY_DEFINITION('cadgen metadata','cadgen:entryKind',#5);+#210=PROPERTY_DEFINITION_REPRESENTATION(#209,#208);+#211=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:sourcePath','model.step.py');+#212=REPRESENTATION('cadgen:sourcePath',(#211),#197);+#213=PROPERTY_DEFINITION('cadgen metadata','cadgen:sourcePath',#5);+#214=PROPERTY_DEFINITION_REPRESENTATION(#213,#212);+#215=DESCRIPTIVE_REPRESENTATION_ITEM('cadgen:sourceHash','d10cd8ed4de6127d16a16d6738b0c69ef4da342f38562c8af4eca6ee519cc0ff');+#216=REPRESENTATION('cadgen:sourceHash',(#215),#197);+#217=PROPERTY_DEFINITION('cadgen metadata','cadgen:sourceHash',#5);+#218=PROPERTY_DEFINITION_REPRESENTATION(#217,#216);+ENDSEC;+END-ISO-10303-21;diff --git a/output/orchestrator-live/token/model.stl b/output/orchestrator-live/token/model.stlnew file mode 100644index 000000000..f3eb03472Binary files /dev/null and b/output/orchestrator-live/token/model.stl differ