SynapCores / Recipe library
Agentic AI Recipes
Memory, RAG, semantic tool routing, knowledge graphs — every primitive an AI agent needs, in plain SQL on SynapCores.
36 recipes in this cluster. Each one is a self-contained Markdown file with the SQL or Cypher you can paste into SynapCores Community Edition and run.
36 of 36 recipes
Build an AI agent that learns from thumbs-up/down feedback — train a model on past interactions to predict whether a draft reply will satisfy the user, all in one SQL database. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Run a deterioration-watch agent that can read the chart but never write to it, then keep a hash-chained, append-only record of every recommendation it made — the traceability a clinical safety review actually asks for.
Give a loan-review agent a hard governance envelope, then hand a regulator a tamper-evident, hash-chained record of every decision it made — all in SQL, inside one database.
An incident-triage agent that correlates the alert with recent deploys, runbooks, and customer impact — producing a structured 'here's what I see / suspected cause / recommended action' in one SQL call.
A compliance-reviewer agent that walks the transaction table, consults KYC docs and regulations by meaning, surfaces hits with citations, and drafts an SAR-style write-up — all in SQL via AGENT_RUN.
A clinical-assistant agent that grounds answers in the patient's chart AND the relevant guideline — never just one or the other. Built on a single SQL session with AGENT_RUN.
An HR-assistant agent that combines the employee's specific row (country, tenure, role band) with the right policy doc to answer correctly — not a generic RAG-only bot that hallucinates country-specific rules.
Stand up an in-database claims-adjuster agent that retrieves policy clauses by meaning, scans prior-claim history for fraud signals, and recommends an action — all in a single SQL session via AGENT_RUN.
A contract-reviewer agent that diffs an inbound MSA against your standard playbook AND your recent negotiated precedents — surfacing deviations with the closest prior deal as a reference.
A shipment-exception agent that joins the late shipment with the customer's SLA tolerance and recalls similar past exceptions, then drafts both the customer notice and the carrier dispatch — in one SQL call.
A returns-processing agent that reads the order, checks return-policy by meaning, scans for abuse patterns in prior returns, checks live inventory for swap availability, and recommends a specific action — all in SQL via AGENT_RUN.
A tier-1 support agent that reads the customer's actual account state AND the help docs in one call, then either resolves the ticket or escalates with full context — not a RAG-only chatbot.
An account-research agent that pulls the CRM record, finds similar past wins by meaning, and outputs a one-page briefing before the sales call — all in SQL via AGENT_RUN.
Build a complete AI customer-support agent on one database — semantic ticket memory, RAG over your help docs, intent routing, priority scoring, and a customer graph, no five-service stack. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Build a personal AI assistant on one database — long-term memory of preferences, semantic tool routing, RAG over your notes, and grounded replies. No five-service stack. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Build an AI research agent that reads documents, builds a knowledge graph, answers multi-hop questions with citations, and synthesizes a briefing — RAG plus a knowledge graph in one database. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Build an AI triage agent that classifies every incoming request by meaning, scores its urgency with AutoML, and routes it to the right queue or human — all on one database. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Turn unstructured text into a queryable knowledge graph an AI agent can reason over — extract entities and relationships with GENERATE, store them as a Cypher graph, all in one database. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Build an AI SDR agent on one database — score leads with AutoML, match them to case studies by meaning, map the buying committee as a graph, and draft personalized outreach with GENERATE. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Stand up everything a coding agent needs — project memory, semantic code search, a code-dependency impact graph, and a tamper-evident decision log — on ONE self-hosted database it queries over MCP or SQL. No stitching four datastores; your code never leaves your box.
Store a chatbot's full conversation history and keep a rolling summary so it never blows the context window — turn buffer, semantic recall, and auto-summary in one SQL database. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
The next-step variant of the rolling-summary recipe — replace the single prose summary with a typed chat_facts table (category, key, value, confidence, updated_at). Higher recall, surgical updates, no contradiction accumulation.
Classify every inbound support message with SENTIMENT() and auto-route it to the right team, owner, and priority — no external NLP service.
Give an AI agent two memory types — episodic (what happened, when) and semantic (durable facts) — in one SQL store, and recall across both by meaning. Framework-agnostic: Claude Code, OpenClaw, LangChain, or a voice agent.
Add persistent, semantic long-term memory to any AI agent — store and recall memories by meaning with vector embeddings in plain SQL. Framework-agnostic: works with Claude Code, OpenClaw, LangChain, or a custom or voice agent.
Give an AI agent multi-hop reasoning — combine semantic retrieval with a knowledge graph so it can answer questions that need several connected facts, not just one passage. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Classify what a user wants — billing, support, sales, cancel — so your AI agent routes the conversation correctly, using vector nearest-example matching in plain SQL. No training job, works with Claude Code, OpenClaw, LangChain, or a voice agent.
Let multiple AI agents collaborate through one shared memory — a blackboard where each agent posts findings and reads what the others know, by meaning, in plain SQL. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Build retrieval-augmented generation for any AI agent in one database — embed your docs, retrieve the most relevant chunks by meaning, and generate a grounded answer in plain SQL. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Add role-based access control to RAG so each user only retrieves the documents they're allowed to see. Nested groups, vector search, the LLM answer and an audit log in one SQL database, with no separate permission service.
Make an AI agent cite its sources — retrieve passages, generate an answer, and attach the source documents it used, all in one SQL database. Auditable RAG that works with Claude Code, OpenClaw, LangChain, or a voice agent.
Make an AI agent recall the right memories by blending semantic relevance with recency — fresh, on-point context in one SQL query, no separate vector store or cache. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
Stop your AI agent from hallucinating — generate an answer, then have the agent verify it against your source data before returning it, all in one SQL database. Self-checking RAG for Claude Code, OpenClaw, LangChain, or a voice agent.
Stop your AI agent from storing the same fact ten times — detect and merge near-duplicate memories by meaning with vector similarity in plain SQL. Keeps agent memory clean for Claude Code, OpenClaw, LangChain, or a voice agent.
Route an AI agent's request to the right tool by meaning — semantic function-calling with vector embeddings in plain SQL, no framework, no brittle keyword rules. Works with Claude Code, OpenClaw, LangChain, or a voice agent.
RAG retrieves what is relevant, not what is still true. Give your AI agent the current value of every fact, the note it came from, and what was true on any date, with CREATE MEMORY, CURRENT, TRACE and RECALL AS OF in plain SQL.