fix: switch MCP server to stdio transport for llmx compatibility

- Add wrapper script run-crawl4ai-mcp.sh for stdio transport
- Update config.toml to use stdio instead of SSE
- llmx uses Streamable HTTP transport which is incompatible with SSE
- DB and REST still run via docker compose, MCP runs on-demand

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

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-30 21:44:05 +01:00
parent 6724fea494
commit 45624a4d91
3 changed files with 24 additions and 3 deletions

16
run-crawl4ai-mcp.sh Executable file
View File

@@ -0,0 +1,16 @@
#!/bin/bash
# Wrapper script to run crawl4ai-rag MCP server with environment variables
set -a
source "$(dirname "$0")/.env"
set +a
exec docker run -i --rm \
--network=llmx_default \
-e TRANSPORT=stdio \
-e SUPABASE_URL=http://crawl4ai-rest:3000 \
-e SUPABASE_SERVICE_KEY="$SUPABASE_SERVICE_KEY" \
-e OPENAI_API_KEY="$LITELLM_API_KEY" \
-e EMBEDDING_API_BASE=https://llm.ai.pivoine.art/v1 \
-e EMBEDDING_MODEL=bge-large-en-v1.5 \
-e EMBEDDING_DIMENSION=1024 \
llmx-crawl4ai-rag