fix: troca chatLog.success inexistente por chatLog.info
chatLog não tem success: a chamada lançava TypeError dentro do try, e analyzeQueryContext e enrichQueries sempre descartavam a resposta do modelo e caíam no fallback heurístico.
This commit is contained in:
1 parent
94941414e9
commit
7247e1e80b
2 files changed
+2
-2
No files matched your search
@@ -206,7 +206,7 @@ export async function analyzeQueryContext(
|
|||||||
complexity: analysis.complexity || 'moderate',
|
complexity: analysis.complexity || 'moderate',
|
||||||
};
|
};
|
||||||
|
|
||||||
chatLog.success(`[ContextualAnalysis] Contexto extraído: ${context.intent}, ${context.entities.length} entidades, ${context.topics.length} tópicos`);
|
chatLog.info(`[ContextualAnalysis] Contexto extraído: ${context.intent}, ${context.entities.length} entidades, ${context.topics.length} tópicos`);
|
||||||
|
|
||||||
return context;
|
return context;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|||||||
@@ -176,7 +176,7 @@ export async function enrichQueries(
|
|||||||
result.expanded.length +
|
result.expanded.length +
|
||||||
result.contextual.length;
|
result.contextual.length;
|
||||||
|
|
||||||
chatLog.success(
|
chatLog.info(
|
||||||
`[QueryEnricher] ${totalQueries} queries geradas: ` +
|
`[QueryEnricher] ${totalQueries} queries geradas: ` +
|
||||||
`${result.literal.length} literal, ${result.semantic.length} semântica, ` +
|
`${result.literal.length} literal, ${result.semantic.length} semântica, ` +
|
||||||
`${result.related.length} relacionadas, ${result.expanded.length} expandidas, ` +
|
`${result.related.length} relacionadas, ${result.expanded.length} expandidas, ` +
|
||||||
|
|||||||
Reference in new issue
Block a user