Compile 3D workflow
Contract
| Field |
Bound contract |
| Trigger |
The user asks for direction and a compilable 3D workflow from an interview. |
| Authority |
Reversible local: writes only the named local 3D workflow artifact file; rollback is deleting that file. No remote mutation. |
| Side effect |
Writes one local 3D workflow artifact file. |
| Done |
A validated local 3D workflow artifact file exists and passes every structural check. |
Inputs
- A direction interview with the user, supplying: the problem being solved, what success looks like, binding constraints, and what is explicitly out of scope. All four required; none inferred.
- The output file path for the workflow artifact. Required.
Artifact schema
The workflow artifact is a YAML file with this structure:
problem: <string>
success_criteria: <string>
constraints: [<string>, ...]
out_of_scope: [<string>, ...]
topology:
nodes:
- id: <string>
task: <string>
depends_on: [<node_id>, ...]
ontology:
groups:
- name: <string>
members: [<node_id>, ...]
feedback_loops:
- name: <string>
sensor: <string>
comparator: <string>
actuator: <string>
Every node id referenced in depends_on must exist in nodes. Every node id in ontology group members must exist in nodes. Every feedback loop must name a sensor, comparator, and actuator as non-empty strings.
Procedure
- Conduct the direction interview. Ask the user for the problem, success criteria, binding constraints, and explicit out-of-scope. Record the answers verbatim. Done when: all four interview inputs are recorded verbatim, or the missing input is named and the skill stops.
- Author the workflow artifact from the interview answers. Build the three dimensions:
- Topology: a DAG of tasks. Each node has an id, a task description, and a depends_on list naming the node ids it waits on. No cycles. No node depends on itself. Every depends_on entry must reference an existing node id.
- Ontology groups: named concept clusters classifying the work domains. Each group names its member node ids. Every group is non-empty. Every member must exist in the topology.
- Feedback loops: cybernetic control cycles. Each loop names its sensor (what is measured), comparator (what is expected), and actuator (what action re-routes). All three are non-empty strings.
Done when: the artifact combines all three dimensions from the interview answers.
- Validate the artifact against the schema. Check every rule:
- Every node has a unique id and a non-empty task.
- Every depends_on entry references an existing node id.
- No cycle exists in the dependency graph (topological sort succeeds).
- Every ontology group is non-empty and every member references an existing node id.
- Every feedback loop names a non-empty sensor, comparator, and actuator.
Done when: every check passes, or the specific defect is named and the skill stops.
- Write the validated artifact to the output file path as YAML. State the rollback path: delete the local artifact file. No remote state was touched. Done when: the artifact file is written and the rollback path is stated.
Failure and recovery
- Interview incomplete: if the user cannot supply the problem, success criteria, constraints, or scope, stop and report which inputs are missing. Do not infer or fabricate direction.
- Schema validation failure: if any node lacks dependencies, any ontology group is empty, any feedback loop is missing its sensor, comparator, or actuator, any depends_on entry references a non-existent node, or a cycle exists in the dependency graph, report the specific defect and stop. Do not emit a partial artifact as complete.
- Partial-result rule: a partially written artifact file is not a compiled workflow. Delete it and report the rollback.
Output
A validated local 3D workflow artifact file (YAML) containing the DAG topology, ontology groups, and feedback loops, with every structural check passing.
1---2name: compile-3d-workflow3description: Use when the user asks for direction and a compilable 3D workflow from an interview. Not for remote, credential, publish, deploy, or irreversible changes.4---56# Compile 3D workflow78## Contract910| Field | Bound contract |11|---|---|12| Trigger | The user asks for direction and a compilable 3D workflow from an interview. |13| Authority | Reversible local: writes only the named local 3D workflow artifact file; rollback is deleting that file. No remote mutation. |14| Side effect | Writes one local 3D workflow artifact file. |15| Done | A validated local 3D workflow artifact file exists and passes every structural check. |1617## Inputs1819- A direction interview with the user, supplying: the problem being solved, what success looks like, binding constraints, and what is explicitly out of scope. All four required; none inferred.20- The output file path for the workflow artifact. Required.2122## Artifact schema2324The workflow artifact is a YAML file with this structure:2526```yaml27problem: <string>28success_criteria: <string>29constraints: [<string>, ...]30out_of_scope: [<string>, ...]31topology:32 nodes:33 - id: <string>34 task: <string>35 depends_on: [<node_id>, ...]36ontology:37 groups:38 - name: <string>39 members: [<node_id>, ...]40feedback_loops:41 - name: <string>42 sensor: <string>43 comparator: <string>44 actuator: <string>45```4647Every node id referenced in `depends_on` must exist in `nodes`. Every node id in ontology group `members` must exist in `nodes`. Every feedback loop must name a sensor, comparator, and actuator as non-empty strings.4849## Procedure50511. Conduct the direction interview. Ask the user for the problem, success criteria, binding constraints, and explicit out-of-scope. Record the answers verbatim. Done when: all four interview inputs are recorded verbatim, or the missing input is named and the skill stops.522. Author the workflow artifact from the interview answers. Build the three dimensions:53 - Topology: a DAG of tasks. Each node has an id, a task description, and a depends_on list naming the node ids it waits on. No cycles. No node depends on itself. Every depends_on entry must reference an existing node id.54 - Ontology groups: named concept clusters classifying the work domains. Each group names its member node ids. Every group is non-empty. Every member must exist in the topology.55 - Feedback loops: cybernetic control cycles. Each loop names its sensor (what is measured), comparator (what is expected), and actuator (what action re-routes). All three are non-empty strings.56 Done when: the artifact combines all three dimensions from the interview answers.573. Validate the artifact against the schema. Check every rule:58 - Every node has a unique id and a non-empty task.59 - Every depends_on entry references an existing node id.60 - No cycle exists in the dependency graph (topological sort succeeds).61 - Every ontology group is non-empty and every member references an existing node id.62 - Every feedback loop names a non-empty sensor, comparator, and actuator.63 Done when: every check passes, or the specific defect is named and the skill stops.644. Write the validated artifact to the output file path as YAML. State the rollback path: delete the local artifact file. No remote state was touched. Done when: the artifact file is written and the rollback path is stated.6566## Failure and recovery6768- Interview incomplete: if the user cannot supply the problem, success criteria, constraints, or scope, stop and report which inputs are missing. Do not infer or fabricate direction.69- Schema validation failure: if any node lacks dependencies, any ontology group is empty, any feedback loop is missing its sensor, comparator, or actuator, any depends_on entry references a non-existent node, or a cycle exists in the dependency graph, report the specific defect and stop. Do not emit a partial artifact as complete.70- Partial-result rule: a partially written artifact file is not a compiled workflow. Delete it and report the rollback.7172## Output7374A validated local 3D workflow artifact file (YAML) containing the DAG topology, ontology groups, and feedback loops, with every structural check passing.