Spring / Spring AI interview questions
What are the Spring AI Spring Initializr options and how do you bootstrap a project?
The fastest way to start a Spring AI project is through start.spring.io. The Spring Initializr now includes Spring AI dependencies as first-class options in the AI category. You pick the AI starters you need alongside your other Spring Boot starters, and the generator creates a ready-to-run project with correct BOMs, repository declarations, and starter wiring.
Available AI starters in Spring Initializr include: OpenAI, Azure OpenAI, Ollama, Anthropic Claude, Mistral AI, Amazon Bedrock, Google Vertex AI Gemini, as well as vector store starters for PgVector, Redis, Chroma, and others.
If you prefer the Spring CLI:
spring boot new --dependencies spring-ai-openai,web,actuator my-ai-app
If you bootstrap manually (adding dependencies by hand), two things are commonly missed:
- Import the
spring-ai-bomindependencyManagementso you do not have to manage individual module versions. - Add the Spring Milestone repository because Spring AI releases are not yet published to Maven Central as GA artifacts for some versions.
<repositories> <repository> <id>spring-milestones</id> <url>https://repo.spring.io/milestone</url> </repository> </repositories>
More Related questions...