QuantRL-Lab: Instructions file for Codex

AGENTS.md

QuantRL-Lab AGENTS.md is an instructions file for Codex, OpenCode from whanyu1212/QuantRL-Lab. It costs 3,951 tokens per session, scanned A, original, MIT.

Instructions for AI agents working in a quantitative research project, including its commands, Python package management, testing, and code-quality checks. The project uses uv to manage dependencies and environments.

In plain words
What is it for?
Setting up the project, running unit or integration tests, checking coverage, selecting tests by name, and running pre-commit checks.
Why use it?
They give agents consistent commands for installing the right optional packages and checking changes before they are committed.

Instructions file for CodexOpenCode

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

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

Reuse

Borrowing it

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

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 QuantRL-Lab AGENTS.md

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/whanyu1212/quantrl-lab/agents-md"><img src="https://agentmods.dev/badge/instructions/whanyu1212/quantrl-lab/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 3,951 This file is loaded in full into every session.
When invoked 3,951 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.03951 $0.03951
Opus 5.5 $0.01580 $0.01580
Sonnet 5.5 $0.00790 $0.00790
Haiku 4.5 $0.00395 $0.00395

Measured 2mo ago against content hash 2614ee489158, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

QuantRL-Lab 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 2mo 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 · 372 lines

How it starts

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

AGENTS.md

This file provides guidance to agents (i.e., ADAL) when working with code in this repository.

Essential Commands

Package Management

This project uses uv (not Poetry). The lock file is uv.lock.

uv sync                                    # Core deps only
uv sync --extra dev --extra notebooks      # With dev/notebook extras
uv sync --all-extras                       # All optional features
source .venv/bin/activate

Optional dependency groups: dev, notebooks, ml (torch/transformers/litellm), tuning, viz, storage, full.

Testing

uv run pytest -m "not integration"         # Unit tests only (CI/CD - no API keys needed)
uv run pytest -m integration               # Integration tests (requires .env with API keys)
uv run pytest tests/data/test_indicators.py  # Specific test file
uv run pytest -k "test_portfolio"          # Tests matching pattern
uv run pytest --cov=quantrl_lab            # With coverage

Code Quality (Pre-commit Hooks)

Pre-commit hooks run automatically on git commit. Run manually with:

pre-commit install                         # One-time setup
pre-commit run --all-files
pre-commit run --files path/to/file.py     # Before committing changes

Hook configuration (.pre-commit-config.yaml):

  • Black: --line-length=120 --skip-string-normalization
  • isort: --profile black
  • flake8: --max-line-length=120
  • docformatter: Google-style, --wrap-summaries=72

CRITICAL: Always verify pre-commit hooks pass after making changes. Common failures: unused imports (flake8), line length violations, missing/malformed docstrings.

Documentation

uv run mkdocs serve    # Local preview
uv run mkdocs build    # Build (always run before committing API changes)

When renaming modules or changing public APIs, update docs/api-reference/ to match actual module paths and run mkdocs build to verify.

Standalone guide tabs (top-level nav, each a self-contained reference):

  • docs/DATA_SOURCES.md — data loaders, capability matrix, usage per source
  • docs/data-processing.md — DataProcessor and DataPipeline with all 7 pipeline steps
  • docs/environments.md — action/observation/reward spaces, all reward strategies, full env example
  • docs/experiments.md — BacktestRunner, ExperimentJob, JobGenerator, AgentExplainer, OptunaRunner

Read the full file on GitHub · 372 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. 2mo ago First seen · 372 lines · 3,951 tokens per session scan A 2614ee489158

Subscribe to this mod's changes

QuantRL-Lab AGENTS.md is an instructions file published in the GitHub repository whanyu1212/QuantRL-Lab (54 stars, last pushed 6mo ago), licensed MIT. It adds 3,951 tokens to every session, about $0.0158 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-30.

Related

QuantRL-Lab AGENTS.md compared with instructions from other repositories

QuantRL-Lab AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
QuantRL-Lab AGENTS.mdwhanyu1212/QuantRL-LabInstructions file546mo agoMITA3,951Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA9,719GitHub Copilot
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA5,516GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149ktodayMITA4,680Codex, OpenCode
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA3,093GitHub Copilot
vscode model-prompts.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA2,022GitHub Copilot