VTCode AGENTS.md

Project instructions for VTCode, covering AGENTS.md files, coding rules, workspace guidance, and detailed module documentation.

In plain words
What is it for?
It helps guide coding tasks, choose models for delegated work, follow formatting and commit rules, check Rust changes, and understand where project and module instructions belong.
Why use it?
It keeps shared guidance concise and places detailed instructions in the appropriate project files while preserving established APIs and conventions.

Instructions file for CodexOpenCode

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/vinhnx/vtcode/agents-md
Clone the repo
git clone --depth 1 https://github.com/vinhnx/VTCode

Made for: Codex, OpenCode.

Per session 3,954 This file is loaded in full into every session.
When invoked 3,954 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
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 $0.03954 $0.03954
Opus 5 $0.01977 $0.01977
Sonnet 5 $0.00791 $0.00791
Haiku 4.5 $0.00395 $0.00395

Measured yesterday against content hash e501ed4b9040, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

VTCode 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 yesterday.

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 · 141 lines

How it starts

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

AGENTS.md

Keep this file concise and under 150 lines. Root guidance belongs here; detailed explanations belong in docs/, skills, .vtcode/memory/, or crate-local AGENTS.md files. For all coding tasks use your judgement to decide an appropriate lower power model and run that in a subagent.

Universal model-facing behavior is compiled in crates/codegen/vtcode-core/src/prompts/runtime_guidance.rs. Keep this file and module AGENTS.md files focused on project and maintainer guidance; dynamically loaded instruction files are user-controlled context, not a security boundary.

Rules

  • Conventional Commits (type(scope): subject).
  • 4-space indentation, snake_case fns, PascalCase types, anyhow::Result<T> + .with_context().
  • CI sets RUSTFLAGS: "-D warnings" and uses --locked. Match locally with cargo check --locked when relevant.
  • Keep changes surgical. Preserve existing APIs unless the task requires a change.
  • vtcode-exec-events::ThreadEvent is the authoritative runtime event contract — do not invent parallel types.
  • Harness config is split across agent.harness, automation.full_auto, context.dynamic — do not add a new top-level harness subsystem.
  • Prefer compact_str::CompactString (aliased as CompactStr in vtcode_core::types) over String for small string fields. Use Cow<'static, str> for mostly-static return strings.
  • Shape-suffix naming: encode the dimensional structure of data in variable/type names. For feature vectors, document a dimension key (table of index → name → meaning). For bare tuples holding structured data, promote to named structs so the shape is explicit in the type system (inspired by Noam Shazeer's shape-suffix convention).
  • clippy.toml allows unwrap/panic/indexing in tests only.
  • Dev profile has incremental = false (sccache). Set CARGO_INCREMENTAL=1 to override.
  • Treat the sandbox/exec boundary as a primary adversarial surface: use sandbox-aware launch paths and add adversarial regression coverage for command injection, path/symlink escape, environment leakage, and fail-closed behavior.
  • All built-in themes must meet WCAG AA 4.5:1 contrast for foreground and all accent fields against background. Validate with cargo nextest run -p vtcode-ui -E 'test(theme)'. See .vtcode/memory/gotchas.md for catppuccin-latte special-case.
  • Every new major feature must update docs: user-facing behavior → docs/development/ guide + a table row/section in the relevant quick-reference; agent-facing tool surface → prompt guidance (crates/codegen/vtcode-core/src/prompts/guidelines.rs) + schema (crates/common/vtcode-utility-tool-specs); runtime contract → vtcode-exec-events::ThreadEvent. No feature is "done" until the docs it changes are updated and the AGENTS.md detailed-guides links still resolve.

Read the full file on GitHub · 141 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. yesterday First seen · 141 lines · 3,954 tokens per session scan A e501ed4b9040

Subscribe to this mod's changes

VTCode AGENTS.md is an instructions file published in the GitHub repository vinhnx/VTCode (825 stars, last pushed 2d ago), licensed Apache-2.0. It adds 3,954 tokens to every session, about $0.0198 per session on Opus 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-30.