FlowiseAI/Flowise · error · Error
This agent only compatible with function calling models.
Error message
This agent only compatible with function calling models.
What it means
Worker's createAgent helper throws when `llm.bindTools === undefined` after assembling its prompt and splicing in any multimodal message template. The worker agent uses `llm.bindTools(tools)` to construct the tool-calling chain; without bindTools the agent cannot invoke its tools.
Source
Thrown at packages/components/nodes/multiagents/Worker/Worker.ts:200
new MessagesPlaceholder('agent_scratchpad')
/* Gettind rid of this for now because other LLMs dont support system message at later stage
[
'system',
[
'Supervisor instructions: {instructions}\n' + tools.length
? `Remember, you individually can only use these tools: ${toolNames}`
: '' + '\n\nEnd if you have already completed the requested task. Communicate the work completed.'
].join('\n')
]*/
])
if (multiModalMessageContent.length) {
const msg = HumanMessagePromptTemplate.fromTemplate([...multiModalMessageContent])
prompt.promptMessages.splice(1, 0, msg)
}
if (llm.bindTools === undefined) {
throw new Error(`This agent only compatible with function calling models.`)
}
const modelWithTools = llm.bindTools(tools)
let agent
if (!workerInputVariablesValues || !Object.keys(workerInputVariablesValues).length) {
agent = RunnableSequence.from([
RunnablePassthrough.assign({
//@ts-ignore
agent_scratchpad: (input: { steps: ToolsAgentStep[] }) => formatToOpenAIToolMessages(input.steps)
}),
prompt,
modelWithTools,
new ToolCallingAgentOutputParser()
])
} else {
agent = RunnableSequence.from([
RunnablePassthrough.assign({View on GitHub (pinned to abe4a8601a)
Solutions
- Choose a tool-calling-capable model for any worker that has tools.
- If the worker has no tools, consider a code path that skips bindTools (requires a code change).
- Ensure the LangChain model package version exposes bindTools.
- Validate at flow-save: refuse to attach tools to a non-tool-calling model.
Example fix
// before
if (llm.bindTools === undefined) {
throw new Error(`This agent only compatible with function calling models.`)
}
// after
if (typeof llm.bindTools !== 'function') {
throw new Error(`Worker needs a tool-calling model. ${llm?.constructor?.name ?? 'Model'} does not implement bindTools.`)
} Defensive patterns
Strategy: type-guard
Validate before calling
if (typeof llm.bindTools !== 'function') {
throw new Error('Worker requires a tool-calling model.')
} Type guard
const isToolCallingModel = (m: any): boolean => typeof m?.bindTools === 'function'
Prevention
- Only attach tools to workers backed by tool-calling models.
- Validate at flow-save: refuse tools on non-tool-calling models.
When it happens
Trigger: Passing a non-function-calling model to a Worker that has tools attached; using a model integration that lacks bindTools in the installed LangChain version.
Common situations: Authoring a tool-using worker against a base/text-only model; downgrading LangChain; mixing in a custom model class.
Related errors
- This agent only compatible with function calling models.
- Agent needs to have a function calling capable models.
- This agent requires that the "bindTools()" method be impleme
- This agent requires that the "bindTools()" method be impleme
- Supervisor name is required!
AI-assisted analysis of FlowiseAI/Flowise@abe4a8601a (2026-08-12).
Data as JSON: /api/errors/9e93ca61410b2e1e.
Report an issue: GitHub.