langchain-ai / langchain-postgres

LangChain abstractions backed by Postgres Backend
MIT License
134 stars 48 forks source link

Support array comparisons #68

Open eyurtsev opened 5 months ago

eyurtsev commented 5 months ago

Define filters and semantics for array comparisons.

Feel free to use this PR as reference: https://github.com/langchain-ai/langchain-postgres/pull/59

Array comparisons may involve an either "all" or "any" condition.

Requirements


Only pick up work on this if you have and use postgresql

jernkuan commented 5 months ago

Hi @eyurtsev

Made another pull request https://github.com/langchain-ai/langchain-postgres/pull/77 that would support both int, float, text.

Not the most optimal, but with postgresql even using raw sql statement i'm not sure whether there is a better way, since ?| support only an array of text and not numbers.

Also added support to run this on windows, as ProacatorEventLoop is not support on windows.