Closed hajsf closed 9 months ago
You can use any embeddings you want. I haven't explored offline embeddings so not sure what libraries might be out there.
Looks like you might be able to user TensorFlow.js to generate your embeddings offline:
https://github.com/tensorflow/tfjs
Here's some example code from LangChain.js to generate embeddings using TensorFlow:
https://github.com/hwchase17/langchainjs/blob/main/langchain/src/embeddings/tensorflow.ts
Here's a video that might help as well:
https://www.youtube.com/watch?v=MdPYT-xCj9w
You'll need this package as well:
https://www.npmjs.com/package/@tensorflow-models/universal-sentence-encoder
Hi, Can U use other methods for embedding than open AI, something offline, so that I do offline enriching for my local pdf files? Thanks