| name | implement-op |
| description | Modify op code to match the manifest-declared interface, making spec tests pass. |
Arguments
op_name, manifest_signature, source_op, source_test — passed by align-family orchestrator.
Contract
- Input:
op_name, manifest_signature, source_op, source_test
- Output: modified op code + commit +
observations list (returned to orchestrator)
- Termination (success):
python scripts/validate_manifest.py --check-op <name> all levels pass + new tests pass.
- Termination (blocked): fix requires changes beyond Op layer. Return
blocked with reason.
- Constraint: must NOT modify
src/tileops/manifest/. Must NOT modify tests written by test-op in this align-op run (spec contract). MAY update pre-existing tests in <source_test> whose call-sites use the legacy API. The parent orchestrator (align-op) handles the manifest flip at FLIP_STATUS. If your implementation needs a contractual-field change to make tests pass, return BLOCKED — do not edit the manifest yourself.
- Behavioral compatibility: default param values (from manifest) must produce identical results to the old implementation. The old API shape (e.g.,
__init__(M, N)) is NOT preserved — the manifest defines the target interface.
Workflow
stateDiagram-v2
[*] --> ANALYZE
ANALYZE --> DIAGNOSE: semantic knowledge extracted
DIAGNOSE --> VALIDATE: gap already resolved (base class fixed by previous op)
DIAGNOSE --> IMPLEMENT: gap exists
IMPLEMENT --> VALIDATE: sub-step completed
VALIDATE --> IMPLEMENT: sub-step failed
VALIDATE --> MARK_DONE: all pass
VALIDATE --> BLOCKED: fix exceeds Op layer scope
MARK_DONE --> COMMIT
COMMIT --> [*]
BLOCKED --> [*]: return blocked to orchestrator