NVIDIA NIM MCP Server

NVIDIA NIM MCP Server

Enables AI agents to access 140+ NVIDIA NIM models for chat, embeddings, reranking, vision, image generation, OCR, and content safety via stdio.

Category
访问服务器

README

@hallaxius/nvidia-nim-mcp

License: MIT npm version Bun

A Model Context Protocol (MCP) server that exposes 140+ NVIDIA NIM models to AI agents via stdio.

Supports: chat, embeddings, reranking, vision, image generation (FLUX), OCR, and content safety.

Features

  • Thin wrapper around integrate.api.nvidia.com/v1 and ai.api.nvidia.com/v1
  • Zero external dependencies (uses global fetch)
  • Bun-native, Node 20+ compatible
  • Offline model capability snapshot for quick lookups
  • Automatic fallback heuristics for unknown models
  • Streaming disabled by default (safe for stdio)

Installation

bun add @hallaxius/nvidia-nim-mcp
# or
bunx @hallaxius/nvidia-nim-mcp

Quick Setup

The fastest way to get started — configure your API key once and forget it:

# Configure your key (one-time)
bunx @hallaxius/nvidia-nim-mcp setup "nvapi-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

# Or run interactively (it will prompt for the key)
bunx @hallaxius/nvidia-nim-mcp setup

# Start the MCP server
bunx @hallaxius/nvidia-nim-mcp

The key is saved to ~/.config/nvidia-nim-mcp/config.json. Environment variables still take priority when set.

Usage

1. Set your NVIDIA API Key

You can also configure the key via environment variable:

export NVIDIA_API_KEY=nvapi-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

Supported aliases: NVIDIA_API_KEY, NIM_API_KEY, NVAPI_KEY.

Get your key: https://build.nvidia.com/explore/discover

2. Run the MCP Server

bunx @hallaxius/nvidia-nim-mcp

The server starts over stdio and registers 9 tools.

3. Configure Your AI Agent

See AGENTS.md for integration with:

Tools

Tool Description Default Model
nim_list_models List all available NIM model IDs
nim_get_model_capabilities Get model type, vision, tools, context
nim_chat_completion Chat completion with LLM z-ai/glm-5.2
nim_create_embeddings Generate text embeddings nvidia/nv-embed-v1
nim_rerank_passages Rank passages by query relevance nvidia/llama-3.2-nemoretriever-500m-rerank-v2
nim_vision_inference Multi-modal inference (text + images) meta/llama-3.2-90b-vision-instruct
nim_flux_generate_image Generate images via FLUX black-forest-labs/flux.1-schnell
nim_ocr_extract Extract text from images (OCR) nvidia/nemotron-ocr-v1
nim_safety_classify Classify text for safety meta/llama-guard-4-12b

Examples

List Available Models

// Agent code / MCP client usage
const models = await callTool("nim_list_models", {});
// Returns: "z-ai/glm-5.2\nmeta/llama-3.3-70b-instruct\n..."

Chat Completion

const result = await callTool("nim_chat_completion", {
  messages: [{ role: "user", content: "Explain quantum computing simply" }],
  model: "z-ai/glm-5.2",
  temperature: 0.7,
  max_tokens: 2048,
});
// Returns: { content: [{ type: "text", text: "..." }] }

Vision (VLM)

const result = await callTool("nim_vision_inference", {
  messages: [
    {
      role: "user",
      content: [
        { type: "text", text: "What is in this image?" },
        { type: "image_url", image_url: { url: "data:image/jpeg;base64,/9j/..." } },
      ],
    },
  ],
  model: "meta/llama-3.2-90b-vision-instruct",
});

Embeddings

const result = await callTool("nim_create_embeddings", {
  inputs: ["Hello world", "AI is amazing"],
  model: "nvidia/nv-embed-v1",
});
// Returns: { embeddings: [[...], [...]], model: "nvidia/nv-embed-v1", usage: {...} }

Reranking

const result = await callTool("nim_rerank_passages", {
  query: "What is the capital of France?",
  passages: ["Paris is the capital of France.", "Berlin is the capital of Germany.", "London is the capital of the UK."],
  model: "nvidia/llama-3.2-nemoretriever-500m-rerank-v2",
});
// Returns: { results: [{ index: 0, score: 0.95 }, ...] }

Image Generation (FLUX)

const result = await callTool("nim_flux_generate_image", {
  prompt: "A serene mountain landscape at sunset, digital art",
  width: 1024,
  height: 1024,
  model: "black-forest-labs/flux.1-schnell",
});
// Returns: { content: [{ type: "image", data: "<base64>", mimeType: "image/png" }] }

OCR

const result = await callTool("nim_ocr_extract", {
  image_path: "/absolute/path/to/screenshot.png",
  // or: image_base64: "<base64 string>"
  model: "nvidia/nemotron-ocr-v1",
});
// Returns: { text: "Extracted text...", detections: [{ text, confidence, bounding_box }] }

Safety Classification

const result = await callTool("nim_safety_classify", {
  text: "This is a harmless text.",
  model: "meta/llama-guard-4-12b",
});
// Returns: { safe: true, categories: {...}, explanation: "..." }

Development

Build

bun run build

Type-check

bun run typecheck

Dev mode (stdio server)

bun run dev

Refresh Model Capabilities

bun run refresh

This fetches the latest model catalog from NVIDIA and updates src/models/capabilities.json.

Supported Models

140+ models across families (sourced from build.nvidia.com/models):

Category Families
LLM Llama, Nemotron, DeepSeek, Qwen, GLM, Mistral, Mixtral, Gemma, Phi, GPT-OSS, MiniMax, Step, DiffusionGemma, SEED-OSS, Solar, Sarvam M, Stockmark
VLM Llama Vision, Nemotron VL, Phi-4 Multimodal, Cosmos, PaliGemma, MiniMax-M3, Ising Calibration
Embeddings NV-Embed, BGE-M3, Llama-Nemotron-Embed, ESM-2 (protein)
Rerank Llama-Nemotron-Rerank, Rerank-QA-Mistral
Image Gen FLUX.1 (dev, schnell), FLUX.2 Klein, Stable Diffusion 3.5, Qwen-Image
OCR & Document Nemotron OCR, Nemoretriever Parse/PAGE, PaddleOCR, NV-YOLOX
Safety Llama-Guard, Nemotron Safety, Nemoguard, GLiNER PII
Audio & Speech Whisper, Parakeet, Canary, Magpie TTS, Chatterbox TTS, Riva Translate, Studio Voice, Nemotron Voicechat
Biology & Science AlphaFold2, ESMFold, OpenFold2/3, Boltz-2, MolMIM, DiffDock, ProteinMPNN, RFDiffusion, Evo2, GenMol, VISTA-3D
Physics & Simulation CuOpt, FourCastNet, Simcenter STAR-CCM+, Fidelity, Fluent, Spectre-X
Autonomous Driving BEVFormer, SparseDrive, StreamPETR
3D & Vision TRELLIS, Relighting, EyeContact, Synthetic Video Detector

The catalog changes — run bun run refresh to update the local capability snapshot, or call nim_list_models at runtime for the latest list.

See https://build.nvidia.com/models for the full catalog.

License

MIT © 2026 @hallaxius

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选