Skip to main content
Glama
Medhā MCP

Medhā MCP

by vivmuk

Medhā MCP

Operator-tuned fork of @veniceai/mcp-server. Same 31 Venice primitives; curated presets for chat/image/video/audio/music baked in via env defaults and surfaced in tool descriptions; one discoverable medha://favorites resource so any agent can fetch the operator's preferences before making a call. Use from any MCP host — Claude Desktop, Claude Code, Cursor, Codex CLI, Hermes, Jiva, Rati, LM Studio, Continue, LibreChat, Open WebUI, AnythingLLM, Jan, Le Chat.


What you get

Surface

Count

Notes

Tools

31

Identical to upstream; descriptions augmented with Operator preferences — default: … also try: … overlays keyed off src/presets.ts

Resources

4

venice://models, venice://styles, venice://voices (upstream) + medha://favorites (canonical JSON dump of presets)

Prompts

7

3 upstream (uncensored-research, nsfw-creative-writing, image-style-explorer) + 4 Medhā workflow briefs (medha_music_video_brief, medha_podcast_pipeline, medha_dashboard_poster, medha_character_dossier)

Transports

stdio and Streamable HTTP (/mcp)

HTTP is the Railway-deployed mode; stdio stays for npx-style install

The Medhā MCP server is thin by design: it forwards agent tool calls to api.venice.ai. The agent (Claude Code / Hermes / Codex / Jiva / Rati / Cursor / etc.) is the orchestrator — it plans the steps, picks models, calls tools in order, handles async polling, and stitches art + audio together.


Related MCP server: mcp-media-engine

Quickstart (5 min deploy on Railway)

1. Get a Venice API key

venice.ai → Settings → API Keys. Save it locally on the operator's Mac:

echo "export VENICE_API_KEY=*** ~/.config/railway/venice-rati-key.env
chmod 600 ~/.config/railway/venice-rati-key.env

2. Clone + push

gh repo clone veniceai/venice-mcp-server ~/tmp/medha-deploy
cd ~/tmp/medha-deploy
# (already customized to Medhā on master if you cloned vivmuk/medha-mcp;
# upstream clone just needs the Phase 1 patches to branding files.)

3. Railway project + service

# Create `medha` project in vivmuk's workspace
railway init --name "medha" --workspace "vivmuk's Projects"
gh repo create vivmuk/medha-mcp \
    --public \
    --description "Medhā — operator-tuned Venice AI MCP bridge." \
    --default-branch master
cd ~/tmp/medha-deploy
git remote rename origin upstream
git remote add origin https://github.com/vivmuk/medha-mcp.git
git fetch upstream --unshallow
git push -u origin master
# Create Railway service that pulls from GitHub
railway add --service medha --repo vivmuk/medha-mcp --branch master

4. Set env vars

Generate a strong bearer token for the MCP HTTP layer:

BEARER=$(python3 -c "import secrets; print(secrets.token_hex(32))")
echo "$BEARER" > ~/.config/railway/medha-bearer.token
chmod 600 ~/.config/railway/medha-bearer.token

Push secrets via --stdin (chat-safe; never argv):

unset RAILWAY_TOKEN RAILWAY_API_TOKEN

python3 - <<'PY'
import subprocess
from pathlib import Path
KEY = Path("/Users/vivgatesai/.config/railway/venice-rati-key.env").read_text()
KV = {l.split("=",1)[0].lstrip("export ").strip(): l.split("=",1)[1].strip().strip('"').strip("'") for l in KEY.splitlines() if l.startswith("export ")}
BEARER = Path("/Users/vivgatesai/.config/railway/medha-bearer.token").read_text().strip()
base = ["railway","variable","set","--service","medha","--skip-deploys"]
for label, value in [("VENICE_API_KEY", KV["VENICE_API_KEY"]), ("VENICE_MCP_AUTH_TOKEN", BEARER)]:
    subprocess.run(base + [label, "--stdin"], input=value, capture_output=True, text=True, timeout=60)
PY

Plain env (no secrets — argv-safe):

for K in \
  "VENICE_MCP_HTTP=1" \
  "VENICE_MCP_HOST=0.0.0.0" \
  "VENICE_DISABLE_NSFW=0" \
  "VENICE_DEFAULT_CHAT_MODEL=minimax-m3-preview" \
  "VENICE_DEFAULT_IMAGE_MODEL=flux-2-pro" \
  "VENICE_DEFAULT_TTS_MODEL=tts-kokoro" \
  "VENICE_DEFAULT_ASR_MODEL=openai/whisper-large-v3" \
  "VENICE_DEFAULT_VIDEO_MODEL=ltx-2" \
  "VENICE_DEFAULT_MUSIC_MODEL=ace-step-15" \
  "VENICE_HTTP_TIMEOUT_MS=120000" \
  "VENICE_MCP_MAX_SESSIONS=100" \
  "VENICE_MCP_SESSION_TTL_MS=1800000" \
  "PORT=3333" \
  "MEDHA_SERVER_NAME=@medha/mcp-server" \
  "MEDHA_SERVER_VERSION=0.4.0-medha"
do
  railway variable set --service medha --skip-deploys "$K"
done

5. Deploy + attach domain

cd ~/tmp/medha-deploy
railway up --service medha --detach
railway domain --service medha
# → https://medha-production.up.railway.app/mcp

6. Smoke

BEARER=$(cat ~/.config/railway/medha-bearer.token)
URL=https://medha-production.up.railway.app/mcp

curl -sS -i -X POST "$URL" \
  -H "Authorization: Bearer *** \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"smoke","version":"0.0.1"}}}' \
  | head

HTTP 200 with a mcp-session-id UUID header → you're live.

7. Connect an agent

See presets.md for the canonical defaults table. For Claude Desktop / Claude Code CLI / Cursor / Codex CLI / Hermes / Jiva connector recipes, see CONNECTORS.md.


Configuration reference

Env

Default

Purpose

VENICE_API_KEY (required)

(none)

Operator's Venice API key. Forwarded as Authorization: Bearer to all upstream calls.

VENICE_SIWX_TOKEN

(none)

Optional SIWE-signed wallet token (x402 mode). Used only when VENICE_API_KEY is unset.

VENICE_MCP_HTTP

(unset)

Set to 1 to enable HTTP mode (binds :3333/mcp).

VENICE_MCP_HOST

127.0.0.1

Bind address. 0.0.0.0 for LAN/Railway.

VENICE_MCP_AUTH_TOKEN

(none)

Bearer required for /mcp when host ≠ loopback. Generate with python3 -c "import secrets; print(secrets.token_hex(32))".

VENICE_MCP_MAX_SESSIONS

100

Cap on concurrent Streamable HTTP sessions.

VENICE_MCP_SESSION_TTL_MS

1800000

Idle session TTL (30 min).

VENICE_HTTP_TIMEOUT_MS

60000

Per-call upstream timeout. Default 120s for video/music latencies.

VENICE_DISABLE_NSFW

0

Set to 1 to remove NSFW capability notes from tool descriptions.

VENICE_DEFAULT_CHAT_MODEL

venice-uncensored

Medhā default: minimax-m3-preview.

VENICE_DEFAULT_IMAGE_MODEL

flux-2-pro

(same as upstream)

VENICE_DEFAULT_TTS_MODEL

tts-kokoro

(same as upstream)

VENICE_DEFAULT_ASR_MODEL

openai/whisper-large-v3

(same as upstream)

MEDHA_SERVER_NAME

@medha/mcp-server

Override the MCP serverInfo.name.

MEDHA_SERVER_VERSION

0.4.0-medha

Override the MCP serverInfo.version.

PORT

3333

Railway-respected; controls the listener.


Operator preferences

The operator-curated defaults are baked into the tool descriptions so agents read them on every tools/list call. They are also a single canonical JSON document available via the medha://favorites resource:

# After defining BEARER + SID as in the smoke test:
curl -sS -X POST https://medha-production.up.railway.app/mcp \
  -H "Authorization: Bearer *** \
  -H "Content-Type: application/json" \
  -H "mcp-session-id: $SID" \
  -d '{"jsonrpc":"2.0","id":2,"method":"resources/read","params":{"uri":"medha://favorites"}}'

See presets.md for the full table with rationale per domain (reasoning / coding / roleplay / vision / longctx / image / music / video / etc.).

The operator prefs are HINTS, not hard rules. Agents you connect can pass model="<any-venice-id>" on any call and the server will forward it. The presets exist to save the agent from re-discovering the operator's taste on every prompt.


Workflow prompts (Medhā-only)

Beyond the upstream 3 (uncensored-research, nsfw-creative-writing, image-style-explorer), Medhā ships 4 workflow prompts that guide the agent into known-good multi-tool sequences:

Prompt

Workflow

Default models

medha_music_video_brief

Quote → music gen → 4-12 image frames → video interpolation per frame → optional TTS.

ace-step-15 (music) · flux-2-pro (image) · ltx-2 (video) · tts-kokoro (TTS)

medha_podcast_pipeline

Web search → scrape top URLs → script via chat → TTS.

qwen-3-7-max (chat) · tts-kokoro (TTS)

medha_dashboard_poster

Chat-compose prompt → flux-2-pro → optional bg-remove → optional 2× upscale.

qwen-3-7-max (chat) · flux-2-pro (image)

medha_character_dossier

Dossier + system prompt via roleplay chat → TTS sample → optional avatar image.

venice-uncensored-role-play (chat) · tts-kokoro (TTS) · flux-2-pro (image)

When the agent invokes one of these prompts, MCP returns a single user-role message that lays out the recommended tool-call sequence with the operator's preferred models. The agent then orchestrates from there.


Provenance + license

Upstream: github.com/veniceai/venice-mcp-server @ v0.2.0 — MIT-licensed by Venice AI. Medhā is a fork: same code, operator-tuned UX. No warranty or SLA from Venice AI. Use at your own risk.

Maintainer: Vivek M (@vivmuk). Brand: Medhā — Sanskrit medhā (मेधा) = wisdom / intelligence / mental power.

Available Tools

31 tools
venice_asrVenice ASR (Speech-to-Text)B

Transcribe audio. Fetches the URL server-side and forwards as multipart/form-data file upload. Operator preferences — default: openai/whisper-large-v3. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: audio_url (required), model, language, response_format.

venice_audio_quoteVenice Music Cost QuoteA

Get a price quote for a music generation BEFORE queuing. Useful for budgeting. Pre-flight price quote for music generation. No authentication required.

Inputs: model (required), character_count, duration_seconds.

venice_chatVenice Chat (LLM)A

Run an OpenAI-compatible chat completion via Venice's uncensored LLM catalog (Claude, GPT-5, Llama, DeepSeek, Qwen, GLM, Kimi, Venice Uncensored 1.1, etc.). Operator preferences — default: minimax-m3-preview; also try: qwen-3-7-max / venice-uncensored-role-play / gemini-3-1-pro-preview. cheap+long (524K ctx) → 1M ctx → character voice → premium reasoning. Uncensored: NSFW prompts allowed where the model permits. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: messages (required), stop, model, top_p, +2 more.

venice_chat_with_characterVenice Character ChatA

Chat with a Venice character by slug. Note: the character lookup itself is API-key-only, but the chat completion supports x402 — so x402 users may need to fetch character info via API key first. Operator preferences — default: venice-uncensored-role-play; also try: venice-uncensored-1-2. Use character_slug from list_characters. Uncensored: NSFW prompts allowed where the model permits.

Inputs: messages (required), character_slug (required), model, max_tokens, +1 more.

venice_crypto_rpcVenice Crypto RPC ProxyA

Proxy a JSON-RPC call to a supported blockchain network (eth_call, eth_blockNumber, etc.). Networks include "base-mainnet", "ethereum-mainnet", "polygon-mainnet", "arbitrum-mainnet", "optimism-mainnet", and others. List all via GET /api/v1/crypto/rpc/networks. Proxies eth_call / eth_blockNumber to Base, Ethereum, Polygon, Arbitrum, Optimism. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: network (required), rpc_method (required), rpc_params.

venice_embeddingsVenice EmbeddingsA

Compute embeddings for text input (OpenAI-compatible). Operator preferences — default: text-embedding-3-small; also try: gemini-embedding-001. Operator batch preferred; OpenAI-compatible. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: input (required), model, encoding_format.

venice_image_editVenice Image EditB

Edit an image with a prompt. Returns base64 PNG. Operator preferences — default: firered-image-edit; also try: qwen-image-edit. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: prompt (required), image_url (required), model, safe_mode, +1 more.

venice_image_generateVenice Image GenerateA

Generate an image. Supports Flux 2 Pro/Max, Lustify SDXL, Anime (WAI), Qwen Image, GPT Image, Nano Banana Pro and others. Operator preferences — default: flux-2-pro; also try: qwen-image / lustify-sdxl / nano-banana-pro. Operator default is flux-2-pro. Use nano-banana-pro for photoreal, anime-wai for stylization, lustify-sdxl for character work. Uncensored: NSFW prompts allowed where the model permits. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: prompt (required), seed, model, steps, +5 more.

venice_image_multi_editVenice Image Multi-EditC

Edit multiple images together with a single prompt (multi-image composition / outpainting). Returns base64 PNG. Operator preferences — default: flux-2-pro; also try: qwen-image. Composition / outpainting; 2-8 input images. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: prompt (required), image_urls (required), model, aspect_ratio.

venice_image_remove_bgVenice Image Background RemoveA

Remove image background; returns a transparent PNG (base64). Operator preferences — default: bria-remove-bg. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: image_url (required).

venice_image_stylesVenice Image StylesA

List image style presets available for venice_image_generate. No authentication required.

Inputs: no named parameters.

venice_image_upscaleVenice Image UpscaleA

Upscale an image (1-4× scale). Endpoint requires base64 image; this tool fetches the URL and uploads it. Returns base64 PNG. Operator preferences — default: flux-2-pro; also try: nano-banana-pro. 1-4× enhancement + replication control. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: image_url (required), scale, enhance, replication.

venice_list_charactersVenice List CharactersB

List public Venice characters. Public Venice characters (api-key only, no x402). API key required — this endpoint does not accept x402 wallet auth.

Inputs: tag, limit, offset, search.

venice_list_modelsVenice List ModelsA

List the live model catalog with capabilities and prices. Live catalog with capability flags + USD pricing. No authentication required.

Inputs: type.

venice_music_completeVenice Music Complete (cleanup)B

Mark a completed music job as downloaded. Cleanup hook. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: model (required), queue_id (required).

venice_music_generateVenice Music QueueA

Queue music generation. Available models: ace-step-15, elevenlabs-music, minimax-music-v2/v25/v26, stable-audio-25, mmaudio-v2-text-to-audio, elevenlabs-sound-effects-v2. Operator preferences — default: ace-step-15; also try: elevenlabs-music / minimax-music-v2 / minimax-music-v25. Operator default = ace-step-15 (broad genre). Elevenlabs-music for vocal. MMaudio-V2 for stem separation. Uncensored: NSFW prompts allowed where the model permits. Supports x402 wallet auth (no Venice account needed) and API key. Returns { model, queue_id }; poll with venice_music_status.

Inputs: model (required), prompt (required), lyrics, instrumental, +1 more.

venice_music_statusVenice Music Retrieve / StatusA

Check status of a queued music job (POST endpoint with body {model, queue_id}). POST /v1/audio/retrieve. Async until COMPLETED. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: model (required), queue_id (required), delete_media_on_completion.

venice_responsesVenice Responses APIA

OpenAI-compatible Responses API. Single-turn or multi-turn with tool support. Operator preferences — default: minimax-m3-preview; also try: qwen-3-7-max. OpenAI Responses API; agentic tool-use loop supported. Uncensored: NSFW prompts allowed where the model permits. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: input (required), model, temperature, max_output_tokens.

venice_text_parserVenice Text Parser (PDF/DOCX/EPUB/PPTX/XLSX)A

Extract text from a document URL. Fetches the URL server-side and uploads the file as multipart/form-data. Operator preferences — default: firecrawl-default. PDF / DOCX / EPUB / PPTX / XLSX → text. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: url (required).

venice_ttsVenice TTS (Speech)B

Convert text to speech. Supports cloned voices + emotion tags ([whispers], [sarcastically], etc.). Operator preferences — default: tts-kokoro; also try: elevenlabs-tts. Voice cloning + emotion tags ([whispers], [sarcastically], [laughs], etc.). Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: input (required), model, speed, voice, +1 more.

venice_video_completeVenice Video Complete (cleanup)A

Mark a completed video as downloaded; deletes server-side media. Cleanup hook; removes server-side media. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: model (required), queue_id (required).

venice_video_generateVenice Video QueueA

Queue a video generation. Supports Sora 2, Veo 3.1, Kling, Wan, LTX 2, Seedance, Runway Gen-4, and others. Pick a specific id like "veo3.1-fast-text-to-video", "veo3.1-fast-image-to-video", "kling-2.6-pro-text-to-video", "wan-2.6-text-to-video", "seedance-2-0-r2v" etc. Operator preferences — default: ltx-2; also try: sora-2 / veo3.1-fast / kling-2.6-pro. Operator prefers ltx-2 for speed. Sora-2 / Veo3.1 / Kling for premium. Seedance 2.0 r2v for video-to-video. Always quote first via venice_video_quote. Uncensored: NSFW prompts allowed where the model permits. Supports x402 wallet auth (no Venice account needed) and API key. Returns { model, queue_id }; poll with venice_video_status. NOTE: 'duration' is a string enum like '4s' / '6s' / '8s' (model-specific, see model card).

Inputs: model (required), prompt (required), seed, audio, +14 more.

venice_video_quoteVenice Video Cost QuoteA

Get a price quote for a video generation BEFORE queuing. Always quote-generate before queue when model pricing is unknown. No authentication required.

Inputs: model (required), duration.

venice_video_statusVenice Video Retrieve / StatusA

Check status of a queued video job. Status enum: PROCESSING, COMPLETED. POST endpoint with body {model, queue_id}. POST /v1/video/retrieve — Venice returns PROCESSING or COMPLETED. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: model (required), queue_id (required), delete_media_on_completion.

venice_video_transcriptionsVenice Video TranscriptionsB

Transcribe a YouTube video URL. Operator preferences — default: youtube-default. YouTube URL → text transcript. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: url (required), response_format.

venice_voice_cloneVenice Voice Clone / ListB

Manage TTS voices. Action 'list' returns the static catalog of built-in voices grouped by TTS model (Venice does not expose a list endpoint). Action 'create' clones a voice from a sample audio URL via multipart upload to /v1/audio/voices. List built-in voices OR clone from a sample audio URL. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: action (required), model, sample_url.

venice_web_scrapeVenice Web ScrapeA

Scrape one URL into markdown text. Operator preferences — default: firecrawl-default. One URL → markdown text. Supports x402 wallet auth (no Venice account needed) and API key.

Inputs: url (required), format.

venice_x402_balanceVenice x402 Wallet BalanceA

Check the prepaid x402 credit balance for a wallet address. SIWX-ONLY: this endpoint rejects API key auth and requires X-Sign-In-With-X (forwarded from VENICE_SIWX_TOKEN). The wallet in the path must match the SIWX-authenticated wallet.

Inputs: wallet_address (required).

venice_x402_top_up_infoVenice x402 Top-up RequirementsA

Fetch step-1 top-up requirements (network, USDC token address, receiver wallet, min amount). Steps 2 (sign USDC authorization) and 3 (POST signed payment) require a wallet and happen OUTSIDE this MCP server.

Inputs: wallet_address (required), amount_usd.

venice_x402_transactionsVenice x402 Transaction HistoryA

List recent x402 top-up + debit transactions for a wallet. SIWX-ONLY: rejects API key, requires X-Sign-In-With-X (VENICE_SIWX_TOKEN). The wallet in the path must match the SIWX-authenticated wallet.

Inputs: wallet_address (required), limit.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 31 tools

    Disambiguation4/5

    Most tools are clearly distinct by domain (chat, image, video, music, web, voice, crypto, x402). However, venice_chat and venice_responses overlap significantly — both are chat completions with nearly identical operator preferences and uncensored behavior. Similarly, venice_video_status/venice_music_status and venice_video_complete/venice_music_complete follow parallel but separate verbs that are easy to confuse across media types. The image_edit vs image_multi_edit distinction is reasonably clear, but chat vs responses and the parallel status/complete pairs introduce ambiguity.

    Naming Consistency4/5

    The naming follows a strong venice_<domain>_<action> pattern consistently (venice_image_generate, venice_video_status, venice_music_complete, venice_web_search). The domain prefix is uniformly applied to all 31 tools. Minor inconsistency: some tools use generic verbs (chat, asr, tts) while others use domain+verb, and venice_voice_clone uses 'manage' semantics differently from venice_image_styles. Overall highly predictable but with minor phrasing variations.

    Tool Count2/5

    31 tools is quite heavy for a single server surface. While the underlying Venice API is genuinely broad (chat, images, video, music, voice, web, crypto, x402 billing), the server bundles what could be several focused MCP servers into one, exceeding the comfortable range. The count feels bloated, especially with 5 different x402/crypto tools and 4 video tools plus 4 music tools that duplicate the lifecycle pattern.

    Completeness4/5

    The surface is remarkably comprehensive, covering chat, images (generate/edit/multi-edit/upscale/remove-bg/styles), video (generate/status/complete/quote), music (generate/status/complete/quote), voice (TTS/asr/clone), text parsing, web search/scrape, embeddings, and x402 billing. Minor gaps: text parsing accepts URLs but there's no direct file-upload handler for documents, and there's no image generation status polling since it's synchronous, which is fine. The x402 billing flow stops at step-1 direction without steps 2-3, which is acknowledged as external.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers