[Python]Embeddings API refactor (#580)

Sets things up for this -> https://github.com/lancedb/lancedb/issues/579
- Just separates out the registry/ingestion code from the function
implementation code
- adds a `get_registry` util
- package name "open-clip" -> "open-clip-torch"
This commit is contained in:
Ayush Chaurasia
2023-10-18 11:02:19 +05:30
committed by GitHub
parent 7372656369
commit 0293bbe142
12 changed files with 636 additions and 602 deletions

View File

@@ -52,7 +52,7 @@ tests = ["pandas>=1.4", "pytest", "pytest-mock", "pytest-asyncio", "requests"]
dev = ["ruff", "pre-commit", "black"]
docs = ["mkdocs", "mkdocs-jupyter", "mkdocs-material", "mkdocstrings[python]"]
clip = ["torch", "pillow", "open-clip"]
embeddings = ["openai", "sentence-transformers", "torch", "pillow", "open-clip", "cohere"]
embeddings = ["openai", "sentence-transformers", "torch", "pillow", "open-clip-torch", "cohere"]
[project.scripts]
lancedb = "lancedb.cli.cli:cli"