fix: Update LLMMetadataExtractor to not modify documents in place#9553
fix: Update LLMMetadataExtractor to not modify documents in place#9553
LLMMetadataExtractor to not modify documents in place#9553Conversation
…n after adding new metadata to docs
Pull Request Test Coverage Report for Build 15925816077Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
julian-risch
left a comment
There was a problem hiding this comment.
I'd like to better understand the issue and where distinguishing the parent documents and the new documents is a problem right now. As an alternative we could consider creating a new id only if the content changes, which is not the case here.
LLMMetadataExtractor to return documents with new IDs based on newly added metadataLLMMetadataExtractor to not modify documents in place
|
@julian-risch I don't think there is much utility in merging this PR anymore, but perhaps serve as a proposal for #9505 So if there are no objections, I'll go ahead and close this PR and update the issue with this proposal |
|
Closing following up on this comment #9553 (comment) |
Related Issues
Proposed Changes:
Update
LLMMetadataExtractorto not modify Document objects in place.I've opted to use the
replacefunction fromdataclassesto do this since it does create a new dataclass object and doesn't modify the old one in place.How did you test it?
Notes for the reviewer
Checklist
fix:,feat:,build:,chore:,ci:,docs:,style:,refactor:,perf:,test:and added!in case the PR includes breaking changes.