agentleFS
SentryKnown publishergetsentry/symx/AGENTS.md

symx

AGENTS.md8 starsChanged 5 months agoMITView on GitHub

If something is unclear, ask questions early instead of inferring intent after a long working phase. For describing current behavior, prefer implementation and workflow files over assumptions or scratch notes. Production metadata is authoritative. If a workflow layer already has IpswArtifact / IpswSource facts such as platform, version, build, devices, or source identity, pass that metadata explicitly into lower layers instead of rediscovering it from filenames or local artifact contents. Untracked files are not automatically irrelevant. They may be part…

  • Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.

    Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.

The file

Show its rules and text

We split this AGENTS.md into the rules it gives an agent

32 rules. About 0 are common, 24 are distinctive, and 8 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈24

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 8

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Always use uv for running the Python application, Python dev tools, and managing Python dependencies.

    line 5
  2. Very specific:

    Use uv run to invoke any Python tool (pytest, ty, ruff, etc.).

    line 6
  3. Very specific:

    Use uv add / uv remove for Python dependency changes.

    line 7
  4. Very specific:

    Use SwiftPM directly for the native admin app under apps/SymxAdmin (swift run, swift test).

    line 8
  5. Distinctive:

    If something is unclear, ask questions early instead of inferring intent after a long working phase.

    line 12
  6. Distinctive:

    Prefer a short set of concrete clarification questions over a speculative plan.

    line 14
  7. Distinctive:

    Do this especially when requirements are ambiguous, there are multiple reasonable implementation paths, or a wording/detail could …

    line 15
  8. Distinctive:

    Do not disappear into a long investigation and only then present a guessed interpretation.

    line 16
  9. Distinctive:

    Treat design questions as questions.

    line 17
  10. Distinctive:

    do not infer project-wide or production behavior from unrelated local scratch files or generated artifacts,

    line 33
  11. Distinctive:

    do not treat unrelated local artifacts as supported project surfaces,

    line 48
  12. Distinctive:

    do not clean them up unless explicitly asked,

    line 49
  13. Distinctive:

    if a local file appears relevant but is not authoritative, verify against tracked code/workflows before relying on it for documentation.

    line 50
  14. Distinctive:

    Keep these distinctions straight:

    line 54
  15. Distinctive:

    Do not split one operation across constructor state, method arguments, and inferred values without a clear reason.

    line 68
  16. Distinctive:

    When logic depends on trusted metadata, require it.

    line 69
  17. Distinctive:

    When parsing structured external data (for example Apple plist/JSON metadata), keep the untyped boundary narrow.

    line 73
  18. Distinctive:

    Prefer typed subset models or dataclasses for the parts the code consumes.

    line 75
  19. Very specific:

    Avoid spreading dict[str, Any], list[object], and broad cast(...)-based traversal through business logic just to satisfy the type checker.

    line 76
  20. Very specific:

    Do not assume every ArtifactProcessingState enum member is actively emitted by automation.

    line 81
  21. Distinctive:

    Verify actual transitions by tracing assignments in runners/storage code.

    line 82
  22. Distinctive:

    When auditing or changing states, cross-check both:

    line 87
  23. Distinctive:

    Every change should be cross-checked against inline comments and Markdown docs in the repo.

    line 95
  24. Distinctive:

    Not every code change requires documentation updates, but every change that invalidates existing documentation must update the …

    line 96
  25. Distinctive:

    When documenting commands or production behavior, verify against current CLI help and workflow YAML instead of guessing from old prose.

    line 97
  26. Very specific:

    Prefer putting detailed architecture/operations material in docs/*.md and linking from README.md.

    line 98
  27. Very specific:

    When changing workflow/state logic, update or add tests under tests/ where practical.

    line 106
  28. Distinctive:

    Treat symbol storage as additive/create-only unless the task explicitly requires something else.

    line 123
  29. Distinctive:

    When changing storage/meta-data behavior, think through concurrent workflows explicitly and preserve the existing safety properties (for …

    line 125
  30. Distinctive:

    If a proposed change weakens concurrency safety or makes destructive overwrites more likely, call that out clearly before proceeding.

    line 126
  31. Distinctive:

    Prefer disposable buckets for development or reproduction.

    line 133
  32. Distinctive:

    If a command appears to target production-like infrastructure, call that out clearly.

    line 134

≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

Agent Instructions

Package & Dependency Management

  • Always use uv for running the Python application, Python dev tools, and managing Python dependencies.
  • Use uv run to invoke any Python tool (pytest, ty, ruff, etc.).
  • Use uv add / uv remove for Python dependency changes.
  • Use SwiftPM directly for the native admin app under apps/SymxAdmin (swift run, swift test).

Clarification & Interaction

If something is unclear, ask questions early instead of inferring intent after a long working phase.

  • Prefer a short set of concrete clarification questions over a speculative plan.
  • Do this especially when requirements are ambiguous, there are multiple reasonable implementation paths, or a wording/detail could materially change the result.
  • Do not disappear into a long investigation and only then present a guessed interpretation.
  • Treat design questions as questions. If the user asks why something is shaped a certain way, whether an approach is weird, or what the right shape should be, answer/propose before editing files.

Sources of Truth

For describing current behavior, prefer implementation and workflow files over assumptions or scratch notes.

  • Pipeline/runtime behavior: symx/ipsw/*, symx/ota/*, symx/sim/*
  • CLI surface: symx/__init__.py, symx/*/app/__init__.py
  • Admin behavior implemented today: symx/admin/*
  • Shared processing-state vocabulary: symx/model.py
  • Production deployment, schedules, runner types, and workflow entrypoints: .github/workflows/*.yml

Production metadata is authoritative. If a workflow layer already has IpswArtifact / IpswSource facts such as platform, version, build, devices, or source identity, pass that metadata explicitly into lower layers instead of rediscovering it from filenames or local artifact contents.

Untracked files are not automatically irrelevant. They may be part of the work in progress. The important distinction is:

  • do not infer project-wide or production behavior from unrelated local scratch files or generated artifacts,
  • but if an untracked file is in scope for the task, read and update it normally.

Local Artifacts

This repo may contain local-only artifacts such as:

  • scratch docs
  • downloaded artifacts
  • coverage output
  • ad-hoc scripts
  • investigation inputs

Guidance:

  • do not treat unrelated local artifacts as supported project surfaces,
  • do not clean them up unless explicitly asked,
  • if a local file appears relevant but is not authoritative, verify against tracked code/workflows before relying on it for documentation.

Architecture Invariants

Keep these distinctions straight:

  • IPSW processing state is tracked per IpswSource inside an IpswArtifact.
  • OTA processing state is tracked per OtaArtifact.
  • GCS meta JSON files are the shared persisted state.
  • GitHub Actions is the production execution/scheduling layer.
  • Sentry is the observability layer.
  • The admin surface implemented today is the code in symx/admin/*; do not infer extra capabilities from design ideas or scratch notes.
  • The application should be able to run locally if a local GCS store is provided
  • Target platforms are Linux and macOS but some features (extraction) can only run on macOS.

Architecture & Data Flow

  • Model cross-layer operations with explicit request/context objects that carry the complete unit-of-work state.
  • Do not split one operation across constructor state, method arguments, and inferred values without a clear reason.
  • When logic depends on trusted metadata, require it. Missing or unparseable metadata should fail early with a clear error unless an explicit fallback preserves the relevant invariants.

Typed Data Boundaries

When parsing structured external data (for example Apple plist/JSON metadata), keep the untyped boundary narrow.

  • Prefer typed subset models or dataclasses for the parts the code consumes.
  • Avoid spreading dict[str, Any], list[object], and broad cast(...)-based traversal through business logic just to satisfy the type checker.
  • Convert typed objects to plain dictionaries only at serialization/diagnostics boundaries when needed.

Processing-State Guidance

  • Do not assume every ArtifactProcessingState enum member is actively emitted by automation.
  • Verify actual transitions by tracing assignments in runners/storage code.
  • Distinguish between:
    • automated transitions,
    • migration/manual-only transitions,
    • reserved/unused states.
  • When auditing or changing states, cross-check both:
    • code assignments in symx/ipsw/*, symx/ota/*, etc., and
    • the latest local admin snapshot if one is available under ~/.cache/symx/admin/snapshots/.

Documentation

Documentation that is out of date is useless.

  • Every change should be cross-checked against inline comments and Markdown docs in the repo.
  • Not every code change requires documentation updates, but every change that invalidates existing documentation must update the documentation in the same change.
  • When documenting commands or production behavior, verify against current CLI help and workflow YAML instead of guessing from old prose.
  • Prefer putting detailed architecture/operations material in docs/*.md and linking from README.md.

Coverage & Testability

Changes should be covered by tests as much as is realistically possible.

Since symx is workflow- and side-effect-heavy, a lot of behavior does not make sense to cover end-to-end. Design should still keep the core behavior testable with small units and injectable side effects.

When changing workflow/state logic, update or add tests under tests/ where practical.

For regression fixes, prefer test-first when feasible:

  • ideally add or identify a test that reproduces the broken setup before attempting the fix,
  • then make the code change,
  • then verify the test passes together with the full relevant suite.

This should also guide development work in general: if, while investigating or implementing, you discover that the current code does not behave as expected, try to capture that setup in a test before changing the code.

This is especially important when fixing subtle state-machine, storage, concurrency, or recovery-path behavior.

Storage & Concurrency

Storage is holy.

  • Overwrites are usually not something we do.
  • Treat symbol storage as additive/create-only unless the task explicitly requires something else.
  • Be extremely careful with metadata writes. Never introduce changes that could leave metadata in a corrupt or partially-written state because concurrency was not considered.
  • When changing storage/meta-data behavior, think through concurrent workflows explicitly and preserve the existing safety properties (for example generation-matched writes / optimistic concurrency where applicable).
  • If a proposed change weakens concurrency safety or makes destructive overwrites more likely, call that out clearly before proceeding.

Safety

Be explicit when suggesting commands that can mutate shared state.

  • Any command using --storage gs://... may read from and write to shared storage.
  • Prefer disposable buckets for development or reproduction.
  • If a command appears to target production-like infrastructure, call that out clearly.

Verification

For code changes, run the full check suite across all files (not just changed ones):

uv run ruff check --fix
uv run ruff format
uv run ty check
uv run pytest

For changes to the native admin app, also run:

cd apps/SymxAdmin
swift format lint --strict --recursive --parallel Sources Tests Package.swift
swift test

Markdown-only changes do not require the full verification suite.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.