Adapter
Anthropic adapter
Connect MemoGrafter to Anthropic models.
Installation
terminal
npm install memo-grafter @anthropic-ai/sdkConfiguration
adapter.ts
const agent = new MemoGrafterAgent({
db: { connectionString: process.env.DATABASE_URL! },
llm: AnthropicLLMAdapter,
embedder: AnthropicEmbedAdapter,
});Supported capabilities
Chat completion for response generation and memory extraction.
Embedding generation when the provider exposes a compatible embedding model.
Server-side authentication through environment variables.
Provider notes
Set
ANTHROPIC_API_KEY on the server.Anthropic supplies completion models; pair it with a compatible embedding adapter.
Normalize system prompts through the adapter contract.
Troubleshooting
Confirm the API key is available to the server process.
Verify the configured model supports the requested operation.
Check rate limits when ingestion succeeds intermittently.