mirror of
https://git.mirrors.martin98.com/https://github.com/mendableai/firecrawl
synced 2025-08-06 00:06:10 +08:00
fix(extraction-service): allow no multiEntityKeys if isMultiEntity is false
This commit is contained in:
parent
0dddf4c055
commit
4db9a4a675
@ -77,10 +77,10 @@ async function analyzeSchemaAndPrompt(
|
||||
|
||||
const checkSchema = z.object({
|
||||
isMultiEntity: z.boolean(),
|
||||
multiEntityKeys: z.array(z.string()),
|
||||
multiEntityKeys: z.array(z.string()).optional().default([]),
|
||||
reasoning: z.string(),
|
||||
keyIndicators: z.array(z.string()),
|
||||
});
|
||||
}).refine(x => !x.isMultiEntity || multiEntityKeys.length > 0, "isMultiEntity was true, but no multiEntityKeys were returned");
|
||||
|
||||
const model = "gpt-4o";
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user