This blog post will integrate the Spring AI framework into a Java application. We’ll use a simple project that includes a ChatService
and a ChatController
to demonstrate using the Spring AI framework to generate text & image responses and horoscopes based on user input.
Tag Archives: spring boot
Using Spring Boot to invoke ChatGPT/OpenAI API
OpenAI provides us the ability to invoke its features via RESTful APIs. This blog shows how to invoke the API using Spring Boot. There is nothing special here and no OpenAI Java libraries that I use. One can do the same in standard Java (non-spring) or even in more concise code with Nodejs. But here goes a sample with Spring Boot.
GraphQL with Netflix dgs-framework
Starting the year with some back-to-basics hands-on coding using small building blocks in areas that I randomly get interested in. This time using the Netflix DGS GraphQL framework. DGS (Domain Graph Service) is a GraphQL server framework for Spring Boot.
Spring Boot and Redis PubSub
A simple Spring Boot sample to publish a message to a Redis queue, with a message subscriber that consumes the message Spring Data. See README in Github for how to set up a local Redis and run the code.
Spring Boot and Redis
A simple Spring Boot sample to save and retrieve an object from Redis using Spring Data. See README in Github for how to setup a local Redis and run the code.
Metrics with Spring Boot, Prometheus and Grafana
Capturing metrics from your system is critical to understanding its internal behavior and to tune its performance. Without this you are operating in the blind. In this post we will go through how you can gather metrics from a Spring Boot application using Prometheus, Grafana and Micrometer.