clarifai -local
Local MCP server for clarifai.com
claude mcp add --transport stdio clarifai-clarifai-mcp-server-local ./mcp_binary --pat YOUR_CLARIFAI_PAT --output-path ~/Desktop/ --default-user-id your_user_id --default-app-id your_app_id
How to use
This MCP server acts as a local bridge to the Clarifai API, exposing Clarifai capabilities (like image generation and inference) through the MCP protocol so clients such as IDE extensions can interact with Clarifai without embedding heavy data in prompts. The server runs on your machine as a standalone binary built from the Go source and is configured via the MCP settings file. Tools exposed by this server include upload_file (to upload a local file as Clarifai input), generate_image (text-to-image generation with optional model and app context), clarifai_image_by_path (inference on a local image), clarifai_image_by_url (inference on an image URL), and search-related tools for inputs, annotations, models, and datasets. The server writes output to the configured path and returns textual results or encoded data as appropriate.
How to install
Prerequisites:
- Go 1.23 or later
- Git
- A Clarifai PAT (Personal Access Token) for API access
Installation steps:
-
Clone the repository and install dependencies
- git clone https://github.com/tot-ra/clarifai-mcp-server-local.git
- cd clarifai-mcp-server-local
- go mod tidy
-
Build the binary for your platform
- make build (This builds an executable named mcp_binary in the project root. On Windows it will be mcp_binary.exe.)
-
Prepare MCP settings (example provided in the README)
- Create a settings JSON (e.g., cline_mcp_settings.json) and set the path to the built binary and required flags, such as --pat, --output-path, --default-user-id, and --default-app-id.
-
Run the server locally (or integrate via your MCP client framework).
- Ensure your MCP client references the server under the configured mcpServers entry.
Notes:
- You can adjust output paths and default IDs to your environment.
- The PAT must be kept secure; do not commit it to public repos.
Additional notes
Tips and caveats:
- Ensure your Go toolchain matches the 1.23+ requirement.
- If the server cannot reach Clarifai, double-check the PAT and network access.
- The example configuration writes outputs to the user’s Desktop; modify --output-path as needed.
- The server exposes read-only resources via MCP for Clarifai models, inputs, and annotations; creation/updating is performed via the Tools interface.
- If you run into permissions issues on macOS/Linux, ensure the executable has execute permissions (e.g., chmod +x mcp_binary).
- When testing, you can bypass cache and run tests with: go test -v -count=1 ./...
Related MCP Servers
trpc-agent-go
trpc-agent-go is a powerful Go framework for building intelligent agent systems using large language models (LLMs) and tools.
station
Station is our open-source runtime that lets teams deploy agents on their own infrastructure with full control.
tiger-cli
Tiger CLI is the command-line interface for Tiger Cloud. It includes an MCP server for helping coding agents write production-level Postgres code.
gopls
MCP server for golang projects development: Expand AI Code Agent ability boundary to have a semantic understanding and determinisic information for golang projects.
kubernetes
A Model Context Protocol (MCP) server for the Kubernetes API.
gcp-cost
💰 An MCP server that enables AI assistants to estimate Google Cloud costs, powered by Cloud Billing Catalog API and built with Genkit for Go