vsag: Instructions file for Codex

AGENTS.md

vsag AGENTS.md is an instructions file for Codex, OpenCode from antgroup/vsag. It costs 1,525 tokens per session, scanned A, original, Apache-2.0.

Core instructions for AI coding agents working on VSAG, a C++ vector-indexing library with Python and Node.js/TypeScript bindings.

In plain words
What is it for?
Use them as the starting point for VSAG changes, especially when locating public APIs, implementation files, or repository-specific rules.
Why use it?
They provide project constraints for formatting, file layout, API compatibility, types, and research before editing code.

Instructions file for CodexOpenCode

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

This is antgroup/vsag's own configuration. It tells Codex and OpenCode how to work on vsag 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 vsag configures →

Reuse

Borrowing it

Nothing to install: this file belongs to antgroup/vsag. 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/antgroup/vsag/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/antgroup/vsag

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 vsag AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/antgroup/vsag/agents-md/github.svg)](https://agentmods.dev/instructions/antgroup/vsag/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/antgroup/vsag/agents-md"><img src="https://agentmods.dev/badge/instructions/antgroup/vsag/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 vsag AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/antgroup/vsag/agents-md"><img src="https://agentmods.dev/badge/instructions/antgroup/vsag/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,525 This file is loaded in full into every session.
When invoked 1,525 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.01525 $0.01525
Opus 5.5 $0.00610 $0.00610
Sonnet 5.5 $0.00305 $0.00305
Haiku 4.5 $0.00153 $0.00153

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

Security

Grade A, and why

vsag 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 5d 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 · 113 lines

How it starts

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

AGENTS.md

Read me first. This file is the entry point for AI coding agents working on VSAG. It is intentionally short. The bullets under Hard Constraints must hold for every change; the Documentation Index points at the detailed rules for each topic.

Project Overview

VSAG is a high-performance vector indexing library for similarity search, written primarily in C++ with Python bindings provided by pyvsag and Node.js/TypeScript bindings provided by vsag.

Hard Constraints (must hold every change)

  • Tool versions are fixed: clang-format and clang-tidy must be version 20 exactly. Newer versions are not acceptable; CI enforces this.
  • Formatting: C++ source and header files use 4-space indentation and a 100-character line limit; Markdown and other non-C++ text files have no line width limit. Use the .cpp (not .cc) suffix, and ensure every committed text file ends with a trailing newline.
  • Layout: public APIs live in include/vsag/; implementation lives in src/; keep code in the vsag namespace unless the file clearly requires otherwise.
  • Prefer uint64_t over size_t in code changes to avoid macOS compile issues.
  • Do not modify extern/ unless the task explicitly requires third-party dependency changes.
  • Tests: new features need tests; bug fixes need regression coverage; the C++ library (src/ + include/) must maintain ≥ 90 % unit-test coverage.
  • Before submitting a PR: run the applicable checks removed from PR CI locally (or in an authorized remote development environment), record results, and follow the pre-submission validation requirements.
  • Commits: use Conventional Commits (feat:, fix:, docs:, chore:, …) and DCO sign-off. AI agents must NOT add their own Signed-off-by: — only humans can certify the DCO. AI agents must also NOT invoke git commit -s, because -s appends Signed-off-by: at the end of the message (with a blank line separating it from earlier trailers) and breaks the required ordering. Instead, write both trailers directly in the commit message body: derive the human identity from git config user.name / user.email, place Signed-off-by: first, and follow it immediately (no blank line) with Assisted-by: <AgentName>:<ModelVersion> (e.g. Assisted-by: OpenCode:claude-opus-4.7). For [skip ci], place it at the start of the subject line.
  • PR pushes: when preparing a pull request, prefer pushing the working branch to the contributor's fork rather than directly to the main antgroup/vsag repository. Push to the main repository only when explicitly required or authorized.
  • Pull requests need two labels: one kind/* (kind/bug, kind/feature, kind/improvement, kind/documentation) and one version/* (e.g. version/1.0). Mergify enforces both.
  • kind/bug / kind/feature PRs must link an issue in the description using a GitHub auto-closing keyword (Fixes: #N, Closes: #N, Resolves: #N; cross-repo or full issue URL also OK). kind/improvement and kind/documentation PRs are exempt. Enforced by the PR Issue Link Check Action and a Mergify protection.
  • Issues do NOT carry Signed-off-by: — DCO only applies to commits.

Read the full file on GitHub · 113 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. 5d ago Changed · +3 lines · +61 tokens per session 873e5cfd37a1
  2. 11d ago Changed · +1 lines · +28 tokens per session 788f17ffed98
  3. 2mo ago First seen · 109 lines · 1,436 tokens per session scan A c79d4d2fc7a3

Subscribe to this mod's changes

vsag AGENTS.md is an instructions file published in the GitHub repository antgroup/vsag (516 stars, last pushed today), licensed Apache-2.0. It adds 1,525 tokens to every session, about $0.0061 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-09-03.

Related

vsag AGENTS.md compared with instructions from other repositories

vsag AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
vsag AGENTS.mdantgroup/vsagInstructions file516todayApache-2.0A1,525Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149ktodayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode