# Tasks — Add `@suaveplan/audio-ir-room-plugin-pool` > Prereqs: `add-audio-ir-core`, `add-audio-ir-loader`, `add-audio-decode-wav` must reach SHIPPED before §5 integration tests can pass. ## 1. Spec authoring - [ ] 1.1 Read `openspec/AGENTS.md` §§ 13, 14, 14a, 2c, 6a, 193 - [ ] 1.2 Read `openspec/changes/add-audio-ir-core/design.md` - [ ] 1.3 `proposal.md` (incl. `## Impact`) - [ ] 1.4 `specs/audio-ir-room-plugin-pool/spec.md` — every requirement carries `**Verified by:**` - [ ] 1.5 Working-notes checklist ## 2. Package scaffold - [ ] 2.1 `mkdir -p packages/audio-ir/audio-ir-room-plugin-pool/{src/{manifest,register},files,tests/integration}` - [ ] 2.2 `package.json` — `version: 0.0.0`, `sideEffects: false`, `files: ["dist", "files", "README.md"]`, deps `@suaveplan/{audio-ir-core,storage-uri,storage-uri-plugin-bundle,storage-uri-plugin-fallback,error,types}`, dev `@suaveplan/{audio-ir-loader,audio-decode-wav,storage-http}`, `zod`, `tslib` - [ ] 2.3 `tsconfig.lib.json`, `vite.config.ts` - [ ] 2.4 Subpath exports: `.`, `./manifest`, `./register` - [ ] 2.5 `README.md` — `## License & sources` recording Mountain Duck path + the CDN URL ## 3. Asset import - [ ] 3.1 Copy `/mnt/c/Users/Administrator/Mountain Duck/74a17879-9780-426d-8bd9-7ed805f53d41/media/_/audio/ir/room/outdoor-swimming-pool.wav` → `packages/audio-ir/audio-ir-room-plugin-pool/files/outdoor-swimming-pool.wav` - [ ] 3.2 Verify the file exists, is non-empty, and decodes through `decodeWav` - [ ] 3.3 Record decoded `channels` and `sampleRate` — the manifest constants - [ ] 3.4 Verify `https://swch.b-cdn.net/_/audio/ir/room/roompool.wav` is reachable AND returns a `200` with `audio/wav` content type AND decodes through `decodeWav` (smoke test at authoring time only; the integration test uses a `node:http` fixture, not the live CDN) ## 4. Implementation - [ ] 4.1 `src/manifest/manifest.ts` + `.md` — `manifest: IrManifest` with the single entry; URI built via `buildFallbackUri([...])` - [ ] 4.2 `src/register/register.ts` + `.md` — `register(registry, resolver)` - [ ] 4.3 `src/index.ts` — explicit named re-exports ## 5. Tests - [ ] 5.1 `src/manifest/manifest.test.ts` — every scenario from manifest requirement - [ ] 5.2 `src/register/register.test.ts` — every scenario from register requirement - [ ] 5.3 `tests/integration/file-presence.test.ts` — bundle file exists + decodes - [ ] 5.4 `tests/integration/bundle-only.test.ts` — bundle wins; HTTPS not fetched - [ ] 5.5 `tests/integration/fallback-walk.test.ts` — bundle-miss `rootUrl` substitution + `node:http` fixture for HTTPS candidate - [ ] 5.6 Every `it(...)` carries `{ timeout: 5000 }` (or 30000 for async) ## 6. Documentation - [ ] 6.1 Sibling `.md` for every `.ts` (≥200 words, basic + advanced examples) - [ ] 6.2 README `## Modules` + `## License & sources` - [ ] 6.3 Update root `CLAUDE.md` Audio IR subsection ## 7. Pre-archive verification (5-gate triple) - [ ] 7.1 `bun run check` — 0/0/0/0 - [ ] 7.2 `bunx turbo lint typecheck test --filter=@suaveplan/audio-ir-room-plugin-pool` — green - [ ] 7.3 `bunx turbo test:coverage --filter=@suaveplan/audio-ir-room-plugin-pool` — 100/100/100/100 - [ ] 7.4 `bun scripts/openspec-conformance.ts @suaveplan/audio-ir-room-plugin-pool` — exit 0 - [ ] 7.5 `bunx turbo build --filter=@suaveplan/audio-ir-room-plugin-pool` — green ## 8. Pre-archive 7-row checklist (AGENTS §13) - [ ] 8.1 Manifest literal types preserved through export - [ ] 8.2 Zod schemas wired (manifest + fallback URI parse) - [ ] 8.3 No package-owned error codes — reuses `AUDIO_IR.*`, `BUNDLE_URI.*`, `FALLBACK_URI.*` - [ ] 8.4 Strict-mode behaviors tested - [ ] 8.5 OTel from upstream packages — counters asserted in `fallback-walk.test.ts` - [ ] 8.6 Lifecycle dedup tested (double-register, double-load via cache) - [ ] 8.7 No retroactive tick ## 9. Archive - [ ] 9.1 Fold delta into new `openspec/specs/audio-ir-room-plugin-pool/spec.md` - [ ] 9.2 Move folder to `openspec/archive/-add-audio-ir-room-plugin-pool/` - [ ] 9.3 Refresh `MANIFEST.md`