intermediate~4h
Tool Calling & Function Calling
RAG lets a model read your data. Tool calling lets it act — query a database, check the time, send an email. This module is how a model that can only emit text ends up triggering real Java code.
Learning objectives
- Beginner: A single no-argument @Tool method (like getCurrentDateTime) to see the request/response round trip end to end.
- Intermediate: Parameterized tools backed by a real repository, with try/catch returning model-safe failure strings instead of propagating exceptions.
- Advanced: A mix of returnDirect tools (raw data lookups) and normal tools (that feed into further reasoning), composed into a multi-step agentic workflow (Module 15) where the model may call several tools across multiple turns before producing a final answer.
This is a Pro chapter
Sign in, then upgrade to Pro or Power to unlock this and the full Spring Ecosystem Mastery library.
Tool Calling & Function Calling