richmondsunlight.com CLAUDE.md

richmondsunlight.com CLAUDE.md is an instructions file for coding agents from openva/richmondsunlight.com. It costs 509 tokens per session, scanned A, original, MIT.

Project-specific coding instructions for RichmondSunlight.com, a site that publishes information about Virginia legislators and bills.

In plain words
What is it for?
Making safe changes to this site's database queries, bill and legislator features, and administrator pages.
Why use it?
They warn the agent about the project's data tables, naming rules, case-sensitive bill numbers, and admin-page conventions.

Instructions file

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/openva/richmondsunlight.com/claude-md
Clone the repo
git clone --depth 1 https://github.com/openva/richmondsunlight.com

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 richmondsunlight.com CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/openva/richmondsunlight.com/claude-md.svg)](https://agentmods.dev/instructions/openva/richmondsunlight.com/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/openva/richmondsunlight.com/claude-md"><img src="https://agentmods.dev/badge/instructions/openva/richmondsunlight.com/claude-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 509 This file is loaded in full into every session.
When invoked 509 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.00509 $0.00509
Opus 5 $0.00254 $0.00254
Sonnet 5 $0.00102 $0.00102
Haiku 4.5 $0.00051 $0.00051

Measured 3d ago against content hash 0c0e6575d7ef, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

richmondsunlight.com CLAUDE.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 3d 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.

CLAUDE.md · 48 lines

How it starts

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

CLAUDE.md

Supplements AGENTS.md with coding-level gotchas and conventions.

Legislator Data Model

There are three overlapping tables for legislators. Use the right one:

Table Status Use for
people Current Canonical identity — shortname, name, sex, race, bio
terms Current Per-term data — chamber, party, district_id, name_formatted, lis_id. FK to people.id via terms.person_id
representatives Legacy Older queries only. Do not use for new code.

New code should JOIN people + terms. video_index.linked_id references terms.id when type = 'legislator'.

Bill Number Case Sensitivity

bills.number uses utf8mb3_bin collation — it is case-sensitive. Bills are stored lowercase (e.g., hb41, not HB41). Always call strtolower() on bill number input before using it in a SQL query.

Admin Pages

Admin pages live in htdocs/admin/ and follow a different pattern from public pages:

  • Do not use the Page class — output raw HTML directly
  • No PHP session check needed — access is controlled by HTTP Basic Auth via .htaccess
  • Include ../../includes/settings.inc.php and ../../includes/functions.inc.php
  • Connect to DB with $database = new Database(); $database->connect_mysqli();

Class Naming

The bill class is named Bill2 (not Bill) to avoid conflicts with legacy code. This is intentional — do not rename it.

Playwright Login Pattern

Logging in during browser tests requires:

  1. POST to /account/login/ with credentials
  2. Extract PHPSESSID from the Set-Cookie response header
  3. Add it to the browser context with secure: false (the test environment is HTTP, not HTTPS)

Test user: [email protected] / see deploy/mysql/test-users.sql for credentials. User ID is 90001.

SESSION_ID and SESSION_YEAR

The current legislative session is hardcoded in deploy/settings-docker.inc.php:

  • SESSION_ID = 31
  • SESSION_YEAR = 2025

Read the full file on GitHub · 48 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. 3d ago First seen · 48 lines · 509 tokens per session scan A 0c0e6575d7ef

Subscribe to this mod's changes

richmondsunlight.com CLAUDE.md is an instructions file published in the GitHub repository openva/richmondsunlight.com (16 stars, last pushed 23d ago), licensed MIT. It adds 509 tokens to every session, about $0.0025 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-09-01.