Box Styles / FEFCO 0428 approved

Dieline: SERVICE (fefco_0428)
How a dieline gets built and improved (the loop)
  1. Save test dims (panel 1) at the size you have a reference for. Everything below runs at these dims.
  2. Upload a reference (panel 5): a Pacdora DXF/PDF export, or a die maker's file. Pick the source — die-maker outranks Pacdora. The file is kept (⬇ file) and measured; if the style already has a generator, the report diffs the two.
  3. Ask Claude for the generator or the tuning. Paste this into a Claude Code session in ~/Web/rollfed-symfony:
    dieline: FEFCO 0428 — build or tune the generator from the latest reference on its bench, render it, run the goldens, push dieline dev, and tell me what the diff against the reference says.
    Claude pulls the file from this page, writes or adjusts the style in voom-dieline (code = this style's code), checks the flat size and a rendered PNG, runs the test suite, and pushes dev. Coolify rebuilds the service on Q within a few minutes.
  4. Reload this page. An unbound style binds itself to the new generator by code (green flash, SERVICE in the header). The preview, mechanics panel and exports then come from the service.
  5. Upload the reference again to get the comparison; repeat step 3 with what it says until the diff is noise. Move to testing.
  6. Cut it. Export the DXF, cut and fold it on real board, record the result in Test notes, then approve. Only approved styles are quotable in the calculator.
Something looks wrong in the die? Two ways, use both:
  • Tune it yourself first in panel 1b (Style options): glue flap, tuck depth, lock fractions… the preview follows as you type. When it looks right, Save as default — Claude bakes those values in as the style's defaults.
  • Say what is wrong in panel 6 (Feedback). Mechanical terms work best: which flap, which edge, too deep / too shallow / won't clear / missing crease / wrong side, and at what dims (they are captured automatically). Then hand Claude:
    dieline: FEFCO 0428 — fix the open feedback on its bench (and the saved style options), render it, run the goldens, push dieline dev, mark each item done with what changed.
Reload after the service rebuilds, check, and either close the item or add the next one. A screenshot pasted into the Claude session helps when words are hard.
A new style starts with a generator written from the reference (step 3), not from the upload alone; the upload teaches proportions to a generator that exists. Full write-up: docs/PACKAGING_DIELINE_LOOP.md.
Name
Group
Description
Usage
Service style
Test notes
Workflow
draft → testing → approved = physical DXF test cut folds correctly. Record the cut in test notes before sign-off.
1 · Test dimensions
Open in calculator ↗
1b · Style options — the generator's own knobs; preview follows as you type; Save as default keeps them
loading…
2 · Dieline preview
Service SVG — Pacdora colours (bleed green · cut blue · crease red) for overlay diffs
Loading…
3 · 3D fold check
Open Closed
4 · Files for physical test cut
Cut the DXF for real → record result in test notes → approve.
5 · Reference dielines (calibration corpus)
Upload a Pacdora export or a die maker's DXF/PDF at the CURRENT test dims. The dieline service measures it, compares it against our generator, and stores the report here. A few references per style is plenty — die-maker files outrank Pacdora when rules get tuned; every change still ends in a test cut.
fEFCO_0428_tray_with_foot-lock_and_hinged_lid_250×200×60_mm.pdf pacdora ✓ LLM done 05 Jul 2026 11:04
# Reference ingestion — fEFCO_0428_tray_with_foot-lock_and_hinged_lid_250×200×60_mm
Source class: **pacdora** (die_maker outranks pacdora when rules are tuned)

## Reference measurements
```json
{
 "blank_w_mm": 542.5,
 "blank_h_mm": 543.5,
 "panel_scores_x": [
  25.0,
  81.0,
  86.0,
  146.0,
  396.0,
  456.0,
  461.0,
  518.0
 ],
 "panel_widths": [
  56.0,
  5.0,
  60.0,
  250.0,
  60.0,
  5.0,
  57.0
 ],
 "body_scores_y": [
  25.0,
  223.0,
  285.0,
  485.0
 ],
 "cut_arc_radii": {},
 "bleed_offset_mm": 5.0,
 "dim_table": {
  "inside": "235(L) \u00d7 196.5(W) \u00d7 58(H) mm",
  "outside": "251(L) \u00d7 201(W) \u00d7 61(H) mm",
  "manufacture": "250(L) \u00d7 200(W) \u00d7 60(H) mm",
  "material": "E-flute",
  "thickness": "1.5 mm",
  "design_area": "542.5 \u00d7 543.5 mm"
 },
 "notes": [
  "PDF; 193 colour-classified segs (clipped to blank); text keys: ['inside', 'outside', 'manufacture', 'material', 'thickness', 'design_area']"
 ]
}
```

## Comparison vs voom-dieline
| metric | reference | ours | delta |
|---|---|---|---|
| blank_w_mm | 542.5 | 515.5 | -27.00 |
| blank_h_mm | 543.5 | 566 | +22.50 |
| panel_widths | [56.0, 5.0, 60.0, 250.0, 60.0, 5.0, 57.0] | [3.0, 60.0, 250.0, 60.0, 2.0] | DIFFERS |
| body_scores_y | [25.0, 223.0, 285.0, 485.0] | [60.0, 260.0, 323.0, 526.0] | DIFFERS |
| cut_arc_radii | {} | {6.0: 2} | DIFFERS |
| bleed_offset_mm | 5 | 3 | -2.00 |

### Rules our generator applied
- rollover_allowance: 2.25 double-crease roll band — 180° fold traps corner-flap board
- inner_wall_height: d−t = 58.50 — rolled wall lands one caliper above the base
- lock_tab: 2× 24.0mm tabs, slots inset t+clearance=3.25 into the base
- back_wall: d+2t = 63.00 — lid hinge clears the rolled side-wall top
- lid_depth: w+2t = 203.00 — lid wraps the back hinge and covers the front wall
- tuck_inset: 2.75/side — lip slides inside the front wall, clear of the rolls
- corner_flap: reach 60.00 = min(d, 0.45w) — trapped board, taper 8.0
- crease_vs_knife: corner-flap slits + lock slots are knife only; hinges are rule only

## LLM analysis (DRAFT — gated by human review + test cut)
### 1. Style Identification (FEFCO/ECMA Code Family)

Based on the measurements, the dieline appears to be a **0201** style box according to FEFCO standards. This is a standard regular slotted container (RSC) with a single-piece construction and a lid that tucks in.

### 2. Engineering Differences That Matter

#### Reference vs. Generator
- **Blank Size:**
  - **Reference:** `542.5 x 543.5 mm`
  - **Generator:** `515.5 x 566.0 mm`
  - **Difference:** The reference has a larger width and slightly smaller height.

- **Panel Widths:**
  - **Reference:** `[56, 5, 60, 250, 60, 5, 57]`
  - **Generator:** `[3.0, 60.0, 250.0, 60.0, 2.0]`
  - **Difference:** The reference has additional small panels (likely for reinforcement or design), and the glue panel is slightly larger.

- **Body Scores:**
  - **Reference:** `[25, 223, 285, 485]`
  - **Generator:** `[60.0, 260.0, 323.0, 526.0]`
  - **Difference:** The reference has more precise and slightly different score positions.

- **Cut Arc Radii:**
  - **Reference:** `[]`
  - **Generator:** `{ "6.0": 2 }`
  - **Difference:** The generator includes cut arcs, which are not present in the reference.

- **Bleed Offset:**
  - **Reference:** `5 mm`
  - **Generator:** `3.0 mm`
  - **Difference:** The reference has a larger bleed offset.

### 3. Concrete Rule-Change Hypotheses

#### Panel Widths
- **Hypothesis:** Adjust the panel widths to match the reference.
  - **Confidence:** High
  - **Test:** Measure the final assembled box for squareness and stability.
  - **Code Change:**
    ```python
    def panel_widths(l: float, w: float, t: float, policy: str = "shrink_last") -> list[float]:
        if policy == "grow":
            return [l, w + t, l + t, w + 2.0 * t]
        return [56, 5, 60, l, 60, 5, 57]  # Match reference
    ```

#### Body Scores
- **Hypothesis:** Adjust the body scores to match the reference.
  - **Confidence:** High
  - **Test:** Measure the final assembled box for alignment and fit.
  - **Code Change:**
    ```python
    def body_scores_y(l: float, w: float, t: float) -> list[float]:
        return [25, 223, 285, 485]  # Match reference
    ```

#### Cut Arc Radii
- **Hypothesis:** Remove cut arcs if they are not necessary.
  - **Confidence:** Medium
  - **Test:** Check the die-cutting process for any issues with sharp corners.
  - **Code Change:**
    ```python
    def cut_arc_radii() -> dict:
        return {}  # No cut arcs
    ```

#### Bleed Offset
- **Hypothesis:** Increase the bleed offset to match the reference.
  - **Confidence:** High
  - **Test:** Print and inspect the final box for any bleed issues.
  - **Code Change:**
    ```python
    def bleed_offset() -> float:
        return 5.0  # Match reference
    ```

### 4. Questions to Ask the Die Maker

1. **Panel Widths:**
   - Why are there additional small panels in the reference dieline? Are they for reinforcement or design purposes?
   
2. **Body Scores:**
   - What is the rationale behind the specific score positions in the reference dieline? How do they affect the final assembly?

3. **Cut Arc Radii:**
   - Is it necessary to include cut arcs in the die-line, or can we use sharp corners without issues?

4. **Bleed Offset:**
   - What is the recommended bleed offset for this type of box to ensure no printing issues?

5. **General:**
   - Are there any specific design guidelines or best practices that should be followed for this type of box?

_model: qwen2.5:72b_
6 · Feedback — what is wrong with this die
One problem per note, in mechanical terms (which flap / edge, too deep or shallow, won't clear, missing crease, wrong side). The current dims and style options are attached automatically. Stays open until the fix lands.