Effect-TS
Apply Effect semantics using local project patterns first, then only the task-specific reference and upstream source
needed to resolve uncertainty.
Fast Path
Do not activate this workflow merely because a file imports effect. For nontrivial Effect changes:
- Inspect neighboring services, layers, errors, schemas, runtime boundaries, and tests.
- Read
references/critical-rules.md before editing. In particular, Effect failures are not caught by ordinary
try/catch inside Effect.gen; avoid assertion-driven type escapes; use explicit terminating yields for error
branches.
- Read only the matching reference rows below.
- Implement the least surprising pattern consistent with local code and verify the changed Effect behavior.
Reference Router
| Task |
Reference |
Services, Layers, tags, Effect.fn |
references/services-layers.md |
| Config and secrets |
references/config.md |
| Schema, JSON Schema, encoded errors/models |
references/schema-jsonschema.md |
@effect/vitest, clocks, fibers, retries |
references/testing.md |
| resources, scheduling, refs, concurrency |
references/runtime.md |
| streams and backpressure |
references/streams.md |
| pattern matching and tagged unions |
references/pattern-matching.md |
@effect/ai |
references/ai.md |
@effect/sql |
references/sql.md |
| platform and RPC |
references/platform-rpc.md |
Next.js / @prb/effect-next |
references/next-js.md |
| Effect Atom |
references/effect-atom.md |
| collection operations |
references/collection-operations.md |
| small utilities and deprecations |
references/quick-utils.md |
Option at nullable boundaries |
references/option-null.md |
| recent upstream drift |
references/recent-upstream.md |
| constructor/combinator lookup |
references/quick-reference.md |
Upstream Evidence
Inspect ~/.effect only when local patterns and the selected reference do not resolve an API, type/runtime, or
recent-behavior question. If the task requires it and the checkout is missing, stop rather than guessing. Compare the
project's installed package version with the relevant package source/changelog; do not assume this skill's last-known
version is authoritative.
Boundaries
- Keep pure helpers, constants, and path manipulation pure unless an Effect boundary provides a concrete dependency,
testability, resource-safety, or error-model benefit.
- Preserve existing domain facades and service/runtime boundaries unless the user requested redesign.
- Prefer typed failures and scoped resources at IO boundaries; choose Schema-backed errors/models only when encoding or
boundary validation is needed.
- Do not broaden environment requirements merely to replace a small platform call.
Completion requires code consistent with local Effect architecture, selected references/upstream evidence where needed,
and the narrowest test/typecheck that exercises the changed semantics.
1---
2disable-model-invocation: false
3name: effect-ts-2
4user-invocable: true
5description:
6 Use for nontrivial Effect-TS work including services/layers, typed errors, Schema/JSONSchema, Config,
7 runtime/concurrency, @effect/vitest, @effect/ai, @effect/sql, or @prb/effect-next.
8metadata:
9 source: https://skillmd.com/skills/om-scogo/effect-ts-2
10---
11
12# Effect-TS
13
14Apply Effect semantics using local project patterns first, then only the task-specific reference and upstream source
15needed to resolve uncertainty.
16
17## Fast Path
18
19Do not activate this workflow merely because a file imports `effect`. For nontrivial Effect changes:
20
211. Inspect neighboring services, layers, errors, schemas, runtime boundaries, and tests.
222. Read `references/critical-rules.md` before editing. In particular, Effect failures are not caught by ordinary
23 `try/catch` inside `Effect.gen`; avoid assertion-driven type escapes; use explicit terminating yields for error
24 branches.
253. Read only the matching reference rows below.
264. Implement the least surprising pattern consistent with local code and verify the changed Effect behavior.
27
28## Reference Router
29
30| Task | Reference |
31| ------------------------------------------ | ------------------------------------- |
32| Services, Layers, tags, `Effect.fn` | `references/services-layers.md` |
33| Config and secrets | `references/config.md` |
34| Schema, JSON Schema, encoded errors/models | `references/schema-jsonschema.md` |
35| `@effect/vitest`, clocks, fibers, retries | `references/testing.md` |
36| resources, scheduling, refs, concurrency | `references/runtime.md` |
37| streams and backpressure | `references/streams.md` |
38| pattern matching and tagged unions | `references/pattern-matching.md` |
39| `@effect/ai` | `references/ai.md` |
40| `@effect/sql` | `references/sql.md` |
41| platform and RPC | `references/platform-rpc.md` |
42| Next.js / `@prb/effect-next` | `references/next-js.md` |
43| Effect Atom | `references/effect-atom.md` |
44| collection operations | `references/collection-operations.md` |
45| small utilities and deprecations | `references/quick-utils.md` |
46| `Option` at nullable boundaries | `references/option-null.md` |
47| recent upstream drift | `references/recent-upstream.md` |
48| constructor/combinator lookup | `references/quick-reference.md` |
49
50## Upstream Evidence
51
52Inspect `~/.effect` only when local patterns and the selected reference do not resolve an API, type/runtime, or
53recent-behavior question. If the task requires it and the checkout is missing, stop rather than guessing. Compare the
54project's installed package version with the relevant package source/changelog; do not assume this skill's last-known
55version is authoritative.
56
57## Boundaries
58
59- Keep pure helpers, constants, and path manipulation pure unless an Effect boundary provides a concrete dependency,
60 testability, resource-safety, or error-model benefit.
61- Preserve existing domain facades and service/runtime boundaries unless the user requested redesign.
62- Prefer typed failures and scoped resources at IO boundaries; choose Schema-backed errors/models only when encoding or
63 boundary validation is needed.
64- Do not broaden environment requirements merely to replace a small platform call.
65
66Completion requires code consistent with local Effect architecture, selected references/upstream evidence where needed,
67and the narrowest test/typecheck that exercises the changed semantics.