Context. surface studio · domain aja · route /studio/aja/martial-arts-pipeline · auth signed-in + studio entitlement · source apps/oshun/web/src/app/studio/aja/martial-arts-pipeline/page.tsx
Last walked. 2026-07-04 focused real-dev-infra Playwright route walk — anonymous redirect, Aja-admin style-consistency catalog, exact seeded pose-shift and edited steady martial-arts 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 §292.
Purpose#
Admin lane console for martial-arts form-consistency checks. Its operations lane
wires @aja/motion-quality analyzeStyleConsistency via
/v1/admin/aja/martial-arts-pipeline: it compares velocity profile, pose
characteristics, and timing patterns across motion segments, returns an overall
score plus velocity / pose / timing sub-scores, and flags frames where the form
style breaks. A preserved Metis embodied-instruction panel bridges the
martial-arts domain into structured learning moments.
Entry points#
- Direct URL / bookmark —
/studio/aja/martial-arts-pipeline; metadata setsalternates.canonical. - Linked from
/studioDomain-bridge studios section (Aja sub-area). - Quick action from sibling route — Sports Pipeline links here.
Layout regions#
page.tsx renders inside <ShellLayout active="studio">:
- Workspace
StudioAjaMartialArtsPipelineWorkspace—<h1>"Aja Martial Arts Pipeline Workspace" + summary (data-aja-martial-arts-pipeline-summary), the Metis panel (data-aja-martial-arts-pipeline-metis-panel,domain="martial-arts"), then the Style Consistency Operations Lane (data-aja-martial-arts-pipeline-operations-lane). - Route Map panel (
data-aja-martial-arts-pipeline-route-map,<h2>) — 5 entries fromSTUDIO_AJA_MARTIAL_ARTS_PIPELINE_ROUTE_MAPexposed withdata-aja-martial-arts-pipeline-route-map-entry/data-route-path. - Quick-action lane (
data-aja-martial-arts-pipeline-quick-actions) — twoLink.quickActionanchors: dance-pipeline and/studio.
States#
The lane fetches GET /v1/admin/aja/martial-arts-pipeline on mount.
- Loading —
data-aja-ma-loading"Loading style-consistency analyzer...". - Unauthorized (gated) —
data-aja-ma-unauthorizedon 401/403; admin scope message ("Aja workspace scope required to analyze style consistency."). - Error —
data-aja-ma-erroron non-OK / malformed / network failure. - Ready (form) —
data-aja-ma-form, catalog attributes (data-aja-ma-analyzer, default window size, sub-score count anddata-aja-ma-sub-scorespans), idle form state, and idle submit state. - Result —
data-aja-ma-resultwith stable score / velocity-consistency / pose-consistency / timing-consistency / style-break-count attributes,data-aja-ma-headline,data-aja-ma-subscores, typeddata-aja-ma-break-rowattributes, anddata-aja-ma-clean. - Validation error —
data-aja-ma-analyze-error(e.g. "Provide at least one joint id." / "Frames must be valid JSON." / "Window size must be an integer of at least 2."). - 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#
Style Consistency form (data-aja-ma-form)#
- Joint ids — input
data-aja-ma-joints(defaultRightHand); comma-separated, at least one. - Frames — textarea
data-aja-ma-frames; JSON array of{ positions: { jointId: { x, y, z } } }, at least 4 frames. - Segment window size — input
data-aja-ma-window; integer at least 2 (default3). - Analyze style consistency — submit
data-aja-ma-submit; firesPOST /v1/admin/aja/martial-arts-pipeline/analyzewith{ joints, frames, windowSize }; locked withdata-aja-ma-submit-state="analyzing"while the real request is pending.
Metis embodied-instruction panel#
- Relationship cards (
data-aja-martial-arts-pipeline-metis-summary+data-aja-martial-arts-pipeline-metis-card) — links bridge themartial-artsdomain 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 Dance Pipeline workspace" →
/studio/aja/dance-pipeline - "Back to Studio workspace index" →
/studio
Data & contracts#
- Reads:
GET /v1/admin/aja/martial-arts-pipeline(catalog:analyzer,summary,defaultWindowSize,subScores) on mount,cache: 'no-store',buildBffAuthHeaders(); client fails closed unless the expectedstyle-consistencyanalyzer, finite default window size, and all three sub-scores are present. - Writes:
POST /v1/admin/aja/martial-arts-pipeline/analyze→{ score, velocityConsistency, poseConsistency, timingConsistency, styleBreaks }; client fails closed unless the result and each style-break 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-sports-pipeline.md,./studio-aja-dance-pipeline.md - Component sources:
apps/oshun/web/src/components/studio/StudioAjaMartialArtsPipelineWorkspace.tsxapps/oshun/web/src/components/studio/StudioAjaMartialArtsPipelineRouteMap.tsapps/oshun/web/src/components/studio/StudioAjaMetisEmbodiedInstructionPanel.tsx
Verification evidence#
apps/oshun/web/e2e/studio-aja-martial-arts-pipeline.spec.tsruns against the real Next Studio shell and local BFF, forwarding browser bearer auth rather than mocking the style-consistency contract.- The spec covers anonymous redirect, Aja-admin catalog load, exact default pose-shift output, edited steady-form clean output, 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.