Programming Languages and Frameworks Used in Embabel Agent: Complete Technical Breakdown
Embabel Agent is primarily built with Java and Kotlin, running on a Spring Boot foundation with Spring AI integration for LLM connectivity.
The embabel-agent repository from Embabel is a polyglot AI agent platform that combines enterprise-grade Java infrastructure with modern Kotlin DSLs. This article examines the specific programming languages, frameworks, and libraries that power this open-source agent framework.
Programming Languages: Java and Kotlin
Embabel Agent uses both Java and Kotlin strategically across its codebase.
Java handles core libraries, servlet APIs, and large-scale components where stability and ecosystem compatibility matter most. You'll find Java in the observability module (embabel-agent-observability), where TrackedAspect.java implements Micrometer-based tracing through AOP.
Kotlin dominates the DSL-style skill definitions, concise service code, and modern language features. The SkillScript.kt file in embabel-agent-skills/src/main/kotlin/com/embabel/agent/skills/script/ demonstrates this pattern—it parses and executes user-defined skills with Kotlin's expressive syntax.
This dual-language approach lets the project leverage Java's mature ecosystem while benefiting from Kotlin's null safety, coroutines, and type-safe builders.
Core Framework: Spring Boot
The entire architecture rests on Spring Boot. According to the pom.xml in the repository root, the project declares standard Spring Boot starters for web, actuator, and testcontainers support.
Spring Boot provides:
- Dependency injection across all modules
- REST endpoint infrastructure for agent interactions
- Embedded servlet container (Netty-based, via Spring WebFlux)
- Auto-configuration for the AI model bindings
The StarwarsPromptProvider.kt in embabel-agent-shell/src/main/kotlin/com/embabel/agent/shell/personality/starwars/ shows typical Spring component wiring with @Component annotations and constructor injection.
AI Integration Layer: Spring AI and Native SDKs
Spring AI forms the abstraction layer for LLM interactions. The framework supports multiple providers through dedicated modules:
- OpenAI (
embabel-agent-openaimodule) - Anthropic
- Ollama (local models)
- Minimax
Beneath Spring AI, Embabel Agent pulls in native SDKs directly. The pom.xml manages versions for the OpenAI-Java SDK, Anthropic SDK, and ONNX Runtime for local embedding models. The OpenAiCompatibleModelFactory.kt file shows how these SDKs integrate with Spring AI's model factory pattern.
// Building an agent with Spring AI + OpenAI
val agent = AgentBuilder()
.withModel(
OpenAiOptions.builder()
.model("gpt-4o-mini")
.apiKey(System.getenv("OPENAI_API_KEY"))
.build()
)
.build()
Networking: Netty
The project imports the Netty BOM (Bill of Materials) in the parent pom.xml at lines 21-22. Netty supplies the non-blocking I/O stack that underpins both the embedded HTTP server and any client utilities for external API calls.
This choice aligns with Spring WebFlux's reactive programming model, though the codebase also supports traditional servlet-based deployment through configuration.
Observability Stack: Micrometer and OpenTelemetry
The embabel-agent-observability module implements production-ready telemetry through Micrometer for metrics and OpenTelemetry for distributed tracing.
The TrackedAspect.java file demonstrates this integration:
@Service
public class TrackedService {
@Tracked
public String process(String input) {
// Business logic with automatic trace/span creation
return "Processed: " + input;
}
}
The @Tracked annotation triggers aspect-oriented programming (AOP) interceptors that inject Micrometer timers and OpenTelemetry spans without polluting business logic.
Build and Test Infrastructure
Maven serves as the build system, with a multi-module structure defined in the parent pom.xml. Key testing dependencies include:
- JUnit 5 for unit and integration tests
- SpringMockK for Kotlin-friendly mocking in Spring contexts
- Testcontainers for integration testing with real infrastructure
The EmbabelMockitoIntegrationTest.kt in embabel-agent-test-support provides a reusable test harness that other modules extend.
Internal Platform: Embabel-Common
The project imports an internal BOM called Embabel-Common (lines 88-99 in pom.xml). This shared library supplies:
- Common data structures across modules
- Code-generation helpers
- Cross-cutting utilities
While not open-sourced separately, references in the build files indicate this is an internal Embabel platform dependency.
Skill Execution Engine: Kotlin DSL with Container Support
The most distinctive architectural element is the skill engine in embabel-agent-skills. It enables user-defined capabilities through three execution modes:
- Kotlin DSL scripts evaluated at runtime
- Docker containers for sandboxed execution
- Native processes for system integration
The SkillScript.kt file implements this polyglot execution environment, while skill definitions use type-safe annotations:
@Skill(name = "hello")
class HelloSkill {
@Tool(name = "greet")
fun greet(name: String): String = "Hello, $name! 👋"
}
Content Processing: Apache Tika
For retrieval-augmented generation (RAG) scenarios, the embabel-agent-rag-tika module integrates Apache Tika. The TikaHierarchicalContentReader.kt demonstrates Java-Kotlin interop for document ingestion and hierarchical content parsing.
Summary
- Primary languages: Java (core infrastructure) and Kotlin (DSL, services, modern features)
- Application framework: Spring Boot with WebFlux/reactive support
- AI abstraction: Spring AI with native SDK fallbacks (OpenAI, Anthropic, ONNX Runtime)
- Networking: Netty for non-blocking I/O
- Observability: Micrometer metrics + OpenTelemetry tracing
- Build system: Maven with JUnit 5, SpringMockK, and Testcontainers
- Skill execution: Kotlin-based DSL with Docker and process sandboxing
- Document processing: Apache Tika for RAG ingestion
Frequently Asked Questions
What is the main programming language in embabel-agent?
Neither language dominates exclusively. Kotlin appears more frequently in user-facing APIs and DSLs, while Java anchors the observability and core infrastructure modules. The project intentionally maintains both for ecosystem compatibility and developer ergonomics.
Is embabel-agent a Spring Boot application?
Yes. The entire platform builds on Spring Boot with standard starters for web, actuator, and testing. The AI integrations follow Spring Boot's auto-configuration pattern, making agent setup declarative through application.properties or YAML.
How does embabel-agent connect to LLM providers?
Through Spring AI abstractions backed by native SDKs. For OpenAI specifically, the embabel-agent-openai module contains OpenAiCompatibleModelFactory.kt, which bridges Spring AI's ChatModel interface with the official OpenAI-Java SDK. Similar patterns exist for Anthropic and local ONNX models.
Can I write custom skills in languages other than Kotlin?
The skill engine primarily targets Kotlin for inline script definitions, but supports any Docker container and any native executable through the SkillScript.kt execution framework. This lets you wrap Python tools, Node.js utilities, or compiled binaries as agent-accessible skills.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →