ProSkillsLibraryFreePassScan
Grill Me

Grill Me · agent skill

ADR Writer

Decisions written down properly.

What it does

Loads when it is needed

Your agent loads it when a technical decision is made. It carries 3 rules and reads a profile.md with your details before it starts, so the output matches your brand and project.

Same prompt, with and without

Record a multi-tenancy decision

Prompt · We just decided how to do multi-tenancy. Write this up as an ADR so the next hire understands why.

Notes from today's call (4 March), by Ravi:
- Decision: all customers share one Postgres schema, every table gets a workspace_id column, and we turn on row-level security (RLS).
- Why: 140 workspaces now, Hana expects about 600 by end of year.
- I spiked schema-per-tenant on Monday. Prisma migrations across 50 schemas took 11 minutes.
- Also looked at a database per tenant on Neon (about $19 a month each, too much), and plain app-level filtering with no RLS.
- App-level filtering is what we had. In February a missed where-clause leaked rows between workspaces on staging.
- Prisma has no RLS support, so we need a transaction wrapper that runs SET LOCAL app.workspace_id before every query.
- Deciders: Hana (founder), Joel (eng lead), me.
- Last ADR in docs/adr is 0008. Related: 0004 (Postgres for all app data).
- Reopen if a customer needs data residency, or we pass 2000 workspaces.

Profile used: Project: Tallybook, bookkeeping app for freelancers. Stack: Next.js, Postgres, Prisma, Vercel. Risk appetite: Balanced.

Without the skill
# ADR 0009: Shared-schema multi-tenancy with row-level security Status: Accepted (4 March) Deciders: Hana (founder), Joel (eng lead), Ravi Related: ADR 0004 (Postgres for all app data) ## Context Tallybook has 140 workspaces and Hana expects about 600 by year end. We need tenant isolation that scales without heavy ops cost. Our existing app-level filtering failed in February, when a missed where-clause leaked rows between workspaces on staging. ## Decision All customers share one Postgres schema. Every table gets a workspace_id column, and we enable row-level security (RLS). Prisma has no RLS support, so a transaction wrapper runs SET LOCAL app.workspace_id before every query. ## Options considered - Schema per tenant: strong isolation, but Ravi's spike showed Prisma migrations across 50 schemas took 11 minutes. That won't scale to 600. - Database per tenant (Neon): about $19/month each, too expensive. - App-level filtering only (status quo): no database-level safety net, and it already leaked data. ## Consequences - Isolation is enforced by the database, not by every developer remembering a filter. - One schema means one fast migration. - Every query must go through the wrapper, or RLS has no workspace set. Add tests for this. - RLS policies need maintaining and add some query overhead. ## Revisit if A customer needs data residency, or we pass 2,000 workspaces.
With the skill
docs/adr/0009-use-shared-schema-with-rls-for-tenancy.md # 0009. Use a shared schema with row-level security for tenancy - Status: accepted - Date: 2026-03-04 - Deciders: Hana (founder), Joel (eng lead), Ravi - Relates to: 0004 (Postgres) ## Context - 140 workspaces today, about 600 expected by year end. - A schema-per-tenant spike took 11 minutes to migrate 50 schemas with Prisma. - In February a missed workspace filter leaked rows on staging. ## Options 1. **Shared schema + workspace_id + RLS.** Pro: one migration run; the database enforces isolation. Con: Prisma lacks RLS support. 2. **Schema per tenant.** Pro: strong separation. Con: migration time grows with tenant count. 3. **Database per tenant (Neon).** Pro: hard isolation. Con: about $19 a month each. 4. **Shared schema, app-level filtering only.** Pro: no extra work. Con: one missed filter leaks data. ## Decision We use one shared schema with RLS. It keeps migrations fast at 600 workspaces and moves isolation from every query into the database. ## Consequences - Good: one migration per release; a leak needs a bypassed policy. - Bad: we maintain a custom wrapper setting app.workspace_id before every Prisma query. - Follow-up: [ ] build the wrapper; [ ] RLS policy on every table, with a cross-workspace read test. ## Revisit when - A customer needs data residency, or workspaces pass 2000. Index row added…

Both answers from the same model (Claude sonnet), 2026-10-16. The one without the skill was written in a separate session that never saw it. Shortened where marked with …

Install

One command, in your project

It detects your agent; add --agent all for every agent.

npx proskills-cli add adr-writer --order <order id from your receipt>

Or copy the skill folder (the one holding SKILL.md) into the directory your agent reads, then restart it or start a new session.

AgentThis projectEvery project
Claude Code.claude/skills/~/.claude/skills/
Cursor.agents/skills/ (or .cursor/skills/)~/.cursor/skills/
Codex.agents/skills/~/.agents/skills/
Gemini CLI.agents/skills/ (or .gemini/skills/)~/.gemini/skills/

Changelog

What changed

  • v1.0.0 · 2026-10-16
    • First versioned release: Decisions written down properly.
    • Scanned 100/100 before release.

Keep it current with npx proskills-cli update; your profile.md is never touched. Everyone who bought it gets the update free and an email when it lands.

Same collection

More from Grill Me

The scan checks spec compliance, token cost, clarity and security patterns. A clean scan is not a guarantee: static scanners can be evaded. Scan any skill yourself.