cd /news/ai-agents/spring-ai-agent-for-java-and-kotlin-… · home › topics › ai-agents › article
[ARTICLE · art-180917] src=blog.jetbrains.com ↗ pub= topic=ai-agents verified=true sentiment=↑ positive

Spring AI Agent for Java and Kotlin: The Next Step in the JetBrains–Spring Partnership

The Spring team, in collaboration with JetBrains, released Spring AI Agent, an experimental project for building AI agents inside Spring Boot applications, now incubating in spring-projects-experimental/spring-ai-agent with plans to merge into Spring AI as part of Spring AI 3.0 in May 2027. The framework defines agents as explicit typed graphs (ModelGraphAgent or GraphAgent) via a fluent builder API using Java records or Kotlin data classes, adds subgraphs, subagents, built-in A2A protocol support and CheckpointFeature persistence for long-running agents and human-in-the-loop approvals, and offers an imperative streaming API (Source<T>) backed by Virtual Threads instead of reactive pipelines. JetBrains, which inspired the design through its open-source Koog agent framework, is advancing the Kotlin experience with idiomatic Kotlin DSLs and dedicated documentation; Michael Minella, Director of OSS Spring R&D at Broadcom, called the collaboration "a strategic opportunity for us to continue to elevate the developer experience.

key takeaway

Spring AI Agent models agents as explicit typed graphs (ModelGraphAgent or GraphAgent) with unit-testable nodes, CheckpointFeature persistence for crash recovery and human-in-the-loop approvals, and a Virtual Threads-backed Source<T> streaming API that replaces reactive boilerplate.

by read5 min views18 publishedDec 3, 2026
Spring AI Agent for Java and Kotlin: The Next Step in the JetBrains–Spring Partnership
Image: Blog (auto-discovered)

Kotlin #

A concise multiplatform language developed by JetBrains

Today, the Spring team, in strategic collaboration with JetBrains, released Spring AI Agent, a new experimental project for building reliable AI agents inside Spring Boot applications. It shares core design principles with – and was inspired by – Koog, JetBrains’ open-source agent framework for Java and Kotlin.

The Spring team develops and maintains the core project, while JetBrains is advancing its Kotlin experience, including idiomatic Kotlin DSLs and dedicated documentation. The project is currently incubating in spring-projects-experimental/spring-ai-agent and there are plans to merge it into Spring AI as part of Spring AI 3.0, scheduled for May 2027. See the Spring AI team’s announcement for the API overview and code examples in Java and Kotlin.

“The Spring team’s collaboration with JetBrains has been a strategic opportunity for us to continue to elevate the developer experience through as many aspects of their workflow as possible. From IDE integrations, Kotlin support, and now the collaboration on Spring AI Agent work, we are excited about the opportunities that this new work presents for the Java ecosystem.”

– Michael Minella, Director of OSS Spring R&D, Broadcom

Build reliable and testable workflows with Spring AI Agent #

Adding a single LLM call to a Spring application is straightforward, but building a reliable AI agent is much harder. An agent is a multi-step process that calls tools, manages state, and makes decisions along the way. If you leave that entire flow to the model, the result is difficult to predict and test.

Spring AI Agent brings structure and modern JVM ergonomics to agentic development:

  • Predictable, testable workflows: You define the agent as an explicit, typed graph (ModelGraphAgent orGraphAgent ) using a fluent builder API and Java records or Kotlin data classes. You control every step and transition, and each node can be isolated and unit-tested.
  • Modular and enterprise-ready: Subgraphs, subagents, and built-in A2A protocol support let you compose complex workflows. Built-in persistence (CheckpointFeature ) enables long-running agents to survive crashes and for human-in-the-loop approvals.
  • Simple concurrency without reactive boilerplate: Instead of forcing teams into complex reactive pipelines for LLM streaming, Spring AI Agentintroduces an imperative streaming API (Source<T> )  backed by Virtual Threads. You consume streamed events in a plain loop out of the box. Reactive Streams adapters are available today and there are plans to add support for Kotlin Flow.
  • Native Spring integration: The agent lives inside your Spring Boot application and directly calls your existing services, data, and integrations.

“Spring AI Agent is an exciting next step for our JVM developer community, advancing the principles we’ve championed with Koog: type safety, fault tolerance, and predictable execution. I believe the Spring ecosystem is the natural home for such a framework because your Spring application already holds what makes enterprise AI agents truly useful: your data, integrations, and business logic. The Spring AI team is making it easier for developers to build on that foundation and bring reliable agents into production within the stack they already know and trust.”

– Vadim Briliantov, former Technical Lead of Koog, JetBrains

Advancing the JetBrains–Spring partnership: Kotlin for agentic systems #

In May 2025, JetBrains and the Spring team announced a strategic partnership with the goal of making Kotlin a first-class language for Spring applications. Spring AI Agent extends that collaboration to agentic system development, offering dedicated Kotlin extensions and a DSL.

Here’s what you get when you use Spring AI Agent with the Kotlin DSL:

  • Readable and declarative agent graphs: Agent workflows constantly pass state and tool schemas between nodes. Kotlin’s data classes and DSL syntax express complex graphs in a readable way without deeply nested builder chains. The logic stays visually clear and type-safe, allowing both JVM backend engineers and ML engineers who use Python to easily review the same agent definition.
  • Compile-time null safety: In Kotlin, nullability is part of the type system, so every optional part of a model response is explicit in its type. The compiler then requires your code to handle any missing value before moving to the next step. Because the compiler enforces this check rather than relying on the prompt, the check is guaranteed to happen whether a developer or a coding assistant writes the code.

The Kotlin DSL is available from day one and works in any Spring Boot application. Even if your project is in Java, you can write a single agent in Kotlin: It runs alongside your existing services and calls them directly, within the same build and deployment pipeline. This hybrid setup is already common in enterprise Spring backends: 61% of Kotlin backend developers work with Spring or Spring Boot, and 70% of teams adopting Kotlin on the backend introduced it into an existing Spring project (The State of Kotlin in 2026). Companies like Worldline already run conversational AI platforms serving over 1 million monthly active users on Kotlin and Spring Boot.

If you use Koog #

For teams running Koog on the JVM with Spring, we see Spring AI Agent as a natural step forward. The concepts you’re familiar with carry over into an official Spring project maintained by the Spring team as part of Spring AI, backed by a large community and offering Kotlin support from day one. To learn more about what this means for existing Koog projects, read our dedicated update dedicated update.

Try Spring AI Agent and help shape the Kotlin experience #

Explore the repository and try building an agent that streamlines one of your existing services. You can report issues through the project’s GitHub issue tracker.

As we expand the Kotlin DSL, we’d love to hear about the agents you’re designing and what would make the API feel most natural in Kotlin. Join the conversation in the #spring-ai-agent channel on the Kotlin Slack (get an invite here).

Further reading:

- [The Spring team’s announcement of Spring AI Agent](https://spring.io/blog/2026/12/03/spring-ai-agent-announcement)
- [What Spring AI Agent means for Koog users](https://blog.jetbrains.com/kotlin/2026/12/what-spring-ai-agent-means-for-koog-users/)
- [Strengthening Kotlin for Backend Development: A Strategic Partnership With Spring](https://blog.jetbrains.com/kotlin/2025/05/strategic-partnership-with-spring/)
- [The State of Kotlin in 2026 report: Backend Kotlin](https://kotlinlang.org/state-of-kotlin-2026)

Subscribe to Kotlin Blog updates

── more in #ai-agents 4 stories · sorted by recency
── more on @spring 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/spring-ai-agent-for-…] indexed:0 read:5min 2026-12-03 · —