Skip to content

Conversation

@ddobrin
Copy link
Contributor

@ddobrin ddobrin commented Dec 9, 2025

These changes are required for

  • Native Image support - mandatory upgrade to 1.30.0
  • Deprecation of text-embedding-004 on Jan 14, 2026

Could this be merged into the 2.0.0 branch and backported to a 1.1.x fixes branch?

cc: @markpollack @ilayaperumalg @tzolov

public class GoogleGenAiTextEmbeddingOptions implements EmbeddingOptions {

public static final String DEFAULT_MODEL_NAME = GoogleGenAiTextEmbeddingModelName.TEXT_EMBEDDING_004.getName();
public static final String DEFAULT_MODEL_NAME = GoogleGenAiTextEmbeddingModelName.GEMINI_EMBEDDING_001.getName();
Copy link
Member

@markpollack markpollack Dec 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

usually we should not change the default for the 1.1.x branch. the TEXT_EMBEDDING_004 is going away next month @ddobrin so this makes it an awkward situation for 1.1.x users, in partiuclar as there are dimension changes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think in this case the default should change to text_embedding_005, with the same dimensions

@markpollack
Copy link
Member

suggestions

  • Fix the typo in documentation: change 'gemini-enmbedding-001' to 'gemini-embedding-001' in the deprecation note (line 199 of the .adoc file)
  • Add a prominent migration guide section to the documentation explaining how users with existing text-embedding-004 embeddings should handle the dimension change when upgrading
  • Consider adding a deprecation warning log message when text-embedding-004 is explicitly specified, alerting users to the January 2026 sunset date
  • Clarify in documentation which model should be used for which use case: text-embedding-005 (768 dims) vs gemini-embedding-001 (3072 dims) and the trade-offs
  • Add a test case that explicitly validates backward compatibility when text-embedding-004 is still used (before Jan 2026) to ensure the transition period works correctly
  • Document the batch size limitation of gemini-embedding-001 in the main properties table, not just in code comments, as this has significant performance implications

@markpollack markpollack reopened this Dec 10, 2025
@ddobrin
Copy link
Contributor Author

ddobrin commented Dec 10, 2025

@markpollack - I'll update as per your suggestions first thing in the morning

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants