Code Monkey home page Code Monkey logo

Comments (5)

buhe avatar buhe commented on June 11, 2024

https://databend.rs/doc/sql-functions/ai-functions/

Vector store support is great, but generating embedding requires the AI_EMBEDDING_VECTOR function, which is too coupled.

Only use OpenAI service.

from langchain-swift.

BohuTANG avatar BohuTANG commented on June 11, 2024

Thanks for mentioning.

Only use OpenAI service.

Databend currently only provides support for OpenAI, but there is potential for adding other LLM models in the future.

Vector store support is great, but generating embedding requires the AI_EMBEDDING_VECTOR function, which is too coupled.

Still confused with too coupled(Also we talked in email), here is some explains:
AI_EMBEDDING_VECTOR is a function that returns only a vector (of ARRAY data type). This means you can store the resulting array in the Databend ARRAY data type or any other persistent ARRAY storage.

Query:select ai_embedding_vector('hi');

Result: [-0.03512698,-0.020624293,-0.015343423,-0.039803572,... <4096 items>]

Please inform me of your preferred version for decoupling.

from langchain-swift.

buhe avatar buhe commented on June 11, 2024

If embedding and storage are separate, then I understand it wrong.

let embeddings = OpenAIEmbeddings()
let s = Supabase(embeddings: embeddings)

My expectation is that embedding and storage arrays are optional.

from langchain-swift.

BohuTANG avatar BohuTANG commented on June 11, 2024

Yes, they are separate, you can only utilize the AI_EMBEDDING_VECTOR function to get the vector array and save it to other stores.

from langchain-swift.

buhe avatar buhe commented on June 11, 2024

Thank you for your answer.

from langchain-swift.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.