← Model losses

Head-to-head comparison

openai / gpt-6.1-sol / low / low effort preferred over xai / grok-4.7-efficient / xhigh / xhigh effort · close win.

Primary judge: Sol 6.1, requested Low. Effective provider effort and internal attempts were not verified. A close win is still a scored preference; it does not establish a material defect.

Reviewed public evidence

Task goal

MVP source audit; taskCategory=ux; module category=ux, difficulty=high, expectedTests=none. Workspace navigation, role-aware shell and layout state across the shell and its focused navigation tests. Source review only; no tests run. Use only exact supplied files and cite file plus original line. Do not run tests, use shell/globs/root traversal, live services, databases, customer data, or edit source. Report concrete source-proven issues with impact and confidence, otherwise state no findings. Identify every excluded boundary explicitly; do not infer production readiness. This source-only audit packet is bound to verified merged main commit 9dab4e99d3bfadf995dbaa031b9b6a365970e1e3; it does not verify runtime or production behavior.

openai / gpt-6.1-sol / low / low effort answer

## Conclusion

**Three source-proven issues found.** Independently reviewed all 20 supplied files directly; no tools, tests, edits, or external actions. Findings apply only to snapshot `9dab4e99d3bfadf995dbaa031b9b6a365970e1e3`.

### 1. Legacy workspace hamburger does not control its sidebar below 1280px
**Severity: Medium · Confidence: 0.99**

- `[REDACTED: private project name]/frontend/src/components/layout/TopBar.tsx:23–30` makes the hamburger toggle `sidebarDrawerOpen`, rather than `sidebarCollapsed`, below 1280px.
- The legacy branch in `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:368–689` renders no drawer; its sidebar width depends exclusively on `sidebarCollapsed` at lines 384–390.

**Impact:** With the explicitly supported V3 rollback active, mobile/tablet users can click “Open menu” without changing navigation visibility. The expanded 240px sidebar remains beside the content.

**Recommendation:** Connect the legacy workspace branch to a drawer, or retain a sidebar-collapse handler appropriate to that branch.

### 2. V3 Standard navigation advertises server-excluded modules
**Severity: Medium · Confidence: 0.99**

- `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:333–343` constructs navigation from the entire fixed registry without consulting `workspace.modules`.
- `[REDACTED: private project name]/frontend/src/lib/navRegistry.ts:184–189` includes `municipal.explorer` and `municipal.reports-amp`.
- `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:200–214` rejects an absent server-backed module and redirects to `default_landing`.
- Neither of those two keys is client-only: `[REDACTED: private project name]/frontend/src/lib/workspaceModules.ts:215–230`.

**Impact:** A workspace that omits either module still displays its navigation destination. Clicking it silently sends users elsewhere, rather than opening the advertised destination. Fixed municipal navigation also fails to reflect the active workspace’s actual module configuration.

**Recommendation:** Derive Standard items from available server modules plus explicitly allowed client-only destinations.

### 3. Focused navigation tests do not enforce the current implementation contract
**Severity: Medium · Confidence: 0.99**

Two concrete discrepancies:

- `[REDACTED: private project name]/frontend/src/__tests__/WorkspaceShell.multinav.test.tsx:189–211` tests an inline replacement handler that invalidates immediately and uses `['userWorkspace']`. Actual code waits for PATCH success and uses the centralized key: `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:245–276`; `[REDACTED: private project name]/frontend/src/api/queryKeys.ts:662–664`. The test neither imports nor invokes that implementation.
- `[REDACTED: private project name]/frontend/tests/app-layout/v3-shell-smoke.spec.ts:209–243` requires `/inspections` and `/repairs` to remain unredirected. Those keys are intentionally excluded from the routing allowlist in `[REDACTED: private project name]/frontend/src/lib/workspaceModules.ts:225–229`, so the shell redirects them through lines 200–214.

**Impact:** The unit test cannot catch regressions in real switch sequencing, while two active smoke cases assert obsolete routing behavior.

**Recommendation:** Test shared production logic or the mounted shell; update smoke expectations to the current dormant-route contract.

## Calibration

- No backend authorization bypass is established. Client-only uploads are explicitly intentional; their underlying authorization is outside this packet.
- Role/backend parity is not verified: `PlatformWorkspacesPage.test.tsx:27–35` compares against a hardcoded frontend expectation, not supplied backend source.
- Pro smoke coverage is explicitly skipped at `v3-shell-smoke.spec.ts:138`. Its nonblank assertion at line 178 also accepts empty content; neither is evidence of runtime correctness.
- No production-readiness conclusion follows.

## Excluded boundaries

All source outside the exact 20-file packet is excluded, including these declared dependencies:

- **API:** `src/api/client.js`, `superAdmin.js`, `auth.js`, `dashboard.js`.
- **Auth/config:** `src/auth/AuthContext.js`, `src/config/features.js`.
- **Hooks:** `src/hooks/useMediaQuery.js`, `usePermissions.js`, `useCommandCenter.js`.
- **Libraries:** `src/lib/roleLabels.js`, `clientToServerMigration.js`, `useUserPreferencesQueue.js`.
- **Stores:** `src/store/useAIStore.js`, `useExplorerStore.js`, `useLayerStore.js`, `useMapRailUIStore.js`, `useMonitorUIStore.js`, `useProfileBankFilterStore.js`, `useViewUIStore.js`, `useWorkspaceProModeStore.js`; `src/stores/useV3SessionStore.js`.
- **Components:** `src/components/alerts/AlertDropdown.js`; `layout/OrgSwitcher.js`, `SurfaceSwitcher.js`, `OffboardingBanner.js`, `SidebarDrawer.js`, `TrustStrip.js`, `V3Sidebar.js`, `V3TopBar.js`; `assistant/AssistantBubble.js`, `assistantBubbleVisibility.js`; `chat/ChatPanel.js`; `common/ErrorBoundary.js`, `Toast.js`; `consultant/CommandCenter.js`; `media/ProcessingIndicator.js`; `v3-review/V3ProDevToggle.js`; `review-tabs/playbackSpeeds.js`.
- **Module bodies:** `src/components/workspace/modules/MunicipalExplorerModule.js`, `MunicipalReportsModule.js`, `MunicipalUploadsModule.js`, `V3InspectionsModule.js`, `V3RepairsModule.js`, `V3TodayModule.js`; `src/pages/v3/V3InspectionReview.js`.

Paths above are relative to `[REDACTED: private project name]/frontend/`. Backend resolver/schema/RBAC behavior, router integration, CSS, test configuration, runtime rendering, live services, databases, customer data, and deployment/production behavior remain unverified.

**Next useful action:** Correct the three source contracts, then separately authorize narrowly scoped verification.

MATERIAL_EVIDENCE_CONFLICT: `[REDACTED: private project name]/frontend/tests/app-layout/v3-shell-smoke.spec.ts:241–243` requires inspections/repairs deep links not to redirect, while `[REDACTED: private project name]/frontend/src/lib/workspaceModules.ts:225–229` explicitly disables those routes and `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:200–214` redirects them.

xai / grok-4.7-efficient / xhigh / xhigh effort answer

Source review only, bound to commit 9dab4e99d3bfadf995dbaa031b9b6a365970e1e3. No tests were run. This does not establish runtime or production readiness. Default shell is V3 (`useV3Shell` returns true with no override).

## 1. Findings

**1. Workspace URLs are not a selector. Back, shared links, and deep links to another accessible workspace are rewritten.** Confidence: 0.93.

`WorkspaceShell` never adopts `:workspaceKey`. Any mismatch with the server-resolved key `replace`-navigates to that key, including when the URL key is in `accessible_workspaces`:

```213:215:[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx
  if (workspace.key !== workspaceKey || resolvedModuleKey !== activeModuleKey) {
    return <Navigate to={`/w/${workspace.key}/${resolvedModuleKey}`} replace />
  }
```

Inaccessible keys toast (lines 179–188). Accessible-but-not-active keys do not (same condition; mirrored as intentional at `WorkspaceShell.multinav.test.tsx` 140–147). After a successful switch, Back lands on the previous `/w/:key/...` entry and is immediately `replace`d back. The target drops the splat tail and query string, so `/w/other/municipal.inspection-review/55?…` becomes `/w/${active}/${module}` only. Module links work only when the workspace key already matches. Applies to both shells. Comments treat non-active keys as “stale”; that still breaks multi-workspace history and shareable URLs.

**2. Default V3 standard nav is not role- or module-aware. Gated items fail silently.** Confidence: 0.86 on the handler; visibility depends on excluded `V3Sidebar.js`.

`WorkspaceShell` does not read role, `effective_capabilities`, or `workspace.modules` when building V3 nav. It always passes fixed `V3_STANDARD_NAV` (`navRegistry.ts` 180–190), including `municipal.reports-amp` and `municipal.explorer`. Click always navigates:

```340:343:[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx
    const onNavigateStandard = (navKey: string) => {
      const def = V3_STANDARD_NAV.find((d) => d.key === navKey)
      const moduleKey = def?.moduleKey ?? navKey
      navigate(`/w/${workspace.key}/${moduleKey}`)
```

The resolver then refuses keys absent from `workspace.modules` and not in `CLIENT_ONLY_MODULE_KEYS` (lines 200–214). The file’s own comment (198–199) says that allowlist exists to stop URL bypass of tier-gated `municipal.reports-amp`. There is no module-level toast (177–190 only checks workspace key), so a click is a silent `replace` to `default_landing`, and the highlight follows the fallback (`standardNavKeyForModule`, line 337). Legacy nav does project `workspace.modules` (294–300). V3 does not, so it can advertise omitted modules and cannot show a server module outside the four-item list. `municipal.uploads` is the opposite hole: it is client-only (`workspaceModules.ts` 215–221, 117–122), so Uploads stays routable with no per-module grant. That bypass is commented as intentional; it is still ungated in both shells (`getClientSidebarModules`, 253–261).

**3. View-as / impersonation banner can be wrong or unusable on a narrow viewport.** Confidence: 0.88 logic, 0.84 narrow-layout. Hits both shells (`ContextBanner` is mounted by `WorkspaceShell` 374 and `V3AppShell` 168).

Server “not view-as” does not suppress the legacy name. Fallback was described for missing `/auth/me` fields (`ContextBanner.tsx` 38–40) but runs whenever `isServerViewAs` is false:

```44:53:[REDACTED: private project name]/frontend/src/components/layout/ContextBanner.tsx
  const isServerViewAs =
    serverActiveId !== null && serverHomeId !== null && serverActiveId !== serverHomeId
  const legacyActiveOrgName = getActiveOrgName()
  const activeOrgName = (isServerViewAs ? serverViewAsName : null) ?? legacyActiveOrgName
  const isViewAs = !!activeOrgName
```

If IDs are present and equal and `getActiveOrgName()` is still set, the orange “ACTING AS …” banner shows. Exit always `navigate('/consultant')` (58–60) with no pending guard (unlike impersonation, 79–80). Inverse: ID mismatch with both names empty hides the banner. Whether `getActiveOrgName()` still returns a name is outside this packet (`client.js`).

Layout: view-as ribbon is `height: 40` with no wrap (165–173); impersonation ribbon is `height: 32` with no wrap (132–141); stacked state is `height: 32` plus `flex-wrap` (86–92). Long copy and Exit / End Impersonation can overflow a phone width. Stacked wrap overflows the fixed 32px flex item over the next chrome row. No breakpoint styles in this file. `WorkspaceShell` 373 calls this banner compliance-critical.

**4. Rollback shell (`?v3shell=0`, sticky via `useV3Shell.ts` 43–45) does not control or explain navigation.** Confidence: 0.9. Non-default path.

Below 1280px, `TopBar` only toggles `sidebarDrawerOpen` (23–27). Legacy `WorkspaceShell` sizes `<nav>` from `sidebarCollapsed` only (102, 384–391) and never reads `sidebarDrawerOpen` or mounts `SidebarDrawer`. Expanded width stays 240px (`useAppStore.ts` 24, default false, persisted 43–44). The hamburger does not dismiss workspace nav on that branch. The legacy tree also never mounts `ToastContainer` (return starts at 368; V3 mounts it at `V3AppShell.tsx` 240), so inaccessible-workspace and switch-failure toasts have no outlet in the supplied legacy tree. `Toast.js` itself was not reviewed.

**5. Focused navigation tests do not execute production navigation, and one mirror encodes the race production avoided.** Confidence: 0.96.

`WorkspaceShell.multinav.test.tsx` 189–211 expects `setQueryData` → `patch` → immediate `invalidateQueries()` → `navigate`, on key `['userWorkspace']`. Production (`WorkspaceShell.tsx` 234–276) navigates immediately, invalidates only inside `patchUiState` `onSuccess`, and uses `queryKeys.userWorkspace.all` (`['user-workspace']`, `queryKeys.ts` 662–664). The test comment (156–161) says a refactor that drops that sequence should fail CI; the handler is inlined, so production can regress without failing. `PlatformWorkspacesPage.test.tsx` imports only `roles.ts` (19); save/toggle/invisible-warning cases reimplement local helpers (53–59, 89–100) and do not touch a page. `v3-shell-smoke.spec.ts` skips every Pro route (138). Its live Standard list expects `/inspections` and `/repairs` not to redirect (209–243). Production removed those keys from `CLIENT_ONLY_MODULE_KEYS` (`workspaceModules.ts` 225–229) so they fall through to `default_landing`. The skipped suite’s “exactly one nav” check is `toBeGreaterThan(0)` (167–169), and blank-main uses `length >= 0` (178), which cannot fail.

**6. Workspace fetch failure always recovers to `/dashboard`.** Confidence: 0.8.

Error effect toasts and `navigate('/dashboard', { replace: true })` (`WorkspaceShell.tsx` 136–141). Unknown module uses the same href (85, 360). `navRegistry.ts` 62 and 129–137 say Dashboard is feature-gated and `firstEnabledProRoute` exists so a missing feature does not land on the lock screen. The shell does not use that helper. Lock-screen behavior is not in this packet.

**7. Module Suspense fallback is a second full-page chrome skeleton.** Confidence: 0.9.

`WorkspaceShellSkeleton` is `min-h-screen` with a fake header and 192px sidebar (39–59). It is also the Suspense fallback inside the already-chromed module slot (356, 678). Module loads paint nested chrome and can overflow `h-full` / `overflow-hidden` main.

**8. Workspace switch has no in-flight guard.** Confidence: 0.74.

`handleSwitchWorkspace` (226–276) returns only when `target.key === workspace.key`. It does not check `patchUiState.isPending`. Overlapping clicks stack PATCHes; `onError` restores `previousWorkspace` captured at that click, which may already be an optimistic snapshot (`modules: []`). Impersonation stop in the same packet does guard `isPending` (`ContextBanner.tsx` 79–80).

**9. “No workspaces assigned” is legacy-only.** Confidence: 0.83 that V3 `WorkspaceShell` omits it; 0.5 that excluded `V3Sidebar.js` does not recreate it.

The status copy is only in the legacy branch (425–446), after the V3 return (365). V3 receives `sidebarWorkspaces` (synthetic active prepend, 306–319) but not that empty-role message. Collapsed legacy still mounts an empty padded status box (425–445) because the text, not the box, is hidden.

**10. Legacy `<main>` is an `aria-live="polite"` region for the whole module.** Confidence: 0.9. Rollback path only (`WorkspaceShell.tsx` 671–676). V3 main has `role="main"` only (`V3AppShell.tsx` 183). Map/grid text updates can be announced continuously. V3 does not have this.

## 2. Alternatives, discarded hypotheses, verified matches

Discarded as product defects: `/w/:ws/inspections` and `/repairs` redirecting to `default_landing` is explicit (`workspaceModules.ts` 225–229; `navRegistry.ts` 185–187). The smoke spec is stale; the redirect is not an accidental lockout. Optimistic `modules: []` and invalidate-inside-`onSuccess` match the race comments at `WorkspaceShell.tsx` 231–248; the defect is the untested/contradictory mirror, not that sequence. Shared `sidebarCollapsed` is a documented cross-surface trade-off (381–383). Refetch rehydration (`useUserPreferencesHydration.ts` 133–150) is documented cross-device sync; clobber of unsaved edits needs excluded stores. Unknown `isOrgScopedQueryKey` roots default to scoped (`queryKeys.ts` 846–849); that is the stated safe default, not a proven stale-tenant bug. `roles.ts` matches the in-packet expected list (`PlatformWorkspacesPage.test.tsx` 27–35); backend `Role` parity is not provable here.

Consultant `default_landing` of `consultant.client-list` (multinav test 73–77) is not in `MODULE_REGISTRY`. A real switch to that key would render `WorkspaceShellError` (279–280, 359–360). Treated as unverified: production workspace keys are not in this packet, and the test fixture may be synthetic.

`useUserPreferencesHydration.ts` 122–131 rewrites pro-mode on every `workspace` cache update, including optimistic switch. No supplied shell reads `useWorkspaceProModeStore`, so UI impact is not established.

Verified in-packet: production cache key is `queryKeys.userWorkspace.all`; V3 and legacy are mutually exclusive returns (no double TopBar); synthetic active prepend matches the test helper (306–319 vs test 44–55); client-only allowlist is what blocks URL bypass of server-gated modules; `user-workspace` is org-scoped (`queryKeys.ts` 809–810).

## 3. Excluded boundaries

Not reviewed, so none of these can be assumed to close a finding: `V3TopBar.js` (only candidate drawer opener; nothing in the V3 tree calls `setSidebarDrawerOpen`), `V3Sidebar.js` (whether `standardItems` are filtered, empty-role copy, Pro role nav, surface toggle), `SidebarDrawer.js` (`wideDesktop`, focus trap, closed-state DOM), `SurfaceSwitcher.js`, `OrgSwitcher.js`, `TrustStrip.js`, `OffboardingBanner.js`, `roleLabels.js`, `usePermissions.js`, `useMediaQuery.js`, `features.js`, `AuthContext.js`, `client.js` (`getActiveOrgName`, `switchActiveOrg`), `superAdmin.js`, `auth.js`, `dashboard.js`, `useCommandCenter.js`, `Toast.js`, `ErrorBoundary.js`, assistant/chat/command-center/processing/dev-toggle modules, preference migration/queue and all hydrated stores (`useExplorerStore.js`, `useLayerStore.js`, `useViewUIStore.js`, `useMonitorUIStore.js`, `useMapRailUIStore.js`, `useProfileBankFilterStore.js`, `useWorkspaceProModeStore.js`, `useV3SessionStore.js`, `playbackSpeeds.js`), and module bodies (`MunicipalExplorerModule.js`, `MunicipalReportsModule.js`, `MunicipalUploadsModule.js`, `V3TodayModule.js`, `V3InspectionsModule.js`, `V3RepairsModule.js`, `V3InspectionReview.js`).

Also absent: `PlatformWorkspacesPage` (tests do not cover it), `Sidebar.tsx` (claimed Pro-nav parity), `app/auth/roles.py`, `workspace_resolver.py`, route/auth guards, and `App.tsx`. Consequence: standard nav below 1440px (`V3AppShell.tsx` 176) has no supplied opener; Pro role gating is unreviewed; banner false-positive frequency depends on `getActiveOrgName()`; module-level write blocking for read-only Uploads is unreviewed. `Omitted JSON: []`.

## 4. Next useful action

Fix in the shell, then re-review with `V3Sidebar.js`, `V3TopBar.js`, and `SidebarDrawer.js`: make `:workspaceKey` selectable for accessible workspaces without eating Back; drive V3 items from `workspace.modules` plus the client-only allowlist and toast on a gated click; keep Exit on-screen and trust server view-as IDs when present. Replace inlined nav tests with imports of the real handler, or delete them so they cannot freeze the wrong sequence.

MATERIAL_EVIDENCE_CONFLICT: `v3-shell-smoke.spec.ts` 242–243 expects `/inspections` and `/repairs` to remain on the URL, but `workspaceModules.ts` 225–229 and `WorkspaceShell.tsx` 200–214 redirect those keys to `default_landing`; `WorkspaceShell.multinav.test.tsx` 163–211 requires immediate unkeyed `invalidateQueries` then `navigate` on `['userWorkspace']`, but `WorkspaceShell.tsx` 251–276 navigates immediately and invalidates `['user-workspace']` only in patch `onSuccess`.

Primary judge's stated reason

Weak, forced preference for A because its narrower findings and explicit separation of intentional access behavior make remediation priorities somewhat more trustworthy for this source-only audit. This is not an established material quality gap: B offers broader useful coverage and better qualification of sidebar visibility, while A also overstates that visibility. An independent review could reasonably prefer B's additional evidence.

This reason is the judge's assessment. No independent factual-defect finding is asserted by this record.

Battle wave: 87604684-5410-4204-96bf-6143dab2c1dc. Pair: brp1_1836d37dcec1f0b3ea98cfa38a7fc0f53035377fb8132620f2e29eb017637c9d. A separate independent review is required before calling a concern a verified factual defect. Judge disagreement is not recorded here.