Metadata-Version: 2.4
Name: ckg-nvidia-ai
Version: 0.5.0
Summary: NVIDIA AI developer stack as a traversable knowledge graph — 20 CKGs, 998 nodes, MCP-native
Project-URL: Homepage, https://graphifymd.com
Project-URL: Repository, https://github.com/Yarmoluk/ckg-nvidia-ai
Project-URL: Bug Tracker, https://github.com/Yarmoluk/ckg-nvidia-ai/issues
Author-email: Daniel Yarmoluk <daniel.yarmoluk@gmail.com>
License: MIT
Keywords: ai-agents,cuda,knowledge-graph,llm,mcp,nemo,nim,nvidia,tensorrt
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Requires-Python: >=3.11
Requires-Dist: mcp[cli]>=1.0.0
Description-Content-Type: text/markdown

<!-- mcp-name: io.github.Yarmoluk/ckg-nvidia-ai -->
# MCP — CKG-NVIDIA-AI

[![PyPI version](https://img.shields.io/pypi/v/ckg-nvidia-ai?color=0f6e56&label=PyPI)](https://pypi.org/project/ckg-nvidia-ai/)
[![Downloads](https://img.shields.io/pypi/dm/ckg-nvidia-ai?color=0f6e56&label=installs%2Fmo)](https://pypi.org/project/ckg-nvidia-ai/)
[![Python](https://img.shields.io/pypi/pyversions/ckg-nvidia-ai?color=0f6e56)](https://pypi.org/project/ckg-nvidia-ai/)
[![License: MIT](https://img.shields.io/badge/license-MIT-0f6e56)](LICENSE)
[![Domains](https://img.shields.io/badge/domains-20-0f6e56)](https://graphifymd.com)
[![Nodes](https://img.shields.io/badge/nodes-998-0f6e56)](https://graphifymd.com)
[![F1: 0.471 · 4× RAG](https://img.shields.io/badge/F1-0.471_%C2%B74%C3%97_RAG-0f6e56)](https://github.com/Yarmoluk/ckg-benchmark/blob/main/paper/main.pdf)
[![KRB v0.6.2](https://img.shields.io/badge/benchmark-KRB_v0.6.2-13201c)](https://github.com/Yarmoluk/ckg-benchmark/blob/main/paper/main.pdf)
[![Free](https://img.shields.io/badge/free-forever-13201c)](https://pypi.org/project/ckg-nvidia-ai/)
[![Built by Graphify.md](https://img.shields.io/badge/built_by-Graphify.md-0f6e56)](https://graphifymd.com)

**MCP server — Compressed Knowledge Graph (CKG) for the full NVIDIA AI developer stack.**

**4× F1 · 11× fewer tokens · 998 nodes · deterministic traversal.**

> **Read-only.** This MCP server never writes, mutates, or executes. Every response is a declared graph traversal — not inference, not retrieval, not generation.

<p align="center">
  <a href="https://yarmoluk.github.io/ckg-nvidia-ai/carousel.html">
    <img src="docs/demo.png" alt="CKG-NVIDIA-AI domain carousel" width="960">
  </a>
</p>

<p align="center">
  <a href="https://graphifymd.com">
    <img src="docs/graph.png" alt="CKG-NVIDIA-AI — 20 domain knowledge graph" width="960">
  </a>
</p>

---

## The problem every AI team hits

More agents. More retrieval. More context. And accuracy drops.

This is the **intelligence paradox**: the more AI you add, the more tokens you burn re-discovering structure your system already knows — or could know. Research finds 73% of enterprise tokens are redundant context. In multi-agent pipelines, context efficiency collapses from 18.2 in Q1 to 1.6 by Q4 — **91% degradation with no model change**.

The model is not the bottleneck. The context is.

Every time your agent calls out to ask what TensorRT-LLM requires to run on Hopper, it spends ~2,982 tokens re-inferring a relationship that could be declared once and traversed in 269. That difference compounds across every query, every agent, every boundary crossing.

**The fix is not a better model. It is structured context.**

---

## What this package does

A CKG is a **layer** — a fast, inexpensive way to convert a large volume of domain documentation into structured, agent-traversable knowledge. Instead of retrieval, the agent traverses. Instead of inference, it reads declared relationships.

This package gives your agent the NVIDIA AI developer stack as its first layer: 20 domains, 998 nodes, every prerequisite chain declared and typed.

**Layers stack. Context windows open.**

| Layer | What your agent gains |
|---|---|
| NVIDIA AI docs (this package) | Platform prerequisites, deployment chains, hardware dependencies |
| Your domain | Company knowledge, internal APIs, product relationships |
| Competitive / market | Competitor stack, pricing, positioning — structured for traversal |
| Regulatory / compliance | Policy graphs, requirement chains, audit trails |

Each additional CKG layer costs your agent fewer tokens to operate, not more. Structured context is **model augmentation** — it does not replace what the model knows, it makes what it knows precise and auditable.

```
query_ckg("TensorRT-LLM", "nvidia-tensorrt-triton", depth=3)

→ TensorRT-LLM requires:
    CUDA Toolkit → CUDA Driver API, cuBLAS
    FP8 / FP4 Quantization → Hopper SM90 Architecture
  TensorRT-LLM enables:
    Triton Inference Server → NIM Microservice Runtime
```

That traversal cost **269 tokens**. A RAG call over the same question costs ~2,982. The graph doesn't guess — it traverses.

---

## Explore the graph

Once installed, paste this into Claude, Cursor, or any MCP client and see what comes back:

```
You have access to the nvidia-ai CKG. I want to understand what it actually takes to deploy
a real-time speech AI pipeline on NVIDIA Jetson at the edge — not the marketing version,
the real dependency chain.

Start here:
  get_prerequisites("Riva ASR", "nvidia-riva")

Then follow the chain into the inference layer:
  query_ckg("TensorRT-LLM", "nvidia-tensorrt-triton", depth=3)

Then map the edge hardware:
  get_prerequisites("Jetson Orin NX", "nvidia-jetson")

Present the result as a layered architecture map — foundation at the bottom, application at the
top, typed edges (REQUIRES / ENABLES) labeled between layers. Show where the three domains share
prerequisites. Flag anything that would block a cold-start deployment.
```

The graph will traverse four domains, surface shared prerequisites, and show you exactly what
stands between an idea and a running system — no hallucination, no guessing, just declared
relationships. See what it gives you.

---

## Quickstart

```bash
pip install ckg-nvidia-ai
```

```bash
uvx ckg-nvidia-ai          # MCP server mode
```

### Claude Desktop
```json
{
  "mcpServers": {
    "nvidia-ai": {
      "command": "uvx",
      "args": ["ckg-nvidia-ai"]
    }
  }
}
```

### Claude Code
```bash
claude mcp add nvidia-ai -- uvx ckg-nvidia-ai
```

### Cursor / Cline / Windsurf
```json
{ "mcpServers": { "nvidia-ai": { "command": "uvx", "args": ["ckg-nvidia-ai"] } } }
```

### System prompt snippet

```
You have access to the nvidia-ai MCP server — a typed dependency graph of 20 NVIDIA AI domains
(NIM, NeMo, TensorRT, CUDA, Isaac, Cosmos, Riva, and 13 more). When answering questions about
NVIDIA infrastructure, prerequisites, or deployment, call query_ckg() or get_prerequisites()
before responding. Do not guess dependency chains — traverse the graph instead.
```

---

## Accuracy model

Every edge was declared by a human reviewer. The graph is in active development — corrections arrive from the community weekly.

**Three-state confidence:**

| State | Meaning | How to use |
|---|---|---|
| `confidence: high` | Reviewed, cross-referenced with NVIDIA docs | Trust for planning |
| `confidence: null` | Plausible, not yet audited | Scaffold — verify before production |
| `confidence: low` | Flagged as uncertain | Treat as a hint, not a fact |

**Typed edges — semantic precision:**

| Type | Meaning | Agent use |
|---|---|---|
| `REQUIRES` | Hard prerequisite | Plan sequencing, gap detection |
| `ENABLES` | Unlocks a capability | Optimization paths |
| `RELATES_TO` | Conceptual proximity | Disambiguation, context |
| `IMPLEMENTS` | Concrete instantiation | Architecture mapping |

If an edge isn't declared, the traversal returns nothing rather than hallucinating a path. That silence is signal.

---

## Tools

All tools are read-only. No writes, no side effects.

### `list_domains()`
Returns all 20 NVIDIA AI domains. **Start here** — domain slugs are required by every other tool.

### `search_concepts(query, domain)`
Find concepts by keyword within a domain.

```
search_concepts("speculative decoding", "nvidia-nim")
→ Speculative Decoding [Optimization]
   Draft Model [Component]
   KV Cache [Infrastructure]
```

### `query_ckg(concept, domain, depth=3)`
Traverse the graph from a concept — prerequisites and dependents.

```
query_ckg("FlashAttention-3", "nvidia-cuda-x-libraries", 3)
→ Prerequisites: SRAM Tiling → On-Chip Memory → Warp Occupancy → ...
   Enables: Multi-Head Attention → KV Cache → Speculative Decoding
```

### `get_prerequisites(concept, domain)`
Full ordered prerequisite chain — everything needed to understand or deploy first.

```
get_prerequisites("Isaac Lab", "nvidia-isaac")
→ Isaac Lab → Isaac Sim → USD Composer → Omniverse Kit → ...
```

### `ask_nvidia(question, domain="")` — new in v0.4.0

Natural-language question answered by Qwen, grounded on the CKG. Runs entirely locally via Ollama.
The model answers only from graph-declared relationships — not parametric memory.

```bash
ollama pull qwen2.5:14b   # one-time setup
```

```
ask_nvidia("What does TensorRT-LLM require to run on Hopper?")

→ [REQUIRES] CUDA Toolkit → cuBLAS, CUDA Driver API
  [REQUIRES] FP8 / FP4 Quantization → Hopper SM90 Architecture
  [ENABLES]  Triton Inference Server → NIM Microservice Runtime
---
Grounded via TensorRT-LLM · nvidia-tensorrt-triton · model: qwen2.5:14b
```

```
ask_nvidia("What does Clara Parabricks require for whole-genome sequencing?")

→ Parabricks requires: NVIDIA GPU (Volta or later) → CUDA Toolkit ≥ 11.0
  Uses: cuBLAS, cuFFT for acceleration kernels
  Integrates with: MONAI for downstream analysis
---
Grounded via Parabricks · nvidia-clara · model: qwen2.5:14b
```

If Ollama is not running, `ask_nvidia()` returns raw graph context so the calling agent can still use it.

| Var | Default | Purpose |
|-----|---------|---------|
| `NVIDIA_CKG_MODEL` | `qwen2.5:14b` | Ollama model |
| `NVIDIA_CKG_OLLAMA` | `http://localhost:11434` | Ollama host |

No new dependencies. `mcp[cli]` is still the only install requirement.

---

## Domains

20 stacks · 998 nodes · call `list_domains()` for the full machine-readable list.

| Domain | Nodes | Description |
|--------|-------|-------------|
| `nvidia-nim` | 46 | Inference Microservices — deployment, scaling, speculative decoding |
| `nvidia-nemo` | 50 | NeMo framework — training, PEFT, guardrails, evaluation |
| `nvidia-tensorrt-triton` | 50 | TensorRT-LLM + Triton — quantization, batching, KV cache |
| `nvidia-cuda-toolkit` | 48 | CUDA compiler, PTX, memory hierarchy, Hopper/Blackwell |
| `nvidia-cuda-x-libraries` | 50 | cuBLAS, cuDNN, cuFFT, NCCL, Thrust |
| `nvidia-hpc-sdk` | 48 | OpenACC, OpenMP, CUDA Fortran, multi-GPU scaling |
| `nvidia-omniverse` | 50 | Universal Scene Description, simulation, digital twins |
| `nvidia-isaac` | 50 | Isaac Lab + Isaac Sim — robot learning, sensor simulation |
| `nvidia-cosmos` | 50 | Physical AI world foundation models — video generation |
| `nvidia-drive` | 50 | Autonomous vehicle stack — perception, planning, safety |
| `nvidia-jetson` | 50 | Edge AI — Orin NX, AGX, DeepStream, Holoscan |
| `nvidia-clara` | 50 | Healthcare AI — MONAI, Parabricks, BioNeMo, Holoscan SDK |
| `nvidia-metropolis` | 50 | Intelligent video analytics — VLMs, TAO Toolkit, DeepStream |
| `nvidia-riva` | 50 | Speech AI — ASR, TTS, NLP pipelines, streaming |
| `nvidia-gameworks` | 44 | Graphics R&D — DLSS, RTX, PhysX, Reflex |
| `nvidia-developer-tools` | 50 | Nsight, CUPTI, Compute Sanitizer, profiling stack |
| `nvidia-graphics-research` | 44 | Neural rendering, path tracing, differentiable rendering |
| `nvidia-ai-enterprise` | 50 | Enterprise AI — NIM blueprints, governance, fleet management |
| `nvidia-developer-ecosystem` | 50 | NGC, DGX, Inception, AgentIQ, MCP integration |
| `nvidia-openshell` | 62 | Agent sandbox runtime — policy enforcement, CVEs, authorization |

---

## Benchmark

Evaluated on [KRB Benchmark v0.6.2](https://github.com/Yarmoluk/ckg-benchmark/blob/main/paper/main.pdf) — open dataset, reproducible methodology, fixed baselines.

| System | Macro F1 | Tokens/query | Cost/1K queries |
|---|---|---|---|
| **CKG** | **0.471** | **269** | **$7.81** |
| RAG (text-embedding-3-small) | 0.123 | 2,982 | $76.23 |
| GraphRAG (MS global mode) | 0.120 | — | — |

4× F1 · 11× fewer tokens · 5-hop F1 **0.772** vs **0.170** · auditable by design

5-hop reasoning is where the gap compounds: retrieval degrades with each hop; graph traversal does not.

---

## How the graph is built

Each domain is a DAG stored as typed edge CSV — human-authored and human-reviewed:

```
ConceptID, ConceptLabel, Dependencies, TaxonomyID
1, TensorRT-LLM,    "",                    Framework
2, CUDA Toolkit,    "",                    Platform
3, FP8 Quantization,"2:REQUIRES",          Optimization
4, Hopper SM90,     "2:REQUIRES",          Architecture
5, Speculative Dec.,"1:REQUIRES|4:REQUIRES",Optimization
```

No embeddings. No vector index. No probabilistic retrieval. The graph is the compressed form — built once, reviewed once, traversed forever.

---

## Why context efficiency collapses — and how CKG reverses it

Liu et al. ([arXiv:2606.30986](https://arxiv.org/abs/2606.30986)) formally quantify **Context Transaction Cost (CTC)**: the compound tax paid every time context crosses an agent boundary. In multi-agent pipelines, CTC efficiency falls from 18.2 in Q1 to 1.6 by Q4 — 91% collapse with no model change.

CKG attacks all three root causes:

| CTC component | What it is | CKG's response |
|---|---|---|
| Token Latency Burden (τ) | Compute cost of transmitting context | 269 tokens instead of 2,982 |
| Handoff Cost (H) | Serialization loss at agent boundaries | `get_prerequisites()` replaces re-retrieval |
| Compression Loss (C) | Information destroyed when context is summarized | The graph *is* the compressed form — done once, offline |

Structured context doesn't consume your context window. It opens it.

---

## The alternative to fine-tuning

When task-specific data is scarce, fine-tuning is often the first instinct — and frequently the wrong one. Fine-tuning requires thousands of labeled examples, a training budget, and a retraining cycle every time your domain shifts. By the time a large enterprise model project completes, the knowledge it was trained on is often already stale.

CKG encodes domain knowledge once as a typed graph. When the knowledge changes — new regulations, new product, new market — you update the graph. Not the model.

> *Directional intelligence, deployed today, updatable tomorrow — at 11× lower token cost.*

**The commercial case in three parts:**

| | Fine-tuning | CKG |
|---|---|---|
| **Speed** | 6-month cycle before you see results | One session to deploy |
| **Adaptability** | Retrain when knowledge shifts | Update the graph, not the model |
| **Sustainability** | Expensive to run at scale | 269 tokens/query — 10,000 questions vs 1,000 |

The opponent isn't just fine-tuning — it's the *perfectionism-as-procurement-strategy* trap: 18 months and significant budget chasing the last few accuracy points while competitors ship directional answers at $7.81/query. Fine-tuning handles the final mile of specialization. CKG handles the knowledge architecture the fine-tuned model still needs to operate correctly.

**Enterprise risk coverage:**

| Risk | CKG response |
|---|---|
| Drift without version control | Typed, declared edges don't drift — every change is a graph update |
| Institutional knowledge lock-in | Human-readable, portable CSV — not vendor-locked |
| Provenance reconstruction failure | Every edge has a declared source and type — inherently auditable |
| New hire / auditor onboarding | CKG as runbook — traversable by anyone, not just the team that built it |

---

## Corrections welcome

Spotted a wrong edge? A `RELATES_TO` that should be `REQUIRES`? A missing concept in Riva or Isaac?

**Edge corrections are the highest-value contribution.** The graph gets more useful with every fix.
Open an issue or PR — see [CONTRIBUTING.md](CONTRIBUTING.md) for the review format.

---

## EVAL

```
benchmark: ckg-benchmark v0.6.2
dataset: huggingface.co/datasets/danyarm/ckg-benchmark
benchmarked: false
rag_baseline_f1: 0.123
graphrag_baseline_f1: 0.120
mean_tokens: 269
paper: github.com/Yarmoluk/ckg-benchmark/blob/main/paper/main.pdf
```

---

## Want a CKG for your domain?

A CKG is a **knowledge layer** — the context optimization component of an agent stack. Instead of retrieval, your agent traverses declared relationships. Fast to build, inexpensive to run, updatable without retraining.

Turn your company documentation, internal APIs, competitive intelligence, or regulatory requirements into a CKG layer in a single session. Stack it with this one. Each layer opens more of your context window without adding token cost.

**[graphifymd.com](https://graphifymd.com)** — contact us for custom domain CKGs and enterprise solutions, including Sealed Appliance: a private CKG + query server deployed in your environment.

CKG Catalog · Context Optimization · Context Architecture · Token Efficiency · Accuracy

---

## Ecosystem

This package is part of the Graphify.md CKG stack.

| Package | What it does |
|---|---|
| **[ckg-nvidia-ai](https://pypi.org/project/ckg-nvidia-ai/)** | This repo — 20 NVIDIA AI domains, free |
| **[ckg-mcp](https://pypi.org/project/ckg-mcp/)** | 97 domains: NVIDIA + science, finance, law, healthcare |
| **[agentmem-mcp](https://github.com/Yarmoluk/agent-memory-mcp)** | Cross-session agent memory, not vendor-locked |
| **[KRB Benchmark](https://huggingface.co/datasets/danyarm/ckg-benchmark)** | Open benchmark dataset — reproduce the F1 numbers yourself |
| **[ckg-eval](https://github.com/Yarmoluk/ckg-eval)** | Path-Fidelity Score (PFS) — reasoning path correctness metric |

**[graphifymd.com/pro/](https://graphifymd.com/pro/)** — custom domain CKGs, sealed appliances, enterprise.

---

*Patent pending. 42× Token Intelligence — more intelligence per watt.*
