agentleFS
aayushusaayushus/skills/agent-config/copilot-instructions.md

skills / agent-config

Copilot instructions1 starsChanged 3 months agoMITView on GitHub

This codebase uses project-specific conventions with hard rules that must never be broken. Always follow these. When in doubt, check installed project docs under docs/guidelines/ if they exist.

The file

Show its rules and text

We split this copilot-instructions.md into the rules it gives an agent

13 rules. About 0 are common, 9 are distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈9

    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. Very specific:

    Always follow these. When in doubt, check installed project docs under docs/guidelines/ if they exist.

    line 4
  2. Very specific:

    If src/design/SKILL.md or design/SKILL.md exists, load it before UI work

    line 38
  3. Distinctive:

    If no design skill exists, follow the project's existing component library and styles

    line 39
  4. Distinctive:

    Do not introduce Tailwind, shadcn, Material UI, or another visual system unless the project already uses it or the user explicitly asks

    line 40
  5. Distinctive:

    Prefer project tokens for colours, radii, spacing, and font names when tokens exist

    line 41
  6. Distinctive:

    Never silence errors — always log or rethrow

    line 47
  7. Very specific:

    No ad-hoc console.log debugging — use the project logger

    line 52
  8. Distinctive:

    No commented-out code — delete it

    line 53
  9. Very specific:

    No TypeScript enum — use string literal unions

    line 55
  10. Distinctive:

    Follow the project's selected testing / QA approach from the Stack section

    line 58
  11. Distinctive:

    Add or update tests for changed behavior when adjacent test patterns exist

    line 59
  12. Distinctive:

    Run the narrowest relevant validation first, then broader checks when confidence is needed

    line 60
  13. Distinctive:

    If QA is manual or not yet configured, say so explicitly

    line 61

≈ “Common” is an estimate: at least 1 in 5 of the 3,950 Copilot instructions 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
copilot-instructions.md

GitHub Copilot workspace instructions

This codebase uses project-specific conventions with hard rules that must never be broken. Always follow these. When in doubt, check installed project docs under docs/guidelines/ if they exist.

Stack

<!-- CUSTOMIZE: Replace this section with your project's actual stack -->
  • Frontend/Backend: [e.g., Next.js 14 App Router, React + Vite, Express, FastAPI]
  • ORM / Query layer: [e.g., Drizzle ORM, Prisma, SQLAlchemy, raw SQL]
  • Primary Database: [e.g., PostgreSQL, SQLite, MySQL]
  • Async Queue: [e.g., BullMQ, Celery, None/Direct Background Streaming]
  • Session Store: [e.g., Redis, database-backed sessions, JWTs]
  • API style: [e.g., REST + JSON / GraphQL / tRPC]
  • Testing / QA: [e.g., Unit + integration + E2E smoke tests / Unit + integration / Manual QA]
  • CI Quality Gates: [e.g., Typecheck + lint + tests on every PR / Typecheck + unit tests / Existing CI only]

Critical rules (catastrophic if missed)

<!-- CUSTOMIZE: Adjust tenancy rules to match your data model (multi-tenant vs single-tenant) -->
  1. Tenancy boundaries — if multi-tenant, every query on tenant data filters by tenantId; if single-tenant, ignore tenant constraints
  2. No raw SQL concatenation — use parameterized ORM/query-builder calls; raw SQL requires explicit review
  3. Tenant identity comes from auth context — never from URL params or request body
  4. Unauthorized reads return 404 — never 403 (prevents existence leak)
  5. Soft deletes for recoverable business data — avoid hard deletes unless the domain explicitly requires them
  6. Consistent primary keys — use the project's chosen ID strategy everywhere
  7. Cursor pagination only — never offset/limit on large sets
  8. Async anything > 1 second — use the project's background queue/worker strategy, never block an HTTP handler
  9. Modern password hashing — use Argon2id, bcrypt cost ≥ 12, or the platform-approved equivalent
  10. Revocable user sessions — prefer server-side session storage where revocation matters
  11. Schema validation on every input boundary — strict/no-extra-keys mode, including max lengths
  12. AI guardrails — validate all LLM-generated parameters with schemas; scrub PII before calling external model APIs
  13. Structured logs only — include request/correlation IDs and tenant IDs where applicable
  14. Secrets in a secrets manager or environment — never in code, never logged
  15. No unsafe dynamic typing — use unknown with narrowing in TypeScript instead of any
  16. No N+1 queries — batch, join, preload, or select related data intentionally

Design system rules

  • If src/design/SKILL.md or design/SKILL.md exists, load it before UI work
  • If no design skill exists, follow the project's existing component library and styles
  • Do not introduce Tailwind, shadcn, Material UI, or another visual system unless the project already uses it or the user explicitly asks
  • Prefer project tokens for colours, radii, spacing, and font names when tokens exist
  • Touch targets: 44×44px minimum on mobile

Error handling

  • Throw exceptions for programming errors (bugs)
  • Return Result types for expected failures (validation, not-found, rate-limit)
  • Never silence errors — always log or rethrow

Code style

  • TypeScript strict: true + noUncheckedIndexedAccess
  • Functions ≤ 40 lines (max 80), files ≤ 300 lines (max 500)
  • No ad-hoc console.log debugging — use the project logger
  • No commented-out code — delete it
  • Boolean variables: is/has/can/should prefix
  • No TypeScript enum — use string literal unions

Testing and QA

  • Follow the project's selected testing / QA approach from the Stack section
  • Add or update tests for changed behavior when adjacent test patterns exist
  • Run the narrowest relevant validation first, then broader checks when confidence is needed
  • If QA is manual or not yet configured, say so explicitly

Performance hard caps

  • UI response: ≤ 100ms | API p95: < 300ms | DB indexed lookup: ≤ 10ms
  • JS bundle gzipped: ≤ 170KB | CSS gzipped: ≤ 30KB
  • LCP: ≤ 2.5s | INP: ≤ 200ms | CLS: ≤ 0.1

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.