@ericrisco/rsc 0.1.48 → 0.1.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: firebase
3
- description: "Use when building on Firebase — modeling Firestore data, writing or auditing Security Rules, wiring Auth, shipping Cloud Functions, storing files in Cloud Storage, or choosing modular Web/Admin SDK imports — and when symptoms appear like 'my database is open to the internet', 'rules reject my query', a counter stuck at 1 write/sec, custom-claim RBAC, or a callable function. Triggers: 'firestore.rules audit', 'denormalize for read paths', 'collection vs subcollection', 'my query works in the emulator but fails in prod with requires-an-index', 'set a custom admin claim', 'regles de seguretat de Firestore', 'mi base de datos está abierta a internet'. NOT managed-Postgres BaaS with SQL and RLS (that is supabase)."
3
+ description: "Use when building on Firebase — Firestore data modeling, Security Rules, Auth and custom claims, Cloud Functions, Storage, modular Web/Admin SDK imports — including symptoms like a database open to the internet, a query rejected by rules, or a doc stuck at ~1 write/sec. NOT managed-Postgres BaaS with SQL and RLS (that is supabase)."
4
4
  tags: [firebase, firestore, security-rules, cloud-functions, auth]
5
5
  recommends: [secure-coding, gcp-essentials, nextjs]
6
6
  origin: risco
@@ -8,43 +8,29 @@ origin: risco
8
8
 
9
9
  # Firebase — Firestore, Rules, Auth, Functions, Storage
10
10
 
11
- Build correctly on the Firebase product surface that sits on top of GCP: model Firestore data,
12
- write and test Security Rules, wire Auth, ship Cloud Functions, and store files — all on the
13
- modular Web SDK (v12) and the Admin SDK. The whole skill exists to stop two failure modes: dragging
14
- relational/SQL habits into a NoSQL document store, and leaving the database open to the internet.
11
+ The Firebase product surface that sits on top of GCP, on the modular Web SDK (v12) and the Admin SDK.
12
+ The whole skill exists to stop two failure modes: dragging relational/SQL habits into a NoSQL
13
+ document store, and leaving the database open to the internet.
15
14
 
16
- Hold these three facts the entire time:
15
+ Two facts drive everything below:
17
16
 
18
- - **It is a NoSQL document store.** No joins, no server-side `OR` across different fields without a
19
- composite index, no `SELECT *` across collections. You shape data for the read path, not for
20
- normalization.
17
+ - **It is a NoSQL document store, shaped for the read path.** No joins, no server-side `OR` across
18
+ different fields without a composite index, no `SELECT *` across collections. Denormalize and
19
+ fan-out so a screen is one cheap query — reads are what you pay for and what users wait on.
21
20
  - **Rules ARE the access control.** Firestore is reachable directly from untrusted clients. There is
22
21
  no app server in the trust path by default — `firestore.rules` (CEL) is the only thing between a
23
22
  browser and your data. App Check attests the request even came from your app before Rules evaluate.
24
- - **Shape data for reads.** Denormalize and fan-out so a screen is one cheap query. Reads are the
25
- thing you pay for and the thing users wait on.
26
-
27
- ## When to use / When NOT to use
28
-
29
- **When to use:**
30
-
31
- - Firestore data modeling: collections vs subcollections, denormalization, fan-out, the 1 MiB
32
- document limit, hotspot avoidance, query constraints.
33
- - Writing or auditing Firestore/Storage Security Rules and testing them with the emulator.
34
- - Firebase Auth: providers, ID-token verification on the server, custom claims, session cookies.
35
- - Cloud Functions (2nd gen): Firestore/HTTPS/callable/Auth-blocking triggers, secrets, idempotency.
36
- - Cloud Storage uploads/downloads gated by Rules + signed URLs.
37
- - Modular SDK imports for tree-shaking, `firebase.json` / `firestore.indexes.json`, Emulator Suite.
38
-
39
- **When NOT to use:**
40
-
41
- - Relational schema, SQL, EXPLAIN, indexing a SQL engine → `../postgresdb/SKILL.md`.
42
- - Managed Postgres BaaS (SQL + Postgres RLS + PostgREST) → `supabase`. This is the most-confused
43
- sibling: same "backend-as-a-service" shape, but a completely different data model and rules language.
44
- - AWS document/key-value store with its own capacity model → `dynamodb`.
45
- - Self-hosted Mongo document modeling → `mongodb`.
46
- - Generic GCP project/IAM/billing not specific to a Firebase product → `gcp-essentials`.
47
- - React/Next.js component or rendering work that merely calls Firebase → `react` / `../nextjs/SKILL.md`.
23
+
24
+ Not this skill:
25
+
26
+ | Instead of Firebase | Go to |
27
+ |---|---|
28
+ | Relational schema, SQL, EXPLAIN, indexing a SQL engine | `../postgresdb/SKILL.md` |
29
+ | Managed Postgres BaaS (SQL + Postgres RLS + PostgREST) — the most-confused sibling: same "backend-as-a-service" shape, completely different data model and rules language | `supabase` |
30
+ | AWS document/key-value store with its own capacity model | `dynamodb` |
31
+ | Self-hosted Mongo document modeling | `mongodb` |
32
+ | Generic GCP project/IAM/billing not specific to a Firebase product | `gcp-essentials` |
33
+ | React/Next.js component or rendering work that merely calls Firebase | `react` / `../nextjs/SKILL.md` |
48
34
 
49
35
  ## Data modeling
50
36
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: fly-io
3
- description: "Use when deploying or operating an app on Fly.io — writing fly.toml, running Machines across regions near users, attaching Volumes, managing secrets, or scaling (autostop/autostart, scale count, fly-replay). Triggers: 'fly deploy', 'fly launch', 'desplega a Fly.io a prop dels usuaris', 'users in Sydney see high latency but my app only runs in iad', 'scale my Fly app to zero overnight', 'attach a persistent disk to my Fly machine', 'forward writes to the primary region'. NOT a generic git-push PaaS (that is railway), NOT frontend edge hosting (that is vercel)."
3
+ description: "Use when deploying or operating an app on Fly.io — writing fly.toml, placing Machines in regions near users, attaching Volumes, managing secrets, or picking a scaling lever (autostop/autostart, scale count, fly-replay). NOT choosing which host to deploy on (that is `deployment`), NOT a git-push PaaS with no regions model (that is `railway`)."
4
4
  tags: [fly-io, deployment, machines, regions, scaling]
5
5
  recommends: [docker, scaling, postgresdb, railway, domains-dns]
6
6
  origin: risco
@@ -8,7 +8,7 @@ origin: risco
8
8
 
9
9
  # Deploy on Fly.io
10
10
 
11
- You are deploying an app to Fly.io: a `fly.toml`, Machines (Firecracker microVMs) placed in regions close to users, optional region-pinned Volumes, secrets, and the right scaling lever. Get the mental model right first, then the config follows.
11
+ You are deploying an app to Fly.io: a `fly.toml`, Machines (Firecracker microVMs) placed in regions close to users, optional region-pinned Volumes, secrets, and the right scaling lever. Get the mental model right first, then the config follows. If none of that placement control matters, ../railway/SKILL.md is the git-push PaaS with no Machines/regions model.
12
12
 
13
13
  ## Mental model
14
14
 
@@ -72,7 +72,7 @@ primary_region = "iad" # 3-letter region code: iad, ord, ams, syd, gr
72
72
  initial_size = "1gb"
73
73
  ```
74
74
 
75
- Full field surface (`[[services]]` vs `[http_service]`, health checks, `[[statics]]`, `[[files]]`, all VM sizes, `[restart]`, `[metrics]`) lives in `references/fly-toml.md` — read it when you need a key that is not above.
75
+ Full field surface (`[[services]]` vs `[http_service]`, health checks, `[[statics]]`, `[[files]]`, all VM sizes, `[restart]`, `[metrics]`) lives in `references/fly-toml.md` — read it when you need a key that is not above. Custom domains, certs and registrar-level DNS are ../domains-dns/SKILL.md.
76
76
 
77
77
  ## Regions: place Machines near users
78
78
 
@@ -162,7 +162,7 @@ Treat secret hygiene as non-negotiable — see ../secure-coding/SKILL.md.
162
162
 
163
163
  Key distinction: **autostop ≠ autoscaler.** Autostop only toggles Machines that already exist; it never changes the count. The metrics autoscaler is what actually adds/removes Machines. Set `auto_stop_machines` and `auto_start_machines` **together** — configuring one without the other is undefined behavior.
164
164
 
165
- `fly-replay` is the multi-region write-forwarding pattern: read-replicas serve local reads, a write replies with `fly-replay: region=<primary>` and the Proxy re-runs the request there. Full header forms and the primary/replica split are in `references/multi-region.md`.
165
+ `fly-replay` is the multi-region write-forwarding pattern: read-replicas serve local reads, a write replies with `fly-replay: region=<primary>` and the Proxy re-runs the request there. Full header forms and the primary/replica split are in `references/multi-region.md`. These are the Fly levers only; platform-agnostic scaling theory (queues, sharding, load shedding) is ../scaling/SKILL.md.
166
166
 
167
167
  ## Cost & HA
168
168
 
@@ -195,12 +195,3 @@ It prefers `fly config validate` when flyctl is on PATH, else does structural ch
195
195
  | Treating Fly Postgres as managed | Fly Postgres is unmanaged; you operate it | Route to it here; operate it via ../postgresdb/SKILL.md |
196
196
  | `min_machines_running` in a non-primary region | Ignored outside primary | Keep warm capacity via `scale count` there |
197
197
  | `fly deploy` with no `release_command` for a schema change | New code hits an old schema mid-rollout | `release_command` runs the migration first |
198
-
199
- ## Related skills
200
-
201
- - ../docker/SKILL.md — the Dockerfile/image build Fly consumes.
202
- - ../scaling/SKILL.md — generic horizontal-scaling theory (queues, sharding, load shedding).
203
- - ../postgresdb/SKILL.md — operating the Postgres engine itself; Fly Postgres is unmanaged.
204
- - ../railway/SKILL.md — git-push PaaS with no Machines/regions model.
205
- - ../domains-dns/SKILL.md — custom domains, certs, registrar-level DNS.
206
- - ../secure-coding/SKILL.md — secret handling beyond `fly secrets`.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: fundraising
3
- description: "Use when planning or running an equity fundraising round and you need the STRATEGY and PROCESS, not a single document — sizing the raise to a milestone, choosing post-money SAFE vs priced round, building and tiering the investor target list around intro paths, sequencing outreach to manufacture momentum, managing the diligence pipeline, or reading a term sheet to know what to push on before you sign. Triggers: 'plan our seed raise', 'how much should we raise and on what terms', 'SAFE or priced round, what cap', 'build my investor target list', 'how many investors do I actually need to contact', 'we have meetings but no term sheet — the raise stalled', 'got a term sheet, what do I push back on', 'planifica la ronda seed', 'cuántos inversores tengo que contactar', '¿SAFE o ronda con precio?', 'planifiquem la ronda d'inversió'. NOT the slide-deck narrative (that is pitch-deck) and NOT the cap-table/valuation math (that is financial-model)."
3
+ description: "Use when planning or running an equity round as a process: sizing the raise to a milestone, choosing post-money SAFE vs priced round, tiering investors by intro path, sequencing outreach for momentum, or reading a term sheet before signing. NOT the slide narrative (that is `pitch-deck`), NOT the cap-table or valuation math (that is `financial-model`)."
4
4
  tags: [fundraising, seed, safe, term-sheet, investor-pipeline, venture-capital, round-strategy]
5
5
  recommends: [pitch-deck, financial-model, investor-materials, cold-outreach, contracts, grants, unit-economics]
6
6
  origin: risco
@@ -8,7 +8,7 @@ origin: risco
8
8
 
9
9
  # Fundraising — The Operating System for an Equity Round
10
10
 
11
- *Own the round as a PROCESS: size it, pick the instrument, build a tiered list around intro paths, run a concentrated sprint, read the term sheet. You do NOT write the deck, build the model, or package the data room — you decide the strategy and drive the sequence.*
11
+ *Own the round as a PROCESS: size it, pick the instrument, build a tiered list around intro paths, run a concentrated sprint, read the term sheet.*
12
12
 
13
13
  This skill thinks in **funnels** (how many investors at the top to land N term sheets), in **instruments** (post-money SAFE vs priced Series Seed), and in **leverage** (warm intros, parallel meetings, a first term sheet that creates real urgency). It consumes the deck, the model, and the collateral that siblings produce, and orchestrates them into a closed round. Scope: pre-seed through Series A priced rounds and SAFE rounds, founder-side.
14
14
 
@@ -119,9 +119,7 @@ Sprint shape
119
119
  Close first term sheet → use it to compress the rest → sign
120
120
  ```
121
121
 
122
- **The first term sheet changes everything** — it converts soft interest into urgency across the whole pipeline. Use it. But the honesty rule is absolute:
123
-
124
- > **Manufacture FOMO from a visibly busy calendar and a real first term sheet — never from fabricated competing offers or invented deadlines.** Lying about a term sheet you don't have is how a raise dies when one investor calls another; the cost of getting caught is the round.
122
+ **The first term sheet changes everything** — it converts soft interest into urgency across the whole pipeline. Use it. But the honesty rule is absolute, because it is the one mistake with no recovery: **manufacture FOMO from a visibly busy calendar and a real first term sheet — never from fabricated competing offers or invented deadlines.** Lying about a term sheet you don't have is how a raise dies when one investor calls another; the cost of getting caught is the round.
125
123
 
126
124
  Track **count-in-pipeline and stage conversion, not activity**. Benchmarks to instrument the funnel: outreach→meeting ~15%, first→second ~50%. Pipeline stages: `Sourced → Intro requested → First meeting → Partner/2nd → Diligence → Term sheet → Closed`. Week-by-week playbook and the honest-momentum mechanics → `references/process-playbook.md`.
127
125
 
@@ -140,9 +138,9 @@ A founder negotiates the few terms that **compound** — not the headline valuat
140
138
 
141
139
  Median seed lead ownership runs ~12.6%. **Don't sign the first term sheet without a comparison** — a single offer with no comp gives away your only leverage. And the hard handoff: the term sheet is mostly non-binding, but **the binding SAFE / SPA / side letter is a legal document → `../contracts/SKILL.md` and a real lawyer.** You read the term sheet to negotiate; you do not draft the binding instrument here. Full term-by-term cheat sheet with bands and push-on guidance → `references/process-playbook.md`.
142
140
 
143
- ## Anti-patterns / rationalizations → STOP
141
+ ## Anti-patterns
144
142
 
145
- | Rationalization | Reality / Fix |
143
+ | Anti-pattern | Do instead |
146
144
  | --- | --- |
147
145
  | "Raise the max — more runway is always better." | More dilution for proof you don't have. Size to the next milestone (Step 1). |
148
146
  | "I'll send a few emails and see who bites." | A serial trickle kills momentum. Concentrate 30–50 meetings in 2 weeks, parallel. |
@@ -153,10 +151,3 @@ Median seed lead ownership runs ~12.6%. **Don't sign the first term sheet withou
153
151
  | "Cold outreach is the main channel." | Cold replies ~1–3%; warm converts ~30–50%. Build around intro paths, cold last. |
154
152
  | "Tell investors we have a competing term sheet." | If untrue, the raise dies when they call each other. FOMO from real signals only. |
155
153
  | "Push the valuation up, that's the win." | The terms that compound are pref, pool, board, dilution — not headline price alone. |
156
-
157
- ## Handoffs + references
158
-
159
- - Story / slides → `../pitch-deck/SKILL.md` · numbers, cap-table, valuation → `../financial-model/SKILL.md` · one-pager, data room, updates → `../investor-materials/SKILL.md`.
160
- - Cold message copy → `../cold-outreach/SKILL.md` · binding legal doc → `../contracts/SKILL.md` · non-dilutive → `../grants/SKILL.md` · LTV/CAC probe → `../unit-economics/SKILL.md`.
161
- - `references/funnel-math.md` — work-backward funnel arithmetic, warm-intro priority ladder with per-path conversion bands, A/B/C tiering rubric, pipeline stage schema, worked $3M-seed top-of-funnel.
162
- - `references/process-playbook.md` — 6–8 week sprint week-by-week, honest momentum/FOMO mechanics, SAFE-vs-priced decision table (cost/speed/dilution), post-money SAFE pile-up worked example, term-sheet-basics cheat sheet with 2025 bands.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: game-design
3
- description: "Use when designing or repairing the design of a game — inventing mechanics and systems, shaping the core loop, layering moment-to-moment / session / meta loops, planning progression, economy, currencies and sinks/faucets, tuning difficulty curves and balance, killing dominant strategies, adding 'juice'/game feel as design intent, prototyping and playtesting, or controlling scope, and especially when the ask is 'why isn't my game fun'. Triggers: 'design the core loop', 'my game isn't fun / doesn't hook', 'balance the economy', 'the difficulty curve feels off', 'players found a dominant strategy', 'how do I scope this', 'reward / progression loop', 'diseñar la mecánica', 'el juego no engancha', 'com equilibro l'economia'. NOT writing engine code, scripts or shaders (route to godot/unity/unreal), NOT narrative, dialogue or story beats (route to game-storytelling), NOT level layout or encounter placement (route to level-design)."
3
+ description: "Use when designing or repairing what makes a game fun — verbs and mechanics, moment-to-moment/session/meta loops, progression, economy faucets and sinks, difficulty curves, dominant strategies, juice, prototyping and scope. NOT engine code (that is `godot`), NOT story (that is `game-storytelling`), NOT level layout (that is `level-design`)."
4
4
  tags: [game-design, mechanics, core-loop, balancing, progression, playtesting, scope, fun]
5
5
  recommends: [level-design, game-storytelling, godot, unity, unreal]
6
6
  profiles: [full]
@@ -9,36 +9,19 @@ origin: risco
9
9
 
10
10
  # Design games that are fun on purpose
11
11
 
12
- Engine-agnostic game design: mechanics, loops, progression, economy, balance, feel, and the discipline of prototyping and scope. No engine APIs live here — when the design is settled, the implementation belongs to `godot`, `unity`, or `unreal`.
12
+ Engine-agnostic game design: mechanics, loops, progression, economy, balance, feel, and the discipline of prototyping and scope. No engine APIs live here — when the design is settled, the implementation belongs to [`godot`](../godot/SKILL.md), [`unity`](../unity/SKILL.md), or [`unreal`](../unreal/SKILL.md).
13
13
 
14
- ## The one rule
14
+ Two premises govern everything below. **Fun is discovered, not designed** — you cannot reason your way to a fun game on paper, you find it by building the smallest playable version and playing it, so every hour spent planning a mechanic you have not prototyped is an hour spent guessing. And **a game is the set of verbs it gives the player plus the loops those verbs live in** — art, story, and levels dress that skeleton; if the skeleton is not fun in greybox, nothing dresses it into fun.
15
15
 
16
- > Fun is discovered, not designed. You cannot reason your way to a fun game on paper; you find it by building the smallest playable version and playing it. Every hour spent planning a mechanic you have not prototyped is an hour spent guessing. Prototype the riskiest assumption first, play it, then decide.
17
-
18
- > The design of a game is the set of **verbs** it gives the player plus the **loops** those verbs live in. Everything else — art, story, levels — dresses that skeleton. If the skeleton is not fun in greybox, nothing dresses it into fun.
19
-
20
- ## When to use / When NOT
21
-
22
- **Use when:**
23
- - Inventing or reworking mechanics and systems, or defining the player's verb set.
24
- - Shaping the core loop, or layering moment-to-moment → session → meta.
25
- - Planning progression, unlocks, pacing, or an in-game economy.
26
- - Tuning a difficulty curve, hunting a dominant strategy, or setting up data-driven balance.
27
- - Adding "juice" / game feel **as a design concept** (what feedback, why).
28
- - Prototyping, planning a playtest, deciding what to measure, or cutting scope.
29
- - The vague-but-critical ask: "why isn't my game fun / why doesn't it hook?"
30
-
31
- **Do NOT use — route instead:**
16
+ Route elsewhere when the ask is not design:
32
17
 
33
18
  | The ask | Route to | Why not here |
34
19
  | --- | --- | --- |
35
- | Write the movement/AI/shader/save code | `godot` / `unity` / `unreal` | This skill decides *what* to build; the engine skill builds it. |
36
- | Author the story, dialogue, characters, lore | `game-storytelling` | Narrative design is its own craft; this skill owns systems and verbs. |
37
- | Lay out a level, encounter, or world map | `level-design` | Spatial/encounter design applies the mechanics this skill defines. |
38
- | Netcode, prediction, lag compensation | `gamedev-multiplayer` | A technical domain, not core design intent. |
39
- | Ship / store page / build pipeline | `gamedev-shipping` | Release logistics, not design. |
40
-
41
- (`godot`, `unity`, `unreal`, `game-storytelling`, `level-design` are linkable siblings; the rest are known ids you name but cannot link yet.)
20
+ | Write the movement/AI/shader/save code | [`godot`](../godot/SKILL.md) / [`unity`](../unity/SKILL.md) / [`unreal`](../unreal/SKILL.md) | This skill decides *what* to build; the engine skill builds it. |
21
+ | Author the story, dialogue, characters, lore | [`game-storytelling`](../game-storytelling/SKILL.md) | Narrative design is its own craft; this skill owns systems and verbs. |
22
+ | Lay out a level, encounter, or world map | [`level-design`](../level-design/SKILL.md) | Spatial/encounter design applies the mechanics this skill defines. |
23
+ | Netcode, prediction, lag compensation | [`gamedev-multiplayer`](../gamedev-multiplayer/SKILL.md) | A technical domain, not core design intent. |
24
+ | Ship / store page / build pipeline | [`gamedev-shipping`](../gamedev-shipping/SKILL.md) | Release logistics, not design. |
42
25
 
43
26
  ## Loops: moment-to-moment → session → meta
44
27
 
@@ -149,13 +132,6 @@ Playtest protocols, metrics/retention definitions, the prototyping ladder, and c
149
132
 
150
133
  If the workspace has a `02-DOCS/` harness, record the design in `02-DOCS/wiki/design/` — a `game-design.md` one-pager (hook, core loop, verbs, pillars, MVP scope, what's out) plus an `economy.md` if there is a currency system. Write each as an OKF v0.1 wiki article per the harness [`wiki-article-template.md`](../harness/references/wiki-article-template.md): YAML frontmatter with a non-empty `type:` (use `type: design`), a `timestamp` in ISO 8601, and standard markdown links — never wikilinks. Index it in `02-DOCS/wiki/index.md`. This is **recorded, not gated** — skip silently if there is no harness.
151
134
 
152
- ## Related skills
153
-
154
- - `../level-design/SKILL.md` — applies these mechanics in space: layout, pacing beats, encounter design.
155
- - `../game-storytelling/SKILL.md` — narrative, dialogue, and how story wraps the systems you define here.
156
- - `../godot/SKILL.md`, `../unity/SKILL.md`, `../unreal/SKILL.md` — implement the settled design; all engine APIs, feel/juice code, and data-driven tuning loaders live there.
157
- - Known siblings to name but not yet link: `gamedev-multiplayer`, `gamedev-physics`, `gamedev-pathing`, `gamedev-shaders`, `gamedev-shipping`.
158
-
159
135
  ## Checklist
160
136
 
161
137
  - [ ] The **core verb** is named and is fun in greybox with no goal attached.