feat(b09): ㉡-3 시간 줄 판정표 — 14-1 입목뿌리 밑막이 · 14-2 근주이식이 섬 · 막힌 셋(물푸기·모노레일·케이블크레인)은 옛 값이 왜 틀렸는지 사유
· 판정표 모양 hour_rows — 장비 h 그대로 · 인력 h ÷ 8(총칙 「일일 작업시간 8시간」) · ÷ 10본 · 원문 「0.8㎥ 굴착기」 가 형식을 안 적어 무한궤도 0201-0080 · 타이어 0211-0080 두 갈래 · 제안 없음(브레인 판정 ①) · 14-1 우드그랩 ↔ 카탈로그 부착용 집게 7206-0070(규격 0.6∼0.8) — 이름이 다름을 사유에(②) · 조합이라 본체 #조합 · 옛 14-2 11,356원은 0.66h 를 인으로 셈(8배) + 굴착기 빠짐 → 무한궤도 4,431 · 타이어 4,631원/본 · 14-1 8,603 → 3,192 · 3,316 · 막힌 셋 사유(③): 12-26 가동시간 원문 없음 · 옛 값 보통인부 1인뿐 / 10-7-4 운전 단가표 보통인부 2 는 적재·짐부리기 2인과 같은 사람 · 옛 값 두 번 센 4인 / 10-8-3 ℓ/kWh 원문 없음 · 옛 값 특별인부 1인뿐 · 마스터 재생성 — 14-1 · 14-2 갈래 키만 잴 시험 넷 빨강→초록 · 끄기 둘 빨강 · 전체 시험 1721 + 392 통과 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BW6Jdsh18WPtYUR6THZJqn
This commit is contained in:
@@ -96,7 +96,27 @@ JUDGED_TABLES: dict[str, dict[str, Any]] = {
|
||||
"same_machine": ("봉상후렉시블(45mm)",),
|
||||
"why": "원문 L6839 12-34-1 「인력 콘크리트공·보통인부 인 · 기계 대 (Q=5.4㎥/hr)」",
|
||||
},
|
||||
# 시간 줄 표 — 장비·인력이 다 「h」(2026-09-15 브레인 ㉡-3). 굴착기 형식을 원문이 안 적어 두 갈래 · 제안 없음(①).
|
||||
"F0450": {
|
||||
"code": "FP-14-01",
|
||||
"shape": "hour_rows",
|
||||
"prefix": "입목뿌리 밑막이",
|
||||
"forms": (("무한궤도", "0201-0080"), ("타이어", "0211-0080")),
|
||||
# 원문 「우드그랩 부착」 ↔ 카탈로그 「부착용 집게 0.6∼0.8」 — 이름이 다름(②).
|
||||
"attachment": "7206-0070",
|
||||
"why": "원문 L7798 14-1 「0.8㎥ 굴착기(우드그랩 부착) h · 보통인부 h」(10본당)",
|
||||
},
|
||||
"F0451": {
|
||||
"code": "FP-14-02",
|
||||
"shape": "hour_rows",
|
||||
"prefix": "근주이식",
|
||||
"forms": (("무한궤도", "0201-0080"), ("타이어", "0211-0080")),
|
||||
"why": "원문 L7809 14-2 「0.8㎥ 굴착기 h · 보통인부 h」(10본당)",
|
||||
},
|
||||
}
|
||||
#: 총칙 L530 「본 품셈에서 제시된 품은 일일 작업시간 8시간을 기준」 — 인력 시간 ÷ 8 = 인.
|
||||
HOURS_PER_DAY = Decimal(8)
|
||||
_RE_SPEC_FIRST_MACHINE = re.compile(r"^\d+(?:\.\d+)?㎥굴착기")
|
||||
#: 줄 첫 칸이 분류 딱지인 표(12-34-1 「자재 | 콘크리트(레미콘)」) — 이름은 다음 칸.
|
||||
_ROW_CATEGORIES = ("자재", "인력", "기계")
|
||||
#: 자원이 아닌 머리 줄(12-04 「횟수별 | 재료별(%) | 노무비(%)」).
|
||||
@@ -206,6 +226,8 @@ def match_judged_table(
|
||||
staged = _use_count(code, table, rows, catalog, basis_quantity, unit)
|
||||
elif judged["shape"] == "remark_labor":
|
||||
staged = _remark_labor(code, table, judged, rows, catalog)
|
||||
elif judged["shape"] == "hour_rows":
|
||||
staged = _hour_rows(code, table, judged, rows, catalog, basis_quantity)
|
||||
elif judged["shape"] == "per_m3_rows":
|
||||
staged = _per_m3_rows(code, table, judged, rows, catalog)
|
||||
else:
|
||||
@@ -370,3 +392,46 @@ def _per_m3_rows(code, table, judged, rows, catalog) -> list | str:
|
||||
amount = amount / Decimal(found_q.group(1))
|
||||
staged.append(_row(code, table, entry, amount, "㎥", index, ""))
|
||||
return staged
|
||||
|
||||
|
||||
def _hour_rows(code, table, judged, rows, catalog, basis_quantity) -> list | str:
|
||||
"""장비·인력이 다 시간인 표 — 장비 h 그대로 · 인력 h ÷ 8 · ÷ 밑수 · 굴착기 형식마다 갈래."""
|
||||
entries = {entry.code: entry for entry in catalog.entries}
|
||||
unit = str(table.get("basis_unit") or "")
|
||||
machine: tuple[int, Decimal] | None = None
|
||||
labor: list = []
|
||||
for index, cells in enumerate(rows):
|
||||
if len(cells) < 3 or "".join(cells[1].split()) != "h":
|
||||
continue
|
||||
hours = parse_amount(cells[2])
|
||||
if hours is None:
|
||||
return f"{cells[0]} 시간"
|
||||
if _RE_SPEC_FIRST_MACHINE.match("".join(cells[0].split())):
|
||||
machine = (index, hours)
|
||||
continue
|
||||
entry = _entry(catalog, cells[0], code)
|
||||
if entry is None:
|
||||
return f"{cells[0]} 줄"
|
||||
labor.append((index, entry, hours / HOURS_PER_DAY))
|
||||
if machine is None:
|
||||
return "장비 줄"
|
||||
staged: list = []
|
||||
for form, machine_code in judged["forms"]:
|
||||
codes = [machine_code, *([judged["attachment"]] if judged.get("attachment") else [])]
|
||||
if any(c not in entries for c in codes):
|
||||
return f"{form} 기종 코드"
|
||||
for machine_code_ in codes:
|
||||
staged.append(
|
||||
_row(
|
||||
code,
|
||||
table,
|
||||
entries[machine_code_],
|
||||
machine[1] / basis_quantity,
|
||||
unit,
|
||||
machine[0],
|
||||
form,
|
||||
)
|
||||
)
|
||||
for index, entry, amount in labor:
|
||||
staged.append(_row(code, table, entry, amount / basis_quantity, unit, index, form))
|
||||
return staged
|
||||
|
||||
Reference in New Issue
Block a user