From 7786316ef548a98276910a8a3d03b72f74a2ac31 Mon Sep 17 00:00:00 2001 From: umsangdon Date: Fri, 18 Sep 2026 14:09:48 +0900 Subject: [PATCH] =?UTF-8?q?feat(b08):=20=EC=A1=B0=EA=B1=B4=EB=B3=84=20?= =?UTF-8?q?=EA=B3=84=EC=88=98=ED=91=9C=20=EC=9E=A3=EB=8C=80=20=E2=80=94=20?= =?UTF-8?q?=EA=B1=B4=EC=84=A4=20=ED=98=95=ED=83=9C=20=EB=AF=B8=ED=8C=90?= =?UTF-8?q?=EC=A0=95=20175=20=E2=86=92=20168?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 「현장조건·토질명」으로 갈리고 값이 모두 1 이하면 **작업효율·계수표**로 봄(8-2-1 도자 E 꼴) - ⚠ 산림 미판정 0 그대로 · 밑수 셈 변화 없음(확보 713 · 미확보 438) - 전체 시험 2,442 통과 Co-Authored-By: Claude Opus 5 (1M context) Claude-Session: https://claude.ai/code/session_01BW6Jdsh18WPtYUR6THZJqn --- ...uantity_Build_WorkItemMaster_FormsConst.py | 14 +- .../data_master_labels/labels_2026-01-01.json | 2 +- .../data_work_item_master/_manifest.json | 4 +- .../_manifest_const.json | 10 +- .../const_form_undetermined_2026-01-01.json | 189 ------------------ .../const_work_item_master_2026-01-01.json | 34 ++-- .../work_item_master_2026-01-01.json | 2 +- 7 files changed, 39 insertions(+), 216 deletions(-) diff --git a/B08_Quantity/B08_Quantity_Build_WorkItemMaster_FormsConst.py b/B08_Quantity/B08_Quantity_Build_WorkItemMaster_FormsConst.py index 89d67cde..5c4fa817 100644 --- a/B08_Quantity/B08_Quantity_Build_WorkItemMaster_FormsConst.py +++ b/B08_Quantity/B08_Quantity_Build_WorkItemMaster_FormsConst.py @@ -178,7 +178,17 @@ def judged_const_form(table: dict[str, Any], _twice: bool = False) -> tuple[str, if sum(1 for h in headers if _COMPACT_RE.search(h)) >= 2: return "reference", "다짐 두께·횟수 기준표 — 시방 기준" - # ⑯ 머리가 두 단인 표 — **위 단을 버리지 않고 아래 단을 머리에 더해** 한 번 더 본다. + # ⑯ 조건별 계수 — 「현장조건·토질명」으로 갈리고 값이 모두 1 이하면 **효율·계수**다(8-2-1 도자 E) + if any(_CONDITION_RE.search(x) for x in headers + first_col): + nums = [ + float(_squeeze(c).replace(",", "")) + for c in _value_cells(table) + if _NUMBER_RE.match(_squeeze(c)) + ] + if nums and all(0 < n <= 1 for n in nums): + return "coefficient", "현장조건별 값이 모두 1 이하 — 작업효율·계수표" + + # ⑰ 머리가 두 단인 표 — **위 단을 버리지 않고 아래 단을 머리에 더해** 한 번 더 본다. # ⚠ 평탄화가 아니다(위 단에 밑수·갈래가 든다) · 한 번만 되본다(두 단이 셋이 되진 않는다). if not _twice and (sub := _sub_header_row(table)): merged = { @@ -198,6 +208,8 @@ _FORMULA_HEAD_RE = re.compile(r"[A-Za-zα-ωΑ-Ω][₀-₉0-9]?(?:\([^)]{1,4}\)) _TIME_ROW_RE = re.compile(r"시간\(|\(분\)|사이클|주기\(") #: 줄 이름이 자재 쓰는 양. _AMOUNT_ROW_RE = re.compile(r"사용량|소요량|사용수량") +#: 조건별 계수표 머리 — 「현장조건」·「작업조건」·「토질명」으로 갈리고 값이 1 이하인 표(작업효율 E). +_CONDITION_RE = re.compile(r"현장조건|작업조건|토질명|토질별작업|시공조건") #: 다짐 기준표 머리 — 두께·횟수·규격을 정한 시방 기준. _COMPACT_RE = re.compile(r"다짐두께|다짐횟수|다짐기계|다짐") diff --git a/resources/data_master_labels/labels_2026-01-01.json b/resources/data_master_labels/labels_2026-01-01.json index 0ff13ee0..4ba5bb72 100644 --- a/resources/data_master_labels/labels_2026-01-01.json +++ b/resources/data_master_labels/labels_2026-01-01.json @@ -7267,7 +7267,7 @@ "name_ko": "형태 미판정 표", "summary": "생산량형인지 소요량형인지 못 정한 표.", "shape": "list", - "rows": 175, + "rows": 168, "columns": [ { "key": "pum_table_id", diff --git a/resources/data_work_item_master/_manifest.json b/resources/data_work_item_master/_manifest.json index 3c32af32..23a6fddd 100644 --- a/resources/data_work_item_master/_manifest.json +++ b/resources/data_work_item_master/_manifest.json @@ -1,7 +1,7 @@ { "schema_version": "1.0", "dataset_id": "data_work_item_master_manifest", - "generated_at": "2026-09-18T13:27:21+09:00", + "generated_at": "2026-09-18T13:50:23+09:00", "built_by": "B08_Quantity/B08_Quantity_Build_WorkItemMaster.py", "source": { "dataset_id": "pum_forest", @@ -12,7 +12,7 @@ "files": [ { "file": "work_item_master_2026-01-01.json", - "sha256": "170b13a97e07bec53f1ba361a8b89664b3c1d0330598ca69ae88debe94d3825b", + "sha256": "2ad038b11e121ae8f211a8cbad97b8da7e75623b5551e443816d00c6a4882072", "size_bytes": 1095122 }, { diff --git a/resources/data_work_item_master/_manifest_const.json b/resources/data_work_item_master/_manifest_const.json index 454062dc..c26c0942 100644 --- a/resources/data_work_item_master/_manifest_const.json +++ b/resources/data_work_item_master/_manifest_const.json @@ -1,7 +1,7 @@ { "schema_version": "1.0", "dataset_id": "data_work_item_master_manifest", - "generated_at": "2026-09-18T13:28:12+09:00", + "generated_at": "2026-09-18T13:51:14+09:00", "built_by": "B08_Quantity/B08_Quantity_Build_WorkItemMaster.py", "source": { "dataset_id": "pum_const", @@ -12,13 +12,13 @@ "files": [ { "file": "const_work_item_master_2026-01-01.json", - "sha256": "f2e53cf68ea6d051d02aefea798d9da380d893a99b6502885bba3678b5c68616", - "size_bytes": 4718431 + "sha256": "e79e3fb7311a13c60e2147a1a63135cc7af91faac385cedad54c957a2b9e8694", + "size_bytes": 4718189 }, { "file": "const_form_undetermined_2026-01-01.json", - "sha256": "16745ba1e2da669dc43febb2dcbc4c52acce7c146debb1ad72dd5cb6216ca81d", - "size_bytes": 104333 + "sha256": "c26b4dffb66b2a352356ec4e9a90607184297e4927a545a31c141370ba8334fc", + "size_bytes": 100578 }, { "file": "const_basis_missing_2026-01-01.json", diff --git a/resources/data_work_item_master/const_form_undetermined_2026-01-01.json b/resources/data_work_item_master/const_form_undetermined_2026-01-01.json index fad17050..8ee7202c 100644 --- a/resources/data_work_item_master/const_form_undetermined_2026-01-01.json +++ b/resources/data_work_item_master/const_form_undetermined_2026-01-01.json @@ -507,36 +507,6 @@ ], "reason": "단위·밑수·직종 표지 없음 · 값은 있는데 표지가 없음 — 사람이 봐야 함" }, - { - "pum_table_id": "C0425", - "section": "8-2-1 불도저", - "headers": [ - "현장조건 토질명", - "자연상태", - "흐트러진 상태" - ], - "first_rows": [ - [ - "", - "양 호", - "보 통", - "불 량", - "양 호", - "보 통", - "불 량" - ], - [ - "모 래 , 사 질 토", - "0.80", - "0.65", - "0.50", - "0.85", - "0.70", - "0.55" - ] - ], - "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" - }, { "pum_table_id": "C0426", "section": "8-2-1 불도저", @@ -620,57 +590,6 @@ ], "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" }, - { - "pum_table_id": "C0432", - "section": "8-2-3 굴착기", - "headers": [ - "현장조건 토질명", - "자연상태", - "흐트러진 상태" - ], - "first_rows": [ - [ - "", - "양 호", - "보 통", - "불 량", - "양 호", - "보 통", - "불 량" - ], - [ - "모 래 , 사 질 토", - "0.85", - "0.70", - "0.55", - "0.90", - "0.75", - "0.60" - ] - ], - "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" - }, - { - "pum_table_id": "C0433", - "section": "8-2-3 굴착기", - "headers": [ - "현장조건 토질명", - "자연상태" - ], - "first_rows": [ - [ - "", - "보통", - "불량" - ], - [ - "모 래 , 사 질 토", - "0.30", - "0.19" - ] - ], - "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" - }, { "pum_table_id": "C0436", "section": "8-2-4 트랜처", @@ -722,36 +641,6 @@ ], "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" }, - { - "pum_table_id": "C0440", - "section": "8-2-5 로더", - "headers": [ - "현장조건 토질명", - "자연상태", - "흐트러진 상태" - ], - "first_rows": [ - [ - "", - "양 호", - "보 통", - "불 량", - "양 호", - "보 통", - "불 량" - ], - [ - "모 래 , 사 질 토", - "0.70", - "0.55", - "0.40", - "0.75", - "0.60", - "0.45" - ] - ], - "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" - }, { "pum_table_id": "C0442", "section": "8-2-6 모터 스크레이퍼", @@ -833,29 +722,6 @@ ], "reason": "단위·밑수·직종 표지 없음 · 값은 있는데 표지가 없음 — 사람이 봐야 함" }, - { - "pum_table_id": "C0446", - "section": "8-2-7 모터 그레이더", - "headers": [ - "작업종류", - "현장조건" - ], - "first_rows": [ - [ - "", - "양호", - "보통", - "불량" - ], - [ - "토사도의 보수 및 정지 등", - "0.8", - "0.7", - "0.6" - ] - ], - "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" - }, { "pum_table_id": "C0448", "section": "8-2-8 덤프트럭", @@ -879,33 +745,6 @@ ], "reason": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음" }, - { - "pum_table_id": "C0455", - "section": "8-2-9 롤러", - "headers": [ - "현장조건 공종 다짐기계", - "양호", - "보통", - "불량" - ], - "first_rows": [ - [ - "표 층", - "머 캐 덤 롤 러", - "0.75", - "0.55", - "0.35" - ], - [ - "", - "타 이 어 롤 러", - "0.65", - "0.45", - "0.25" - ] - ], - "reason": "단위·밑수·직종 표지 없음 · 값은 있는데 표지가 없음 — 사람이 봐야 함" - }, { "pum_table_id": "C0457", "section": "8-2-12 크러셔", @@ -1358,34 +1197,6 @@ ], "reason": "단위·밑수·직종 표지 없음 · 값이 규격·치수뿐 — 원문이 품을 안 적음(할 일 아님)" }, - { - "pum_table_id": "C0477", - "section": "8-2-18 콘크리트 배치플랜트(강제 혼합식)", - "headers": [ - "공 종 현장조건", - "도로포장", - "교 량", - "터 널", - "사 방" - ], - "first_rows": [ - [ - "양 호", - "0.90", - "0.50", - "0.75", - "0.85" - ], - [ - "보 통", - "0.70", - "0.45", - "0.65", - "0.75" - ] - ], - "reason": "단위·밑수·직종 표지 없음 · 값은 있는데 표지가 없음 — 사람이 봐야 함" - }, { "pum_table_id": "C0482", "section": "8-2-22 디젤 파일 해머", diff --git a/resources/data_work_item_master/const_work_item_master_2026-01-01.json b/resources/data_work_item_master/const_work_item_master_2026-01-01.json index 0f0099cc..5c724957 100644 --- a/resources/data_work_item_master/const_work_item_master_2026-01-01.json +++ b/resources/data_work_item_master/const_work_item_master_2026-01-01.json @@ -4,7 +4,7 @@ "effective_date": "2026-01-01", "pum_edition": "2026-01-01", "toc_edition": "2026-01-01", - "generated_at": "2026-09-18T13:28:12+09:00", + "generated_at": "2026-09-18T13:51:14+09:00", "dataset_version": { "dataset_id": "pum_const", "effective_date": "2026-01-01", @@ -38,7 +38,7 @@ "tables_total": 2273, "tables_attached": 2273, "tables_orphan": 0, - "form_undetermined": 175, + "form_undetermined": 168, "basis_found": 713, "basis_missing": 438, "basis_absent_in_source": 436, @@ -32710,8 +32710,8 @@ "pum_table_id": "C0425", "section": "8-2-1 불도저", "source_line": 138, - "pum_form": "undetermined", - "form_basis": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음", + "pum_form": "coefficient", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, @@ -33264,8 +33264,8 @@ "pum_table_id": "C0432", "section": "8-2-3 굴착기", "source_line": 243, - "pum_form": "undetermined", - "form_basis": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음", + "pum_form": "coefficient", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, @@ -33335,8 +33335,8 @@ "pum_table_id": "C0433", "section": "8-2-3 굴착기", "source_line": 262, - "pum_form": "undetermined", - "form_basis": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음", + "pum_form": "coefficient", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, @@ -33708,8 +33708,8 @@ "pum_table_id": "C0440", "section": "8-2-5 로더", "source_line": 340, - "pum_form": "undetermined", - "form_basis": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음", + "pum_form": "coefficient", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, @@ -34141,8 +34141,8 @@ "pum_table_id": "C0446", "section": "8-2-7 모터 그레이더", "source_line": 431, - "pum_form": "undetermined", - "form_basis": "단위·밑수·직종 표지 없음 · 머리 두 단 · 값 있음 — 아래 단을 이어 봐도 표지가 없음", + "pum_form": "coefficient", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, @@ -34832,8 +34832,8 @@ "pum_table_id": "C0455", "section": "8-2-9 롤러", "source_line": 557, - "pum_form": "undetermined", - "form_basis": "단위·밑수·직종 표지 없음 · 값은 있는데 표지가 없음 — 사람이 봐야 함", + "pum_form": "coefficient", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, @@ -37519,8 +37519,8 @@ "pum_table_id": "C0477", "section": "8-2-18 콘크리트 배치플랜트(강제 혼합식)", "source_line": 925, - "pum_form": "undetermined", - "form_basis": "단위·밑수·직종 표지 없음 · 값은 있는데 표지가 없음 — 사람이 봐야 함", + "pum_form": "coefficient", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, @@ -37982,7 +37982,7 @@ "section": "8-2-22 디젤 파일 해머", "source_line": 1020, "pum_form": "coefficient", - "form_basis": "건설 꼴 — 머리 두 단을 이어 보니 — 머리가 공식 기호 'F' — 시공능력 밑값", + "form_basis": "건설 꼴 — 현장조건별 값이 모두 1 이하 — 작업효율·계수표", "basis_quantity": null, "basis_unit": null, "basis_source": null, diff --git a/resources/data_work_item_master/work_item_master_2026-01-01.json b/resources/data_work_item_master/work_item_master_2026-01-01.json index d6dc99ed..816a5faf 100644 --- a/resources/data_work_item_master/work_item_master_2026-01-01.json +++ b/resources/data_work_item_master/work_item_master_2026-01-01.json @@ -4,7 +4,7 @@ "effective_date": "2026-01-01", "pum_edition": "2026-01-01", "toc_edition": "산림청고시제2025-82호", - "generated_at": "2026-09-18T13:27:21+09:00", + "generated_at": "2026-09-18T13:50:23+09:00", "dataset_version": { "dataset_id": "pum_forest", "effective_date": "2026-01-01",