Skip to content

Releases: StefanBratanov/jvm-openai

v0.9.2

22 May 13:40
694eb6d
Compare
Choose a tag to compare

This release contains the following fixes/additions:

General

  • Fix the visibility of ToolResources static initialization methods (#9)
  • Fix serializing of classes which use @JsonSubTypes annotation (#10)
  • Add GPT_4o to OpenAIModel enum
  • Add Role, Purpose and Voice enums

Messages

  • Add ability to reference an image URL in the content of a message via the content parameter when creating a message

Full Changelog: v0.9.1...v0.9.2

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.9.2")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.9.2</version>
</dependency>

v0.9.1

08 May 07:48
Compare
Choose a tag to compare

This release contains the following fixes/additions:

General

  • Add workaround for record deserialization issues reported in #3 and #7

Chat

Full Changelog: v0.9.0...v0.9.1

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.9.1")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.9.1</version>
</dependency>

v0.9.0

06 May 09:23
Compare
Choose a tag to compare

This release has too many changes to mention all, but in short it provides support for Assistants API v2. If you would like to continue using v1, use Release v0.8.0 instead. A guide for migrating from v1 to v2 is available at https://platform.openai.com/docs/assistants/migration.

This release also contains the following additions/fixes:

General

  • When adding parameters for a Function Tool, escaped JSON strings will be unescaped when serializing .

Runs

Full Changelog: v0.8.0...v0.9.0

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.9.0")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.9.0</version>
</dependency>

v0.8.0

19 Apr 11:08
Compare
Choose a tag to compare

This release contains the following additions/fixes:

General

  • Add support for Batch API
  • Add ability to pass a project id (OpenAI-Project header) when building the OpenAI instance

Fine-tuning

  • Change learning_rate_multiplier parameter in Hyperparameters to be a double instead of an int

Assistants

  • Add ability to pass temperature, top_p and response_format when creating an assistant

Runs

  • Add ability to pass top_p, max_prompt_tokens, max_completion_tokens, truncation_strategy, tool_choice and response_format when creating a run
  • Add top_p, max_prompt_tokens, max_completion_tokens, truncation_strategy, tool_choice and response_format fields to ThreadRun

Full Changelog: v0.7.0...v0.8.0

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.8.0")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.8.0</version>
</dependency>

v0.7.0

10 Apr 11:00
Compare
Choose a tag to compare

Special thanks to @maciej-cz for his first contribution in #5 🎉

This release contains the following additions/improvements:

General

  • Add OpenAIModel enum to simplify the selection of a model

Chat

  • Improved handling of streaming events when ChatCompletionStreamSubscriber is used
  • Renamed StreamChatCompletionSubscriber to ChatCompletionStreamSubscriber

Fine-tuning

  • Add ability to pass integrations and seed fields when creating a fine-tuning job
  • Add integrations and seed field to FineTuningJob
  • Add support for listing checkpoints for a fine-tuning job.

Messages

  • Add ability to pass run_id query param when listing messages to allow filtering by the run id that generated them

Runs

  • Add ability to pass additional_messages, temperature and stream fields when creating a run
  • Add temperature field to ThreadRun
  • Add ability to pass stream field when submitting tool outputs to run
  • Add createRunAndStream, createThreadAndRunAndStream and submitToolOutputsAndStream to RunsClient to support Assistants Streaming

Full Changelog: v0.6.2...v0.7.0

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.7.0")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.7.0</version>
</dependency>

v0.6.2

13 Mar 16:37
Compare
Choose a tag to compare

This release contains the following additions/improvements:

General

  • Upgraded Jackson library to version 2.17.0
  • Removed argument validations when building requests, which allows the library to be more easily maintained in case of API changes

Full Changelog: v0.6.1...v0.6.2

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.6.2")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.6.2</version>
</dependency>

v0.6.1

20 Feb 08:12
Compare
Choose a tag to compare

This release contains the following additions/improvements:

General

  • Add ability to set a requestTimeout when initializing OpenAI. This timeout will apply to all requests.
OpenAI openAI = OpenAI.newBuilder(System.getenv("OPENAI_API_KEY"))
    .requestTimeout(Duration.ofSeconds(10))
    .build();

Chat

Full Changelog: v0.6.0...v0.6.1

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.6.1")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.6.1</version>
</dependency>

v0.6.0

14 Feb 07:08
Compare
Choose a tag to compare

This release contains the following additions/improvements:

General

  • Improvements for multipart/form-data requests

Audio

  • Add response_format and timestamp_granularities parameters when creating a transcription
  • Add response_format parameter when creating a translation

Chat

  • Add instance_id parameter when creating a chat completion

Embeddings

  • Add dimensions parameter when creating embeddings

Full Changelog: v0.5.2...v0.6.0

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.6.0")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.6.0</version>
</dependency>

v0.5.2

20 Jan 10:52
Compare
Choose a tag to compare

This release contains the following additions/improvements:

General

  • Use JsonInclude.Include.NON_ABSENT instead of JsonInclude.Include.NON_EMPTY in order to serialize empty collections/maps/arrays/strings

Runs

  • Add ability to pass additional_instructions when creating a run
  • Add usage field to ThreadRun and ThreadRunStep

Full Changelog: v0.5.1...v0.5.2

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.5.2")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.5.2</version>
</dependency>

v0.5.1

13 Jan 17:16
Compare
Choose a tag to compare

This release contains the following additions/fixes:

General

  • Make jackson-annotations a compile dependency to resolve compile warnings

Chat

  • Add capability to pass StreamChatCompletionSubscriber interface implementation for stream requests in order to subscribe to streamed responses
  • The following objects were renamed to align more closely with the API:
    • ChatRequest -> CreateChatCompletionRequest
    • ChatResponse -> ChatCompletion
    • ChatChunkResponse -> ChatCompletionChunk

Full Changelog: v0.5.0...v0.5.1

The artifact is available on Maven Central and can be imported as follows:

Gradle

implementation("io.github.stefanbratanov:jvm-openai:0.5.1")

Maven

<dependency>
    <groupId>io.github.stefanbratanov</groupId>
    <artifactId>jvm-openai</artifactId>
    <version>0.5.1</version>
</dependency>