adk-js
adk-js copied to clipboard
Unable to submit request because it must include at least one parts field
Describe the bug A root agent is unable to transfer to subagents.
To Reproduce Steps to reproduce the behavior:
- Install
@google/adkv0.2.0 - Add:
import { LlmAgent } from '@google/adk';
export const jokeAgent = new LlmAgent({
name: 'tell_a_joke_agent',
model: 'gemini-2.0-flash',
description: 'Tell a joke',
instruction: `You are a helpful assistant that tells a joke.`,
});
export const philosophicalAgent = new LlmAgent({
name: 'philosophical_agent',
model: 'gemini-2.0-flash',
description: 'Say a philosophical statement',
instruction: `You are a helpful assistant that says a philosophical statement.`,
});
export const rootAgent = new LlmAgent({
name: 'root_agent',
model: 'gemini-2.0-flash',
description: 'Root agent',
instruction: `You are a helpful assistant that is the root agent.`,
subAgents: [jokeAgent, philosophicalAgent],
});
- Start the local web UI and trigger one of the subagents, like
tell me a joke - See the error appear:
Unable to submit request because it must include at least one parts field, which describes the prompt input. Learn more: https://cloud.google.com/vertex-ai/generative-ai/docs/model-reference/gemini
Expected behavior It should be able to transfer to a subagent
Screenshots
Desktop (please complete the following information):
- OS: macOS (Darwin 25.1.0, arm64)
- TS version/environment: 5.9.3
- ADK version(see maven dependency): 0.2.0