Created
June 15, 2024 17:23
-
-
Save calebdre/80b295d7e360bf30556bcd2d2ed855f4 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const createEmbedding = async ( | |
model: string, | |
text: string | |
) => { | |
const resp = await ollama.embeddings({ | |
model: model, | |
prompt: text | |
}) | |
return resp.embedding | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment