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

#9 Add the ability to use Ollama Embeddings models #10

Merged
merged 6 commits into from
May 21, 2024

Conversation

sighmon
Copy link
Contributor

@sighmon sighmon commented May 13, 2024

Resolves #9

So that we can work completely off-line and with open source models, let's add OllamaEmbeddings.

Acceptance Criteria

  • Add the ability to use OllamaEmbeddings

Relevant design files

  • None

Testing instructions

  1. Delete your vector database: rm -rf works_db
  2. Add below to your config.env
  3. Start your ollama server: OLLAMA_HOST=0.0.0.0:11434 ollama serve
  4. Build a local virtual environment: make build-local
  5. Start the chat to re-build embeddings using llama3 from our public API: make up-local (note creating embeddings takes a while)
  6. Quit the chat, and start the server: make server-local
  7. Note you can chat off-line: http://localhost:8000/playground/
  8. Note you can also set a different embedding model to the llm model: EMBEDDINGS_MODEL=nomic-embed-text
  9. Install that embedding model: ollama pull nomic-embed-text
  10. Delete your vector database again: rm -rf works_db
  11. Re-build the embeddings: make up-local
MODEL=llama3
LLM_BASE_URL=http://localhost:11434

Copy link

@sam-s-maher sam-s-maher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice one, looks good

@sighmon sighmon merged commit 679dd3c into main May 21, 2024
4 checks passed
@sighmon sighmon deleted the add/9-ollama-embeddings branch May 21, 2024 01:47
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.

Add the ability to use Ollama Embeddings models
3 participants