Reputation: 1
If Replit itself does NOT have built-in vector search, AI response, or RAG, does it have the capability to connect to these services? If yes, does this mean that Replit CAN function like an AI-driven no-code platform where you can build anything with natural language prompts — As long as it’s connected to the right external tools?
Basically, following are my main questions:
For example:
So far, it feels inefficent when trying to connect APIs of even simpler integration like Open AI Api key thru prompts to make it work.
Upvotes: -2
Views: 34
Reputation: 1
the potgres database supports pgvector - you can enable it and then store and query verctors in the neon database.
here is an overview of the sql
CREATE EXTENSION pgvector;
SELECT * FROM pg_extension WHERE extname = 'vector';
CREATE TABLE embeddings (
id SERIAL PRIMARY KEY,
embedding vector(1536) -- Replace 1536 with your vector dimension
);
INSERT INTO embeddings (embedding) VALUES ('[0.1, 0.2, 0.3, ..., 0.9]');
SELECT id, embedding <=> '[0.1, 0.2, 0.3, ..., 0.9]' AS distance
FROM embeddings
ORDER BY distance ASC
LIMIT 5;
note the ... is to shortend the embeddings, they are 1536 long! Once you have the vector extension installed you'll be good to go.
Upvotes: -1