mirror of
https://github.com/labring/FastGPT.git
synced 2025-10-16 08:01:18 +00:00
fix: child usage remove (#5698)
* fix: child usage remove * remove runloop empty usage
This commit is contained in:
@@ -61,6 +61,7 @@ export const dispatchAppRequest = async (props: Props): Promise<Response> => {
|
||||
|
||||
const { flowResponses, flowUsages, assistantResponses, system_memories } = await runWorkflow({
|
||||
...props,
|
||||
usageId: undefined,
|
||||
runningAppInfo: {
|
||||
id: String(appData._id),
|
||||
name: appData.name,
|
||||
|
@@ -112,6 +112,7 @@ export const runToolCall = async (
|
||||
// Run entry tool
|
||||
const toolRunResponse = await runWorkflow({
|
||||
...workflowProps,
|
||||
usageId: undefined,
|
||||
isToolCall: true
|
||||
});
|
||||
const stringToolResponse = formatToolResponse(toolRunResponse.toolResponses);
|
||||
|
@@ -134,6 +134,7 @@ export const dispatchRunAppNode = async (props: Props): Promise<Response> => {
|
||||
system_memories
|
||||
} = await runWorkflow({
|
||||
...props,
|
||||
usageId: undefined,
|
||||
lastInteractive: childrenInteractive,
|
||||
// Rewrite stream mode
|
||||
...(system_forbid_stream
|
||||
|
@@ -95,6 +95,7 @@ export const dispatchLoop = async (props: Props): Promise<Response> => {
|
||||
|
||||
const response = await runWorkflow({
|
||||
...props,
|
||||
usageId: undefined,
|
||||
lastInteractive: interactiveData?.childrenResponse,
|
||||
variables: newVariables,
|
||||
runtimeNodes,
|
||||
@@ -150,12 +151,14 @@ export const dispatchLoop = async (props: Props): Promise<Response> => {
|
||||
loopDetail: loopResponseDetail,
|
||||
mergeSignId: props.node.nodeId
|
||||
},
|
||||
[DispatchNodeResponseKeyEnum.nodeDispatchUsages]: [
|
||||
{
|
||||
totalPoints,
|
||||
moduleName: name
|
||||
}
|
||||
],
|
||||
[DispatchNodeResponseKeyEnum.nodeDispatchUsages]: totalPoints
|
||||
? [
|
||||
{
|
||||
totalPoints,
|
||||
moduleName: name
|
||||
}
|
||||
]
|
||||
: [],
|
||||
[DispatchNodeResponseKeyEnum.newVariables]: newVariables
|
||||
};
|
||||
};
|
||||
|
@@ -120,6 +120,7 @@ export const dispatchRunPlugin = async (props: RunPluginProps): Promise<RunPlugi
|
||||
const { flowResponses, flowUsages, assistantResponses, runTimes, system_memories } =
|
||||
await runWorkflow({
|
||||
...props,
|
||||
usageId: undefined,
|
||||
// Rewrite stream mode
|
||||
...(system_forbid_stream
|
||||
? {
|
||||
|
Reference in New Issue
Block a user