Same-frame F1 follow-up per Codex round 43 (#15527). matrix §4.1 Fix 7
4-class F1 path (no Track A pause, small fixes + Codex re-review).
Three fixes :
1. F1-a — explicit col_a/col_b label defaults
- Previous (c7b0f5b) used empty defaults `col_a_label_default: ""` /
`col_b_label_default: ""`, so an upstream MDX path without explicit
column headers would render blank header cells.
- Fix : set `col_a_label_default: "BIM"` and `col_b_label_default: "DX"`
in F18 contract. Frame intent is the BIM-vs-DX comparison, so the
headers are semantic and must not silently become blank.
2. F1-b — narrow prefix-stripping aliases (parser → builder option)
- Previous parser used a broad regex
`^[A-Za-z가-힣]{1,8}\s*:\s*(.+)$` to strip any short prefix before
`:`. That could accidentally remove meaningful Korean/English
prefixes from real cell content.
- Fix : remove auto-stripping from `parse_compare_row_2col_item`.
Stripping is now configurable via builder option
`strip_col_prefix_aliases: [<list of exact aliases>]` and applied
by `_build_compare_table_2col`. F18 contract uses `["BIM", "DX"]`,
so only `BIM:` / `DX:` (with optional fullwidth `:`) prefixes are
stripped; other Korean/English colons in real content stay intact.
- Parser signature unchanged. Builder is the single place that owns
the stripping policy.
3. F1-c — cardinality semantic clarification
- Previous top-level `cardinality.strict: 2` was ambiguous: it could
be read as `row strict: 2`. Rows are actually `1..12` via
`sub_zones.rows.cardinality`.
- Fix : add YAML comment that the top-level strict 2 = column count
(col_a / col_b), not row count. Per-sub_zone cardinality remains
authoritative for rows.
Verification :
- python -m py_compile src/phase_z2_mapper.py : PASS
- python scripts/smoke_frame_render.py --self-check : PASS 7/7 (F18
fixture rendered unchanged at 4211 chars; smoke harness only loaded
the partial, builder/parser logic not directly exercised in smoke)
- Manual builder/parser invocation test with synthetic units :
- col_a_label / col_b_label resolve to "BIM" / "DX" defaults.
- `BIM: Only 3D` → `Only 3D` (alias-stripped).
- `DX: BIM << DX (ENG. 포함)` → `BIM << DX (ENG. 포함)` (alias-stripped).
- `분야별 단절` → `분야별 단절` (no BIM/DX prefix, untouched).
- This matches the F1-b narrow-alias intent.
- python scripts/smoke_frame_render.py bim_dx_comparison_table
--render-to data/runs/imp04_f18_visual_r2 : PASS, R3 artifact written
with same character count, generic viewer title.
scope-lock honored : no V4 logic, no new builder/parser added (only
behavior refinement of existing F18 builder/parser/contract), no other
partial, no Phase Z production render, no Phase R'/AI/Kei changes.
4-class status (F18 post-F1) :
- class 1 readiness : adapter cleanup complete — defaults explicit,
aliases narrow, cardinality semantically clear.
- class 2 content-fit : still a watch item (long Korean wrapping,
6+ rows). max_rows=12 protection unchanged.
- class 3 / 4 : N/A.
Refs Gitea #4 (IMP-04 Track A frame 4 — F1 follow-up per Codex round 43)
Same-frame F1 follow-up commit per Codex round 37 (#15503). Matrix §4.1
Fix 7 4-class: F1 = small same-frame fix + Codex re-review (not F2/F3,
no Track A pause needed).
Two fixes (both Codex-caught) :
1. F1-a — `intersection` sub_zone contract semantics
- Previous (c67609c) declared `cardinality: { strict: 1 }` on the
intersection sub_zone, while the builder used `intersection_default: ""`
and the partial hides empty intersection. That mismatch meant
production payloads could silently omit the center concept while
the contract still demanded strict 1.
- Fix : `cardinality: { min: 0, max: 1 }` — intersection is now
explicitly optional, matching analysis.md "slots 5개, required 4개"
(intersection was originally the optional 5th slot).
- Builder behavior unchanged (intersection_default = "" still
produces empty when MDX has no center text; partial's :empty hide
remains semantically correct).
2. F1-b — smoke harness viewer title leakage
- Previous harness output had `<title>F14 render artifact — {template_id}</title>`
hardcoded from the original F14-specific implementation.
- Fix : generic `<title>Phase Z render artifact — {template_id}</title>`.
- Affects all `--render-to` dev artifacts going forward.
Verification :
- python scripts/smoke_frame_render.py --self-check : PASS 5/5
- python scripts/smoke_frame_render.py construction_goals_three_circle_intersection
--render-to data/runs/imp04_f12_visual_r2 : PASS, generated title now reads
"Phase Z render artifact — construction_goals_three_circle_intersection"
- Catalog yaml parse : intersection cardinality = {min: 0, max: 1}
scope-lock honored : no V4 logic, no builder/parser logic, no other
partial, no Phase Z production render, no Phase R'/AI/Kei changes. F1
fix scope only.
Refs Gitea #4 (IMP-04 Track A frame 2 — F1 follow-up per Codex round 37)
Re-apply the W1 wording clarifications previously agreed in the comment
thread. The originally executed wording commit `6d33884` was reverted by
Codex via `c807b2c` after Codex acknowledged that `ㄱ` for both Claude and
Codex is comment-only review (no source/doc edit). Both sides 100%
agreement is restored via Claude rounds 16/17/19 and Codex rounds 15/18.
This Claude-applied commit is the agreed re-application path (option A).
Six fixes applied to docs/architecture/IMP-04-FRAME-SUITABILITY-MATRIX.md :
1. §2 ACTIVE 4 frames table : add resource status (A/T/I/F/S) column.
F13 has no `assets/` directory (marked `-`). State that ACTIVE means
catalog-registered / runtime-active, not necessarily A+T+I+F+S
resource-complete.
2. §4 Track B : strengthen wording. Track B = visual-resource-pending
inside the 32-frame scope, **NOT exclusion / discard / scope
reduction**. Visual-resource acquisition timing is the only difference.
3. §4 Track B option (b) : minimal CSS partial from analysis/texts only
is **main path X, explicit temporary placeholder only**. Avoids the
frame 1 (`three_persona_benefits` 556b448) quality failure pattern.
4. §4.1 Track A priority : **execution ordering only, NOT scope filter**.
All 16 reusable-now frames remain activation targets. V4-weak 11
frames stay in scope. Builder family grouping = secondary ordering
allowed after first refinement calibration.
5. §4.1 Codex review granularity explicit : first refinement, new builder
pattern, ambiguous mapping, shared catalog/builder logic = Codex
review mandatory. Low-risk repeated frames may be grouped only after
pattern is proven.
6. §4.1 calibration failure modes F1/F2/F3 (Claude round 14 catch + Codex
round 15 (a) accepted) :
- F1 small styling/wording issue -> same-frame follow-up commit +
Codex re-review.
- F2 approach-level problem -> pause Track A, approach re-lock round,
retry refinement.
- F3 scope/resource problem -> reopen scope/resource axis, possibly
IMP-04b, block bulk activation until resolved.
History trace : `fe766f1` (matrix base) -> `6d33884` (Codex W1 execute,
wrong workflow) -> `c807b2c` (Codex revert + workflow lock symmetric)
-> this commit (Claude re-apply under user execution signal, option A).
History noise retained as honest trace of the corrected ㄱ definition.
No source code changes. Documentation clarification only.
Refs Gitea #4 (IMP-04 — matrix wording re-application post-revert)
- Add active-frame resource status and clarify catalog-active versus resource-complete.\n- Clarify Track B as visual-resource-pending inside the 32-frame scope, not exclusion.\n- Clarify Track A priority as execution order, not scope filter.\n- Add Codex review granularity and calibration failure modes for the first refinement.\n- Mark minimal CSS from analysis/texts as temporary placeholder only.
- Add scripts/smoke_frame_render.py for IMP-04 scope-lock §11+§13:
isolated StrictUndefined Jinja partial render gate, separated from
production render_slide() permissive behavior
- CLI: --self-check runs every bundled fixture; positional template_id
takes payload via --payload <json> / stdin / fixture
- Bundled mock payloads for the 3 existing active frames match real
builder output shape; all 3 partials PASS self-check
- New frame activation gate (per-frame 6-step Step 5): partial must
pass smoke render with a complete mock that mirrors the builder's
output dict (optional fields supplied as empty/falsy so {% if %}
guards still work under StrictUndefined)
- Exit codes: 0=all pass, 1=at least one fail, 2=invalid input
Latent finding (out of IMP-04 scope, surfaced for the record):
bim_issues_quadrant_four partial references slot_payload.quadrant_N_headline,
but _build_quadrant_flat_slots() only produces quadrant_N_label and
quadrant_N_body. The headline div therefore never renders in production.
Either dead reference or a builder extension that was never landed —
reconcile in a follow-up axis, not in IMP-04 catalog expansion.
production render path (phase_z2_pipeline.render_slide) unchanged.
Refs Gitea #4 (IMP-04 A-2 Catalog 확장 — infra commit)
- Classify pipeline.py as Archive-heavy with Salvage Candidate 0
- Record Phase Q/R'/T execution flow as outside Phase Z normal path
- Mark deterministic pipeline utilities as Reference Only
- Mark pipeline_context.py schema and lifecycle methods as Reference Only
- Surface §1 B-1 as indirect surface, not direct composition planner
- Add §5-1 dated entry for 2026-05-12
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Classify §2.10 as Mixed with Salvage Candidate 0
- Mark utilities / matching helpers / Phase Q-2 filtering as Reference Only
- Record block_reference high-level entries as Phase R' reference path Archive
- Record block_selector format_candidates_for_prompt as Kei prompt formatter Archive
- Surface §1 A-2 indirect, catalog duplication, block_selector legacy as separate axes
- Add §5-1 dated entry for 2026-05-12
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Classify html_generator.py as Archive-heavy with Salvage Candidate 0
- Record AI HTML generation path as Phase R' Archive Candidate
- Mark deterministic duplicate helpers as Reference Only
- Surface A-3/A-4 mapping mismatch as a factual note
- Add §5-1 dated entry for 2026-05-12
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Classify renderer.py as Mixed with Salvage Candidate 0
- Mark Jinja/catalog/template rendering helpers as Reference Only
- Record render_slide_from_html Phase R' path as Archive Candidate
- Clarify A-3 as indirect preview render surface
- Clarify A-4 as slide-base impact surface without conditional CSS implementation
- Add §5-1 dated entry for 2026-05-12
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Classify content_verifier.py as Mixed (Reference Only + Archive Candidate)
- Mark deterministic utilities (text extraction, Korean normalization, verification logic) as Reference Only — Phase Z normal path direct slot absent
- Mark Kei artifact detection (verify_no_forbidden_content + FORBIDDEN_KEI_MEMOS) and Kei AI generation retry loop (generate_with_retry) as Archive Candidate
- Clarify L4 Selenium / L5 Opus vision are header documentation only (no implementation in this file)
- Record no §3 Salvage application target (Salvage Candidate 0)
- Surface §1 B-2 mapping as indirect; H1-H3 reference axis candidates, H4-H5 Archive markers, H6 L4/L5 factual note
- Add §5-1 dated entry for 2026-05-12
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Classify content_editor.py as Archive Candidate at module level
- Document Kei AI direct slot-fill flow (fill_content / fill_candidates / EDITOR_PROMPT)
- Mark Kei API infrastructure (_call_kei_editor_with_retry / _parse_json) as outside Phase Z normal path
- Record no §3 Salvage Plan target for this module
- Surface §1 B-1/B-2 candidate-file mapping mismatch and AI repair fallback infrastructure as separate axes
- Add §5-1 dated entry for 2026-05-12
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
문서 역할 분담:
- README : 프로젝트 개요 + 큰 그림 (가끔 갱신)
- OVERVIEW : 22 단계 도면 (구조 잠금)
- STATUS-BOARD : 각 단계 정확한 상태 (자주 갱신)
- CHANGE-LOG : 결정 변경 이력
- ROADMAP (신규): 진행 계획 + 당장 할 일 + 세부 todo (자주 갱신)
내용:
1. 현재 위치 (MDX03 정상 경로 통과)
2. 지금까지 완료한 작업 6 가지 영역
3. 22 단계 진행 수준 (추정 % 표 + STATUS-BOARD 단일 출처 caveat)
4. 큰 로드맵 7 단계
5. 세부 todo (5.1 보고용 프로토타입 우선 / 5.2~5.8 단계별)
6. 당장 실행 순서 (보고용 프로토타입 → 22 단계 정리 복귀)
7. 문서 역할 분담 표
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- 1. 프로젝트 개요 + 핵심 용어 표 (MDX / V4 / Phase Z / Frame / Region / Slot)
- 2. 22 단계 파이프라인 — 각 단계 별도 박스, 한글 라벨, 결정 분기 포함
- 3. 현재 완료 수준 — MDX03 정상 경로 통과, 진행 약 65~70%
- 4. 향후 로드맵 — 7 단계 (한글 LR Mermaid + 단계별 상세)
- 5. 운영 원칙 — 절대 원칙 / V4 ↔ Phase Z 책임 / 렌더 정책
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- .gitignore : forex/ 추가 (session workspace, 작업 흐름 trace, push X 사용자 결정 2026-05-08).
- .mcp.json : figma-desktop MCP endpoint sse → http (localhost:3845/mcp).
- .claude/settings.json : 권한 list 갱신 (200+ 새 entry).
GitHub PAT 가 박혀 있던 5 줄 *제거* (curl Authorization Bearer 줄)
— Bash 권한 history 잔여, 인증 token 으로 사용 X.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
전체 401 files (397 추가 + 4 수정), 14304 insertions.
추가:
- figma_to_html_agent/blocks/ — Figma 변환 결과 (32 frame, ~79MB).
각 frame folder = {analysis.md, flat.md, texts.md, index.html, assets/,
_renders/, _render.py, RELATIONSHIPS.md / STATUS.md / classification.md
(일부 frame)}.
Phase Z 의 *figma source layer* — runtime 에서 직접 사용 X, contract /
partial / builder adapter (미래 axis A) 의 source.
- figma_to_html_agent/DISCUSSION-SUMMARY-20260411.md — 변환 설계 회의 기록.
- figma_to_html_agent/HARNESS.md — 변환 검증 harness.
- figma_to_html_agent/scripts/fetch_figma_screenshots.py — Figma 스크린샷 자동 수집.
수정:
- figma_to_html_agent/PROCESS-CONTROL.md / PROCESS.md / RULES.md —
변환 프로세스 / 룰 갱신 (R8/R9 lock 강화 등).
- figma_to_html_agent/blocks_index.md — 32 frame 인덱스 갱신.
Phase Z 영향 0 (figma_to_html_agent/blocks/ 가 V4 catalog +
templates/phase_z2/families adapter 의 source — runtime 에서 직접 import X).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
전체 561 files, 32464 deletions. Phase Z runtime 의존성 0 — 모두 옛 작업 흔적.
대상:
- templates/blocks/ (104) — 옛 design_agent block library (BEPs, cards, structures,
emphasis, headers, media, svg, visuals, tables 등). Phase Z 가 templates/phase_z2/
로 이전 후 outdated.
- templates/catalog.yaml — 위 block library 의 catalog (의존성과 같이 폐기).
- figma_to_html_agent/block-tests/ (301) — figma 옛 변환 시도들 (renders, assets,
html, png, json, txt, md). 새 figma_to_html_agent/blocks/ 가 대체.
- figma_to_html_agent/templates_staging/ (49) — 옛 staging 시도.
- figma_to_html_agent/figma-{assets,screenshots,analysis,_ref}/ — 옛 figma 자료.
- figma_to_html_agent/previews/ (3) — 옛 preview.
- figma_to_html_agent/{FIGMA-*.md, PLAN.md, RESEARCH.md, PHASE-FIGMA-BLOCKS.md} (7)
— outdated docs (figma 통합 axis 가 끝난 후 polluting).
- figma_to_html_agent/{block_index.faiss, block_metadata.json, figma_*.json} (6)
— 옛 FAISS index + metadata.
Phase Z runtime / V4 catalog 영향 0 (의존성 grep 으로 사전 검증).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- enable B1/B2/B4 source-shape-aware F13 placement behind env flag
- align F13 placement_trace with mapper top_bullets cardinality
- preserve canonical render output when flag is off
- gate V4/B4 mismatch zones via PHASE_Z_B4_GATEKEEPER env (default OFF)
- record mismatch as adapter_needed_units with reason and mismatch_detail
- preserve render path byte-identical when flag unset
- consolidate evidence-based principles for Step 5/6/7 and B-axis matching layer
- record CompositionUnit, candidate-based composition, and 4-tier terminology
- defer bridge architecture and slot_payload evolution as scope-locked open items
- align Phase Z hierarchy terms with Layer A and Frame Slot planning
- reframe Type A/B/B'/B'' as legacy layout hints
- record trace-only render path activation as the current anchor model
- mark content object, internal region, and placement steps as partial
- record B1-B5 and trace-only runtime activation status
- refresh current missing items and bottleneck summary
- run B1/B2/B4 placement planning in trace-only mode
- record placement_trace per rendered zone in debug output
- preserve existing render output and visual routing behavior
- add Internal Region model to Phase Z architecture docs and specs
- add frame contract content type and Frame Slot declarations
- add dormant content object extractor and internal region planner
- 무엇인가 → 구성/구현 → 문제점 → 개선 방향(AS-IS/TO-BE) → 현황 → 다음 단계
- 설계/계획 내용은 docs/architecture/ 문서로 분리 참조
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- 토큰 기반 CSS 체계 섹션 추가 (2층 구조, 글자 위계, 블록 작성 규칙)
- 스타일 폴더 구조 명시 (tokens/themes/base/blocks)
- 실행 원칙 추가 (direct-fit, recipe-path, fit 루프)
- Source of Truth 명시
- 설계 문서 링크 (IMPROVEMENT-PLAN, TOKENS-v1, BLOCK-RULES)
- 역할 분리 (figma_to_html_agent / design_agent)
- 향후 개선 방향을 진행 중/다음 단계로 분리
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- 목표: MDX → BEPs 매칭 → 슬라이드 자동 생성
- 핵심 축: 표현 기준 통일, 블록 역할 재정의, direct-fit/recipe 2경로화
- 6단계 진행 계획: 토큰 → slide-base 분리 → 규칙 문서 → 폴더 정리 → 블록 전환 → 파이프라인 연결
- 역할 분리: figma_to_html_agent(원재료) / design_agent(조립 시스템)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- 현재 프로세스(AS-IS) 7단계 정리
- 개선 프로세스(TO-BE) 5단계 정리
- 핵심 차이: 꼭지 추출 시점, redesign 반복 조정, 빈 공간 재분배, 시각 검증
- 프로젝트 구조/산출물/향후 방향 포함
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
figma_to_html_agent/:
- Figma MCP 기반 블록 추출 에이전트 (CLAUDE.md, PLAN.md, PROCESS.md 등)
- block-tests/: Figma→HTML 변환 결과물 (bim-3roles-cards 등)
- templates_staging/: Jinja2 템플릿 + meta.yaml + example.yaml
- figma-analysis/, figma-assets/: Figma 분석 데이터 + 에셋
- scripts/: gradient_math.py 등 유틸리티
설정:
- .mcp.json: Figma MCP 서버 연결 설정
- .claude/settings.json: Claude Code 프로젝트 설정
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- 루트의 IMPROVEMENT-PHASE-*.md, PHASE-*.md 등 45개 → docs/history/로 이동
- docs/block-tests/ 오래된 블록 테스트 HTML 삭제 (figma_to_html_agent로 대체)
- docs/figma-analysis/, docs/figma-assets/, docs/figma-screenshots/ 정리
- docs/test-*.html 등 초기 테스트 파일 정리
- 참고 페이지/ 스크린샷 정리
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
파이프라인 현황 문서 신규 작성:
- Stage 0~4 전체 흐름, Type A/B/B'/B'' 구분, MDX↔유형 매핑
- 단계별 파일/함수 맵, 데이터 흐름, 현재 구현 상태
- ARCHITECTURE_OVERVIEW.md는 3/27 스냅샷으로 archived 처리
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- hero-icon-cards_1.html: hero-icon-cards 변형 (icon → 소제목+불릿 계층)
- compare-detail-gradient.html: 하단 2열 비교 블록 (Figma Frame 4 기반)
- 오답노트.md: 절대 하지 말아야 하는 실수 목록
- figma_to_html.py: Figma→HTML 변환 스크립트
- static/figma-assets/: Figma export 이미지 (배지, 화살표)
- 주의: compare-detail-gradient CSS 폰트 크기가 임의 수정됨 — 원본 복원 필요
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- block_assembler_b2.py: B'' 전용 조립 함수 (별도 파일)
- 상단: 색상 바 제목 + 소제목(accent 색상) + 불릿(들여쓰기)
- 하단: 색상 바 제목 + 표(있으면) + 불릿
- border/gradient 박스 없음, 여백과 폰트로 구분
- 이제부터 스타일 세부 조정은 하나씩 반영 예정
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- block_assembler B': 카드 div에 flex:1 추가 → 가로 균등 높이/폭
- block_assembler: [핵심요약:] 이후 라인 break → 결론 텍스트가 하단에 섞이는 문제 해결
- 남은 문제: 하단 좌 콘텐츠 잘림, 상단 자연(여건) 불릿 잘림
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- block_assembler B': 카드 3개 이상 + 이미지 없음 → 가로(row) 배치
- block_assembler B': section title이 카드 제목, D1은 카드 내 bold 불릿
- block_assembler: overflow:auto → overflow:hidden, [핵심요약:] 마커 필터
- block_assembler: \x01 바이트 수정
- pipeline: Selenium 실측 기반 zone 간 재배분 (allocated-scrollHeight로 slack 계산)
- pipeline: surplus 최대 50%만 이전 (하단 최소 공간 보장)
- pipeline: bottom_left/bottom_right → Selenium bottom zone 매핑
- kei_client: 상단은 팝업 대상 제외, 하단에서만 팝업 분리
결과: 02번/03번 모두 overflow 없이 정상 출력
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- build_escalation_report 결과에 Selenium overflow px 정보 추가
- Kei가 실측 overflow를 인식하고 popup 결정을 내림 (7건)
- 미완: Kei popup 결정이 상단/하단좌 조립에 미반영 + 결정 과격 (전부 팝업)
- 다음: popup 결정 조립 반영 + Kei 가이드 개선 (일부만 팝업, 핵심은 유지)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- pipeline: filled→측정→Kei 재판단→재조립 루프 (최대 3회)
- pipeline: Selenium overflow가 있으면 calculate_fit과 무관하게 에스컬레이션
- 문제: build_escalation_report가 Selenium 측정 결과를 포함하지 않아 Kei가 빈 결정 반환
- 다음: content family 기반 범용 파이프라인 설계 필요 (Phase X-C)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- block_assembler + assemble_stage2: 기존 [이미지:] 패턴에 ![markdown image 패턴 추가
- 02번 상단 "소통과 신뢰" 카드에 이미지 경로가 불릿으로 표시되던 문제 해결
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- slide_measurer: data URI → 임시파일 방식 (대용량 HTML 측정 가능)
- pipeline: Type B zone 간 재배분 (top↔bottom 공간 이전)
- pipeline: overflow 분기에 top/bottom zone 추가
- kei_client: 에스컬레이션 prompt 개선
- 텍스트 원문 보존 원칙 명시 (삭제/요약/압축 금지)
- action을 popup만으로 제한
- 실제 역할명 목록을 prompt에 전달
- block_assembler: Kei popup 결정 반영 (해당 역할 콘텐츠 → 팝업 링크)
결과: 02번 상단 카드 3개 모두 표시, 하단 우측 표 → 팝업 분리
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Selenium 측정 실패 (data URI 크기 제한)
- overflow 분기에 Type B zone 없음
- calculate_fit에서 Type B 역할 인식 불가
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- XBX-1: normalizer 불릿 depth 보존 (D1/D2 마커) + 조립 로직 계층 반영
- XBX-3: 하단 구조 개선 — 하나의 큰 박스 안에 중제목 헤더 + 세로 구분선 2분할
- XBX-5: before→filled→after 파이프라인 연결 확인 (filled 2.2MB, 측정/재배분 정상)
- XBX-6: Type B에서 Sonnet 재구성 + renderer 스킵 — code_assembled 직접 사용
- final.html: 4,934 bytes → 2.2MB (Type B 정상 출력)
- Type A 코드 한 글자도 안 건드림
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- PHASE-X-BX.md: 유형 B 미완료 6개 task 수행 방향 상세 (02번 먼저 → 03번 확장)
- PHASE-X-C.md: 서브존 프리셋 기반 범용 레이아웃 방향
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- block_assembler: _assemble_slide_html_type_b 추가 (filled/after용 HTML 생성)
- fit_verifier: redistribute()가 ROLE_ZONE_MAP 대신 containers zone 사용
- renderer: render_slide_from_html()에 zone 기반 높이 탐색 추가
- pipeline: 팝업 HTML CSS를 콘텐츠 유형별(table/list/text) 분기
- run_from_stage1b: MDX 파일 하드코딩 제거 + layout_template 전달 추가
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
03번 하단 구조:
- 좌(2.1): 3개 소주제(Digital화+표, GIS+BIM, Solution) 각각 불릿 있음
- 우(2.2): 3개 소주제(품질향상, 정보물추가, 효율화) 각각 불릿 있음
- 결론: 원본 그대로
문제: _assemble_type_b가 내용을 제대로 조립 못 함
다음 세션: 하단 좌/우 내용 정확히 조립 + 렌더링 확인
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- _assemble_type_b: 상단에 해당하는 모든 level=2 section을 합침
(03번처럼 기술/사람/자연이 별도 section으로 분리된 경우 대응)
- 하단 대목차: level=3 바로 앞의 level=2 section으로 정확히 찾기
- 03번 결과: 상단 카드(기술/사람/자연) + 하단(과정혁신/결과변화) 정상
- 02번 영향 없음
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
현재 상태:
- 유형 A: ✅ 동작
- 유형 B: code_assembled만 동작, 파이프라인(filled/after) 미연결
- 핵심 문제: block_assembler가 고정 4역할만 처리 → 유형 B 지원 필요
다음 세션:
1. block_assembler 유형 B 지원
2. 컨테이너 크기 맞춤 (Selenium 측정 기반)
3. 유형 A 깨지지 않는지 확인
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
핵심 변경:
- mdx_normalizer: ### (h3) 소목차도 section으로 분리 (기존 ## 만)
- _assemble_type_b: Kei structured_text 대신 normalized.sections에서 직접 텍스트
- 대목차/소목차 계층 구조 그대로 반영
결과:
- 슬라이드 제목: 원본 MDX frontmatter 그대로
- 대목차: "DX 기반 Process 혁신에 따른 주체별 기대효과"
- 소목차 좌: "업무 수행 과정(Process)의 변화"
- 소목차 우: "DX 시행 주체별 기대효과" + 팝업 링크 + Kei 요약 표
- 캡션: normalized.images alt text
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
X-B-3~5 완료:
- space_allocator: build_containers_type_b() 추가
- assemble_stage2: _assemble_type_b() 추가 (소제목 카드형)
- pipeline.py: layout_template 분기 (A/B)
- pipeline_context: Analysis.layout_template 필드
- validators: 유형 B 검증 완화
텍스트 보존 강화:
- KEI_PROMPT: 제목 원본 그대로, 텍스트 재작성 금지
- KEI_STRUCTURED_TEXT_PROMPT: 소제목 유지, 원본 문장 그대로
원본 MDX 복구:
- samples/mdx_batch/02.mdx: 표 데이터 누락 수정 (원본에서 재복사)
미해결 (다음 세션):
- 들여쓰기: 대제목→중제목→소제목→본문 계층 구조
- 이미지 캡션: [그림 제목] 형식 (대괄호 포함)
- 상단 컨테이너: 빈칸 위로 붙이기
- 카드 디자인: 안전과품질/생산성향상/소통과신뢰 디자인 개선
- 제목: Kei가 원본 제목 바꾸는 문제 잔존
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
X-B-1: KEI_PROMPT에 유형 B 옵션 추가
- 유형 A: 기존 배경/본심/첨부/결론 (참조자료 있는 콘텐츠)
- 유형 B: 본심1(상단)+본심2(하단2분할)+결론 (본문만으로 구성)
- Kei가 콘텐츠 보고 A/B 선택, layout_template 필드로 반환
- 검증: 01번→A, 02번→B 정확히 선택
X-B-2: 검증기 완화
- 유형 A: 본심 필수 유지
- 유형 B: 결론(footer)만 필수, 자유 역할명 허용
- 섹션 수 차이 허용 확대 (유형 B: 4)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- V'-2: 표 공간 계산에 V'-4(결론 위까지 채움) 높이 반영
→ Kei에게 정확한 행 수 전달 (1행 → 5행)
- V'-2: 이미지 높이를 실제 비율로 계산 (sub_layout 고정값 대신)
→ 200/2.73 = 73px (기존 172px → 공간 100px 확보)
- footer 최소 높이: design tokens 기반 동적 계산
→ weight 0.05일 때 26px → 53px 보장
- assemble_stage2: 이미지 높이도 실제 비율 반영
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
폰트 위계 적용:
- key-msg: 11→14px (가장 중요, 가장 큰 폰트)
- core: 12px 유지
- bg: 11px/9-10px 유지
- sidebar: 제목 14→11px, 불릿 12→10px (가장 덜 중요, 가장 작은 폰트)
불릿 충돌 수정:
- BG/SIDEBAR: <style> 블록 금지, 인라인 style만 사용
- CORE의 .bp::before CSS가 BG의 .bp에 적용되는 문제 해결
pipeline.py 통합:
- generate_slide_html() → generate_with_retry() 교체
- step2b_verification.json 저장 추가
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>