@wrongstack/webui 1.0.0 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (124) hide show
  1. package/dist/assets/AgentRosterView-BVjk_vTm.js +12 -0
  2. package/dist/assets/AnalyticsDashboard-cR9JJBI8.js +1 -0
  3. package/dist/assets/AudienceMemoryPanel-DyP-vZA-.js +3 -0
  4. package/dist/assets/ChangesView-DY2KWV9y.js +1 -0
  5. package/dist/assets/{ChimeraReviewsView-CpfSkgQ2.js → ChimeraReviewsView-nLzoGYHL.js} +1 -1
  6. package/dist/assets/ChronicleDashboard-D4O8L9vh.js +1 -0
  7. package/dist/assets/CodeEditor-BZCXLxnq.js +2 -0
  8. package/dist/assets/CodeMap-CBAbAWkc.js +1 -0
  9. package/dist/assets/CronJobsPanel-xM7j0r4p.js +1 -0
  10. package/dist/assets/{DeadCodeScanPanel-Cn5bSfLv.js → DeadCodeScanPanel-DWsSzjSp.js} +1 -1
  11. package/dist/assets/{DebugDashboard-Uh9QLbEk.js → DebugDashboard-D9DoHsUb.js} +1 -1
  12. package/dist/assets/DesignGalleryView-C2SBhANT.js +1 -0
  13. package/dist/assets/{GoalView-BgVxzzzS.js → GoalView-u24_HH2B.js} +1 -1
  14. package/dist/assets/KanbanView-BfrSarZw.js +3 -0
  15. package/dist/assets/MailboxDetailView-POq0LIQF.js +1 -0
  16. package/dist/assets/{MemoryDrawer-C5sEdVvj.js → MemoryDrawer-B4aW4mVs.js} +1 -1
  17. package/dist/assets/MemoryManager-BAe2zkyG.js +1 -0
  18. package/dist/assets/ProcessMonitor-9clcCd5a.js +1 -0
  19. package/dist/assets/{PromptJournalView-B65KxlYi.js → PromptJournalView-DiinN7LV.js} +1 -1
  20. package/dist/assets/QueuePanel-DxHkfNun.js +1 -0
  21. package/dist/assets/RefreshDebugView-DuRu5_AZ.js +1 -0
  22. package/dist/assets/{RequirementIntakeView-BnrQSVE_.js → RequirementIntakeView-BE1ZpNh1.js} +1 -1
  23. package/dist/assets/SageTabs-DdwqvEQL.js +2 -0
  24. package/dist/assets/{SddFlowGraph-CNOyn5N9.js → SddFlowGraph-DcUtqxxR.js} +1 -1
  25. package/dist/assets/SddHub-DYCzKYUr.js +2 -0
  26. package/dist/assets/SessionInspectView-d9NH-E5d.js +1 -0
  27. package/dist/assets/SessionList-DP_TUCns.js +1 -0
  28. package/dist/assets/SessionsDashboard-CvlpSVyY.js +1 -0
  29. package/dist/assets/SetupScreen-3_DYzzKv.js +1 -0
  30. package/dist/assets/SkillDetailView-BTuq1wJm.js +3 -0
  31. package/dist/assets/TechStackView-CQHW3en0.js +2 -0
  32. package/dist/assets/TerminalPanel-BWr1bOrP.js +1 -0
  33. package/dist/assets/{activity-Dt348P4m.js → activity-C-Y-_UKp.js} +1 -1
  34. package/dist/assets/{activity-CCW2-qSA.js → activity-CwnkusGI.js} +1 -1
  35. package/dist/assets/{activity-CXLMCm4J.js → activity-D4XDbREq.js} +1 -1
  36. package/dist/assets/{activity-CmzV075e.js → activity-DSr_k7lf.js} +1 -1
  37. package/dist/assets/{activity-D2D6_ljD.js → activity-IxF62i-n.js} +1 -1
  38. package/dist/assets/{activity-FxWZooaS.js → activity-NKeG9bGy.js} +1 -1
  39. package/dist/assets/{activity-87Kr1xrI.js → activity-sgjix1RN.js} +1 -1
  40. package/dist/assets/{button-rqi3MczV.js → button-BIFXNDDY.js} +1 -1
  41. package/dist/assets/{css.worker-DRH2OcAG.js → css.worker-NNelxtRr.js} +6 -6
  42. package/dist/assets/{dialog-xJxaQi60.js → dialog-DT8I6gze.js} +1 -1
  43. package/dist/assets/{empty-state-BxilAuC3.js → empty-state-DtseAzny.js} +1 -1
  44. package/dist/assets/{html.worker-DQLddT9h.js → html.worker-B4rXkk6r.js} +6 -6
  45. package/dist/assets/i18n-Dq2jJcme.js +2 -0
  46. package/dist/assets/index-CbwgQF8l.js +176 -0
  47. package/dist/assets/index-Cg_zbV9k.css +1 -0
  48. package/dist/assets/{input-ClZR-odw.js → input-DE1O73TJ.js} +1 -1
  49. package/dist/assets/{json.worker-D_Dqrls5.js → json.worker-izi4BK3w.js} +4 -4
  50. package/dist/assets/{markdown-BP6Z3HKc.js → markdown-BzXmcdZg.js} +15 -15
  51. package/dist/assets/{monaco-_kWjHrlo.js → monaco-LhToOuuW.js} +59 -59
  52. package/dist/assets/{monaco-theme-Dmx6JuoU.js → monaco-theme-BOzs6u2L.js} +1 -1
  53. package/dist/assets/{react-core-BNmTiJ-I.js → react-core-D0Ec-185.js} +1 -1
  54. package/dist/assets/{roster-ws-n_N7K9tX.js → roster-ws--cUKX8Eo.js} +1 -1
  55. package/dist/assets/{shared-D8dubdNH.js → shared-k2sZgl6A.js} +1 -1
  56. package/dist/assets/{ts.worker-DkYoA6bF.js → ts.worker-Dj4vg72D.js} +114 -114
  57. package/dist/assets/{ui-store-CLXDcLPI.js → ui-store-BPQ-dcnY.js} +1 -1
  58. package/dist/assets/{utils-BpBOwXlT.js → utils-CmY0Pw1m.js} +1 -1
  59. package/dist/assets/{vector-memory-panel-BwPPCCbh.js → vector-memory-panel-UsWhpyqi.js} +1 -1
  60. package/dist/assets/vendor-DcnGbJ82.js +125 -0
  61. package/dist/assets/ws-client-DitX7fid.js +22 -0
  62. package/dist/assets/xterm-DA3G7037.js +16 -0
  63. package/dist/assets/xyflow-BlkaZTzI.js +7 -0
  64. package/dist/components/CodeMapVisuals.d.ts +10 -0
  65. package/dist/components/CustomRosterPanel.d.ts +1 -0
  66. package/dist/components/QuotaChip.d.ts +21 -0
  67. package/dist/components/SettingsPanel/OAuthLoginSection.d.ts +4 -5
  68. package/dist/components/codemap-model.d.ts +21 -1
  69. package/dist/hooks/ws-handlers/session-execution-handlers.d.ts +8 -0
  70. package/dist/hooks/ws-handlers/session-handlers.d.ts +1 -1
  71. package/dist/index.html +13 -22
  72. package/dist/index.js +2127 -1665
  73. package/dist/lib/bug-hunt-message.d.ts +3 -0
  74. package/dist/lib/ws-client-domain-methods.d.ts +14 -3
  75. package/dist/stores/bug-hunt-run-store.d.ts +44 -0
  76. package/dist/stores/index.d.ts +3 -0
  77. package/dist/stores/provider-quota-store.d.ts +69 -0
  78. package/dist/stores/types.d.ts +1 -0
  79. package/dist/types/client-message.d.ts +4 -0
  80. package/dist/types/protocol-core.d.ts +13 -0
  81. package/dist/types/server-message.d.ts +4 -4
  82. package/dist/types/system.d.ts +18 -1
  83. package/package.json +9 -9
  84. package/dist/assets/AgentRosterView-B_J6SvVF.js +0 -12
  85. package/dist/assets/AnalyticsDashboard-BgZiiiDb.js +0 -1
  86. package/dist/assets/AudienceMemoryPanel-CPuksIMN.js +0 -3
  87. package/dist/assets/ChangesView-CmZeNwbw.js +0 -1
  88. package/dist/assets/ChronicleDashboard-B6lhZGjz.js +0 -1
  89. package/dist/assets/CodeEditor-Daz1yqjF.js +0 -2
  90. package/dist/assets/CodeMap-D-H9FNUJ.js +0 -1
  91. package/dist/assets/ConfirmModal-CjsZbvo3.js +0 -1
  92. package/dist/assets/CronJobsPanel-DGKW_zwc.js +0 -1
  93. package/dist/assets/DesignGalleryView-Da1QtI5b.js +0 -1
  94. package/dist/assets/KanbanView-_JvZKFyI.js +0 -3
  95. package/dist/assets/MailboxDetailView-26bVSSbU.js +0 -1
  96. package/dist/assets/MemoryManager-BqWzNt8w.js +0 -1
  97. package/dist/assets/ModelPicker-DqRzzv5J.js +0 -1
  98. package/dist/assets/ProcessMonitor-ygFLD5zk.js +0 -1
  99. package/dist/assets/QueuePanel-CJlIV0pX.js +0 -1
  100. package/dist/assets/RefreshDebugView-CNovrSAn.js +0 -1
  101. package/dist/assets/SageTabs-CJqOqiY7.js +0 -2
  102. package/dist/assets/SddHub-mFjsa_Zl.js +0 -2
  103. package/dist/assets/SessionInspectView-MEmxIEzB.js +0 -1
  104. package/dist/assets/SessionList-DmcQJmzw.js +0 -1
  105. package/dist/assets/SessionsDashboard-BCYViJlx.js +0 -1
  106. package/dist/assets/SetupScreen-BwnSJt7v.js +0 -1
  107. package/dist/assets/SkillDetailView-ebz2dRUQ.js +0 -3
  108. package/dist/assets/TechStackView-DESDpUDA.js +0 -2
  109. package/dist/assets/TerminalPanel-BiWnldbB.js +0 -1
  110. package/dist/assets/chat-store-BcfvHUUj.js +0 -1
  111. package/dist/assets/codemap-activity-store-CWi-Yd9Z.js +0 -1
  112. package/dist/assets/codemap-index-store-3M7F08K_.js +0 -1
  113. package/dist/assets/i18n-DBqM1FUM.js +0 -2
  114. package/dist/assets/index-CWYymMpa.css +0 -1
  115. package/dist/assets/index-TDhvFXb0.js +0 -144
  116. package/dist/assets/mailbox-store-yydAVjyj.js +0 -1
  117. package/dist/assets/stores-Cfei1ViB.js +0 -7
  118. package/dist/assets/useWebSocket-AYEcpb1U.js +0 -27
  119. package/dist/assets/vendor-BshlG0z-.js +0 -125
  120. package/dist/assets/view-navigation-CvWJeGMc.js +0 -1
  121. package/dist/assets/ws-client-C_IqS0t4.js +0 -22
  122. package/dist/assets/xterm-BWzBEEhg.js +0 -18
  123. package/dist/assets/xyflow-BNn76cbK.js +0 -7
  124. /package/dist/assets/{settings-D9AQ5wLT2.js → settings-D9AQ5wLT.js} +0 -0
@@ -1,7 +1,10 @@
1
1
  export interface BugHuntSummary {
2
2
  scope: string;
3
3
  maxBugs: 1 | 2 | 3;
4
+ currentRound: number;
4
5
  }
6
+ /** The compact user turn for rounds after the full builtin prompt. */
7
+ export declare function buildBugHuntContinuation(summary: BugHuntSummary): string;
5
8
  /** Adds durable display metadata without changing the instruction sent to the agent. */
6
9
  export declare function buildBugHuntMessage(instruction: string, summary: BugHuntSummary): string;
7
10
  /** Recognizes a persisted Bug Hunter run and recovers its compact display data. */
@@ -16,6 +16,16 @@ declare const domainMethods: {
16
16
  unstageGit(this: WsClientDomainHost, paths: string | string[]): void;
17
17
  discardGit(this: WsClientDomainHost, paths: string | string[]): void;
18
18
  commitGit(this: WsClientDomainHost, message: string): void;
19
+ /**
20
+ * Ask for the current plan-quota readings.
21
+ *
22
+ * Sent once per connection. Quota is pushed as it changes, so a tab that was
23
+ * open all along needs nothing — but one that connects mid-session has missed
24
+ * every push, and the server will not re-fetch from the provider (that costs
25
+ * a request against the very budget being checked). This replays what the
26
+ * server already holds.
27
+ */
28
+ getProviderQuota(this: WsClientDomainHost): void;
19
29
  getProviderStatus(this: WsClientDomainHost): void;
20
30
  getProviderAuditHistory(this: WsClientDomainHost, count?: number | undefined): void;
21
31
  retryProviderModel(this: WsClientDomainHost, providerId: string, model: string): void;
@@ -58,9 +68,10 @@ declare const domainMethods: {
58
68
  setActiveKey(this: WsClientDomainHost, providerId: string, label: string): void;
59
69
  addProvider(this: WsClientDomainHost, id: string, family: string, baseUrl?: string | undefined, apiKey?: string, models?: string[] | undefined, customModels?: Record<string, ProviderCustomModelWire> | undefined): void;
60
70
  removeProvider(this: WsClientDomainHost, providerId: string): void;
61
- startOAuth(this: WsClientDomainHost, kind: 'chatgpt' | 'claude' | 'copilot', providerId?: string): void;
62
- submitOAuthCode(this: WsClientDomainHost, kind: 'chatgpt' | 'claude' | 'copilot', input: string): void;
63
- cancelOAuth(this: WsClientDomainHost, kind: 'chatgpt' | 'claude' | 'copilot'): void;
71
+ listOAuthProviders(this: WsClientDomainHost): void;
72
+ startOAuth(this: WsClientDomainHost, kind: string, providerId?: string): void;
73
+ submitOAuthCode(this: WsClientDomainHost, kind: string, input: string): void;
74
+ cancelOAuth(this: WsClientDomainHost, kind: string): void;
64
75
  probeProvider(this: WsClientDomainHost, providerId: string, timeoutMs?: number): void;
65
76
  clearProviderModels(this: WsClientDomainHost, providerId: string): void;
66
77
  undoProviderClear(this: WsClientDomainHost, providerId: string, previousModels: string[]): void;
@@ -0,0 +1,44 @@
1
+ export interface BugHuntRun {
2
+ scope: string;
3
+ totalRounds: 1 | 2 | 3;
4
+ /** The round currently running, or most recently completed when inactive. */
5
+ currentRound: number;
6
+ /** `null` after recovery; the next completion then claims the resumed run. */
7
+ requestId: string | null;
8
+ }
9
+ interface BugHuntRunState {
10
+ runs: Record<string, BugHuntRun>;
11
+ start(sessionId: string, run: BugHuntRun): void;
12
+ /** Whether a result with a request id belongs to the active round. */
13
+ ownsRequest(sessionId: string, requestId?: string): boolean;
14
+ /** Claim one completed round and reserve the next send against duplicate results. */
15
+ advance(sessionId: string, requestId?: string): BugHuntRun | null;
16
+ setRequestId(sessionId: string, requestId: string): void;
17
+ stop(sessionId: string, requestId?: string): void;
18
+ recover(sessionId: string, run: Omit<BugHuntRun, 'requestId'>): void;
19
+ clear(sessionId: string): void;
20
+ }
21
+ /**
22
+ * Session-keyed state for WebUI's one-bug-per-turn hunt loop. Persistence lets
23
+ * a refreshed page recover the active budget; every submitted round also
24
+ * carries durable chat-journal metadata for session replay.
25
+ */
26
+ export declare const useBugHuntRunStore: import("zustand").UseBoundStore<Omit<import("zustand").StoreApi<BugHuntRunState>, "persist" | "setState"> & {
27
+ setState(partial: BugHuntRunState | Partial<BugHuntRunState> | ((state: BugHuntRunState) => BugHuntRunState | Partial<BugHuntRunState>), replace?: false | undefined): unknown;
28
+ setState(state: BugHuntRunState | ((state: BugHuntRunState) => BugHuntRunState), replace: true): unknown;
29
+ persist: {
30
+ setOptions: (options: Partial<import("zustand/middleware").PersistOptions<BugHuntRunState, {
31
+ runs: Record<string, BugHuntRun>;
32
+ }, unknown>>) => void;
33
+ clearStorage: () => void;
34
+ rehydrate: () => Promise<void> | void;
35
+ hasHydrated: () => boolean;
36
+ onHydrate: (fn: (state: BugHuntRunState) => void) => () => void;
37
+ onFinishHydration: (fn: (state: BugHuntRunState) => void) => () => void;
38
+ getOptions: () => Partial<import("zustand/middleware").PersistOptions<BugHuntRunState, {
39
+ runs: Record<string, BugHuntRun>;
40
+ }, unknown>>;
41
+ };
42
+ }>;
43
+ export {};
44
+ //# sourceMappingURL=bug-hunt-run-store.d.ts.map
@@ -1,3 +1,5 @@
1
+ export type { BugHuntRun } from './bug-hunt-run-store.js';
2
+ export { useBugHuntRunStore } from './bug-hunt-run-store.js';
1
3
  export { useChatStore } from './chat-store.js';
2
4
  export type { ChimeraReportNotice } from './chimera-reports-store.js';
3
5
  export { useChimeraReportsStore } from './chimera-reports-store.js';
@@ -36,6 +38,7 @@ export { useMonitorStore } from './monitor-store.js';
36
38
  export type { AppNotification, NotificationAction, NotificationStoreState, NotificationVariant, } from './notification-store.js';
37
39
  export { toast, useNotificationStore, useToastStore, } from './notification-store.js';
38
40
  export { type BackgroundStyle, DEFAULT_WAIT_THRESHOLD_MS, useOfficeMapStore, WAIT_THRESHOLD_PRESETS, } from './office-map-store.js';
41
+ export { formatQuotaResetIn, type QuotaCredits, type QuotaSnapshot, type QuotaWindow, quotaWindowLabel, selectWorstQuotaWindow, useProviderQuotaStore, } from './provider-quota-store.js';
39
42
  export { type ProviderAuditEntry, type ProviderHealthEntry, type ProviderHealthState, useProviderStatusStore, } from './provider-status-store.js';
40
43
  export { type SddBoardFeedEntry, type SddBoardSnapshotUI, type SddBoardStatus, type SddBoardSummary, type SddLifecycleResultUI, useSddBoardStore, } from './sdd-board-store.js';
41
44
  export { type SddWizardPhase, type SddWizardSnapshot, useSddWizardStore, } from './sdd-wizard-store.js';
@@ -0,0 +1,69 @@
1
+ /**
2
+ * Zustand store for subscription plan quota — the browser mirror of the
3
+ * server-side store in `@wrongstack/core/quota`.
4
+ *
5
+ * Metered providers (ChatGPT/Codex today, any plan-backed login next) report
6
+ * how much of their rolling budget is spent on the responses to requests the
7
+ * agent already makes. The server broadcasts every reading as `provider.quota`;
8
+ * a tab that connected mid-session asks once with `provider.quota.get`, because
9
+ * the reading is never re-fetched from the provider — asking a metered plan how
10
+ * much you have spent costs a request against the very budget you are checking.
11
+ *
12
+ * Deliberately global rather than per-session: a plan belongs to the account,
13
+ * not to a conversation. Every tab shows the same numbers, and a reading that
14
+ * arrived while another tab was in the foreground stays valid here.
15
+ *
16
+ * The shape mirrors `ProviderQuotaSnapshot` exactly. It is redeclared rather
17
+ * than imported: this bundle is browser-only and pulling a Node-side entry in
18
+ * for four field names is how `node:fs` ends up in the Vite graph.
19
+ */
20
+ export interface QuotaWindow {
21
+ id: string;
22
+ label?: string | undefined;
23
+ usedPercent: number;
24
+ windowMinutes?: number | undefined;
25
+ /** Absolute reset time in epoch **seconds**. */
26
+ resetsAt?: number | undefined;
27
+ }
28
+ export interface QuotaCredits {
29
+ hasCredits: boolean;
30
+ unlimited: boolean;
31
+ balance?: string | undefined;
32
+ }
33
+ export interface QuotaSnapshot {
34
+ providerId: string;
35
+ meterId: string;
36
+ meterLabel?: string | undefined;
37
+ planLabel?: string | undefined;
38
+ windows: QuotaWindow[];
39
+ credits?: QuotaCredits | undefined;
40
+ reachedWindowId?: string | undefined;
41
+ note?: string | undefined;
42
+ capturedAt: number;
43
+ }
44
+ interface ProviderQuotaState {
45
+ /** Every known meter, keyed `providerId\0meterId`. */
46
+ meters: Record<string, QuotaSnapshot>;
47
+ /** Merge readings for one provider (a `provider.quota` push). */
48
+ apply: (snapshots: readonly QuotaSnapshot[]) => void;
49
+ clear: () => void;
50
+ }
51
+ export declare const useProviderQuotaStore: import("zustand").UseBoundStore<import("zustand").StoreApi<ProviderQuotaState>>;
52
+ /**
53
+ * The window a one-line surface should show: the most-consumed one across every
54
+ * provider and meter, ties broken toward the sooner reset.
55
+ *
56
+ * Same rule as the TUI chip. A status bar has room for one number, and the one
57
+ * that matters is the one nearest to cutting the user off — not the first
58
+ * provider to report.
59
+ */
60
+ export declare function selectWorstQuotaWindow(meters: Record<string, QuotaSnapshot>): {
61
+ snapshot: QuotaSnapshot;
62
+ window: QuotaWindow;
63
+ } | undefined;
64
+ /** `5h` / `7d` / the window's own label / its id. */
65
+ export declare function quotaWindowLabel(window: QuotaWindow): string;
66
+ /** Compact `4h 12m` / `38m` / `45s` countdown, or undefined when unknown/past. */
67
+ export declare function formatQuotaResetIn(window: QuotaWindow | undefined, now?: number): string | undefined;
68
+ export {};
69
+ //# sourceMappingURL=provider-quota-store.d.ts.map
@@ -56,6 +56,7 @@ export interface ChatMessage {
56
56
  bugHunt?: {
57
57
  scope: string;
58
58
  maxBugs: 1 | 2 | 3;
59
+ currentRound: number;
59
60
  } | undefined;
60
61
  /** The same treatment for a built-in performance ratchet round: the full
61
62
  * prompt goes to the agent, the transcript shows the mode, scope, and the
@@ -620,6 +620,8 @@ export type WSClientMessageCore = WSUserMessage | {
620
620
  providerId: string;
621
621
  timeoutMs?: number | undefined;
622
622
  };
623
+ } | {
624
+ type: 'auth.oauth.list';
623
625
  } | {
624
626
  type: 'auth.oauth.start';
625
627
  payload: {
@@ -637,6 +639,8 @@ export type WSClientMessageCore = WSUserMessage | {
637
639
  payload: {
638
640
  kind: OAuthKind;
639
641
  };
642
+ } | {
643
+ type: 'provider.quota.get';
640
644
  } | {
641
645
  type: 'provider.status.get';
642
646
  } | {
@@ -285,6 +285,19 @@ export interface WSProviderStatusChanged {
285
285
  lastAgentId?: string | null | undefined;
286
286
  };
287
287
  }
288
+ /**
289
+ * `provider.quota` — subscription plan readings, pushed on every metered
290
+ * response and replayed on `provider.quota.get`. `providerId` is present on a
291
+ * push (it names the provider that just reported) and absent on a replay,
292
+ * which carries every provider at once.
293
+ */
294
+ export interface WSProviderQuota {
295
+ type: 'provider.quota';
296
+ payload: {
297
+ providerId?: string | undefined;
298
+ snapshots: unknown[];
299
+ };
300
+ }
288
301
  export interface WSProviderStatusSnapshot {
289
302
  type: 'provider.status.snapshot';
290
303
  payload: Record<string, unknown>;
@@ -2,7 +2,7 @@ import type { ChronicleFacet, ChronicleFacetValue, ChronicleGraphResult, Chronic
2
2
  import type { WSCollabAnnotationAdded, WSCollabAnnotationResolved, WSCollabEvent, WSCollabInjectionGranted, WSCollabParticipantJoined, WSCollabParticipantLeft, WSCollabPauseGranted, WSCollabPauseReleased, WSCollabState } from './collab.js';
3
3
  import type { AutoHealStatusEvent, ConnectionsHealthReport, ServiceActionResult } from './connections.js';
4
4
  import type { WSAgentStatusChanged, WSAgentTimelineMessage, WSEternalIteration, WSGoalAssessResult, WSGoalLifecycle, WSGoalList, WSGoalProgress, WSGoalState, WSKanbanResult, WSKanbanTaskActivity, WSModesList, WSWorktreeCleanupResult, WSWorktreeDiffResult, WSWorktreeEvent, WSWorktreeMergeResult, WSWorktreeOrphans, WSWorktreeState } from './goal-kanban-worktree.js';
5
- import type { WSCodeMapToolExecuted, WSCodeMapToolStarted, WSIterationCompleted, WSIterationLimitReached, WSIterationStarted, WSProviderActiveBlocked, WSProviderAuditHistory, WSProviderError, WSProviderFallback, WSProviderFallbackPending, WSProviderResponse, WSProviderRetry, WSProviderStatusChanged, WSProviderStatusSnapshot, WSProviderStreamError, WSRunResult, WSSessionEnd, WSSessionResumeProgress, WSSessionRunState, WSSessionStart, WSTextDelta, WSThinkingDelta, WSToolExecuted, WSToolProgress, WSToolUseStart } from './protocol-core.js';
5
+ import type { WSCodeMapToolExecuted, WSCodeMapToolStarted, WSIterationCompleted, WSIterationLimitReached, WSIterationStarted, WSProviderActiveBlocked, WSProviderAuditHistory, WSProviderError, WSProviderFallback, WSProviderFallbackPending, WSProviderQuota, WSProviderResponse, WSProviderRetry, WSProviderStatusChanged, WSProviderStatusSnapshot, WSProviderStreamError, WSRunResult, WSSessionEnd, WSSessionResumeProgress, WSSessionRunState, WSSessionStart, WSTextDelta, WSThinkingDelta, WSToolExecuted, WSToolProgress, WSToolUseStart } from './protocol-core.js';
6
6
  import type { WSCompactionFailed, WSContextCompacted, WSContextDebug, WSContextEditorApplied, WSContextEditorSnapshot, WSContextEditorValidation, WSContextMaxContext, WSContextModeChanged, WSContextModesList, WSContextPct, WSContextRepaired, WSDelegateCompleted, WSDelegateStarted, WSError, WSMemoryList, WSSessionStats, WSTokenCostEstimateUnavailable, WSTokenThreshold, WSToolConfirmNeeded, WSToolLoopDetected, WSToolsList, WSTopicAdviceResult, WSTrustPersisted } from './runtime.js';
7
7
  import type { WSMemorySageBackfillRecoverable, WSMemorySageCandidateResolve, WSMemorySageDelete, WSMemorySageForFile, WSMemorySageGet, WSMemorySageGraph, WSMemorySageList, WSMemorySageListCandidates, WSMemorySageListPage, WSMemorySageRecover, WSMemorySageRemember, WSMemorySageSearchBreakdown, WSMemorySageUpdate } from './sage.js';
8
8
  import type { WSChimeraServerMessage } from './server-message-chimera.js';
@@ -11,8 +11,8 @@ import type { WSFleetServerMessage } from './server-message-fleet.js';
11
11
  import type { WSMcpServerMessage } from './server-message-mcp.js';
12
12
  import type { WSSystemMiscServerMessage } from './server-message-system.js';
13
13
  import type { WSDesignList, WSDesignMaterialize, WSDesignSet, WSDesignState, WSDesignSwap, WSDesignTune, WSDesignUse, WSDesignVerify, WSSkillContent, WSSkillsCreated, WSSkillsEdited, WSSkillsExported, WSSkillsInstalled, WSSkillsList, WSSkillsUninstalled, WSSkillsUpdated } from './skills-design.js';
14
- import type { WSAuthOAuthStatus, WSCatalogModelSearchResult, WSCompletionResult, WSDiagGet, WSFilesList, WSKeyOperationResult, WSModelSwitchResult, WSProviderCatalog, WSProviderModels, WSProviderProbe, WSSavedProviders, WSSessionInspect, WSSessionsList, WSSideEffects, WSStatsGet, WSTodosCleared, WSTodosUpdated } from './system.js';
15
- export type WSServerMessage = WSSessionStart | WSSessionEnd | WSTextDelta | WSThinkingDelta | WSToolUseStart | WSToolProgress | WSToolExecuted | WSCodeMapToolStarted | WSCodeMapToolExecuted | WSIterationStarted | WSIterationCompleted | WSIterationLimitReached | WSProviderResponse | WSProviderRetry | WSProviderAuditHistory | WSProviderError | WSProviderFallback | WSProviderFallbackPending | WSProviderStatusChanged | WSProviderStatusSnapshot | WSProviderActiveBlocked | WSProviderStreamError | WSRunResult | WSSessionRunState | WSSessionResumeProgress | WSSessionStats | WSError | WSToolConfirmNeeded | WSTrustPersisted | WSToolLoopDetected | WSDelegateStarted | WSDelegateCompleted | WSContextDebug | WSContextCompacted | WSCompactionFailed | WSContextRepaired | WSContextEditorSnapshot | WSContextEditorValidation | WSContextEditorApplied | WSContextPct | WSTopicAdviceResult | WSContextMaxContext | WSTokenThreshold | WSTokenCostEstimateUnavailable | WSContextModesList | WSContextModeChanged | WSToolsList | WSMemoryList | WSMemorySageList | WSMemorySageListPage | WSMemorySageListCandidates | WSMemorySageGet | WSMemorySageGraph | WSMemorySageSearchBreakdown | WSMemorySageUpdate | WSMemorySageRemember | WSMemorySageDelete | WSMemorySageRecover | WSMemorySageCandidateResolve | WSMemorySageBackfillRecoverable | WSMemorySageForFile | WSSkillsList | WSSkillContent | WSDesignList | WSDesignUse | WSDesignState | WSDesignSet | WSDesignTune | WSDesignSwap | WSDesignMaterialize | WSDesignVerify | WSSkillsInstalled | WSSkillsUninstalled | WSSkillsUpdated | WSSkillsCreated | WSSkillsEdited | WSSkillsExported | WSDiagGet | WSStatsGet | {
14
+ import type { WSAuthOAuthProviders, WSAuthOAuthStatus, WSCatalogModelSearchResult, WSCompletionResult, WSDiagGet, WSFilesList, WSKeyOperationResult, WSModelSwitchResult, WSProviderCatalog, WSProviderModels, WSProviderProbe, WSSavedProviders, WSSessionInspect, WSSessionsList, WSSideEffects, WSStatsGet, WSTodosCleared, WSTodosUpdated } from './system.js';
15
+ export type WSServerMessage = WSSessionStart | WSSessionEnd | WSTextDelta | WSThinkingDelta | WSToolUseStart | WSToolProgress | WSToolExecuted | WSCodeMapToolStarted | WSCodeMapToolExecuted | WSIterationStarted | WSIterationCompleted | WSIterationLimitReached | WSProviderResponse | WSProviderRetry | WSProviderAuditHistory | WSProviderError | WSProviderFallback | WSProviderFallbackPending | WSProviderStatusChanged | WSProviderQuota | WSProviderStatusSnapshot | WSProviderActiveBlocked | WSProviderStreamError | WSRunResult | WSSessionRunState | WSSessionResumeProgress | WSSessionStats | WSError | WSToolConfirmNeeded | WSTrustPersisted | WSToolLoopDetected | WSDelegateStarted | WSDelegateCompleted | WSContextDebug | WSContextCompacted | WSCompactionFailed | WSContextRepaired | WSContextEditorSnapshot | WSContextEditorValidation | WSContextEditorApplied | WSContextPct | WSTopicAdviceResult | WSContextMaxContext | WSTokenThreshold | WSTokenCostEstimateUnavailable | WSContextModesList | WSContextModeChanged | WSToolsList | WSMemoryList | WSMemorySageList | WSMemorySageListPage | WSMemorySageListCandidates | WSMemorySageGet | WSMemorySageGraph | WSMemorySageSearchBreakdown | WSMemorySageUpdate | WSMemorySageRemember | WSMemorySageDelete | WSMemorySageRecover | WSMemorySageCandidateResolve | WSMemorySageBackfillRecoverable | WSMemorySageForFile | WSSkillsList | WSSkillContent | WSDesignList | WSDesignUse | WSDesignState | WSDesignSet | WSDesignTune | WSDesignSwap | WSDesignMaterialize | WSDesignVerify | WSSkillsInstalled | WSSkillsUninstalled | WSSkillsUpdated | WSSkillsCreated | WSSkillsEdited | WSSkillsExported | WSDiagGet | WSStatsGet | {
16
16
  type: 'connections.health_result';
17
17
  payload: ConnectionsHealthReport;
18
18
  } | {
@@ -62,7 +62,7 @@ export type WSServerMessage = WSSessionStart | WSSessionEnd | WSTextDelta | WSTh
62
62
  payload: {
63
63
  message: string;
64
64
  };
65
- } | WSSessionsList | WSSessionInspect | WSProviderCatalog | WSCatalogModelSearchResult | WSProviderModels | WSSavedProviders | WSProviderProbe | WSKeyOperationResult | WSModelSwitchResult | WSAuthOAuthStatus | WSFilesList | WSFilesGitServerMessage | WSCompletionResult | WSTodosUpdated | WSTodosCleared | WSModesList | WSGoalState | WSGoalProgress | WSGoalLifecycle | WSGoalList | WSGoalAssessResult | WSEternalIteration | WSAgentTimelineMessage | WSAgentStatusChanged | WSKanbanResult | WSKanbanTaskActivity | WSWorktreeState | WSWorktreeEvent | WSWorktreeOrphans | WSWorktreeCleanupResult | WSWorktreeMergeResult | WSWorktreeDiffResult | WSCollabState | WSCollabParticipantJoined | WSCollabParticipantLeft | WSCollabEvent | WSCollabAnnotationAdded | WSCollabAnnotationResolved | WSCollabPauseGranted | WSCollabPauseReleased | WSCollabInjectionGranted | WSSideEffects | WSMcpServerMessage | WSChimeraServerMessage | WSFleetServerMessage | WSSystemMiscServerMessage;
65
+ } | WSSessionsList | WSSessionInspect | WSProviderCatalog | WSCatalogModelSearchResult | WSProviderModels | WSSavedProviders | WSProviderProbe | WSKeyOperationResult | WSModelSwitchResult | WSAuthOAuthStatus | WSAuthOAuthProviders | WSFilesList | WSFilesGitServerMessage | WSCompletionResult | WSTodosUpdated | WSTodosCleared | WSModesList | WSGoalState | WSGoalProgress | WSGoalLifecycle | WSGoalList | WSGoalAssessResult | WSEternalIteration | WSAgentTimelineMessage | WSAgentStatusChanged | WSKanbanResult | WSKanbanTaskActivity | WSWorktreeState | WSWorktreeEvent | WSWorktreeOrphans | WSWorktreeCleanupResult | WSWorktreeMergeResult | WSWorktreeDiffResult | WSCollabState | WSCollabParticipantJoined | WSCollabParticipantLeft | WSCollabEvent | WSCollabAnnotationAdded | WSCollabAnnotationResolved | WSCollabPauseGranted | WSCollabPauseReleased | WSCollabInjectionGranted | WSSideEffects | WSMcpServerMessage | WSChimeraServerMessage | WSFleetServerMessage | WSSystemMiscServerMessage;
66
66
  export type { WSChimeraServerMessage } from './server-message-chimera.js';
67
67
  export type { WSFilesGitServerMessage } from './server-message-files.js';
68
68
  export type { WSFleetServerMessage } from './server-message-fleet.js';
@@ -1,3 +1,4 @@
1
+ import type { ModelProvenance } from '@wrongstack/core/types';
1
2
  import type { SessionScopedPayload } from './protocol-core.js';
2
3
  export interface WSDiagGet {
3
4
  type: 'diag.get';
@@ -163,6 +164,7 @@ export interface ProviderCatalogModelMatch {
163
164
  maxOutput?: number | undefined;
164
165
  inputCost?: number | undefined;
165
166
  outputCost?: number | undefined;
167
+ provenance?: ModelProvenance | undefined;
166
168
  capabilities: string[];
167
169
  }
168
170
  export interface WSCatalogModelSearchResult {
@@ -184,6 +186,7 @@ export interface WSProviderModels {
184
186
  contextWindow?: number | undefined;
185
187
  inputCost?: number | undefined;
186
188
  outputCost?: number | undefined;
189
+ provenance?: ModelProvenance | undefined;
187
190
  capabilities: string[];
188
191
  }>;
189
192
  };
@@ -284,7 +287,21 @@ export interface WSModelSwitchResult {
284
287
  };
285
288
  }
286
289
  /** Which subscription OAuth login a flow is running. */
287
- export type OAuthKind = 'chatgpt' | 'claude' | 'copilot';
290
+ export type OAuthKind = string;
291
+ export interface OAuthProviderMetadata {
292
+ id: string;
293
+ providerId: string;
294
+ label: string;
295
+ description?: string | undefined;
296
+ aliases?: readonly string[] | undefined;
297
+ interactionTypes: readonly ('browser' | 'device_code')[];
298
+ }
299
+ export interface WSAuthOAuthProviders {
300
+ type: 'auth.oauth.providers';
301
+ payload: {
302
+ providers: OAuthProviderMetadata[];
303
+ };
304
+ }
288
305
  /**
289
306
  * Progress for an in-flight subscription OAuth login, broadcast in reply to
290
307
  * `auth.oauth.start` / `auth.oauth.code`. `phase` drives the UI:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wrongstack/webui",
3
- "version": "1.0.0",
3
+ "version": "1.0.3",
4
4
  "license": "MIT",
5
5
  "description": "Browser-based WebUI for WrongStack — React + Vite frontend. The WebSocket backend lives in the separate @wrongstack/webui-server package (extracted in PR #018b to remove the CLI -> @wrongstack/webui/server cross-package edge).",
6
6
  "keywords": [
@@ -57,12 +57,12 @@
57
57
  "@radix-ui/react-tabs": "^1.1.21",
58
58
  "@tanstack/react-virtual": "^3.14.10",
59
59
  "@uiw/react-textarea-code-editor": "^3.1.1",
60
- "@wrongstack/core": "1.0.0",
61
- "@wrongstack/kanban": "1.0.0",
62
- "@wrongstack/plugins": "1.0.0",
63
- "@wrongstack/providers": "1.0.0",
64
- "@wrongstack/tools": "1.0.0",
65
- "@wrongstack/webui-protocol": "1.0.0",
60
+ "@wrongstack/core": "1.0.3",
61
+ "@wrongstack/kanban": "1.0.3",
62
+ "@wrongstack/plugins": "1.0.3",
63
+ "@wrongstack/providers": "1.0.3",
64
+ "@wrongstack/tools": "1.0.3",
65
+ "@wrongstack/webui-protocol": "1.0.3",
66
66
  "@xterm/addon-fit": "^0.11.0",
67
67
  "@xterm/xterm": "^6.0.0",
68
68
  "@xyflow/react": "^12.11.3",
@@ -98,8 +98,8 @@
98
98
  "@types/ws": "^8.18.1",
99
99
  "@vitejs/plugin-react": "^6.1.0",
100
100
  "@vitest/coverage-v8": "^4.1.11",
101
- "@wrongstack/sdd": "1.0.0",
102
- "@wrongstack/webui-server": "1.0.0",
101
+ "@wrongstack/sdd": "1.0.3",
102
+ "@wrongstack/webui-server": "1.0.3",
103
103
  "jsdom": "^30.0.1",
104
104
  "tailwindcss": "^4.3.3",
105
105
  "typescript": "^7.0.2",