agentleFS
jenrehjenreh/appkit/AGENTS.md

appkit

AGENTS.md4 starsChanged 5 months agoMITView on GitHub

Stacks: Python 3.14 · Reflex.dev (UI) · FastAPI · SQLAlchemy 2.0 · Alembic · Pydantic · FastMCP · LangChain Prefer local changes over cross-module refactors. Prefer official docs; widen via web search for cross-version issues. Task Runner: task (via Taskfile.dist.yml), not make. Full rules in writing-python-code skill. Key: Full rules in reflex-state-and-architecture skill. Appkit-specific:

  • Reads credentials

The file

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

12 rules. About 0 are common, 8 are distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈8

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 4

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Think → Memory → Tools → Code → Memory: Use code-reasoning; search Memory and claude-context first.

    line 9
  2. Distinctive:

    Minimal diff: Add tests before code. Keep simple.

    line 11
  3. Distinctive:

    Consistency > cleverness: Follow SOPs and stack idioms.

    line 12
  4. Very specific:

    No extensive docs/summaries/comments unless requested.

    line 15
  5. Distinctive:

    Prefer official docs; widen via web search for cross-version issues.

    line 57
  6. Distinctive:

    Read first failing assertion.

    line 74
  7. Distinctive:

    Add/adjust unit tests to codify expected behavior.

    line 76
  8. Very specific:

    No print: Use logging module.

    line 81
  9. Distinctive:

    No f-strings in logger calls.

    line 111
  10. Very specific:

    Never redeclare inherited props — MantineComponentBase → MantineLayoutComponentBase → MantineInputComponentBase provide ~40 common props.

    line 134
  11. Very specific:

    No credentials in code/history.

    line 141
  12. Distinctive:

    Update vulnerable deps; document CVE-driven updates in commits & Memory.

    line 145

≈ “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

AppKit — Reflex-Mantine Component Library

Stacks: Python 3.14 · Reflex.dev (UI) · FastAPI · SQLAlchemy 2.0 · Alembic · Pydantic · FastMCP · LangChain


1) Golden Rules

  1. Think → Memory → Tools → Code → Memory. Use code-reasoning; search Memory and claude-context first; minimal diff; write learnings back.
  2. Tests are truth. Failures → fix code first. Change tests only if clearly wrong spec.
  3. Minimal diff. Add tests before code. Keep simple.
  4. Consistency > cleverness. Follow SOPs and stack idioms.
  5. Memory multiplies. Persist decisions, patterns, error signatures, proven fixes.
  6. Files ≤ 1000 lines. Exceed → refactor (see §5).
  7. No extensive docs/summaries/comments unless requested.
  8. No --autogenerate for Alembic migrations; write manually.
  9. No cat to create files; use tools.
  10. Log default: logger.debug. Important events: logger.info. Issues only: logger.warning/error. No print.

Prefer local changes over cross-module refactors.


2) Task Bootstrap Pattern

<!-- plan:start
goal: <one line clear goal>
constraints:
- Python 3.14; Reflex UI; FastAPI; SQLAlchemy 2.0; Alembic; Pydantic; appkit_mantine;
- logging: no f-strings in logger calls
- files ≤ 1000 lines; apply design patterns where appropriate
- minimal diff; add/adjust tests first
definition_of_done:
- tests pass; coverage ≥ 80% (non-Reflex classes & Reflex states); lint/type checks clean; memory updated
steps:
1) Search Memory for "<keywords>"
2) Draft/adjust failing test to capture expected behavior
3) Implement minimal code change
4) Run task test; iterate until green
5) Update Memory: decisions, patterns, error→fix
plan:end -->

3) Tooling Decision Matrix

SituationPrimarySecondaryStore to Memory
API/pattern uncertaintyContext7—Canonical snippet + link; edge cases
Ecosystem bug/issueDuckDuckGoContext7Minimal repro; versions; workaround
Repeated test failureMemory (search)Context7Error signature → fix; root cause
New feature scaffoldContext7—How‑to snippet; checklist
House style/toolingThis fileContext7Checklist results

Prefer official docs; widen via web search for cross-version issues.


4) SOP — Development Workflow

Task Runner: task (via Taskfile.dist.yml), not make.

Prepare

  1. Memory first — search prior solutions.
  2. Reasoning plan — Task Bootstrap Pattern.
  3. task sync (uv, Python 3.13).
  4. task test — snapshot current failures.

Triage Failures

  • Read first failing assertion; map to spec.
  • Tests match spec → fix code. Diverge → document; adjust spec/tests (after approval).
  • Add/adjust unit tests to codify expected behavior.

Implement (Minimal Diff)

  • Tests-first for new behavior. Approved stacks only. Apply design patterns (see §5).
  • No print. Use logging module.
  • No f-strings in logger calls:

    import logging
    
    log = logging.getLogger(__name__)
    log.info("Loaded items: %d", count)  # ✅
    # log.info(f"Loaded items: {count}") # ❌

Quality Gates

  • task lint, task format.
  • task test — coverage ≥ 80% non-Reflex classes & Reflex states.

Commit & PR

  • Conventional Commits (feat:, fix:, refactor:…).
  • PR: description, Closes #123, UI screenshots, migration rationale.

Learn → write to Memory


5) Python Code & Testing

Full rules in writing-python-code skill. Key:

  • Python 3.14; uv; line length 88.
  • No f-strings in logger calls.
  • Files ≤ 1000 lines.
  • Coverage ≥ 80% non-Reflex classes & State classes.
  • Type annotations on all functions/methods.

6) Reflex Best Practices

Full rules in reflex-state-and-architecture skill. Appkit-specific:

  • Substates & Mixins: State vars on main class; methods split by concern in mixins.
  • Background Task Chaining: Yield class method ref: yield MyState.background_task.
  • rx.cond operators: & and |, not and/or.
  • DB Access: No rx.session() in background/callbacks/utils. Use appkit_commons.database.session_manager.get_session_manager().session().

7) appkit_mantine Components

Full API in appkit-mantine-reference skill. Rules:

  • import appkit_mantine as mn — Mantine 9.5.2.
  • Never redeclare inherited props — MantineComponentBase → MantineLayoutComponentBase → MantineInputComponentBase provide ~40 common props.
  • MantineProvider auto-injected at priority 44 — no manual wrap.

8) Security & Config

  • No credentials in code/history; .env local, Key Vault prod.
  • Non-secret YAML; env __ override pattern.
  • Parameterized logs; no sensitive values.
  • SecretStr → .get_secret_value().
  • Update vulnerable deps; document CVE-driven updates in commits & Memory.

9) Search SOPs

  • Context7 first for framework truths; cite in Memory.
  • DuckDuckGo for cross-version issues; prefer official docs.
  • Store only final answer: minimal snippet + rationale + version pins + link.

10) Pre‑PR Checklist

  • Tests added/updated; all green
  • Coverage ≥ 80% non-Reflex classes & Reflex states
  • task format && task lint pass
  • No file > 1000 lines
  • Design patterns applied
  • Migrations reviewed & documented
  • Memory updated (decisions, patterns, error→fix)
  • PR description complete; links/screenshots added

11) Skills

SkillPurpose
writing-python-codePython 3.14 style, logging, type annotations, design patterns, testing
reflex-state-and-architectureState design, event handlers, background tasks, form validation, page factory, service registry, repo pattern, DB models, architecture
appkit-mantine-referenceFull API for appkit_mantine components — inputs, layout, overlays, charts, data display, navigation
testing-reflex-statePytest unit tests for Reflex State — event handlers, computed vars, substates
multi-stage-dockerfileOptimized multi-stage Dockerfiles, layer caching, security, healthchecks

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.