I’ve set up a table in a PGVector database and populated it with records, including two vector fields, using psycopg2-binary (version 2.9.9) in Python. The initial table creation was done through SQL in pgAdmin. Now, I’m looking to perform queries on this table utilizing the langchain framework in Python.
While langchain seems to support loading from an index by collection name, I haven’t found documentation on how to work with an existing table directly or how to specify which of the two vector fields to query against.
My questions are:
-
Can langchain be used to query a pre-existing table in a PGVector database, and if so, what is the process? (assuming the table was not created via langchain)
-
How can I specify which of the two vector fields in my table should be used for the queries?
-
Can langchain be used to query a pre-existing table in a PGVector database, and if so, what is the process? (assuming the table was not created via langchain)
-
How can I specify which of the two vector fields in my table should be used for the queries?