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

[BUG]: Wrong GenerateEmbeddingResponse Format #5

Closed
TonyWang666 opened this issue Nov 30, 2023 · 1 comment · Fixed by #6
Closed

[BUG]: Wrong GenerateEmbeddingResponse Format #5

TonyWang666 opened this issue Nov 30, 2023 · 1 comment · Fixed by #6

Comments

@TonyWang666
Copy link

TonyWang666 commented Nov 30, 2023

Version: OllamaSharp 1.0.2
The GenerateEmbeddingResponse doesn't match the actual returned json format from endpoint api/embeddings

I am using OllamaSharp 1.0.2 to call endpoint api/embeddings with model(llama2:70b) and prompt. However, the returned json is { "embedding": [ 1232321, 1232321, ...] } instead of GenerateEmbeddingResponse with { "embeddings": [ 1232321, 1232321, ...] }

According to the official doc, the returned key word should be embedding without s.

@awaescher
Copy link
Owner

Nice catch, thanks. I just found out that the docs where wrong about that too.
Going to fix it.

awaescher added a commit that referenced this issue Nov 30, 2023
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 a pull request may close this issue.

2 participants