Spring AI Example logo

Spring AI Example

by lucasdengcn

This project demonstrates various implementation patterns and best practices for using Spring AI tools. It consists of an MCP server and a proposal agent.

View on GitHub

Last updated: N/A

What is Spring AI Example?

This project is a Spring Boot application showcasing the use of Spring AI for building AI-powered applications. It includes an MCP server with SSE support and a proposal agent that acts as an MCP client.

How to use Spring AI Example?

The project provides examples of using methods as tools, custom tool result converters, tool context injection, and tool parameter annotations. Refer to the mcp-server and proposal-agent modules for specific usage instructions and the README files within each module for detailed documentation.

Key features of Spring AI Example

  • Model Context Protocol (MCP) Server implementation

  • MCP Client implementation for AI-powered proposals

  • Integration with Ollama AI model

  • Vector store with PGVector

  • SSE (Server-Sent Events) for real-time updates

  • Customizable tool implementations with annotations and context

Use cases of Spring AI Example

  • Building AI agents that interact with external services

  • Creating real-time AI-powered applications with SSE

  • Implementing custom tools for AI models

  • Integrating AI models with Spring Boot applications

FAQ from Spring AI Example

What is MCP?

MCP stands for Model Context Protocol. It's used for communication between AI models and applications.

What is SSE?

SSE stands for Server-Sent Events. It's a server push technology enabling real-time data updates to clients.

What is Ollama?

Ollama is an AI model used within this project.

What is PGVector?

PGVector is a vector store used for storing and retrieving vector embeddings.

How do I configure the AI model?

The project uses Spring Boot configuration for the AI model. Refer to the project's configuration files for details.