diff --git a/web/app/components/workflow/nodes/tool/components/context-generate-modal/hooks/use-context-generate.ts b/web/app/components/workflow/nodes/tool/components/context-generate-modal/hooks/use-context-generate.ts index a5db2ad989..69e2b30d44 100644 --- a/web/app/components/workflow/nodes/tool/components/context-generate-modal/hooks/use-context-generate.ts +++ b/web/app/components/workflow/nodes/tool/components/context-generate-modal/hooks/use-context-generate.ts @@ -74,7 +74,7 @@ const resolveVarSchema = (variable: Var): Record | undefined => const toAvailableVarsPayload = ( availableVars: NodeOutPutVar[], - nodeMap: Map, + nodeMap: Map, ): ContextGenerateAvailableVar[] => { const results: ContextGenerateAvailableVar[] = [] availableVars.forEach((nodeVar) => { diff --git a/web/service/debug.ts b/web/service/debug.ts index fbfb60ca83..dbc6042e35 100644 --- a/web/service/debug.ts +++ b/web/service/debug.ts @@ -1,6 +1,8 @@ import type { IOnCompleted, IOnData, IOnError, IOnFile, IOnMessageEnd, IOnMessageReplace, IOnThought } from './base' import type { FileEntity } from '@/app/components/base/file-uploader/types' import type { ModelParameterRule } from '@/app/components/header/account-setting/model-provider-page/declarations' +import type { StructuredOutput } from '@/app/components/workflow/nodes/llm/types' +import type { BlockEnum, ValueSelector, VarType } from '@/app/components/workflow/types' import type { ChatPromptConfig, CompletionPromptConfig } from '@/models/debug' import type { AppModeEnum, CompletionParams, ModelModeType } from '@/types/app' import { get, post, ssePost } from './base' @@ -34,13 +36,13 @@ export type ContextGenerateMessage = { // FIXME export type ContextGenerateAvailableVar = { - value_selector: string[] - type: string + value_selector: ValueSelector + type: VarType description?: string node_id?: string node_title?: string - node_type?: string - schema?: Record | null + node_type?: BlockEnum + schema?: StructuredOutput['schema'] | Record | null } export type ContextGenerateParameterInfo = {