Exploring interactions with LLMs : Practical insights with Spring AI
June 18, 2025 · View on GitHub

Exploring interactions with LLMs : Practical insights with Spring AI
LLM (Large Language Model) concept is widely used to build chatbots, question-answering systems, and other conversational applications.
In this workshop, we will discover how to interact with a LLM as we craft a conversational agent step-by-step. Throughout this journey, we will understand the capabilities and limitations of LLMs, and explore prompt engineering techniques to elevate their standard behavior.
For the practical part, we will learn about Spring AI's chat completion features to interact with LLMs. Spring AI serves as an abstraction layer able to interact with several LLM providers. For the workshop's purposes, we will use Ollama, a solution for running LLMs locally.
:sparkles: Quick start
If you don't want to save your work, you can start the workshop directly in a cloud environment.
:wrench: Environment setup
- GitHub Codespaces (5min)
- GitPod (5min)
- Local Hosting (15min)
:crystal_ball: Install Mistral 7B model
Execute this command only once to pull the model.
docker exec -it ollama sh -c "ollama pull mistral:7b"
:building_construction: Build the project
Execute this command after code update.
mvn clean install
:running_woman: Run the application
mvn spring-boot:run
:rocket: Hands-on
- Zero-shot prompting (15min)
- Conversational memory (15min)
- Information extraction (20min)
- Retrieval Augmented Generation (RAG) (30min)
- Conclusion
:gift: Bonus / Best Practices
- Conversational memory with Advisor (10min)
- RAG with Advisor (QuestionAnswerAdvisor) (10min)
- RAG and safe gard implementation with Advisor (SafeGuardAdvisor) (10min)
:star: Contributors
This workshop is proposed by AXA France's Development Guild.
Maintainers: