打印来源

This commit is contained in:
2026-01-11 16:12:54 +08:00
parent df1279633e
commit 165b5788d2

View File

@@ -142,7 +142,7 @@ def main():
for i, doc in enumerate(docs, 1):
print(f"[{i}] {doc.metadata.get('title', 'N/A')}")
# print(f" 来源: {doc.metadata.get('source_file', 'N/A')}")
print(f" 来源: {doc.metadata.get('source_file', 'N/A')}")
# print(f" 内容预览: {doc.page_content[:200]}...")
print()