AI Flow
Public Made by Adomby adom
Adom's AI Flow: a tool to help the AI follow all of the steps it takes to build a board.
Route geometry: off-45° segments, right-angle corners and wiggles reach finish unchecked
Route geometry: off-45° segments, right-angle corners and wiggles reach finish unchecked
Seen on: adom-aiflow 0.2.40 to 0.2.44, the same AM32 ESC built twice (2 layers, about 40 × 40 mm molecule):
- AI Flow: adom/am32-esc-2s6s-molecule, a full AI Flow run, board of record
board-19, delivered 2026-11-03. - Hands-on: adom/am32-esc-v1, placed and routed by hand in KiCad by Noah (2026-11-02).
Both pages are private to the adom org.
What happened: the AI Flow board passed gate and finish (DRC clean, 100 % routed). Its traces still look wrong to a layout engineer. They run at odd angles, turn at right angles and wiggle in short sideways steps. A script read both .kicad_pcb files with pcbnew 10.0.6; the script is attached as route_fig.py.txt:
| AI Flow | Hands-on | |
|---|---|---|
| Track segments / total length | 941 / 1098 mm | 442 / 579 mm |
| Segments off a multiple of 45° (by more than 1°) | 151 (117 mm, 10.7 % of the length) | 0 |
| 90° corners (two segments of one net, one layer) | 66 | 6 |
| Direction reversals within 1 mm (jogs, wiggles) | 250 | 41 |
Where the bad copper came from (each segment matched to the plan that drew it):
- The AI's own hand-written plan for the power copper and gate drive (
power_route.py, landed withtake route=ai): 74 off-angle segments (95 mm) and 44 of the 90° corners. - AI Flow's grid router (
route --variants 8 --passes 9, plus a second pass): 77 off-angle segments (22 mm). They are mostly short entries into off-grid pads, about 0.3 mm on average. The router also drew 22 of the 90° corners.
So two things are wrong. The router itself leaves off-angle pad entries and right-angle turns, and gate judges only DRC. Copper written by the AI (or by Freerouting, or anything given to gate --plan) is never held to a geometry standard at all.
Why it matters: slow signals on a modern fab still work with this copper. But it is not how a board should be drawn. It is harder to review, odd angles and wiggles add length and coupling, and a human picking up the board has to redo it. The rule a layout engineer follows:
- Traces run at 0, 45, 90, 135, 180, 225, 270 or 315° only.
- Right-angle corners are a last resort, for a slow signal in a very tight spot.
- No zig-zags.
The hands-on board meets the rule with 0 off-angle segments, and its 6 right angles are trace-into-via joins.
Suggested fix:
A route-geometry check in
gate(and in theroutereport andfinish) that runs on every plan whoever wrote it. It counts:- off-45° segments (excluding the arc of a deliberate curve, if any are ever planned)
- 90° corners and acute corners
- direction reversals shorter than N × width
Each count names the net, with coordinates. It warns by default. It is an error on the nets the spec ranks highest (#129), and when
spec.routeStyle: "strict"is set.Router: enter an off-grid pad along the pad's own axis, then take the 45° jog onto the grid. Never draw the diagonal straight to the pad centre. Extend
simplify.rsto chamfer 90° turns into two 45° turns where the clearance allows, and to merge wiggles (alternating turns within a few track widths) into one straight run.Timeline: show the geometry counts beside DRC in the routing step, so the human sees them before
finish.
The attached route_fig.py gives the metric definitions and the drawing below. Legend: red = off-45° segment, yellow ring = 90° corner, cyan × = short reversal, white dot = signal via. Left is AI Flow, right is hands-on.


Related: #128 (vias and detours), #129 (signal priority), #130 (placement priorities).
3 Replies
Log in to reply.