{
  "markdown": "# watsonx MCP Server\n\nMCP server for IBM watsonx.ai integration with Claude Code. Enables Claude to delegate tasks to IBM's foundation models (Granite, Llama, Mistral, etc.).\n\n## Features\n\n- **Text Generation** - Generate text using watsonx.ai foundation models\n- **Chat** - Have conversations with watsonx.ai chat models\n- **Embeddings** - Generate text embeddings\n- **Model Listing** - List all available foundation models\n\n## Available Tools\n\n| Tool | Description |\n|------|-------------|\n| `watsonx_generate` | Generate text using watsonx.ai models |\n| `watsonx_chat` | Chat with watsonx.ai models |\n| `watsonx_embeddings` | Generate text embeddings |\n| `watsonx_list_models` | List available models |\n\n## Setup\n\n### 1. Install Dependencies\n\n```bash\ncd ~/watsonx-mcp-server\nnpm install\n```\n\n### 2. Configure Environment\n\nSet these environment variables:\n\n```bash\nWATSONX_API_KEY=your-ibm-cloud-api-key\nWATSONX_URL=https://us-south.ml.cloud.ibm.com\nWATSONX_SPACE_ID=your-deployment-space-id  # Recommended: deployment space\nWATSONX_PROJECT_ID=your-project-id          # Alternative: project ID\n```\n\n**Note**: Either `WATSONX_SPACE_ID` or `WATSONX_PROJECT_ID` is required for text generation, embeddings, and chat. Deployment spaces are recommended as they have Watson Machine Learning (WML) pre-configured.\n\n### 3. Add to Claude Code\n\nThe MCP server is already configured in `~/.claude.json`:\n\n```json\n{\n  \"mcpServers\": {\n    \"watsonx\": {\n      \"type\": \"stdio\",\n      \"command\": \"node\",\n      \"args\": [\"/Users/matthewkarsten/watsonx-mcp-server/index.js\"],\n      \"env\": {\n        \"WATSONX_API_KEY\": \"your-api-key\",\n        \"WATSONX_URL\": \"https://us-south.ml.cloud.ibm.com\",\n        \"WATSONX_SPACE_ID\": \"your-deployment-space-id\"\n      }\n    }\n  }\n}\n```\n\n## Usage\n\nOnce configured, Claude can use watsonx.ai tools:\n\n```\nUser: Use watsonx to generate a haiku about coding\n\nClaude: [Uses watsonx_generate tool]\nResult: Code flows like water\n       Bugs arise, then disappear\n       Programs come alive\n```\n\n## Available Models\n\nSome notable models available:\n\n- `ibm/granite-3-3-8b-instruct` - IBM Granite 3.3 8B (recommended)\n- `ibm/granite-13b-chat-v2` - IBM Granite chat model\n- `ibm/granite-3-8b-instruct` - Granite 3 instruct model\n- `meta-llama/llama-3-70b-instruct` - Meta's Llama 3 70B\n- `mistralai/mistral-large` - Mistral AI large model\n- `ibm/slate-125m-english-rtrvr-v2` - Embedding model\n\nUse `watsonx_list_models` to see all available models.\n\n## Architecture\n\n```\nClaude Code (Opus 4.5)\n         │\n         └──▶ watsonx MCP Server\n                    │\n                    └──▶ IBM watsonx.ai API\n                              │\n                              ├── Granite Models\n                              ├── Llama Models\n                              ├── Mistral Models\n                              └── Embedding Models\n```\n\n## Two-Agent System\n\nThis enables a two-agent architecture where:\n\n1. **Claude (Opus 4.5)** - Primary reasoning agent, handles complex tasks\n2. **watsonx.ai** - Secondary agent for specific workloads\n\nClaude can delegate tasks to watsonx.ai when:\n- IBM-specific model capabilities are needed\n- Running batch inference on enterprise data\n- Using specialized Granite models\n- Generating embeddings for RAG pipelines\n\n## IBM Cloud Resources\n\nThis MCP server uses:\n- **Service**: watsonx.ai Studio (data-science-experience)\n- **Plan**: Lite (free tier)\n- **Region**: us-south\n\nCreate your own watsonx.ai project and deployment space in IBM Cloud.\n\n## Integration with IBM Z MCP Server\n\nThis watsonx MCP server works alongside the IBM Z MCP server:\n\n```\nClaude Code (Opus 4.5)\n         │\n         ├──▶ watsonx MCP Server\n         │         └── Text generation, embeddings, chat\n         │\n         └──▶ ibmz MCP Server\n                   └── Key Protect HSM, z/OS Connect\n```\n\nDemo scripts in the ibmz-mcp-server:\n- `demo-full-stack.js` - Full 5-service pipeline\n- `demo-rag.js` - RAG with watsonx embeddings + Granite\n\n## Document Analyzer\n\nThe document analyzer (`document-analyzer.js`) provides powerful tools for analyzing your external drive data using watsonx.ai:\n\n### Commands\n\n```bash\n# View document catalog (9,168 documents)\nnode document-analyzer.js catalog\n\n# Summarize a document\nnode document-analyzer.js summarize 1002519.txt\n\n# Analyze document type, topics, entities\nnode document-analyzer.js analyze 1002519.txt\n\n# Ask questions about a document\nnode document-analyzer.js question 1002519.txt 'What AWS credentials are needed?'\n\n# Generate embeddings for documents\nnode document-analyzer.js embed\n\n# Semantic search across documents\nnode document-analyzer.js search 'IBM Cloud infrastructure'\n```\n\n### Features\n\n- **Summarization**: Generate concise summaries of any document\n- **Analysis**: Extract document type, topics, entities, and sentiment\n- **Q&A**: Ask natural language questions about document content\n- **Embeddings**: Generate 768-dimensional vectors for semantic search\n- **Semantic Search**: Find similar documents using vector similarity\n\n### Demo\n\nRun the full demo:\n```bash\n./demo-external-drive.sh\n```\n\n## Embedding Index & RAG\n\nThe `embedding-index.js` tool provides semantic search and RAG (Retrieval Augmented Generation):\n\n```bash\n# Build an embedding index (50 documents)\nnode embedding-index.js build 50\n\n# Semantic search\nnode embedding-index.js search 'cloud infrastructure'\n\n# RAG query - retrieves relevant docs and generates answer\nnode embedding-index.js rag 'How do I set up AWS for Satellite?'\n\n# Show index statistics\nnode embedding-index.js stats\n```\n\n## Batch Processor\n\nThe `batch-processor.js` tool processes multiple documents at once:\n\n```bash\n# Classify documents into categories\nnode batch-processor.js classify 20\n\n# Extract topics from documents\nnode batch-processor.js topics 15\n\n# Generate one-line summaries\nnode batch-processor.js summarize 10\n\n# Full analysis (classify + topics + summary)\nnode batch-processor.js full 10\n```\n\nCategories: technical, business, creative, personal, code, legal, marketing, educational, other\n\n## Files\n\n- `index.js` - MCP server implementation\n- `document-analyzer.js` - Document analysis CLI tool\n- `embedding-index.js` - Embedding index and RAG tool\n- `batch-processor.js` - Batch document processor\n- `demo-external-drive.sh` - Demo script\n- `package.json` - Dependencies\n- `README.md` - This file\n\n## Author\n\nMatthew Karsten\n\n## License\n\nMIT\n",
  "bytes": 6383,
  "sha": "a00f107a15c68b89da1989da9800143aeec86f9489df3d1b615db605f14f4dbb",
  "repo_slug": "expertvagabond/watsonx-mcp-server",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_expertvagabond_watsonx_8eb28a3d/readme"
}