Normalize data agent records output path
This commit is contained in:
@@ -549,6 +549,9 @@ def _dedupe_output_path(root: str, output_path: str, plan_id: str) -> str:
|
||||
from pathlib import Path
|
||||
|
||||
path = Path(output_path)
|
||||
# 会话 output 下的标准 records 文件名需要保持稳定;导出工具默认允许覆盖。
|
||||
if path.name in {'records.jsonl', 'records.json'} and 'output' in path.parts:
|
||||
return output_path
|
||||
resolved = path if path.is_absolute() else Path(root).resolve() / path
|
||||
if not resolved.exists():
|
||||
return output_path
|
||||
|
||||
Reference in New Issue
Block a user