A Spring Boot API for intelligent LLM interactions with document processing, vector storage, and Retrieval Augmented Generation (RAG).
- π€ LLM Integration - Uses Ollama for chat and embedding models with intelligent response generation
- π― Intent-Based Prompts - Automatically classifies user messages and selects appropriate tools and prompts
- π MCP Server Integration - Connects to Model Context Protocol (MCP) servers with secure OAuth2 authentication
- π Document Processing - Supports PDF and other document formats with intelligent content extraction
- π Vector Storage - Uses pgvector for efficient vector embeddings storage and similarity search
- π§ RAG (Retrieval Augmented Generation) - Enhances LLM responses with relevant contextual information
- π€ User Management - Supports user-specific chat history, preferences, and personalized experiences
- β‘ Atlassian Integration - Seamless connectivity with Jira and Confluence for product management workflows
- π OAuth2 Token Broker - Secure 3-legged OAuth2 authentication with automatic refresh token rotation
- π‘οΈ Enterprise Security - OAuth2 with JWT authentication, comprehensive authorization controls
- Java 24 or later
- Docker and Docker Compose
- Ollama (for LLM services)
docker compose -f docker/docker-compose-db.yml up -dCreate a .env file with minimal required variables:
# Database
SPRING_DATASOURCE_URI=jdbc:postgresql://localhost:5445/solesonic-llm-api
SPRING_DATASOURCE_USERNAME=solesonic-llm-api
SPRING_DATASOURCE_PASSWORD=docker_pw
DB_PASSWORD=docker_pw
# Application
APPLICATION_NAME=solesonic-llm-api
CORS_ALLOWED_ORIGINS=http://localhost:3000π Complete Configuration: See docs/configuration.md for all environment variables and advanced setup options.
# Build the application
./mvnw clean verify
# Run with local profile
./mvnw spring-boot:run -Dspring-boot.run.profiles=localIDE Users: Import as Maven project and run SolesonicLlmApiApplication with local profile.
The application runs at http://localhost:8080
# Health check
curl http://localhost:8080/actuator/healthThe Solesonic LLM API features intelligent intent classification that automatically selects the most appropriate tools and prompts based on user messages, eliminating the need for users to specify which tools they want to use.
- π Automatic Classification: Every message is classified as
GENERAL,CREATING_JIRA_ISSUE, orCREATING_CONFLUENCE_PAGE - π οΈ Smart Tool Selection: Appropriate tools (Jira, Confluence) are automatically provided based on detected intent
- β‘ Optimized Responses: Context-aware responses tailored for specific task types
- π Consistent Experience: Similar requests always receive the same specialized handling
This enables efficient, context-aware interactions where users can simply describe what they need in natural language.
The following example demonstrates automatic Jira issue creation from natural language:
What happened:
- User described a deployment need using natural language
- System automatically detected
CREATING_JIRA_ISSUEintent - Created properly formatted Jira issue (IB-34) with user story format, detailed acceptance criteria, and proper assignment
- Returned direct link to the created issue
This showcases the power of intent-based prompting and seamless Atlassian integration.
The API supports secure integration with Model Context Protocol (MCP) servers, enabling connection to external tools and services with enterprise-grade authentication.
Key Features:
- π Secure Token Broker: 3-legged OAuth2 with refresh token rotation
- β‘ Automatic Management: Transparent token refresh and user context propagation
- π Security First: Short-lived access tokens minimize exposure risk
The token broker acts as a secure intermediary, storing long-lived refresh tokens safely while providing short-lived access tokens to MCP servers.
π Detailed Guide: See docs/mcp-integration.md for complete integration instructions.
- Getting Started Guide - Complete setup walkthrough with troubleshooting
- Configuration Reference - All environment variables and configuration options
- API Documentation - Complete API reference with examples
- Contributing Guide - Development setup and contribution guidelines
- MCP Integration - Model Context Protocol server integration
- Product Management - Jira/Confluence integration and RAG workflows
- Database Schema - PostgreSQL with pgvector setup and migrations
- Deployment Guide - Production deployment strategies
- Security Guide - OAuth2, JWT, and security architecture
- Troubleshooting Guide - Common issues and solutions
π Project Resources:
- LICENSE - Apache 2.0 License
π Ready to get started? Follow the Getting Started Guide for detailed setup instructions.

