agent-instructions
Use when writing project instructions for a coding agent (CLAUDE.md, AGENTS.md, or equivalent). Covers what belongs in them, what…
Use when a significant technical decision needs to be recorded. Produces Architecture Decision Records that capture context, options, the decision, and its consequences — so the reasoning survives the people who made it. Trigger on "write an adr for this", "document why we chose
Claude Code
$ npx -y skills add nimadorostkar/Claude-Skills-collection --skill architecture-decisions --agent claude-code
Codex
$ npx skills add nimadorostkar/Claude-Skills-collection --skill architecture-decisions -a codex -y
Cursor
$ npx skills add nimadorostkar/Claude-Skills-collection --skill architecture-decisions -a cursor -y
Gemini CLI
$ npx skills add nimadorostkar/Claude-Skills-collection --skill architecture-decisions -a gemini-cli -y
GitHub Copilot
$ npx skills add nimadorostkar/Claude-Skills-collection --skill architecture-decisions -a github-copilot -y
OpenCode
$ npx skills add nimadorostkar/Claude-Skills-collection --skill architecture-decisions -a opencode -y
Windsurf
$ npx skills add nimadorostkar/Claude-Skills-collection --skill architecture-decisions -a windsurf -y
name: architecture-decisions description: Use when a significant technical decision needs to be recorded. Produces Architecture Decision Records that capture context, options, the decision, and its consequences — so the reasoning survives the people who made it. Trigger on "write an adr for this", "document why we chose postgres", "record this decision", "nobody remembers why we did this". Do not use for designing the system itself — see the system-design skill. metadata: category: development version: 1.0.0 tags: [adr, documentation, architecture, decision-record]
Record why a decision was made, not just what was decided. Code shows the what. The context, the alternatives, and the constraints that made the choice correct at the time are otherwise lost within months.
A numbered ADR in `docs/adr/NNNN-short-title.md` with:
1. **State the forces** — What is pushing on this decision? Latency, cost, team familiarity, compliance, an existing commitment. If there are no forces, there is no decision to record. 2. **List real options** — Including the status quo. An ADR with one option is a justification, not a decision. 3. **Evaluate against the forces** — Each option, against each force. The trade-offs should be visible in the table. 4. **Decide and state it plainly** — "We will use PostgreSQL." Not "PostgreSQL was considered favorably." 5. **Write the consequences honestly** — Especially the negative ones. An ADR with only upsides is marketing. 6. **Never delete an ADR** — Supersede it. The old reasoning is what explains the old code.
# 0007. Use Postgres advisory locks for job deduplication - Status: Accepted - Date: 2025-03-11 - Deciders: platform team ## Context Scheduled jobs run on three application instances. Each instance's cron fires independently, so a nightly reconciliation job runs three times. Two of the three runs are wasted work; occasionally they interleave and double-write ledger entries. We already run Postgres 15 and have no Redis or Zookeeper in production. Adding one introduces a new operational dependency for a problem that occurs once per night. ## Options | Option | Correctness | New infra | Ops cost | |----------------------------|-------------|-----------|----------| | Postgres advisory lock | Strong | None | None | | Redis SETNX lock | Strong | Redis | Moderate | | Leader election (Raft lib) | Strong | None | High | | Single designated instance | Weak (SPOF) | None | Low | ## Decision We will use Postgres transaction-level advisory locks, keyed by job name, acquired at the start of each scheduled run. An instance that cannot acquire the lock exits immediately. ## Consequences - No new infrastructure; the lock is released automatically if an instance dies, because it is tied to the transaction. - Job scheduling now depends on Postgres availability. If Postgres is down, no jobs run — which is already true, since every job writes to it. - This does not generalize to jobs that must run without a database. If we add such a job, this decision must be revisited.
A curated library of 137 production-grade skills for Claude and other AI coding agents. Every skill follows one structure, speaks with one voice, and earns its place by changing what the agent does.
Use when writing project instructions for a coding agent (CLAUDE.md, AGENTS.md, or equivalent). Covers what belongs in them, what…
Use when an agent needs state that survives a session or a context compaction. Covers what to persist, file-based memory,…
Use when automating agent behavior with lifecycle hooks. Covers hook events, deterministic enforcement of rules the model should…
Use when packaging skills, commands, hooks, and MCP servers into a distributable plugin. Covers manifest structure, bundling,…
Use when writing a new skill for an AI agent. Covers scoping, description writing for reliable triggering, progressive…
Use when reviewing or improving an existing agent skill. Covers triggering accuracy, content quality, redundancy with the base…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.