# SDKs and frameworks

Clients and adapters that put Remiq's context in front of your model. Each one is one call to `/v1/context` before the model call; your model and its key stay yours.

## Clients

| Language | File | Use |
|---|---|---|
| Python | `prism_client.py` | `p = Prism(key, url)`, then `p.add(text, user=...)` and `p.context(query, user=...)`. One file, standard library only |
| TypeScript | `sdk-ts/prism.ts` | The same calls, typed answers, no dependencies (global `fetch`) |

## Frameworks

| Framework | Adapter | What it does |
|---|---|---|
| LangChain | `adapters/langchain_prism.py` | `PrismRetriever(prism=p, user="alice").invoke(question)` returns the cited records as Documents; `with_prism(your_chat_model, p, user="alice")` puts the context in front of your model |
| LlamaIndex | `adapters/llamaindex_prism.py` | `PrismRetriever(p, user="alice").retrieve(question)` returns the cited records, best first |
| OpenAI Agents SDK | `adapters/openai_agents_prism.py` | `Agent(..., tools=prism_tools(p, user="alice"))`: remember and get context as function tools |
| Claude Agent SDK | `adapters/claude_agent_prism.py` | `ClaudeAgentOptions(mcp_servers={"prism": prism_mcp_server(p, user="alice")})`: Remiq as MCP tools in your agent |
| Claude memory tool | `adapters/anthropic_memory.py` | A backend for Anthropic's memory tool: what Claude writes under `/memories` becomes searchable, permissioned records. Your Anthropic key stays with you |
| Vercel AI SDK | `sdk-ts/adapters/vercel.ts` | `wrapLanguageModel({ model, middleware: prismMiddleware(p, { user }) })`: one context call before each model call |
| Voice (LiveKit, Pipecat) | `adapters/livekit_prism.py`, `adapters/pipecat_prism.py` | One context call per spoken turn; the user's words are saved in the background |
