Fix LangflowApplication initialization and update cohere version (#1342)
This commit is contained in:
commit
37f331b578
4 changed files with 8 additions and 9 deletions
8
poetry.lock
generated
8
poetry.lock
generated
|
|
@ -974,13 +974,13 @@ testing = ["pytest (>=7.2.1)", "pytest-cov (>=4.0.0)", "tox (>=4.4.3)"]
|
|||
|
||||
[[package]]
|
||||
name = "cohere"
|
||||
version = "4.43"
|
||||
version = "4.44"
|
||||
description = "Python SDK for the Cohere API"
|
||||
optional = false
|
||||
python-versions = ">=3.8,<4.0"
|
||||
files = [
|
||||
{file = "cohere-4.43-py3-none-any.whl", hash = "sha256:ddedf89f759cdf1c2addbcfa36cc3f7cf505c5b1124c0b78777b9f7d835dcab8"},
|
||||
{file = "cohere-4.43.tar.gz", hash = "sha256:540b14e660eda547a7d1adf3f432edfad7c3f1dddc2a19975081a88888287dd1"},
|
||||
{file = "cohere-4.44-py3-none-any.whl", hash = "sha256:a6d01d579dcd43ef98ce1886b55e00a308d40332eafc1da4bf56526c81d6ff73"},
|
||||
{file = "cohere-4.44.tar.gz", hash = "sha256:06d9d056ed9b40f152d9551ca547a20ed08410e2e43488ba174e9025cf09746b"},
|
||||
]
|
||||
|
||||
[package.dependencies]
|
||||
|
|
@ -9400,4 +9400,4 @@ local = ["ctransformers", "llama-cpp-python", "sentence-transformers"]
|
|||
[metadata]
|
||||
lock-version = "2.0"
|
||||
python-versions = ">=3.9,<3.11"
|
||||
content-hash = "64f2c09d9343730423866788339c25c3b4aa6411e6ee3c502f26729deb4ce18a"
|
||||
content-hash = "19c6501f1567e95376c7482fe4c589c3fbde90a0e3bb7eaa37181f4ca701ee98"
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ tiktoken = "~0.5.0"
|
|||
wikipedia = "^1.4.0"
|
||||
qdrant-client = "^1.7.0"
|
||||
websockets = "^10.3"
|
||||
weaviate-client = "^4.0.0"
|
||||
weaviate-client = { version = "^4.4b6", allow-prereleases = true }
|
||||
jina = "*"
|
||||
sentence-transformers = { version = "^2.2.2", optional = true }
|
||||
ctransformers = { version = "^0.2.10", optional = true }
|
||||
|
|
|
|||
|
|
@ -305,7 +305,7 @@ def run_langflow(host, port, log_level, options, app):
|
|||
else:
|
||||
from langflow.server import LangflowApplication
|
||||
|
||||
LangflowApplication(options).run()
|
||||
LangflowApplication(app, options).run()
|
||||
except KeyboardInterrupt:
|
||||
logger.info("Shutting down server")
|
||||
sys.exit(0)
|
||||
|
|
|
|||
|
|
@ -2,12 +2,11 @@ from gunicorn.app.base import BaseApplication # type: ignore
|
|||
|
||||
|
||||
class LangflowApplication(BaseApplication):
|
||||
def __init__(self, options=None):
|
||||
def __init__(self, app, options=None):
|
||||
self.options = options or {}
|
||||
from langflow.main import create_app
|
||||
|
||||
self.options["worker_class"] = "uvicorn.workers.UvicornWorker"
|
||||
self.application = create_app()
|
||||
self.application = app
|
||||
super().__init__()
|
||||
|
||||
def load_config(self):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue