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

Fix two bugs introduced by previous updates for VertexAI #4016

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Lash-L
Copy link
Contributor

@Lash-L Lash-L commented Feb 7, 2025

Description

Opening this in place of #3711 as it fixes all of the relevant problems instead of just one.

Seems like a bug was introduced when the embeddings were merged into the llm.
b14b8c4#diff-f6056e365b00006d0872276e5078b8e10b940dfeca7f0aa106b1c842e5aa5a14

The embedding class's base url didn't have a slash at the end, while the llm one did. Neither one was 'wrong', but they were different, so when it was merged, it ended up having a // in the url.

Removing the / before the embedding url fixes this problem.

As well, a bug was introduced in 3b25f78 that broke sending messages as it took the options out of the needed subsection.

Gemini via AI studio and VertexAI are very very similar. So I extracted out the logic that could be copied from the vertexai send and I now call it in VertexAI. This should help prevent any future issues and allow vertexAI's gemini deployment to piggyback on gemini's.

Checklist

  • [] The relevant docs, if any, have been updated or created
  • [] The relevant tests, if any, have been updated or created

Screenshots

[ For visual changes, include screenshots. ]

Testing instructions

[ For new or modified features, provide step-by-step testing instructions to validate the intended behavior of the change, including any relevant tests to run. ]

Copy link

netlify bot commented Feb 7, 2025

Deploy Preview for continuedev canceled.

Name Link
🔨 Latest commit 11eabd6
🔍 Latest deploy log https://app.netlify.com/sites/continuedev/deploys/67aa50489d1416000789fdcc

@sestinj
Copy link
Contributor

sestinj commented Feb 8, 2025

Can you add a test in llm.test.ts for the Vertex class? Shouldn't take much, just about 5 lines of code

@Lash-L Lash-L changed the title Fix two bugs introduced by previous updates Fix two bugs introduced by previous updates for VertexAI Feb 8, 2025
@Lash-L
Copy link
Contributor Author

Lash-L commented Feb 8, 2025

Can you add a test in llm.test.ts for the Vertex class? Shouldn't take much, just about 5 lines of code

Hi are you looking for a TestLLM call? Or something else?

@Lash-L
Copy link
Contributor Author

Lash-L commented Feb 11, 2025

Hey @sestinj - sorry for the ping - just trying to figure out what kind of tests you would like to see.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants