Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gemini node don't use custom host for completions/embeddings. #12451

Open
laxtiz opened this issue Jan 3, 2025 · 1 comment
Open

Gemini node don't use custom host for completions/embeddings. #12451

laxtiz opened this issue Jan 3, 2025 · 1 comment
Labels
in linear Issue or PR has been created in Linear for internal review

Comments

@laxtiz
Copy link

laxtiz commented Jan 3, 2025

Bug Description

I use the Cloudflare AI Gateway proxied for Google Gemini.
I noticed one thing: GooglePlamApi.credentials supports a custom host attribute, but LmChatGoogleGemini and EmbeddingaGoogleGemini nodes only use this host attribute to retrieve the model list, and do not use the custom host in chat completions and embeddings requests.
In contrast, LmChatOpenAi uses the custom base_url parameter.

To Reproduce

  1. Create a GooglePlamApi credentials with a custom host (e.g., cloudflare ai gateway).
  2. Use the LmChatGoogleGemini node in the workflow.
  3. Chat with any Gemini model.
  4. The logs only requests for list models and do not include chat completion requests.

Expected behavior

The ChatGoogleGenerativeAI class's constructor parameters include base_url, similar to the LmChatOpenAi node, where the base_url parameter is appended when creating an instance of the model.

Operating System

Debian 12.8

n8n Version

1.72.1

Node.js Version

20.18.0

Database

SQLite (default)

Execution mode

main (default)

@Joffcom
Copy link
Member

Joffcom commented Jan 3, 2025

Hey @laxtiz,

We have created an internal ticket to look into this which we will be tracking as "N8N-8041"

@Joffcom Joffcom added the in linear Issue or PR has been created in Linear for internal review label Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in linear Issue or PR has been created in Linear for internal review
Projects
None yet
Development

No branches or pull requests

2 participants