[Feature Request]: Multiple schema for LLM extraction. #1453
Replies: 1 comment
-
| I do not think this would be beneficial as an array. This would lead to the model being confused, just give it one schema with all the schemas combined would be better for this and he can leave empty what he does not use. Now a solution where we give an array of schemas, and a lesser model or maybe rules based on our schema array chooses the best one for a given url may be a better approach for usability. This would allow for multi url crawls which changes extraction based on content in it. The general big schema to target general data is most likely a way better solution unless the schema grows too large. The general big schema has no downsize other than size and this would only really matter for llm. So its either change all extractions schemas to allow multiple and somehow choose the best one or for which is the only one who matters Llm singularly does this instead of all. Ps: I was replying to this guy, and I just was thinking what would be the best case for this. | 
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
What needs to be done?
Allow array input for the schema field we have in LLMExtractionStrategy.
schema=[Products.model_json_schema(),Information.model_json_schema()]What problem does this solve?
Allowing different schema output
Target users/beneficiaries
Developers
Current alternatives/workarounds
I have to use the UNION type in Python to do it.
Proposed approach
schema=[Products.model_json_schema(),Information.model_json_schema()]Beta Was this translation helpful? Give feedback.
All reactions