Skip to content

Conversation

@Milofax
Copy link

@Milofax Milofax commented Jan 17, 2026

Summary

The MCP server Docker image cannot use the Anthropic LLM provider because the anthropic package is not installed. It's defined as an optional dependency under [project.optional-dependencies].providers but the Dockerfile only runs uv sync --no-group dev.

Problem

When configuring llm.provider: anthropic in config.yaml, the server fails because AnthropicClient cannot be imported.

Solution

Install only the anthropic package directly instead of using --extra providers, which would pull in heavy dependencies like torch and transformers from other providers (Voyage, etc.).

# Install anthropic for Claude support (not in default deps)
RUN --mount=type=cache,target=/root/.cache/uv \
    uv pip install anthropic>=0.49.0

Alternatives Considered

  • --extra providers: Rejected because it installs all providers including torch/transformers (~500MB+)
  • Build argument for provider selection: More complex, could be future enhancement

Test Plan

  • Built Docker image with this change
  • Configured MCP server with llm.provider: anthropic
  • Successfully processed episodes using Claude via Anthropic API

🤖 Generated with Claude Code

The anthropic package is an optional dependency in graphiti-core but
required for using the Anthropic LLM provider. Without it, the MCP
server fails to create AnthropicClient instances.

This installs only anthropic (not --extra providers) to avoid pulling
heavy dependencies like torch/transformers from other providers.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant