Context. surface studio · domain aja · route /studio/aja/dance-pipeline · auth signed-in + studio entitlement · source apps/oshun/web/src/app/studio/aja/dance-pipeline/page.tsx
Last walked. 2026-07-04 focused real-dev-infra Playwright route walk — anonymous redirect, Aja-admin temporal-coherence catalog, exact seeded teleport/stutter and edited clean-flow dance motions through the real BFF, local/BFF validation, malformed/transport failures, loading/403/503/malformed catalog states, pending controls, Metis links, route-map + quick-action affordances, mobile/touch/axe, and direct BFF auth/schema gates. Evidence: WALKTHROUGH/results/v1-real-infra-run-2026-06-22.md §288.
Purpose#
Admin lane console for dance-motion flow analysis. Its operations lane wires
@aja/motion-quality analyzeTemporalCoherence via
/v1/admin/aja/dance-pipeline: run a dance motion through the flow/rhythm
analyzer — it detects jumps (teleporting joints), freezes (sustained near-zero
velocity), and stutters (sudden velocity changes), and scores frame-to-frame
continuity, motion-phase consistency, and rhythm stability, returning the
overall + three sub-scores and the discontinuity list. A preserved Metis
embodied-instruction panel bridges the dance domain into structured learning.
Entry points#
- Direct URL / bookmark —
/studio/aja/dance-pipeline; metadata setsalternates.canonical. - Linked from
/studioDomain-bridge studios section (Aja sub-area). - Quick action — "Open Aja Fitness Pipeline workspace"
(
/studio/aja/fitness-pipeline).
Layout regions#
page.tsx renders inside <ShellLayout active="studio">:
- Workspace
StudioAjaDancePipelineWorkspace—<h1>"Aja Dance Pipeline Workspace" + summary (data-aja-dance-pipeline-summary), the Metis panel (data-aja-dance-pipeline-metis-panel,domain="dance"), then the Temporal Coherence Operations Lane (data-aja-dance-pipeline-operations-lane). - Route Map panel (
data-aja-dance-pipeline-route-map,<h2>) — 5 entries fromSTUDIO_AJA_DANCE_PIPELINE_ROUTE_MAPexposed withdata-aja-dance-pipeline-route-map-entry/data-route-path. - Quick-action lane (
data-aja-dance-pipeline-quick-actions) — twoLink.quickActionanchors: fitness-pipeline and/studio.
States#
The lane fetches GET /v1/admin/aja/dance-pipeline on mount.
- Loading —
data-aja-dp-loading"Loading coherence analyzer...". - Unauthorized (gated) —
data-aja-dp-unauthorizedon 401/403; admin scope message ("Aja workspace scope required to analyze temporal coherence."). - Error —
data-aja-dp-erroron non-OK / malformed / network failure. - Ready (form) —
data-aja-dp-form, catalog attributes (data-aja-dp-analyzer, jump/freeze thresholds, sub-score count anddata-aja-dp-sub-scorespans), and idle submit state. - Result —
data-aja-dp-resultwith stable score / continuity / phase-consistency / rhythm-stability / discontinuity-count attributes,data-aja-dp-headline,data-aja-dp-subscores, typeddata-aja-dp-discontinuity-rowattributes, anddata-aja-dp-clean. - Validation error —
data-aja-dp-analyze-error(e.g. "Provide at least one joint id." / "Frames must be valid JSON."). - Mobile/touch containment — form controls and route actions remain at least 44 px tall with no horizontal overflow.
- Empty — N/A; catalog + Metis panel are constant
Interactions#
Temporal Coherence form (data-aja-dp-form)#
- Joint ids — input
data-aja-dp-joints(defaultRightHand); comma-separated, at least one. - Frames — textarea
data-aja-dp-frames; JSON array of{ positions: { jointId: { x, y, z } } }, at least 4 frames. - Analyze coherence — submit
data-aja-dp-submit; firesPOST /v1/admin/aja/dance-pipeline/analyzewith{ joints, frames }; locked withdata-aja-dp-submit-state="analyzing"while the real request is pending.
Metis embodied-instruction panel#
- Relationship cards (
data-aja-dance-pipeline-metis-summary+data-aja-dance-pipeline-metis-card) — links bridge thedancedomain into Metis study moments and expose stable hrefs.
Route Map panel#
- 5 entries — non-interactive listing with exact path ordering.
Quick-action lane#
- "Open Aja Fitness Pipeline workspace" →
/studio/aja/fitness-pipeline - "Back to Studio workspace index" →
/studio
Data & contracts#
- Reads:
GET /v1/admin/aja/dance-pipeline(catalog:analyzer,summary,defaultThresholds,subScores) on mount,cache: 'no-store',buildBffAuthHeaders(); client fails closed unless the expectedtemporal-coherenceanalyzer and all three sub-scores are present. - Writes:
POST /v1/admin/aja/dance-pipeline/analyze→{ score, continuity, phaseConsistency, rhythmStability, discontinuities }; client fails closed unless the result and each discontinuity row have the expected typed fields. - Realtime: none.
- Caching: client fetch on mount (no-store); SSR shell.
- Auth/role check: BFF endpoints admin-scoped, fail-closed (401/403 → unauthorized render); route gated signed-in + studio via the proxy.
Cross-references#
- Parent:
../../studio-overview.md - Sibling routes:
./studio-aja-fitness-pipeline.md - Component sources:
apps/oshun/web/src/components/studio/StudioAjaDancePipelineWorkspace.tsxapps/oshun/web/src/components/studio/StudioAjaDancePipelineRouteMap.tsapps/oshun/web/src/components/studio/StudioAjaMetisEmbodiedInstructionPanel.tsx
Verification evidence#
apps/oshun/web/e2e/studio-aja-dance-pipeline.spec.tsruns against the real Next Studio shell and local BFF, forwarding browser bearer auth rather than mocking the temporal-coherence contract.- The spec covers anonymous redirect, Aja-admin catalog load, exact default
teleporting/stuttering
RightHandmotion, edited clean-flow motion, local validation with no POST, BFF validation details, malformed result, transport failure, loading / 503 / malformed / non-admin states, pending form locking, Metis bridge links, mobile no-overflow + 44px controls, scoped axe, and direct BFF 401/403/400/200 gates.
Open questions / known gaps#
- Route Map lists
scenes/exports/revisions/governancechild routes that are not yet implemented as pages.