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

ValueError: Unrecognized protocol: admin #10

Open
Prasad6f opened this issue Aug 3, 2023 · 0 comments
Open

ValueError: Unrecognized protocol: admin #10

Prasad6f opened this issue Aug 3, 2023 · 0 comments

Comments

@Prasad6f
Copy link

Prasad6f commented Aug 3, 2023

I recently attended the webinar on llama 2. I'm trying to build a local QA model, i followed every step mentioned in the git. Upon pasting the singlestore connecting string i got an error from connection string part.
Below is the error message,

Traceback (most recent call last):
File "C:\Users\91979\Desktop\llama-2-local\main.py", line 27, in
dbqa = setup_dbqa()
^^^^^^^^^^^^
File "C:\Users\91979\Desktop\llama-2-local\src\utils.py", line 59, in setup_dbqa
vectorstore = SingleStoreDB.from_documents(texts, embeddings, distance_strategy="DOT_PRODUCT", table_name="demo0")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\langchain\vectorstores\base.py", line 336, in from_documents
return cls.from_texts(texts, embedding, metadatas=metadatas, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\langchain\vectorstores\singlestoredb.py", line 423, in from_texts
instance = cls(
^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\langchain\vectorstores\singlestoredb.py", line 212, in init
self._create_table()
File "C:\Users\91979\anaconda3\Lib\site-packages\langchain\vectorstores\singlestoredb.py", line 216, in _create_table
conn = self.connection_pool.connect()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 452, in connect
return _ConnectionFairy._checkout(self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 1267, in _checkout
fairy = _ConnectionRecord.checkout(pool)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 716, in checkout
rec = pool._do_get()
^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\impl.py", line 169, in _do_get
with util.safe_reraise():
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\util\langhelpers.py", line 147, in exit
raise exc_value.with_traceback(exc_tb)
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\impl.py", line 167, in _do_get
return self._create_connection()
^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 393, in _create_connection
return _ConnectionRecord(self)
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 678, in init
self.__connect()
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 902, in __connect
with util.safe_reraise():
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\util\langhelpers.py", line 147, in exit
raise exc_value.with_traceback(exc_tb)
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 898, in __connect
self.dbapi_connection = connection = pool._invoke_creator(self)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\sqlalchemy\pool\base.py", line 365, in
return lambda rec: creator_fn()
^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\langchain\vectorstores\singlestoredb.py", line 55, in _get_connection
return s2.connect(**self.connection_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\91979\anaconda3\Lib\site-packages\singlestoredb\connection.py", line 1413, in connect
raise ValueError(f'Unrecognized protocol: {driver}')
ValueError: Unrecognized protocol: admin

Below is the connection string i used.
os.environ["SINGLESTOREDB_URL"] = "admin:*********@mysql://svc-1cc8f156-7256-4966-84dc-4eeb15b2812f-dml.aws-mumbai-1.svc.singlestore.com:3306/s2_dataset_martech_8fd11b9e"

Any help would be appreciable!!

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

No branches or pull requests

1 participant