mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-23 05:12:39 +00:00
fix: CQ module output (#445)
This commit is contained in:
@@ -121,14 +121,13 @@ const NodeCQNode = ({ data }: NodeProps<FlowModuleItemType>) => {
|
||||
|
||||
onChangeNode({
|
||||
moduleId,
|
||||
type: 'updateOutput',
|
||||
key: agentKey,
|
||||
value: outputs.concat({
|
||||
type: 'addOutput',
|
||||
value: {
|
||||
key,
|
||||
label: '',
|
||||
type: FlowNodeOutputTypeEnum.hidden,
|
||||
targets: []
|
||||
})
|
||||
}
|
||||
});
|
||||
}}
|
||||
>
|
||||
|
@@ -127,6 +127,9 @@ ${systemPrompt}
|
||||
tokens: response.usage?.total_tokens || 0
|
||||
};
|
||||
} catch (error) {
|
||||
console.log(agentFunction.parameters);
|
||||
console.log(response.choices?.[0]?.message);
|
||||
|
||||
console.log('Your model may not support function_call', error);
|
||||
|
||||
return {
|
||||
|
@@ -141,6 +141,9 @@ async function functionCall({
|
||||
try {
|
||||
return JSON.parse(response.choices?.[0]?.message?.function_call?.arguments || '{}');
|
||||
} catch (error) {
|
||||
console.log(agentFunction.parameters);
|
||||
console.log(response.choices?.[0]?.message);
|
||||
console.log('Your model may not support function_call', error);
|
||||
return {};
|
||||
}
|
||||
})();
|
||||
|
Reference in New Issue
Block a user