# ISIS v2 WS08-008: RunPod Endpoint Classes for Audio-Heavy Workflows

## Summary

`WS08-008` introduces dedicated RunPod endpoint classes for audio-heavy Isis
workflows so audio traffic can be routed to specialized serverless lanes instead
of sharing only generic image/video families.

## Implemented Endpoint Classes

- `audio-sfx`: optimized lane for `text-to-audio` workflows.
- `audio-voice`: optimized lane for `voice-synthesis` workflows.
- `audio-music`: optimized lane for `music-generation` workflows.

Implemented for both `production` and `staging` desired-state inventories with
separate stable/canary endpoint environment variables, worker bounds, GPU class,
idle timeout, and execution timeout definitions.

## Contract and Routing Updates

- Added new feature-flag/env contracts for audio endpoint IDs and canary rollout
  controls:
  - `RUNPOD_AUDIO_SFX_ENDPOINT_ID`
  - `RUNPOD_AUDIO_VOICE_ENDPOINT_ID`
  - `RUNPOD_AUDIO_MUSIC_ENDPOINT_ID`
  - `RUNPOD_AUDIO_SFX_CANARY_ENDPOINT_ID`
  - `RUNPOD_AUDIO_SFX_CANARY_PERCENTAGE`
  - `RUNPOD_AUDIO_VOICE_CANARY_ENDPOINT_ID`
  - `RUNPOD_AUDIO_VOICE_CANARY_PERCENTAGE`
  - `RUNPOD_AUDIO_MUSIC_CANARY_ENDPOINT_ID`
  - `RUNPOD_AUDIO_MUSIC_CANARY_PERCENTAGE`
- Expanded generation-api provider compatibility endpoint-family matrix with
  `audio-sfx`, `audio-voice`, and `audio-music` support declarations.
- Expanded RunPod operations and provider routing diagnostics payloads to expose
  audio endpoint IDs and canary state.
- Expanded SDK/client type contracts to include new endpoint families.

## Web Exposure

- Updated RunPod operations UI to render canary status lines for all endpoint
  families, including audio classes.
- Updated feature flag diagnostics UI to surface endpoint canary state for the
  new audio classes.

## Verification

- `python3 scripts/isis/validate_runpod_desired_state.py --file infra/runpod/endpoints/desired-state.json`
- `pnpm --filter @oshun/config exec vitest run src/features.spec.ts --reporter=dot`
- `pnpm --filter @isis/generation-api exec vitest run src/routes/jobs.spec.ts --reporter=dot`
- `pnpm --filter @isis/web exec vitest run src/pages/RunPodPage.spec.tsx src/pages/FeatureFlagsPage.spec.tsx src/pages/RunPodParityPage.spec.tsx --reporter=dot`

## Outcome

Audio-heavy workflows now have dedicated RunPod endpoint classes with explicit
stable/canary routing controls and end-to-end visibility in API, SDK, and web
operations surfaces.
