How ylee-sling/separation-logic-gcode-verifier works
This prototype turns machining intent into a verified G-code program through an evaluator–refiner loop. The orchestrator grounds the workspace, asks a generator for G-code, compiles motion blocks into discrete swept volumes, and checks them against environment and stock. A collision is formatted as structured feedback for another generation attempt; successful proof yields the program. The README documents STEP fixtures and stock as additional grounding inputs. The generator is currently a scripted stub. The graph follows documented relationships and sampled calls; unsampled implementation details are not inferred.
Main entry points: main_loop.py Pipeline orchestrator · sl_prover.py Block evaluator · cad_extractor.py STEP extraction · parser.py G-code discretizer
Components 15
Workspace Grounding
- STEP extraction
cad_extractor.py - Feature bounds
cad_extractor.py - Obstacle padding
cad_extractor.py - Workspace heap setup
main_loop.py - Grounded system prompt
main_loop.py
Generation Loop
- Pipeline orchestrator
main_loop.py - G-code generator
main_loop.py
Spatial Verification
- G-code discretizer
parser.py - Motion footprints
parser.py - Spatial heap
sl_prover.py - Block evaluator
sl_prover.py
Feedback and Results
- Conflict feedback
sl_feedback_generator.py - Verified program
Other components
- Machining intent
- STEP geometry
Connections 19
- Machining intent → Pipeline orchestrator: provides intent
README.md - STEP geometry → STEP extraction: supplies geometry
README.md - STEP extraction → Feature bounds: extracts features
cad_extractor.py - Feature bounds → Obstacle padding: pads bounds
cad_extractor.py - Pipeline orchestrator → Workspace heap setup: grounds workspace
main_loop.py - Obstacle padding → Workspace heap setup: provides obstacles
README.md - Workspace heap setup → Grounded system prompt: supplies bounds
main_loop.py - Grounded system prompt → G-code generator: grounds generation
main_loop.py - Pipeline orchestrator → G-code generator: requests draft
main_loop.py - G-code generator → Pipeline orchestrator: returns G-code
README.md - Pipeline orchestrator → G-code discretizer: compiles draft
README.md - G-code discretizer → Motion footprints: emits steps
parser.py - Pipeline orchestrator → Block evaluator: executes steps
main_loop.py - Workspace heap setup → Spatial heap: initializes resources
main_loop.py - Block evaluator → Spatial heap: checks and updates
sl_prover.py - Pipeline orchestrator → Conflict feedback: formats fault
main_loop.py - Block evaluator → Pipeline orchestrator: returns conflict
main_loop.py - Conflict feedback → G-code generator: guides retry
README.md - Pipeline orchestrator → Verified program: returns on proof
README.md