submitqueue AGENTS.md

A project guide for SubmitQueue, a distributed system that manages code-submission workflows across multiple services.

In plain words
What is it for?
Use it when changing SubmitQueue controllers, storage, or related architecture. It is especially relevant to version checks, retries, immutable records, event history, and concurrency handling.
Why use it?
It explains the project’s rules for handling updates, versions, stored events, and delayed synchronization between services, reducing the risk of inconsistent data.

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/uber/submitqueue/agents-md
Clone the repo
git clone --depth 1 https://github.com/uber/submitqueue

Made for: Codex, OpenCode.

Per session 8,360 This file is loaded in full into every session.
When invoked 8,360 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.08360 $0.08360
Opus 5 $0.04180 $0.04180
Sonnet 5 $0.01672 $0.01672
Haiku 4.5 $0.00836 $0.00836

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

Security

Grade A, and why

submitqueue 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 2d 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 · 377 lines

How it starts

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

SubmitQueue Repository Guide

Key Concepts

SubmitQueue is a distributed system for managing code submission workflows. It follows clean architecture with interface-driven extensibility.

Immutability and Eventual Consistency:

  1. Immutable entities — once created, don't modify in place. Create new versions with updated fields.
  2. Eventual consistency — handle stale reads, idempotent operations, and convergence over time.
  3. Event sourcing — store events (what happened) rather than just current state for critical changes.
  4. Optimistic locking — use version numbers instead of pessimistic locks. Avoid transactions; prefer optimistic concurrency and retries. Version arithmetic lives in the controller, not the storage layer. Update methods take both oldVersion (the where-clause guard) and newVersion (the value to write); the store performs a pure conditional write. Controllers compute newVersion = oldVersion + 1, call the store, and only assign entity.Version = newVersion after the call succeeds. Pre-incrementing in memory before the call is a bug pattern — on error the in-memory version drifts ahead of the database. See submitqueue/extension/storage/README.md.
  5. Idempotency keys — include unique request IDs, check for duplicates before executing.
  6. Persist before you publish — when a message hands work to a later stage, write the state first and publish only once the write has succeeded. Publishing first races the consumer against the write: it can load an entity that was never recorded, or a version older than the one the message describes, and then build on an assumption that was never true. Ordered write-then-publish, a failed publish leaves the state durable and the retry re-publishes; the reverse leaves a message describing a state nothing wrote. The exception is a message that depends on nothing the write does — a status log recording a transition, or an idempotent nudge whose consumer re-derives everything from current state. Those publish first on purpose, so that a failure leaves nothing written and the retry redoes the whole step rather than stranding a durable state change with no way to announce it; see submitqueue/orchestrator/controller/speculate/finalize.go and .../buildsignal/buildsignal.go for the reasoning at those two sites.

Read the full file on GitHub · 377 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. 2d ago First seen · 377 lines · 8,360 tokens per session scan A 4d0893bd1ef1

Subscribe to this mod's changes

submitqueue AGENTS.md is an instructions file published in the GitHub repository uber/submitqueue (211 stars, last pushed 3d ago), licensed Apache-2.0. It adds 8,360 tokens to every session, about $0.0418 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.