openvidia: Instructions file for Codex

AGENTS.md

openvidia AGENTS.md is an instructions file for Codex, OpenCode from autcir/openvidia. It costs 1,032 tokens per session, scanned A, original, MIT.

Project instructions for OpenVidia, a local proxy that sends requests from different AI clients to NVIDIA NIM using a shared pool of API keys. They describe its mission, architecture, and main modules.

In plain words
What is it for?
Use them when working on OpenVidia's proxy, desktop dashboard, API compatibility shims, key rotation, cooldowns, request limits, or automatic context reduction.
Why use it?
They give developers the project context needed to change or operate the proxy without misunderstanding how clients, key rotation, limits, and compatibility layers fit together.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions Claude Code; mentions Codex; mentions OpenCode.

This is autcir/openvidia's own configuration. It tells Codex and OpenCode how to work on openvidia itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything openvidia configures →

Reuse

Borrowing it

Nothing to install: this file belongs to autcir/openvidia. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/autcir/openvidia/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/autcir/openvidia

Made for: Codex, OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for openvidia AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/autcir/openvidia/agents-md/github.svg)](https://agentmods.dev/instructions/autcir/openvidia/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/autcir/openvidia/agents-md"><img src="https://agentmods.dev/badge/instructions/autcir/openvidia/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for openvidia AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/autcir/openvidia/agents-md"><img src="https://agentmods.dev/badge/instructions/autcir/openvidia/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,032 This file is loaded in full into every session.
When invoked 1,032 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.01032 $0.01032
Opus 5.5 $0.00413 $0.00413
Sonnet 5.5 $0.00206 $0.00206
Haiku 4.5 $0.00103 $0.00103

Measured 12d ago against content hash f2d824208576, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

openvidia AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 97 lines

How it starts

The opening of the file, as written. The whole thing — 97 lines — stays where its author put it; the contents beside it link to each section on GitHub.

OpenVidia — Multi-key proxy for NVIDIA NIM

Mission

Multi-key proxy for NVIDIA NIM with a native desktop dashboard. A pool of free-tier API keys behind a single endpoint, with automatic rotation, per-key cooldown, sliding-window RPM limiting, and auto-compaction.


Architecture

Client CLI → localhost:1919/v1 → Proxy Engine → integrate.api.nvidia.com/v1
                                    │
                                    ├─ /v1/chat/completions  (catch-all: opencode, Grok, any OpenAI client)
                                    ├─ /v1/responses         (shim: Codex CLI)
                                    ├─ /v1/messages          (shim: Claude Code)
                                    └─ /v1/models            (upstream model list)

Core modules

File Lines Role
proxy_app.py ~573 FastAPI app factory, routing, health check, pre-warm
proxy_state.py ~730 Thread-safe state: KeyState, cooldown, RPM tracker, circuit breaker
responses_shim.py ~1126 Shim /v1/responses → /v1/chat/completions (Codex CLI)
anthropic_shim.py ~705 Shim /v1/messages → /v1/chat/completions (Claude Code)
compaction.py ~784 Context auto-compaction on context overflow
config.py ~351 Cross-platform config paths, timeouts, model options
__main__.py ~727 Entry point, CLI setup (opencode/codex/grok), tray, server manager
webui.py ~472 Web dashboard (pywebview), API endpoints
server_manager.py 107 uvicorn start/stop, dual-stack binding
safe_file.py 197 Atomic backup of config files
_upstream_utils.py 43 Global semaphore + ResourceExhausted detection

Shared key rotation

_rotation_phase() in responses_shim.py is the function shared by all paths:

  • max 5 attempts per phase, 3 phases with a 1s pause
  • saturation gate: if <5% of keys are live, fast-fail with 503
  • probe timeout (90s) on the first attempt for fast dead-model detection
  • send timeout (180s) on subsequent attempts
  • handles 429 ResourceExhausted (transient, key untouched) vs 429 rate-limit (cooldown)
  • imported by proxy_app.py (catch-all), anthropic_shim.py (Claude Code)

Read the full file on GitHub · 97 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago Changed · +9 lines · +54 tokens per session f2d824208576
  2. 2mo ago First seen · 88 lines · 978 tokens per session scan A e8a23aa058f6

Subscribe to this mod's changes

openvidia AGENTS.md is an instructions file published in the GitHub repository autcir/openvidia (8 stars, last pushed 13d ago), licensed MIT. It adds 1,032 tokens to every session, about $0.0041 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

openvidia AGENTS.md compared with instructions from other repositories

openvidia AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
openvidia AGENTS.mdautcir/openvidiaInstructions file813d agoMITA1,032Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149kyesterdayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode