forked from RC219805/Transformation_Portal
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathportal.html
More file actions
1932 lines (1863 loc) · 177 KB
/
Copy pathportal.html
File metadata and controls
1932 lines (1863 loc) · 177 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html lang="en" class="light">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="theme-color" content="#F4F7FB" media="(prefers-color-scheme: light)" />
<meta name="theme-color" content="#020617" media="(prefers-color-scheme: dark)" />
<title>Transformation Portal — Orchestrator</title>
<link rel="preload" as="font" type="font/woff2" crossorigin href="__PORTAL_FONT_SANS_URL__" />
<link rel="stylesheet" href="__PORTAL_CSS_URL__" />
</head>
<!--
============================================================================
TRANSFORMATION PORTAL — OPERATOR CONSOLE
============================================================================
This file contains the HTML structure for the portal operator console.
It is organized into the following sections:
1. HEADER - Top bar with branding, health status, actions
2. OVERVIEW VIEW - Dashboard with status, recent jobs, next action
3. BUILD VIEW - Pipeline configuration and dispatch stepper
4. OPERATE VIEW - Job queue, inspector, logs, artifacts
5. REVIEW VIEW - Artifact preview and comparison
6. OVERLAYS - Shortcuts, effective config drawers
7. SCRIPTS - Portal JavaScript import
Contract notes:
- data-ui attributes used by browser smoke tests
- ?view= query param routes: overview, build, operate, review
- job=, artifact=, compare=1 additive params
- /portal/assets/* served by FastAPI
============================================================================
-->
<body
data-console-view="overview"
data-bootstrap-status="pending"
data-review-surface-js-url="__PORTAL_REVIEW_JS_URL__"
data-review-surface-css-url="__PORTAL_REVIEW_CSS_URL__"
data-operate-surface-js-url="__PORTAL_OPERATE_JS_URL__"
data-build-surface-js-url="__PORTAL_BUILD_JS_URL__"
data-overview-surface-js-url="__PORTAL_OVERVIEW_JS_URL__"
class="shell-bg text-slate-900 dark:text-slate-100 antialiased selection:bg-cyan-500/25 transition-colors duration-300"
>
<a href="#main-content" class="skip-link rounded-lg px-4 py-2 text-sm font-medium text-white bg-indigo-600 shadow-lg">
Skip to main content
</a>
<div aria-hidden="true" class="shell-noise"></div>
<!-- ============================================ -->
<!-- 1. HEADER -->
<!-- ============================================ -->
<header class="portal-topbar sticky top-0 z-40 border-b backdrop-blur-xl transition-colors duration-300" data-ui="portal-topbar">
<div class="portal-topbar__inner mx-auto max-w-7xl px-6 py-4 flex items-center justify-between gap-4">
<div class="flex items-center gap-4 min-w-0">
<div class="portal-brand-mark flex h-12 w-12 items-center justify-center rounded-2xl text-sm font-black tracking-[0.24em] shadow-soft">
<img
class="portal-brand-asset portal-brand-asset--light"
src="__PORTAL_BRAND_LIGHT_URL__"
alt=""
width="48"
height="48"
decoding="async"
fetchpriority="high"
aria-hidden="true"
/>
<img
class="portal-brand-asset portal-brand-asset--dark"
src="__PORTAL_BRAND_DARK_URL__"
alt=""
width="48"
height="48"
decoding="async"
aria-hidden="true"
/>
</div>
<div class="flex min-w-0 flex-col">
<p class="section-kicker">Operator Console</p>
<h1 class="mt-0.5 text-lg font-extrabold tracking-tight">Transformation Portal</h1>
<p class="topbar-subtitle">Task-first build, live operations, and governed artifact review.</p>
</div>
<div class="topbar-status hidden lg:flex">
<span id="healthIndicator" class="status-dot"></span>
<span id="healthText" class="text-[11px] font-mono font-semibold text-slate-600 dark:text-slate-400">Checking...</span>
</div>
</div>
<div class="portal-topbar__actions flex items-center gap-3" data-ui="portal-topbar-actions">
<button id="shortcutsBtn" type="button" class="portal-action-control portal-action-control--topbar portal-action-control--shortcut border px-3 py-2 text-[11px] font-semibold uppercase tracking-[0.18em] text-slate-500 hover:text-slate-900 hover:border-slate-300 dark:text-slate-400 dark:hover:text-white dark:hover:border-slate-600 transition-colors">
Shortcuts <span class="kbd">?</span>
</button>
<button id="themeBtn" type="button" class="portal-action-control portal-action-control--topbar px-4 py-2 text-xs font-semibold border hover:bg-slate-50 dark:hover:bg-slate-800 transition-colors" aria-label="Theme preference: system. Click to switch to dark.">
Theme: System
</button>
<button id="logoutBtn" type="button" data-ui="logout-button" hidden class="portal-action-control portal-action-control--topbar px-4 py-2 text-xs font-semibold border hover:bg-slate-50 dark:hover:bg-slate-800 transition-colors disabled:opacity-50 disabled:cursor-not-allowed" aria-label="Sign out of the operator console">
Sign out
</button>
</div>
</div>
</header>
<main id="main-content" tabindex="-1" class="portal-main mx-auto max-w-7xl outline-none">
<div class="portal-shell-grid">
<!-- ============================================ -->
<!-- 2. OVERVIEW VIEW -->
<!-- ============================================ -->
<section id="overview-shell" data-ui="overview-grid" class="portal-overview-shell mb-6 lg:mb-0 grid grid-cols-1 lg:grid-cols-12 gap-4 lg:items-start">
<div id="mission-shell" class="workspace-shell workspace-shell--overview overview-primary lg:col-span-7 rounded-[1.75rem] shell-panel-strong p-6" data-ui="overview-summary">
<div id="missionShellSkeletonState" class="hidden space-y-5" aria-hidden="true" data-ui="overview-skeleton">
<div class="surface-skeleton-row">
<div class="flex-1 space-y-3">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-medium"></span>
<span class="skeleton-line"></span>
</div>
<div class="hidden lg:flex flex-col gap-2 w-40">
<span class="skeleton-pill"></span>
<span class="skeleton-pill"></span>
</div>
</div>
<div class="grid grid-cols-2 gap-3 lg:grid-cols-4">
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
</div>
<div class="surface-skeleton-card">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
<span class="skeleton-line skeleton-line-medium"></span>
</div>
</div>
<div id="missionShellContent">
<div class="flex flex-col gap-5 lg:flex-row lg:items-start lg:justify-between">
<div class="max-w-2xl">
<p class="section-kicker">Overview</p>
<h2 class="mt-3 text-3xl font-extrabold tracking-tight text-slate-950 dark:text-white">Current operator status</h2>
<p class="mt-3 text-base leading-7 text-slate-600 dark:text-slate-300">
Start a new run, resume the current draft, or jump straight into the latest live or reviewable work.
</p>
</div>
<div class="overview-actions" data-ui="overview-actions-cluster">
<button id="heroRunBtn" type="button" class="hero-action hero-action-primary" data-ui="overview-new-run">
New Run
</button>
<button id="resumeDraftBtn" type="button" class="hero-action hero-action-secondary" data-ui="overview-resume-draft">
Resume Draft
</button>
<button id="heroExportBtn" type="button" class="hero-action hero-action-secondary disabled:opacity-50 disabled:cursor-not-allowed btn-busy" disabled data-ui="overview-active-job" aria-busy="false">
View Active Job
</button>
<button id="refreshHealthBtn" type="button" class="hero-action hero-action-secondary disabled:opacity-50 disabled:cursor-not-allowed btn-busy" disabled data-ui="overview-latest-review" aria-busy="false">
Review Latest Output
</button>
</div>
</div>
</div>
</div>
<div id="intelligence-shell" class="workspace-shell workspace-shell--overview overview-secondary lg:col-span-5 rounded-[1.75rem] shell-panel p-6 shadow-soft dark:shadow-soft-dark" data-ui="overview-side">
<div id="intelligenceShellSkeletonState" class="hidden space-y-4" aria-hidden="true" data-ui="overview-draft-skeleton">
<div class="surface-skeleton-row">
<div class="flex-1 space-y-3">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
<div class="flex gap-2">
<span class="skeleton-pill skeleton-pill-short"></span>
<span class="skeleton-pill skeleton-pill-short"></span>
</div>
</div>
<div class="surface-skeleton-card">
<span class="skeleton-line"></span>
<span class="skeleton-line skeleton-line-medium"></span>
</div>
<div class="surface-skeleton-grid">
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
</div>
</div>
<div id="intelligenceShellContent">
<div class="flex items-start justify-between gap-4">
<div>
<p class="section-kicker">Current Draft</p>
<h3 id="presetHeadline" class="mt-3 text-2xl font-extrabold tracking-tight text-slate-900 dark:text-white">premium</h3>
</div>
<div class="flex flex-wrap justify-end gap-2">
<span id="presetStabilityBadge" class="signal-badge">Stable</span>
<span id="backendModeBadge" class="signal-badge">Offline</span>
</div>
</div>
<p id="presetDescription" class="mt-4 text-sm leading-7 text-slate-600 dark:text-slate-300">
Balanced production quality preset.
</p>
<div class="overview-meta-grid mt-6">
<div class="panel-subtle rounded-2xl p-4">
<p class="stat-label">Input Root</p>
<p id="heroInputDir" class="mt-2 text-[12px] font-mono leading-6 text-slate-700 dark:text-slate-200 break-all">./input_images</p>
</div>
<div class="panel-subtle rounded-2xl p-4">
<p class="stat-label">Output Root</p>
<p id="heroOutputDir" class="mt-2 text-[12px] font-mono leading-6 text-slate-700 dark:text-slate-200 break-all">./output/lux_depth_v3_apex</p>
</div>
<div class="panel-subtle rounded-2xl p-4">
<p class="stat-label">Readiness</p>
<p id="heroReadinessLabel" class="mt-2 text-sm font-bold text-slate-900 dark:text-white">No warnings</p>
</div>
<div class="panel-subtle rounded-2xl p-4">
<p class="stat-label">Warning Count</p>
<p id="heroWarningCount" class="mt-2 text-sm font-bold text-slate-900 dark:text-white">0</p>
</div>
</div>
<details id="overviewRuntimeClarityShell" class="quiet-disclosure mt-6">
<summary class="quiet-disclosure__summary">
<div>
<p class="section-kicker">Runtime summary</p>
<p class="quiet-disclosure__title">Open runtime posture and checkpoint detail</p>
</div>
<span class="micro-status">Backend-owned policy</span>
</summary>
<div class="quiet-disclosure__body">
<p class="text-[12px] leading-6 text-slate-500 dark:text-slate-400">
Selected backends, runtime posture, checkpoint expectations, and license acknowledgments stay available while the draft changes.
</p>
<div id="overviewRuntimeBriefing" class="runtime-briefing-grid mt-4" data-ui="runtime-clarity-grid"></div>
</div>
</details>
</div>
</div>
<div id="overviewStatsSkeletonState" class="hidden portal-overview-stats-skeleton lg:col-span-12 grid grid-cols-2 gap-3 sm:grid-cols-4" aria-hidden="true" data-ui="overview-stats-skeleton">
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
</div>
</div>
<div id="overviewStatsRow" class="portal-overview-stats lg:col-span-12 grid grid-cols-2 gap-3 sm:grid-cols-4">
<div class="stat-tile" data-ui="overview-card">
<p class="stat-label">Pipeline</p>
<p id="heroPipelineValue" class="stat-value">lux-depth-v3</p>
</div>
<div class="stat-tile" data-ui="overview-card">
<p class="stat-label">Preset</p>
<p id="heroPresetValue" class="stat-value">premium</p>
</div>
<div class="stat-tile" data-ui="overview-card">
<p class="stat-label">Connection</p>
<p id="heroModeValue" class="stat-value">Checking…</p>
</div>
<div class="stat-tile" data-ui="overview-card">
<p class="stat-label">Recent Jobs</p>
<p id="heroQueueValue" class="stat-value">0 live jobs</p>
</div>
</div>
<div id="overviewCapabilitySkeletonState" class="hidden portal-overview-capability-skeleton lg:col-span-12" aria-hidden="true" data-ui="overview-capability-skeleton">
<span class="skeleton-line skeleton-line-tiny"></span>
<div class="mt-3 flex flex-wrap gap-2">
<span class="skeleton-pill skeleton-pill-short"></span>
<span class="skeleton-pill skeleton-pill-short"></span>
<span class="skeleton-pill"></span>
<span class="skeleton-pill skeleton-pill-short"></span>
<span class="skeleton-pill"></span>
</div>
</div>
<div id="overviewCapabilityRow" class="portal-overview-capability lg:col-span-12">
<p class="stat-label">Capability Stack</p>
<div id="capabilityChips" class="mt-3 flex flex-wrap gap-2"></div>
</div>
</section>
<nav aria-label="Workspace sections" class="portal-workspace-rail workspace-rail mb-6 lg:mb-0 rounded-2xl px-3 py-3" data-ui="view-switcher">
<div class="workspace-rail-copy">
<p class="section-kicker">Workspace</p>
<p class="workspace-rail-text">
Overview, build, live operation, and review in one quiet shell.
</p>
<p class="workspace-shortcut-hint" data-ui="workspace-shortcut-hint">
Keyboard: <span class="kbd">1</span> overview, <span class="kbd">2</span> build, <span class="kbd">3</span> operate, <span class="kbd">4</span> review, <span class="kbd">?</span> shortcuts.
</p>
</div>
<div class="workspace-rail-links" aria-label="Console views">
<a class="workspace-link is-active" data-view-link="overview" data-ui="view-link" href="?view=overview" aria-current="page" aria-keyshortcuts="1">
<span class="workspace-link-heading">
<span class="workspace-link-label">Overview</span>
<span class="workspace-link-shortcut" aria-hidden="true">1</span>
</span>
<span class="workspace-link-meta">Status, recent jobs, and next action.</span>
</a>
<a class="workspace-link" data-view-link="build" data-ui="view-link" href="?view=build" aria-keyshortcuts="2">
<span class="workspace-link-heading">
<span class="workspace-link-label">Build</span>
<span class="workspace-link-shortcut" aria-hidden="true">2</span>
</span>
<span class="workspace-link-meta">Preview-backed dispatch flow.</span>
</a>
<a class="workspace-link" data-view-link="operate" data-ui="view-link" href="?view=operate" aria-keyshortcuts="3">
<span class="workspace-link-heading">
<span class="workspace-link-label">Operate</span>
<span class="workspace-link-shortcut" aria-hidden="true">3</span>
</span>
<span class="workspace-link-meta">Queue, inspector, artifacts, and logs.</span>
</a>
<a class="workspace-link" data-view-link="review" data-ui="view-link" href="?view=review" aria-keyshortcuts="4">
<span class="workspace-link-heading">
<span class="workspace-link-label">Review</span>
<span class="workspace-link-shortcut" aria-hidden="true">4</span>
</span>
<span class="workspace-link-meta">Artifact preview, provenance, and actions.</span>
</a>
</div>
</nav>
<section id="console-context-shell" class="portal-shell-card portal-shell-card--context workspace-shell portal-context-shell mb-6 lg:mb-0 shell-panel" data-ui="console-context-shell">
<div class="portal-context-head flex flex-col gap-3 lg:flex-row lg:items-end lg:justify-between">
<div>
<p class="section-kicker">Current View</p>
<h2 id="consoleViewTitle" class="mt-2 text-2xl font-extrabold tracking-tight text-slate-900 dark:text-white">Overview</h2>
<p id="consoleViewSummary" class="mt-2 max-w-3xl text-[14px] leading-7 text-slate-600 dark:text-slate-300">Status, recent jobs, and the clearest next operator action.</p>
</div>
<p id="consoleViewMeta" class="portal-context-meta text-[11px] font-mono text-slate-500 dark:text-slate-400">View routing stays client-side to preserve the live orchestrator contract.</p>
</div>
<div class="console-context-strip mt-4" data-ui="console-context-strip">
<div id="consoleContextRibbon" class="console-context-ribbon portal-context-ribbon hidden" data-ui="console-context-ribbon" aria-live="polite" role="status">
<div id="contextRibbonCard1" class="console-context-card" data-tone="info">
<p id="contextRibbonCard1Label" class="console-context-label">Job</p>
<p id="contextRibbonJob" class="console-context-value">No job selected</p>
<p id="contextRibbonJobMeta" class="console-context-meta">Choose a run in operate or review to pin context here.</p>
</div>
<div id="contextRibbonCard2" class="console-context-card" data-tone="info">
<p id="contextRibbonCard2Label" class="console-context-label">State</p>
<p id="contextRibbonState" class="console-context-value">Idle</p>
<p id="contextRibbonFreshness" class="console-context-meta">No live telemetry</p>
</div>
<div id="contextRibbonCard3" class="console-context-card" data-tone="info">
<p id="contextRibbonCard3Label" class="console-context-label">Artifact</p>
<p id="contextRibbonArtifact" class="console-context-value">Awaiting selection</p>
<p id="contextRibbonArtifactMeta" class="console-context-meta">Review context will show the active artifact path here.</p>
</div>
<div id="contextRibbonCard4" class="console-context-card" data-tone="info">
<p id="contextRibbonCard4Label" class="console-context-label">Compare</p>
<p id="contextRibbonCompare" class="console-context-value">No compare pair</p>
<p id="contextRibbonCompareMeta" class="console-context-meta">No paired comparison is available for the current artifact.</p>
</div>
</div>
<section id="consoleActionRail" class="console-action-rail hidden" data-ui="console-action-rail" data-tone="info">
<div class="console-action-rail-copy" aria-live="polite" role="status">
<p class="console-action-rail-kicker">Action rail</p>
<p id="consoleActionRailTitle" class="console-action-rail-title">Keep the next operator move pinned</p>
<p id="consoleActionRailDetail" class="console-action-rail-detail">Contextual review, artifact, compare, and recovery actions update here from the current run state.</p>
<p id="consoleActionRailHint" class="console-action-rail-hint" data-ui="console-action-shortcuts">
Keyboard: <span class="kbd">1</span> overview, <span class="kbd">2</span> build, <span class="kbd">3</span> operate, <span class="kbd">4</span> review, <span class="kbd">?</span> shortcuts.
</p>
</div>
<div id="consoleActionRailActions" class="console-action-rail-actions">
<button id="consoleActionPrimaryBtn" type="button" class="operator-action-btn operator-action-btn-primary hidden" data-ui="console-action-primary"></button>
<button id="consoleActionSecondaryBtn1" type="button" class="operator-action-btn operator-action-btn-secondary hidden" data-ui="console-action-secondary-1"></button>
<button id="consoleActionSecondaryBtn2" type="button" class="operator-action-btn operator-action-btn-secondary hidden" data-ui="console-action-secondary-2"></button>
</div>
</section>
</div>
</section>
<!-- ============================================ -->
<!-- 3. BUILD VIEW -->
<!-- ============================================ -->
<div id="console-grid" class="grid grid-cols-1 lg:grid-cols-12 gap-8 hidden">
<!-- Left Column: Configuration -->
<section id="build-shell" class="portal-shell-card portal-shell-card--build lg:col-span-7 flex flex-col gap-6">
<!-- Orchestration Profile -->
<div id="profile-shell" data-ambient-zone="profile" data-ambient-focus-x="18" data-ambient-focus-y="28" data-ambient-shift-x="-22" data-ambient-shift-y="-4" data-ambient-stage-scale="1.02" data-ambient-stage-rotate="-0.45" data-ambient-color-a="#34d399" data-ambient-color-b="#f59e0b" data-ambient-color-c="#67e8f9" data-ambient-focus-color="#99f6e4" class="workspace-shell deferred-shell rounded-2xl shell-panel p-6 shadow-soft dark:shadow-soft-dark transition-colors duration-300" data-shell-size="compact" data-ui="connection-card">
<div id="profileShellSkeletonState" class="hidden space-y-4" aria-hidden="true" data-ui="build-skeleton">
<div class="surface-skeleton-row">
<div class="flex-1 space-y-3">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-medium"></span>
<span class="skeleton-line"></span>
</div>
<span class="skeleton-pill skeleton-pill-short"></span>
</div>
<div class="surface-skeleton-grid">
<div class="surface-skeleton-card">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
<span class="skeleton-line skeleton-line-medium"></span>
</div>
<div class="surface-skeleton-card">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
<span class="skeleton-line skeleton-line-medium"></span>
</div>
</div>
<div class="surface-skeleton-card">
<span class="skeleton-line skeleton-line-medium"></span>
<span class="skeleton-line"></span>
</div>
</div>
<div id="profileShellContent">
<div class="flex flex-col gap-2 md:flex-row md:items-end md:justify-between">
<div>
<p class="section-kicker">Connection</p>
<h2 class="mt-2 text-xl font-extrabold tracking-tight text-slate-900 dark:text-white">Pipeline and auth mode</h2>
<p class="mt-2 text-[14px] leading-7 text-slate-600 dark:text-slate-300">Choose the active pipeline, confirm connection mode, and keep profile restore close at hand.</p>
</div>
<span class="signal-badge">Build prerequisites</span>
</div>
<div class="grid grid-cols-1 sm:grid-cols-2 gap-4">
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="pipelineSelect">Pipeline Execution</label>
<select id="pipelineSelect" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="lux-depth-v3">lux-depth-v3</option>
<option value="archive-gate-a">archive-gate-a (Fixity / Manifest Prep)</option>
<option value="archive-gate-b">archive-gate-b (BagIt Build)</option>
<option value="archive-gate-c">archive-gate-c (METS Export)</option>
</select>
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="profileSelect">Local Profile</label>
<div class="flex gap-2">
<select id="profileSelect" class="flex-1 rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] transition-colors cursor-pointer">
<!-- Populated by JS -->
</select>
<button id="saveProfileBtn" type="button" class="rounded-xl px-4 py-2 text-[13px] font-semibold border border-slate-300 dark:border-slate-700 hover:bg-slate-50 dark:hover:bg-slate-800 transition-colors btn-busy" aria-busy="false">
Save
</button>
</div>
</div>
</div>
<details id="connectionDetails" class="quiet-disclosure mt-4" data-ui="connection-details">
<summary class="quiet-disclosure__summary">
<div>
<p class="section-kicker">Connection details</p>
<p class="quiet-disclosure__title">Managed access posture and direct-debug controls</p>
</div>
<div class="disclosure-summary-meta">
<span id="authModeBadge" class="rounded-full border border-slate-300 dark:border-slate-700 bg-slate-100 dark:bg-slate-800 px-2.5 py-1 text-[10px] font-mono uppercase tracking-[0.16em] text-slate-600 dark:text-slate-300">managed_unavailable</span>
<span class="disclosure-chevron text-slate-400">▾</span>
</div>
</summary>
<div class="quiet-disclosure__body">
<p id="apiKeyManagedHint" class="text-[12px] leading-relaxed text-slate-600 dark:text-slate-300">Managed mode is active. Backend credentials stay server-side and are never stored in the browser.</p>
<div id="apiKeySection" class="mt-4 hidden">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300" for="apiKeyInput">API Key</label>
<p class="mt-1 text-[12px] leading-relaxed text-slate-600 dark:text-slate-300">Direct-debug tokens are session-only and never persisted in browser local storage.</p>
<div class="mt-3 flex flex-col sm:flex-row gap-2 sm:items-center">
<input type="password" id="apiKeyInput" class="flex-1 rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" placeholder="Bearer token for /v1/jobs endpoints" autocomplete="off" spellcheck="false" disabled />
</div>
</div>
</div>
</details>
<div id="portalAccessState" class="portal-access-state mt-4" data-ui="portal-access-state" data-tone="info" data-bootstrap-status="pending">
<div class="portal-access-state__head">
<div>
<p class="portal-access-state__kicker">Access posture</p>
<p id="bootstrapRecoveryHint" class="portal-access-state__detail">Bootstrap is still being confirmed. Privileged actions remain disabled until portal authentication is resolved.</p>
</div>
<span id="bootstrapStatusBadge" class="signal-badge portal-access-state__badge" data-tone="info">Confirming access</span>
</div>
</div>
<details id="buildRuntimeClarityShell" class="quiet-disclosure mt-5">
<summary class="quiet-disclosure__summary">
<div>
<p class="section-kicker">Execution briefing</p>
<p class="quiet-disclosure__title">Open runtime and license posture detail</p>
</div>
<span class="micro-status">Decision support</span>
</summary>
<div class="quiet-disclosure__body">
<p class="text-[12px] leading-6 text-slate-500 dark:text-slate-400">
The selected depth path, segmentation mode, checkpoint expectation, and license posture stay pinned here while you move through Steps 2-4.
</p>
<div id="buildRuntimeBriefing" class="runtime-briefing-grid runtime-briefing-grid--compact mt-4" data-ui="build-runtime-clarity"></div>
</div>
</details>
</div>
</div>
<section id="buildStepperShell" class="rounded-2xl shell-panel p-5 shadow-soft dark:shadow-soft-dark" data-ui="build-stepper">
<div id="buildStepperSkeletonState" class="hidden space-y-4" aria-hidden="true" data-ui="build-stepper-skeleton">
<div class="surface-skeleton-row">
<div class="flex-1 space-y-3">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
<span class="skeleton-line"></span>
</div>
<div class="hidden lg:flex gap-2">
<span class="skeleton-pill"></span>
<span class="skeleton-pill"></span>
</div>
</div>
<div class="grid grid-cols-1 gap-3 md:grid-cols-2 xl:grid-cols-4">
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
<div class="surface-skeleton-card surface-skeleton-card-compact">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
</div>
</div>
</div>
<div id="buildStepperShellContent">
<div class="flex flex-col gap-4 lg:flex-row lg:items-end lg:justify-between">
<div>
<p class="section-kicker">Build Flow</p>
<h2 id="buildStepTitle" class="mt-2 text-xl font-extrabold tracking-tight text-slate-900 dark:text-white">1. Configure the draft</h2>
<p id="buildStepSummary" class="mt-2 text-[14px] leading-7 text-slate-600 dark:text-slate-300">Start with the pipeline and preset, then move through paths, contextual options, and dispatch review.</p>
</div>
<div class="build-stepper-actions-inline">
<button id="buildStepBackBtn" type="button" class="stepper-nav-btn">
Back
</button>
<button id="buildStepNextBtn" type="button" class="stepper-nav-btn stepper-nav-btn-primary">
Next
</button>
</div>
</div>
<div id="buildPulseGrid" class="build-pulse-grid mt-5" data-ui="build-step-pulse">
<div id="buildPulseDraftCard" class="build-pulse-card" data-tone="info">
<p class="build-pulse-label">Draft</p>
<p id="buildPulseDraft" class="build-pulse-value">premium</p>
<p id="buildPulseDraftMeta" class="build-pulse-meta">lux-depth-v3 draft is staged for preview-backed dispatch.</p>
</div>
<div id="buildPulseStepCard" class="build-pulse-card" data-tone="info">
<p class="build-pulse-label">Current Focus</p>
<p id="buildPulseStep" class="build-pulse-value">1 of 4 · Configure</p>
<p id="buildPulseStepMeta" class="build-pulse-meta">Pipeline and preset posture.</p>
</div>
<div id="buildPulsePreviewCard" class="build-pulse-card" data-tone="info">
<p class="build-pulse-label">Preview</p>
<p id="buildPulsePreview" class="build-pulse-value">Refreshing</p>
<p id="buildPulsePreviewMeta" class="build-pulse-meta">Preview-backed validation will summarize the draft here.</p>
</div>
<div id="buildPulseDispatchCard" class="build-pulse-card" data-tone="info">
<p class="build-pulse-label">Dispatch</p>
<p id="buildPulseDispatch" class="build-pulse-value">Review dispatch posture</p>
<p id="buildPulseDispatchMeta" class="build-pulse-meta">The next operator action stays pinned here while the draft changes.</p>
</div>
</div>
<div id="buildStepTabs" class="build-step-tabs mt-5" role="tablist" aria-label="Build steps">
<button id="buildStepTab1" type="button" class="build-step-tab is-active" data-build-step-target="1" role="tab" aria-selected="true" data-ui="build-step-tab">
<span class="build-step-index">1</span>
<span class="build-step-copy">
<span class="build-step-label">Configure</span>
<span class="build-step-meta">Pipeline and preset posture.</span>
</span>
</button>
<button id="buildStepTab2" type="button" class="build-step-tab" data-build-step-target="2" role="tab" aria-selected="false" data-ui="build-step-tab">
<span class="build-step-index">2</span>
<span class="build-step-copy">
<span class="build-step-label">Paths</span>
<span class="build-step-meta">Inputs, outputs, and stage-specific files.</span>
</span>
</button>
<button id="buildStepTab3" type="button" class="build-step-tab" data-build-step-target="3" role="tab" aria-selected="false" data-ui="build-step-tab">
<span class="build-step-index">3</span>
<span class="build-step-copy">
<span class="build-step-label">Outputs</span>
<span class="build-step-meta">Deliverables, posture, and readiness.</span>
</span>
</button>
<button id="buildStepTab4" type="button" class="build-step-tab" data-build-step-target="4" role="tab" aria-selected="false" data-ui="build-step-tab">
<span class="build-step-index">4</span>
<span class="build-step-copy">
<span class="build-step-label">Dispatch</span>
<span class="build-step-meta">Primary review, launch, and parity tools.</span>
</span>
</button>
</div>
</div>
</section>
<!-- Parameters -->
<div id="parameters-shell" class="workspace-shell deferred-shell rounded-2xl shell-panel p-6 shadow-soft dark:shadow-soft-dark transition-colors duration-300" data-shell-size="tall">
<div id="parametersShellSkeletonState" class="hidden space-y-4" aria-hidden="true" data-ui="build-parameters-skeleton">
<div class="surface-skeleton-row">
<div class="flex-1 space-y-3">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line skeleton-line-short"></span>
<span class="skeleton-line"></span>
</div>
<span class="skeleton-pill skeleton-pill-short"></span>
</div>
<div class="surface-skeleton-grid">
<div class="surface-skeleton-card">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
<span class="skeleton-line skeleton-line-medium"></span>
</div>
<div class="surface-skeleton-card">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-line"></span>
<span class="skeleton-line skeleton-line-medium"></span>
</div>
</div>
<div class="surface-skeleton-card">
<span class="skeleton-line skeleton-line-tiny"></span>
<span class="skeleton-block"></span>
</div>
</div>
<div id="parametersShellContent">
<div class="flex items-start justify-between gap-3 mb-4">
<div>
<h2 class="text-[11px] font-bold uppercase tracking-widest text-slate-500 dark:text-slate-400">Pipeline Parameters</h2>
<p class="mt-2 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Move quickly from intent to dispatch: choose the outcome, set the input/output paths, then open advanced controls only when the run contract needs them.</p>
</div>
<span class="signal-badge">Preset or custom flow</span>
</div>
<section id="presetBuilderShell" data-build-step-panel="1" class="rounded-xl border border-slate-200 dark:border-slate-800 bg-slate-50/80 dark:bg-slate-900/50 p-5 build-step-panel" data-ui="build-step-panel">
<div class="flex items-start justify-between gap-3">
<div>
<p class="section-kicker">Step 1</p>
<h3 class="mt-2 text-base font-extrabold tracking-tight text-slate-900 dark:text-white">Choose a preset or manual mode</h3>
<p class="mt-2 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Curated presets still hydrate the fastest valid path. Switch to custom when you need manual Lux controls without backfilling a curated preset contract.</p>
</div>
<span class="micro-status">Preset or custom → draft posture</span>
</div>
<div class="mt-4 grid grid-cols-1 sm:grid-cols-3 gap-4">
<div class="sm:col-span-3">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="presetSelect">Preset</label>
<select id="presetSelect" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="premium" selected>premium (Stable)</option>
<option value="default">default (Canary)</option>
<option value="depth-anything-v3.1-research-m4">v3.1-m4 (Experimental)</option>
<option value="custom">custom (Manual)</option>
</select>
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="qualityTier">Quality Tier</label>
<select id="qualityTier" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="apex">apex (Max)</option>
<option value="premium" selected>premium</option>
<option value="standard">standard</option>
</select>
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="depthDevice">Compute Device</label>
<select id="depthDevice" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="cpu" selected>cpu</option>
<option value="cuda">cuda</option>
<option value="mps">mps (macOS)</option>
</select>
</div>
<div class="panel-subtle rounded-2xl p-4">
<p class="text-[10px] font-bold uppercase tracking-[0.18em] text-slate-500 dark:text-slate-400">Preset effect</p>
<p id="presetBuilderHint" class="mt-2 text-[12px] leading-6 text-slate-600 dark:text-slate-300">Recommended defaults and advanced sections will adapt when the preset changes.</p>
</div>
</div>
</section>
<section id="buildPathsShell" data-build-step-panel="2" class="mt-5 rounded-xl border border-slate-200 dark:border-slate-800 bg-slate-50/80 dark:bg-slate-900/50 p-5 build-step-panel" data-ui="build-step-panel">
<div class="flex items-start justify-between gap-3">
<div>
<p class="section-kicker">Step 2</p>
<h3 class="mt-2 text-base font-extrabold tracking-tight text-slate-900 dark:text-white">Set inputs and output destination</h3>
<p class="mt-2 text-[12px] leading-6 text-slate-500 dark:text-slate-400">A standard Lux Depth run should be dispatchable from these paths alone. JSON import/export, custom manual tuning, and full CLI parity stay available below for exact reproducibility.</p>
</div>
<span class="micro-status">Input → output → dispatch</span>
</div>
<div class="mt-4 grid grid-cols-1 sm:grid-cols-2 gap-4">
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="inputDir">Input Directory</label>
<input type="text" id="inputDir" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" value="./input_images" autocomplete="off" spellcheck="false" required aria-required="true" />
<p id="inputDirStatus" class="field-status mt-1 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Set the source folder for the next run.</p>
<div id="stagedUploadShell" class="mt-3 hidden rounded-xl border border-dashed border-slate-300 dark:border-slate-700 bg-white/70 dark:bg-slate-900/60 p-4" data-ui="staged-upload-shell">
<div class="flex flex-wrap items-start justify-between gap-3">
<div>
<p class="text-[11px] font-semibold uppercase tracking-[0.16em] text-slate-500 dark:text-slate-400">Staged Uploads</p>
<p id="stagedUploadStatus" class="mt-2 text-[12px] leading-6 text-slate-600 dark:text-slate-300">Upload a file set and the staged input directory will replace the current source path.</p>
</div>
<div class="flex flex-wrap gap-2">
<button type="button" id="stagedUploadPickFilesBtn" class="inline-flex items-center justify-center rounded-lg border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2 text-[12px] font-semibold text-slate-700 dark:text-slate-200 transition-colors hover:border-indigo-400 hover:text-indigo-600 dark:hover:text-indigo-300" data-ui="staged-upload-pick-files">Choose files</button>
<button type="button" id="stagedUploadPickFolderBtn" class="inline-flex items-center justify-center rounded-lg border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2 text-[12px] font-semibold text-slate-700 dark:text-slate-200 transition-colors hover:border-indigo-400 hover:text-indigo-600 dark:hover:text-indigo-300" data-ui="staged-upload-pick-folder">Choose folder</button>
</div>
</div>
<div id="stagedUploadDropzone" class="mt-3 rounded-lg border border-slate-200 dark:border-slate-800 bg-slate-50/80 dark:bg-slate-950/40 px-4 py-4 text-[12px] leading-6 text-slate-600 dark:text-slate-300" data-ui="staged-upload-dropzone" tabindex="0" role="button" aria-label="Choose files or drop files for staged upload" aria-describedby="stagedUploadStatus">
Drop files here or choose a file set from disk. Relative paths are preserved for managed staging.
</div>
<div class="mt-3">
<div class="h-2 w-full overflow-hidden rounded-full bg-slate-200 dark:bg-slate-800">
<div id="stagedUploadProgressBar" class="h-full w-0 rounded-full bg-indigo-500 transition-[width]" data-ui="staged-upload-progress"></div>
</div>
<p id="stagedUploadProgressLabel" class="mt-2 text-[12px] leading-6 text-slate-500 dark:text-slate-400">No upload in progress.</p>
</div>
<div id="stagedUploadSummary" class="mt-3" aria-live="polite" aria-atomic="true" role="status"></div>
<p id="stagedUploadError" class="mt-1 text-[12px] leading-6 text-red-600 dark:text-red-300" aria-live="assertive" role="alert"></p>
<input type="file" id="stagedUploadFilesInput" class="hidden" multiple />
<input type="file" id="stagedUploadFolderInput" class="hidden" webkitdirectory directory multiple />
</div>
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="outputDir">Output Directory</label>
<input type="text" id="outputDir" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" value="./output/lux_depth_v3_apex" autocomplete="off" spellcheck="false" required aria-required="true" />
<p id="outputDirStatus" class="field-status mt-1 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Choose the governed destination for generated outputs.</p>
</div>
</div>
</section>
<!-- Lux Depth Specific Fields -->
<div id="fieldsLuxDepth" data-build-step-panel="3" class="pipeline-fields build-step-panel block space-y-6 mt-5 pt-5 border-t border-slate-200 dark:border-slate-800" data-ui="build-step-panel">
<div class="flex items-start justify-between gap-3">
<div>
<p class="section-kicker">Step 3</p>
<h3 class="mt-2 text-base font-extrabold tracking-tight text-slate-900 dark:text-white">Shape deliverables and confirm output posture</h3>
<p class="mt-2 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Keep deliverables, primary output posture, and immediate readiness readable first, then open advanced, governance, or reconstruction controls only when the current run contract needs them.</p>
</div>
<span class="micro-status">Deliverables first, research controls second</span>
</div>
<div class="grid grid-cols-1 sm:grid-cols-2 gap-4">
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="depthBackend">Depth Backend</label>
<select id="depthBackend" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="da3" selected>da3 (Depth Anything v3)</option>
<option value="depth_pro">depth_pro (Research-Only)</option>
</select>
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="modelKey">DA3 Model</label>
<select id="modelKey" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="da3-metric" selected>da3-metric (Apache-2.0)</option>
<option value="da3-research">da3-research (CC-BY-NC)</option>
</select>
</div>
</div>
<fieldset class="group-bare">
<legend class="sr-only">Segmentation</legend>
<div class="grid grid-cols-1 sm:grid-cols-2 xl:grid-cols-4 gap-4">
<label class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-slate-50/50 dark:bg-slate-800/50 px-4 py-3.5 cursor-pointer group transition-colors">
<span class="text-[12px] font-medium select-none text-slate-700 dark:text-slate-300">Enable Segmentation</span>
<div class="relative inline-flex items-center">
<input type="checkbox" id="enableSegmentation" role="switch" class="sr-only peer" checked />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-indigo-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-indigo-600"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
<div id="segmentationBackendField">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="segmentationBackend">Segmentation Backend</label>
<select id="segmentationBackend" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="sam2">sam2</option>
<option value="efficientsam" selected>efficientsam</option>
<option value="stub">stub</option>
</select>
</div>
<div id="sam2ModelSizeField" class="hidden">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2ModelSize">SAM2 Model Size</label>
<select id="sam2ModelSize" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">
<option value="base" selected>base</option>
<option value="large">large</option>
</select>
</div>
<label id="strictSegmentationField" class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-slate-50/50 dark:bg-slate-800/50 px-4 py-3.5 cursor-pointer group transition-colors">
<span class="text-[12px] font-medium select-none text-slate-700 dark:text-slate-300">Strict Segmentation</span>
<div class="relative inline-flex items-center">
<input type="checkbox" id="strictSegmentation" role="switch" class="sr-only peer" checked />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-indigo-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-indigo-600"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
</div>
</fieldset>
<p id="segmentationApplicabilityHint" class="text-[11px] leading-5 text-slate-500 dark:text-slate-400">Segmentation is active via efficientsam. SAM2-only controls stay hidden until you switch back to sam2.</p>
<div id="sam2CheckpointField" class="hidden">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2CheckpointPath">SAM2 Checkpoint Path (Optional)</label>
<input type="text" id="sam2CheckpointPath" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" placeholder="./models/sam2/sam2.1_hiera_large.pt" autocomplete="off" spellcheck="false" />
</div>
<div id="sam2TuningPanel" class="hidden rounded-2xl border border-slate-200 dark:border-slate-800 bg-slate-50/80 dark:bg-slate-900/50 p-4 space-y-4">
<div class="flex items-start justify-between gap-3">
<div>
<p class="text-[10px] font-bold uppercase tracking-[0.18em] text-slate-500 dark:text-slate-400">SAM2 Tuning</p>
<p id="sam2TuningHint" class="mt-2 text-[11px] leading-5 text-slate-500 dark:text-slate-400">Generator controls always apply while SAM2 is active. Tiling values matter only when tiling is enabled.</p>
</div>
<span class="shrink-0 rounded border border-indigo-300 dark:border-indigo-700 bg-indigo-50 dark:bg-indigo-900/20 px-1.5 py-0.5 text-[9px] uppercase tracking-wide text-indigo-700 dark:text-indigo-400">Advanced</span>
</div>
<label id="sam2TilingToggleField" class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-white dark:bg-slate-800 px-4 py-3.5 cursor-pointer group transition-colors">
<span class="text-[12px] font-medium select-none text-slate-700 dark:text-slate-300">Enable SAM2 Tiling</span>
<div class="relative inline-flex items-center">
<input type="checkbox" id="sam2TilingEnabled" role="switch" class="sr-only peer" />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-indigo-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-indigo-600"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
<div id="sam2TilingConfigFields" class="hidden grid grid-cols-1 sm:grid-cols-2 xl:grid-cols-4 gap-4">
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2TileSizePx">Tile Size (px)</label>
<input type="number" id="sam2TileSizePx" min="1" step="1" value="1536" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2OverlapPx">Overlap (px)</label>
<input type="number" id="sam2OverlapPx" min="0" step="1" value="256" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2GlobalPassLongestSide">Global Pass Longest Side</label>
<input type="number" id="sam2GlobalPassLongestSide" min="1" step="1" value="1280" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2MaxConcurrency">Max Concurrency</label>
<input type="number" id="sam2MaxConcurrency" min="1" step="1" value="1" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
</div>
<div id="sam2GeneratorConfigFields" class="grid grid-cols-1 sm:grid-cols-2 xl:grid-cols-5 gap-4">
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2PointsPerSide">Points / Side</label>
<input type="number" id="sam2PointsPerSide" min="1" step="1" value="32" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2PointsPerBatch">Points / Batch</label>
<input type="number" id="sam2PointsPerBatch" min="1" step="1" value="64" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2PredIouThresh">Pred IoU Threshold</label>
<input type="number" id="sam2PredIouThresh" min="0" max="1" step="0.01" value="0.88" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2StabilityScoreThresh">Stability Threshold</label>
<input type="number" id="sam2StabilityScoreThresh" min="0" max="1" step="0.01" value="0.85" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
<div>
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="sam2CropNLayers">Crop Layers</label>
<input type="number" id="sam2CropNLayers" min="0" step="1" value="1" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" />
</div>
</div>
</div>
</div>
<!-- Archive Gate Fields -->
<div id="fieldsArchiveGate" data-build-step-panel="2" class="pipeline-fields build-step-panel hidden space-y-4 pt-4 border-t border-slate-200 dark:border-slate-800" data-ui="build-step-panel">
<p class="text-[12px] text-slate-500 dark:text-slate-400">Archiving parameters for deterministic packaging and export. Align with repository governance.</p>
<div class="rounded-2xl border border-slate-200 dark:border-slate-800 bg-slate-50/80 dark:bg-slate-900/50 p-4">
<p class="text-[10px] font-bold uppercase tracking-[0.18em] text-slate-500 dark:text-slate-400">Canonical Command</p>
<p id="archiveCanonicalCommand" class="mt-2 text-[13px] font-mono font-semibold text-slate-800 dark:text-slate-100">fixity-scan</p>
<p id="archiveCanonicalCommandHint" class="mt-2 text-[11px] leading-5 text-slate-500 dark:text-slate-400">The portal build flow uses one canonical archive command per stage and keeps alternate subcommands API-only.</p>
</div>
<div id="archiveIndexField">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="archiveIndexPath">Archive Index Path</label>
<input type="text" id="archiveIndexPath" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" value="" placeholder="./tests/fixtures/archive_small/archive_index_normalized.csv.gz" autocomplete="off" spellcheck="false" />
<p id="archiveIndexStatus" class="mt-1 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Required for `fixity-scan`. Supply an existing normalized archive index that is safe to read from the local allowlist.</p>
</div>
<div id="rightsManifestField" class="hidden">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="rightsManifestPath">Rights Manifest JSONL</label>
<input type="text" id="rightsManifestPath" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors" value="" placeholder="./output/archive_manifest_v2.rights.jsonl" autocomplete="off" spellcheck="false" />
<p id="rightsManifestStatus" class="mt-1 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Required for `bag-build` and `mets-export`. This must point to an existing rights-manifest artifact generated by an earlier archive stage.</p>
</div>
</div>
</div>
</div>
<!-- Pipeline Flags -->
<fieldset id="flags-shell" data-build-step-panel="3" class="workspace-shell deferred-shell rounded-2xl shell-panel p-6 shadow-soft dark:shadow-soft-dark transition-colors duration-300 build-step-panel" data-shell-size="tall" data-ui="build-step-panel">
<legend class="block text-[11px] font-bold uppercase tracking-widest text-slate-500 dark:text-slate-400 mb-4">Primary Output Posture</legend>
<p class="step-primary-note">Shape the deliverables first. Diagnostics, acknowledgments, and runtime detail stay below as secondary controls unless the preview or contract pulls them forward.</p>
<div class="grid grid-cols-1 sm:grid-cols-2 gap-4">
<!-- Toggle Wrapper Template -->
<label class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-slate-50/50 dark:bg-slate-800/50 hover:bg-slate-100 dark:hover:bg-slate-800 px-4 py-3.5 cursor-pointer group transition-colors">
<span class="text-[13px] font-medium select-none text-slate-700 dark:text-slate-300">Materials V3</span>
<div class="relative inline-flex items-center">
<input type="checkbox" id="flagMaterials" role="switch" class="sr-only peer" checked />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-indigo-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-indigo-600"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
<label class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-slate-50/50 dark:bg-slate-800/50 hover:bg-slate-100 dark:hover:bg-slate-800 px-4 py-3.5 cursor-pointer group transition-colors">
<span class="text-[13px] font-medium select-none text-slate-700 dark:text-slate-300">PBR Generation</span>
<div class="relative inline-flex items-center">
<input type="checkbox" id="flagPBR" role="switch" class="sr-only peer" checked />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-indigo-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-indigo-600"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
<label class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-slate-50/50 dark:bg-slate-800/50 hover:bg-slate-100 dark:hover:bg-slate-800 px-4 py-3.5 cursor-pointer group transition-colors">
<span class="text-[13px] font-medium select-none text-slate-700 dark:text-slate-300">Cache Depth</span>
<div class="relative inline-flex items-center">
<input type="checkbox" id="flagCache" role="switch" class="sr-only peer" checked />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-indigo-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-indigo-600"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
<label class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-slate-50/50 dark:bg-slate-800/50 hover:bg-slate-100 dark:hover:bg-slate-800 px-4 py-3.5 cursor-pointer group transition-colors">
<span class="text-[13px] font-medium select-none text-red-600 dark:text-red-400">Overwrite Existing</span>
<div class="relative inline-flex items-center">
<input type="checkbox" id="flagOverwrite" role="switch" class="sr-only peer" />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-red-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-red-500"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
<label class="flex items-center justify-between rounded-xl border border-slate-200 dark:border-slate-700 bg-slate-50/50 dark:bg-slate-800/50 hover:bg-slate-100 dark:hover:bg-slate-800 px-4 py-3.5 cursor-pointer group transition-colors sm:col-span-2">
<span class="text-[13px] font-medium select-none text-slate-700 dark:text-slate-300">Enable V2 Compatibility</span>
<div class="relative inline-flex items-center ml-4">
<input type="checkbox" id="flagEnableV2" role="switch" class="sr-only peer" />
<div class="w-9 h-5 rounded-full transition-colors duration-200 ease-in-out peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-indigo-500 bg-slate-300 dark:bg-slate-600 peer-checked:bg-indigo-600"></div>
<div class="absolute left-[2px] top-[2px] bg-white w-4 h-4 rounded-full transition-transform duration-200 ease-in-out peer-checked:translate-x-4 shadow-sm"></div>
</div>
</label>
<div id="v2PresetField" class="hidden sm:col-span-2">
<input type="text" id="v2Preset" placeholder="V2 Preset (e.g. default)" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-4 py-2.5 text-[13px] font-mono transition-colors disabled:opacity-50" value="default" disabled autocomplete="off" spellcheck="false" />
</div>
</div>
<div class="mt-6 flex items-start justify-between gap-3">
<div>
<p class="section-kicker">Expected Deliverables</p>
<p class="mt-2 text-[12px] leading-6 text-slate-500 dark:text-slate-400">Keep the primary output set readable before opening deeper runtime or research-only controls.</p>
</div>
<span class="micro-status">Primary output contract</span>
</div>
<!-- Native Emit Checkboxes -->
<fieldset class="mt-4 group-bare">
<legend class="sr-only">Emit outputs</legend>
<div class="grid grid-cols-2 sm:grid-cols-3 xl:grid-cols-5 gap-3">
<label class="flex items-center gap-3 rounded-xl border border-slate-200 dark:border-slate-700 bg-white dark:bg-slate-800 px-3 py-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-700 transition-colors">
<input type="checkbox" id="emitMaster16" checked class="w-4 h-4 rounded text-indigo-600 border-slate-300 dark:border-slate-600 dark:bg-slate-900" />
<span class="text-[11px] font-mono select-none truncate text-slate-600 dark:text-slate-300">master16</span>
</label>
<label class="flex items-center gap-3 rounded-xl border border-slate-200 dark:border-slate-700 bg-white dark:bg-slate-800 px-3 py-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-700 transition-colors">
<input type="checkbox" id="emitUpscaled16" checked class="w-4 h-4 rounded text-indigo-600 border-slate-300 dark:border-slate-600 dark:bg-slate-900" />
<span class="text-[11px] font-mono select-none truncate text-slate-600 dark:text-slate-300">upscaled16</span>
</label>
<label class="flex items-center gap-3 rounded-xl border border-slate-200 dark:border-slate-700 bg-white dark:bg-slate-800 px-3 py-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-700 transition-colors">
<input type="checkbox" id="emitMarketing" class="w-4 h-4 rounded text-indigo-600 border-slate-300 dark:border-slate-600 dark:bg-slate-900" />
<span class="text-[11px] font-mono select-none truncate text-slate-600 dark:text-slate-300">marketing</span>
</label>
<label class="flex items-center gap-3 rounded-xl border border-slate-200 dark:border-slate-700 bg-white dark:bg-slate-800 px-3 py-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-700 transition-colors">
<input type="checkbox" id="emitReport" checked class="w-4 h-4 rounded text-indigo-600 border-slate-300 dark:border-slate-600 dark:bg-slate-900" />
<span class="text-[11px] font-mono select-none truncate text-slate-600 dark:text-slate-300">report</span>
</label>
<label class="flex items-center gap-3 rounded-xl border border-slate-200 dark:border-slate-700 bg-white dark:bg-slate-800 px-3 py-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-700 transition-colors">
<input type="checkbox" id="emitRunCard" checked class="w-4 h-4 rounded text-indigo-600 border-slate-300 dark:border-slate-600 dark:bg-slate-900" />
<span class="text-[11px] font-mono select-none truncate text-slate-600 dark:text-slate-300">run_card</span>
</label>
<label class="flex items-center gap-3 rounded-xl border border-slate-200 dark:border-slate-700 bg-white dark:bg-slate-800 px-3 py-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-700 transition-colors">
<input type="checkbox" id="emitRunCardIncludeProofs" class="w-4 h-4 rounded text-indigo-600 border-slate-300 dark:border-slate-600 dark:bg-slate-900" />
<span class="text-[11px] font-mono select-none truncate text-slate-600 dark:text-slate-300">run_card_proofs</span>
</label>
</div>
</fieldset>
<div id="runCardVersionField" class="mt-4 max-w-xs">
<label class="block text-xs font-medium text-slate-700 dark:text-slate-300 mb-1.5" for="runCardVersion">Run Card Version</label>
<select id="runCardVersion" class="w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-slate-50 dark:bg-slate-800 px-3 py-2.5 text-[13px] font-mono transition-colors cursor-pointer">