feat: 海运确认卡和补问展示十项字段

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-09-20 17:48:07 +08:00
co-authored by Cursor
parent 3a6884e27d
commit 91bde83e9b
2 changed files with 50 additions and 1 deletions
+9 -1
View File
@@ -25,6 +25,7 @@ from agent.schema.field_validate import (
)
from agent.schema.land_options import option_prompt as _land_option_prompt
from agent.schema.quote_adjust import total_price_label
from agent.schema.sea_options import sea_class_prompt
# 空运补问:与合同 8 项一致。报价日期默认当天,不进待补充。
_AIR_EXAMPLES = {
@@ -406,7 +407,10 @@ def ask_clarify(
for key, label, example in rows:
if key in missing_set:
any_missing = True
lines.append(f"{label}:(如:{example})")
if sea and key == "运输分类":
lines.append(sea_class_prompt())
else:
lines.append(f"{label}:(如:{example})")
if not any_missing:
return ""
return "\n".join(lines)
@@ -487,6 +491,8 @@ def inquiry_field_lines(
qty = (facts.get("货量") or facts.get("货物数量") or "-").strip() or "-"
load = (facts.get("整柜或拼柜") or "-").strip() or "-"
box = (facts.get("箱型箱量") or "-").strip() or "-"
trade = (facts.get("贸易条款") or "-").strip() or "-"
klass = (facts.get("运输分类") or "-").strip() or "-"
return [
f"工单号:{work_order_no}",
f"运输方式:{transport_mode}",
@@ -496,6 +502,8 @@ def inquiry_field_lines(
f"货物数量:{qty}",
f"整柜或拼柜:{load}",
f"箱型箱量:{box}",
f"贸易条款:{trade}",
f"运输分类:{klass}",
f"报价日期:{quote_date}",
]
if (transport_mode or "").strip() == "陆运":