Internal search that feels like extended context.
Polygres turns the Postgres you already run into internal search for AI agents. Rows, relationships, embeddings — one hybrid query, one ranked answer. Stop stuffing prompts. Start searching.
Why it feels like extended context.
Because from your agent's side, that is exactly how it behaves. It searches for what it needs the moment it needs it, and the answer is already there. No window to ration. No history to compress. No guessing which rows to bring.
It never runs out of room
Ten rows or ten million, the prompt stays the same shape. Every answer arrives sized to the agent's budget, so nothing useful gets dropped to make room for something else.
It never forgets
Every row, relationship, and past interaction stays addressable for as long as it lives in your database. Nothing ages out. Nothing gets summarized into something vaguer.
You stop curating context
No deciding in advance which tables might matter. The agent asks, and the right rows come back ranked — per query, in milliseconds.
The mechanism is search, not a bigger model. The outcome is an agent that works like your whole database is sitting in the prompt.
Ask once. Retrieve everything.
pgGraph walks your relationships. pgContext runs ten kinds of search at once. Polygres fuses it all into one ranked answer, in the Postgres you already run.
Graph retrieval
Your foreign keys become a compiled graph. Multi-hop traversal, shortest paths, and relationship search over the tables you already have. The customer's orders, the ticket's history, all at memory-scan speed.
evokoa/pggraphFused search
Ten ways to search, one engine. They all run against your live tables at once, then a single fusion pass merges the results and re-scores every hit exactly. One query in, one ranked list out.
evokoa/pgcontextOne fused result
Graph hops and ten search methods don't return separate answers. Semantic hits seed the graph, pgGraph expands along the relationships, and everything gets re-ranked together. Rows, paths, and matches land in a single, token-ready context block.
Context assembly is one call.
Say what the agent needs. Semantic match, graph hops, scalar filters. Polygres hands back a ranked, token-ready context block. No vector store. No sync layer. No glue code.
Read the documentation# everything the agent needs, in one query
context = polygres.retrieve(
query="why did order #8231 fail?",
graph_hops=2, # orders → payments → disputes
filters={"status": "failed"},
limit_tokens=8_000,
)
agent.run(context) # grounded in your databaseStop rationing tokens.
Models cap out at a few million tokens. Your database doesn't. Search turns every row into working memory, fetched the moment your agent needs it.
Give your agents the whole database.
Deploy a managed instance in seconds. Or point the open source SDK at your existing schema.
Start Building with Polygres
Managed Postgres with graph traversal, vector search, and hybrid retrieval built in. First query in minutes.
Product Hunt