fix: add all urls as the last event

This commit is contained in:
Han Xiao 2025-02-22 19:39:41 +08:00
parent cbefcb7e20
commit 5c91d5b4ad

View File

@ -799,7 +799,11 @@ But unfortunately, you failed to solve the issue. You need to think out of the b
console.log(thisStep) console.log(thisStep)
await storeContext(system, schema, [allContext, allKeywords, allQuestions, allKnowledge], totalStep); await storeContext(system, schema, [allContext, allKeywords, allQuestions, allKnowledge], totalStep);
return {result: thisStep, context, visitedURLs: [...visitedURLs, ...Object.keys(allURLs)]}; return {
result: thisStep,
context,
visitedURLs: [...new Set([...visitedURLs, ...Object.keys(allURLs)])]
};
} }