Skip to content

Make ToolCallAdvisor the default tool call management option #5459

@tzolov

Description

@tzolov

Currently, the tool-call lifecycle is managed internally by each concrete ChatModel implementation.

The ToolCallAdvisor allows you to manage this lifecycle as a part of the Advisor chains. The latter provides clear visibility for the tool request and response messages, allowing manipulation and storing of those messages in Memory. This is a requirement for many AI and Agentic use cases.

When the ToolCallAdvisor is added to the chain (e.g. ChatClient.advisors(ToolCallAdsvior.builder()...), it disables the low-level ChatMemory tool handling implementations. The proposal is to auto-register the ToolCallAdvisor by default when there are registered ChatClient Tools or tool callbacks.

Also a the toolcall advisor should disable its internal conversation memory support if there are ChatMemory advisors registered after it in the chain.

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions