Skip to content

Commit 07764ff

Browse files
committed
fix(models): keep gemini-embedding-001 active
Only mark text-embedding-004 and embedding-001 as deprecated; the gemini-embedding-001 model is still served by the Google Generative AI v1beta endpoint, so leave it visible without the badge.
1 parent 36401bc commit 07764ff

1 file changed

Lines changed: 10 additions & 4 deletions

File tree

src/lfx/src/lfx/base/models/google_generative_ai_constants.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,17 +112,23 @@
112112
"models/embedding-001",
113113
]
114114

115-
# Embedding models as detailed metadata
116-
# Marked deprecated: not natively supported by the Knowledge Base ingestion
117-
# flow; hidden from the embedding model picker until support is added.
115+
# Embedding models as detailed metadata.
116+
# `text-embedding-004` and `embedding-001` are marked deprecated because they
117+
# are no longer served by the Google Generative AI v1beta endpoint used by KB
118+
# ingestion (404). `gemini-embedding-001` is the current supported model.
119+
_GOOGLE_DEPRECATED_EMBEDDING_MODELS = {
120+
"models/text-embedding-004",
121+
"models/embedding-001",
122+
}
123+
118124
GOOGLE_GENERATIVE_AI_EMBEDDING_MODELS_DETAILED = [
119125
create_model_metadata(
120126
provider="Google Generative AI",
121127
name=name,
122128
icon="GoogleGenerativeAI",
123129
model_type="embeddings",
124130
default=True,
125-
deprecated=True,
131+
deprecated=name in _GOOGLE_DEPRECATED_EMBEDDING_MODELS,
126132
)
127133
for name in GOOGLE_GENERATIVE_AI_EMBEDDING_MODELS
128134
]

0 commit comments

Comments
 (0)