Skip to content

A web UI designed to simplify AI experimentation, integration, and testing. It offers Java developers an easy way to explore and use large language models (LLMs), vector databases, and prompts.

Notifications You must be signed in to change notification settings

JM-Lab/spring-ai-playground

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spring AI Playground

Spring AI Playground Demo

Spring AI Playground is a self-hosted web UI designed to simplify AI experimentation, integration, and testing. It offers Java developers an easy way to explore and use large language models (LLMs), vector databases, and prompts.

Built with inspiration from various LLM Playgrounds, it uses the power of Spring AI to support major AI model providers. The goal is to make AI more accessible to Java developers, helping them quickly prototype and build Spring AI-powered applications.

Quick Start

Build and run the app:

./mvnw clean install
./mvnw spring-boot:run

Open http://localhost:8080 in your browser.

Auto-configurations

Spring AI Playground is configured to use Ollama by default for local LLM and embedding models. No API keys are required, making it easy to get started.

To enable Ollama, ensure it is installed and running on your system. Refer to the Spring AI Ollama Chat Prerequisites for setup details.

Switching to OpenAI

Switching to OpenAI is a primary example of how you can use a different AI model with Spring AI Playground. To explore other models supported by Spring AI, learn more in the Spring AI Documentation.

To switch to OpenAI, follow these steps:

  1. Modify the pom.xml file:

    • Remove the Ollama dependency:

      <dependency>
         <groupId>org.springframework.ai</groupId>
         <artifactId>spring-ai-ollama-spring-boot-starter</artifactId>
      </dependency>
    • Add the OpenAI dependency:

      <dependency>
         <groupId>org.springframework.ai</groupId>
         <artifactId>spring-ai-openai-spring-boot-starter</artifactId>
      </dependency>
    1. Update application.yaml:

      • Update the following configuration to set OpenAI as the default profile:
      spring:
        profiles:
          default: openai
        ai:
          openai:
            api-key: your-openai-api-key

Upcoming Features

Here are some features we are planning to develop for future releases of Spring AI Playground:

  • Vector Databases:
    Adding support for vector databases to enhance data storage and search capabilities for AI tasks.

  • RAG Chat (Retrieval-Augmented Generation):
    Improving AI chat by using external data to provide more accurate and relevant responses.

  • Observability:
    Introducing tools to track and monitor AI performance, usage, and errors for better management and debugging.

  • Authentication:
    Implementing login and security features to control access to the Spring AI Playground.

  • Multimodal Support:
    Supporting embedding, image, audio, and moderation models from Spring AI

These features will help make Spring AI Playground even better for testing and building AI projects.

About

A web UI designed to simplify AI experimentation, integration, and testing. It offers Java developers an easy way to explore and use large language models (LLMs), vector databases, and prompts.

Topics

Resources

Stars

Watchers

Forks