RAG Eval
NVIDIAOfficialCreated by NVIDIA RAG
- Skill
- Review and audit
- Software development
- Apache-2.0
- Medium risk
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill provides a structured approach to evaluating RAG (Retrieval-Augmented Generation) pipeline quality using the NVIDIA RAG Blueprint framework. It utilizes a specific filesystem layout consisting of a corpus directory and a train.json file to run automated evaluations via the evaluate_rag.py script. The process leverages RAGAS metrics to assess accuracy, context relevance, and groundedness, allowing developers to tune retrieval and generation parameters for optimal performance.
What it does
- Automates RAG quality evaluation using RAGAS metrics.
- Supports tuning of retrieval parameters like top_k and vdb_top_k.
- Enables configuration of generation settings such as temperature and max-tokens.
- Provides structured JSON output for headline metrics and per-query forensics.
- Includes troubleshooting guidance for common ingestion and evaluation errors.
- Facilitates comparative analysis of different pipeline configurations.
When to use it
- When you need to measure the quality of your RAG pipeline's responses.
- When comparing different retrieval or generation settings for your RAG system.
- When you have prepared a dataset following the required corpus and train.json structure.
- When you need to perform forensic analysis on specific query failures.
Advantages
- Standardized evaluation workflow within the NVIDIA RAG Blueprint ecosystem.
- Clear separation between quality evaluation and performance benchmarking.
- Detailed per-query data for deep-dive analysis of retrieval and generation.
- Flexible configuration for testing various RAG pipeline parameters.
Usage examples
- “Run a full RAG evaluation on my dataset located at /data/my_rag_test.”
- The agent will execute the evaluation script using the provided dataset path, host, and port, generating RAGAS metrics and summary reports in the results directory.
- “How can I compare the impact of different top_k settings on my RAG quality?”
- The agent will guide you to adjust the --top_k and --vdb_top_k flags in the evaluation command to perform comparative runs and analyze the resulting RAGAS scores.
Install
Download the skill as a ZIP:
https://autogineer.com/agent-skills/nvidia/rag-eval/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip rag-eval.zip -d .agents/skills
Documentation by NVIDIA RAG
On-disk RAG evaluation (corpus/ + train.json)
Purpose
Guide agents through NVIDIA RAG Blueprint filesystem benchmarks: preparing corpus/ and train.json, running scripts/eval/evaluate_rag.py, tuning retrieval and generation flags for quality comparisons, interpreting RAGAS JSON outputs, and triaging failures (HTTP/stream errors, empty contexts, collection mismatch, judge API).
For latency, throughput, and load testing, use the rag-perf skill (scripts/rag-perf, docs/performance-benchmarking.md) — not this skill.
When not to use
Do not use this skill for: deploying or repairing services (use rag-blueprint); evaluating APIs without the corpus/ + train.json layout; general ML experimentation unrelated to this evaluator; production monitoring/alerting; or latency/throughput benchmarking (use rag-perf).
Prerequisites
Repo cloned; run commands from repo root (imports and paths assume this).
Python 3.11+ and uv; eval deps:
uv sync --project scripts/eval.Reachable RAG server and ingestor (defaults often
localhost:8081/8082).NVIDIA_API_KEYfor RAGAS (see credential hygiene); optionalRAG_EVAL_JUDGE_MODEL.Dataset roots passed to
--dataset-pathseach containcorpus/andtrain.json.
Instructions
Prepare data — Ensure each dataset directory matches the layout and
train.jsonrules inreferences/dataset-and-conversion.md. When sources arrive as public links (sites or dataset pages), materialize documents undercorpus/—prefer PDF for multimodal content so images stay embedded; convert CSV/JSONL/etc. using the patterns there.Run eval —
uv run --project scripts/eval python scripts/eval/evaluate_rag.pywith--dataset-paths,--host, and--port. Seereferences/benchmark-execution.mdfor command examples, outputs, and errors. Usereferences/evaluate-rag-cli.mdfor flag-level detail.Tune quality — Adjust
--top_k/--vdb_top_k, reranker and query-rewriting toggles, and generation overrides (--temperature,--top-p,--max-tokens) as documented inreferences/benchmark-execution.mdwhen comparing retrieval/generation configs for RAGAS scores.Analyze results — Use
references/result-analysis.mdfor scripts; scanrag_*_evaluation_summary.jsonfor headline RAGAS metrics.Triage errors — Use the error signal table and the Troubleshooting section below.
Examples
Set API key without putting secrets in shell history (preferred patterns): load from a gitignored env file or secrets manager; avoid committing .env; rotate keys if exposed. Details: references/benchmark-execution.md#credential-hygiene-nvidia_api_key.
Minimal eval (key already in environment):
uv sync --project scripts/eval
uv run --project scripts/eval python scripts/eval/evaluate_rag.py \
--dataset-paths /path/to/my_dataset \
--host localhost \
--port 8081Pretty-print summary JSON:
python3 -m json.tool results/my_dataset/rag_my_dataset_evaluation_summary.jsonMore examples (skip ingestion, quality sweeps): references/benchmark-execution.md.
Limitations
Evaluator behavior is fixed to the filesystem contract and
evaluate_rag.py; it does not substitute for custom offline judges or non-RAG benchmarks.Vector DB / embedding choices follow deployed ingestor and RAG env — not overridden by this CLI alone.
Scores depend on retrieval quality, judge model availability, and
NVIDIA_API_KEY; empty contexts yield partial RAGAS metrics (see references).Large procedural detail lives under
references/to keep routing concise; read those files when the user needs step-by-step conversion, full flags, or error tables.
Troubleshooting
| Error / signal | Likely cause | What to do |
|---|---|---|
Immediate exit mentioning NVIDIA_API_KEY | Missing or invalid key | Set key via secure channel; see credential hygiene in references/benchmark-execution.md. |
train.json must be a JSON array | Wrong JSON shape | Top-level array of objects; validate per references/dataset-and-conversion.md. |
Fewer rows in evaluation_data.json than train.json | Per-query failures | Check stderr: network or stream JSON errors; see error table in benchmark-execution. |
Empty generated_contexts everywhere | Retrieval gap | Verify collection, ingestion, top_k / vdb_top_k, and ingestor_server_url without /v1 suffix. |
| Ingestor 404 on upload | Bad ingestor base URL | Pass http://host:port only — code appends /v1/. |
Full signal table: references/benchmark-execution.md#common-error-cases-and-signals.
Gotchas
Run from repo root: paths and imports in
scripts/eval/evaluate_rag.pyassume this; a wrong directory silently breaks imports.--ingestor_server_url: passhttp://host:portwithout/v1—the code appends/v1/automatically. Including/v1causes 404s on ingestor calls.Vector DB / embedding settings: not set by this CLI; configure via the deployed ingestor and RAG server env vars (e.g.
APP_VECTORSTORE_URL, embedding model).--model/--llm_endpoint: forwarded verbatim only when explicitly set; omit to keep the server's configured LLM.Stale collections: a previous run's ingested data persists unless you use
--force_ingestion. Use--collectionwith a unique name when comparing quality across isolated runs.Empty context metrics: if all
generated_contextsare empty, RAGAS scores onlynv_accuracyand leaves the other two metrics blank—this is not a silent success.
Source of truth
| Piece | Location |
|---|---|
| Driver | scripts/eval/evaluate_rag.py (CORPUS_DIRECTORY = corpus, EVAL_DATA = train.json) |
| Human README (always in-repo) | scripts/eval/README.md |
| Full CLI (flags, defaults) | scripts/eval/evaluate_rag.py --help; references/evaluate-rag-cli.md |
| Dataset / conversion | references/dataset-and-conversion.md |
| Runs, outputs, errors | references/benchmark-execution.md |
| Result analysis scripts | references/result-analysis.md |
| Latency / throughput | rag-perf skill, docs/performance-benchmarking.md |
Agent playbook
Run eval —
uv sync --project scripts/evalthenuv run --project scripts/eval python scripts/eval/evaluate_rag.pywith required--dataset-paths,--host, and--port(and envNVIDIA_API_KEY). Argument--ingestor_server_urlis optional (defaults tohttp://localhost:8082); pass it only when overriding the ingestor endpoint.Quality tuning — See
references/benchmark-execution.md:--top_k/--vdb_top_k, reranker and query-rewriting toggles,--temperature,--top-p,--max-tokens.Data conversion — Follow
references/dataset-and-conversion.md.Analyze results —
references/result-analysis.md; quick scan:python3 -m json.tool results/<dataset>/rag_<dataset>_evaluation_summary.json.Error triage —
references/benchmark-execution.md#common-error-cases-and-signals.
Files
- ATTRIBUTION.mdAdded by AutoGineer886 B
- BENCHMARK.md2.8 KiB
- LICENSELicence file added by AutoGineer11.2 KiB
- SKILL.md9.2 KiB
- eval/h100.json2.8 KiB
- eval/nvidia_hosted.json1.9 KiB
- references/benchmark-execution.md8.1 KiB
- references/dataset-and-conversion.md8.2 KiB
- references/evaluate-rag-cli.md4.2 KiB
- references/result-analysis.md2.8 KiB
- skill-card.md2.6 KiB
- skill.oms.sig5.7 KiB
skill.oms.sig
{"mediaType":"application/vnd.dev.sigstore.bundle.v0.3+json","verificationMaterial":{"x509CertificateChain":{"certificates":[{"rawBytes":"MIICgzCCAgmgAwIBAgIUKIyS7SxNteQIiWzK1dWj85E6520wCgYIKoZIzj0EAwMwVTELMAkGA1UEBhMCVVMxGzAZBgNVBAoMEk5WSURJQSBDb3Jwb3JhdGlvbjEpMCcGA1UEAwwgTlZJRElBIEFnZW50IENhcGFiaWxpdGllcyBJQ0EgMDEwHhcNMjYwNDAxMDAwMDAwWhcNMjgwNDIyMTUzMzA5WjBUMQswCQYDVQQGEwJVUzEb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gEGMAoGCCqGSM49BAMDA2cAMGQCMCwtAjWLaNwgGWNCgdyNoTyvNhqWRECRJV2r3+7w8g0PL6NHLOsbkgE09BH95h8XlgIwTaQmbbUh2ChAJ5TA1wRiVDnCcvbzHlZl2jM2FcwQQZlk19LOAbyGMRixbu2Ww/rj"}]},"tlogEntries":[]},"dsseEnvelope":{"payload":"ewogICJfdHlwZSI6ICJodHRwczovL2luLXRvdG8uaW8vU3RhdGVtZW50L3YxIiwKICAic3ViamVjdCI6IFsKICAgIHsKICAgICAgIm5hbWUiOiAicmFnLWV2YWwiLAogICAgICAiZGlnZXN0IjogewogICAgICAgICJzaGEyNTYiOiAiNDExOTQ1NTMyNzYyYmY4ZmU4YjQyNjY1YzAyZTY5ZWI1OTFiYzkxZjk3YjJiZDEwZjgxYWJhYzg4ZjIxYjJiMCIKICAgICAgfQogICAgfQogIF0sCiAgInByZWRpY2F0ZVR5cGUiOiAiaHR0cHM6Ly9tb2RlbF9zaWduaW5nL3NpZ25hdHVyZS92MS4wIiwKICAicHJlZGljYXRlIjogewogICAgInNlcmlhbGl6YXRpb24iOiB7CiAgICAgICJhbGxvd19zeW1saW5rcyI6IGZhbHNlLAogICAgICAibWV0aG9kIjogImZpbGVzIiwKICAgICAgImhhc2hfdHlwZSI6ICJzaGEyNTYiLAogICAgICAiaWdub3JlX3BhdGhzIjogWwogICAgICAgICIuZ2l0aWdub3JlIiwKICAgICAgICAiLmdpdCIsCiAgICAgICAgIi5naXRhdHRyaWJ1dGVzIiwKICAgICAgICAiLmdpdGh1YiIKICAgICAgXQogICAgfSwKICAgICJyZXNvdXJjZXMiOiBbCiAgICAgIHsKICAgICAgICAiZGlnZXN0IjogImM4ZjE2NDc5MGRjYjYyMmVmYjgxYTJmZTk5MmQ2MjBmN2MyNGFiM2U4MjBhOGFlODhjZmU5MDNmNzE1N2NhMjYiLAogICAgICAgICJuYW1lIjogIkJFTkNITUFSSy5tZCIsCiAgICAgICAgImFsZ29yaXRobSI6ICJzaGEyN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XMvZGF0YXNldC1hbmQtY29udmVyc2lvbi5tZCIsCiAgICAgICAgImFsZ29yaXRobSI6ICJzaGEyNTYiCiAgICAgIH0sCiAgICAgIHsKICAgICAgICAiZGlnZXN0IjogImY2ODg3ZmE5N2FiOWI4MmQ5MjVkZDVmZDQ4MTkxMTY5NmFiMzFlZmE3NTIxZjI1OWNkMGNlMTA0YzkwMzA1ZTYiLAogICAgICAgICJuYW1lIjogInJlZmVyZW5jZXMvZXZhbHVhdGUtcmFnLWNsaS5tZCIsCiAgICAgICAgImFsZ29yaXRobSI6ICJzaGEyNTYiCiAgICAgIH0sCiAgICAgIHsKICAgICAgICAiZGlnZXN0IjogIjYxODg3M2M0YjFhYzZjYWRjZDI3MzEzOWMyOTcyNWM5YmU4YTdhM2UyMDdhZmQ0ODBhOGJkMWYxODk2NDVjOWUiLAogICAgICAgICJuYW1lIjogInJlZmVyZW5jZXMvcmVzdWx0LWFuYWx5c2lzLm1kIiwKICAgICAgICAiYWxnb3JpdGhtIjogInNoYTI1NiIKICAgICAgfSwKICAgICAgewogICAgICAgICJkaWdlc3QiOiAiZDcwOTU2YmUwNGY1MDk4ZDM0Y2ZlYjAxOGE1ZTEyNWVjNTQ1N2ViN2ZkZmIyZDM3M2I3OWI3Y2QwZWUyODRmOSIsCiAgICAgICAgIm5hbWUiOiAic2tpbGwtY2FyZC5tZCIsCiAgICAgICAgImFsZ29yaXRobSI6ICJzaGEyNTYiCiAgICAgIH0KICAgIF0KICB9Cn0=","payloadType":"application/vnd.in-toto+json","signatures":[{"sig":"MGYCMQCM8wu6kAx8FMhbKo9qnkarjf+NGdGLyZbVHDTO55Tbv4BUfR9LxROyfJ7gDHjnQlgCMQD+F7iVfMuaUY6vck4PfZK2orXApRY+tIJqT+x1Jrqcc3A/iaU8z+eIqT5XvWFR4k0=","keyid":""}]}}Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Declares allowed tools, Needs an API key, Needs Python
The author says: Repository checkout with uv; Python 3.11+; run from repo root; uv sync --project scripts/eval (eval deps live in scripts/eval/pyproject.toml); network to RAG, ingestor, and vdb endpoints; NVIDIA_API_KEY for RAGAS; optional RAG_EVAL_JUDGE_MODEL (default mistralai/mixtral-8x22b-instruct-v0.1).
Security
What our scanner noticed· Medium risk
- Large base64-encoded blobs
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Created by
- NVIDIA RAG
- Publisher
- NVIDIA (Official)
- Source
- NVIDIA/skills · skills/rag-eval · commit fce3cca
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE-APACHE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by NVIDIA RAG or NVIDIA.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download rag-eval.zip