feat(metadata): enhance document processing to include metadata extraction and handling

- Updated DocReaderServicer to pass metadata in responses.
- Modified PipelineParser to accumulate and merge metadata from all parsers.
- Enhanced StdWebParser to extract and log the title from web page content.
- Implemented logic in knowledge service to update knowledge title based on extracted metadata.
This commit is contained in:
wizardchen
2026-04-01 14:35:31 +08:00
committed by lyingbug
parent ce7df624fb
commit c4f5db7e88
4 changed files with 32 additions and 4 deletions
+1
View File
@@ -151,6 +151,7 @@ class DocReaderServicer(docreader_pb2_grpc.DocReaderServicer):
markdown_content=_c(result.content),
image_refs=image_refs,
image_dir_path=image_dir,
metadata={k: _c(str(v)) for k, v in result.metadata.items()} if result.metadata else {},
)
logger.info(
"Read response: content_len=%d, images=%d",