Gemini Embeddings Issue After Discourse Update to 3.6.0 Beta 2

I’m going to answer my own post. The problem is not the build but the timing. In Oct google made the current embedding model (embedding-001) obsolete so it stopped working. The new model is gemini-embedding-001

In the Embedding configuration (Admin->Plugins->Discourse AI->Embeddings->Edit), you need to change the Embeddings service URL from
https://generativelanguage.googleapis.com/v1beta/models/embedding-001:embedContent

to

https://generativelanguage.googleapis.com/v1beta/models/gemini-embedding-001:embedContent

You can find the details here: https://ai.google.dev/gemini-api/docs/embeddings

@Falco maybe the default gemini configuration needs to be updated in discourse, when creating a new gemini embedding it still uses embedding-001 instead of gemini-embedding-001

1 Like