落地多段联运私聊:齐了才建单拉群,附件只收格子值,核对改正不再整单重开。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-09-23 15:08:15 +08:00
co-authored by Cursor
parent 6e3e09a316
commit 2334524bb8
30 changed files with 4033 additions and 40 deletions
+9 -2
View File
@@ -54,8 +54,15 @@ def harvest_sea_class(text: str, current: dict[str, str] | None = None) -> dict[
kept = canonicalize_sea_class(str(merged.get("运输分类") or ""))
if kept:
merged["运输分类"] = kept
else:
merged.pop("运输分类", None)
return merged
from agent.schema.land_options import canonicalize_land_class
# 多段陆运补「急件」时,不能按海运名单把已收的陆运分类清掉。
land_kept = canonicalize_land_class(str(merged.get("运输分类") or ""))
if land_kept:
merged["运输分类"] = land_kept
return merged
merged.pop("运输分类", None)
return merged