Skip to content

Add super-user Plan and knowledge graph settings with benchmark tooling - #8637

Open
Sg312 wants to merge 32 commits into
stagingfrom
feat/plan-discovery-hillclimb
Open

Sg312 wants to merge 32 commits into
stagingfrom
feat/plan-discovery-hillclimb

Conversation

@Sg312

@Sg312 Sg312 commented Oct 5, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Add private named knowledge graphs, detailed Plan-mode specifications and an organization benchmark console. Plan and knowledge use the same server-side eligibility as Benchmark UI: the existing benchmark deployment opt-in plus platform admin status and enabled Super User Mode. The UI, chat creation/admission, graph settings and worker memory scope enforce that policy; ordinary organization admin status is insufficient.

The branch also adds separately gated desktop computer use, read-only Search integration tooling, catalog credential/scope guidance and client-tool result recovery fixes. Computer use and Search tools retain their separate rollout gates; no production flag is enabled by this PR. A benchmark's selected user must independently qualify for Plan.

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation
  • Other

Testing

  • Full root bun run test: 355 script tests and all 19 workspace tasks pass; Sim app 34,918 pass, 21 skip.
  • All 26 workspace type/lint tasks, 58 architecture audits, block-registry checks, migration safety and schema drift pass.
  • 37 real PostgreSQL integration cases cover benchmark persistence and pagination, target-user eligibility, private graph scopes and sealed desktop completions.
  • 240 focused owner tests pass, plus the corrected 15-case secret delegation fixture. Native transport’s real-child regression fails against the old frame guard and passes with the fix. Stop remains usable during pending or failed permission reads.

Review fixes cover selected-user admission, lease renewal/expiry, timestamp precision, score constraints, draft preservation, scoped search selection, native replay/visual transport and memory binding on workspace transfer. Additive migrations 0395–0399 introduce graph/benchmark storage and the NOT VALID score check. Dev databases retaining the earlier feature migration journal still require the documented reconciliation before redeployment; no live journal or configuration was changed.

No customer content, paid comparison runs, deployment or merge. Earlier failed local receipts are retained: an outdated Plan-positive fixture needed explicit eligibility, and an initial heavily concurrent script run hit fixture timeouts. The corrected full rerun passes without weakening assertions or test deadlines.

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced (existing upload-test namespace-import and script-template warnings remain)
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

Screenshots/Videos

No new screenshots captured for the eligibility change. Plan and knowledge settings use the existing composer and settings layouts.

Companion PR

Companion: https://github.com/simstudioai/mothership/pull/598

@Sg312
Sg312 requested a review from a team as a code owner October 5, 2026 22:36
@vercel

vercel Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
docs Ready Ready Preview Oct 8, 2026 12:54am UTC

Request Review

@greptile-apps

greptile-apps Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 3/5

[High risk] Adds native macOS computer-use capability with new APIs and desktop bridge.

The PR does not appear safe to merge while webhook reconciliation can undo a newer cancellation and the comparison request can expire before its stages finish.

Findings

  1. P1 Comparison request can expire ▶

Summary

The PR adds private knowledge graphs, Plan eligibility enforcement, an organization benchmark console, separately gated desktop computer use, and read-only Search tooling. The changes since the previous review also add billing subscription-to-Stripe convergence and embedded CLI isolation.

  • Benchmark runs persist staged results and restrict the selected user’s Plan access.
  • Billing syncs record current cancellation and seat intent across retries and webhooks.
  • One webhook reconciliation race can still replace a newer cancellation with an older Stripe observation.

Reviews (6) · Last reviewed commit: "fix(plan): isolate embedded CLI and chec..." · Reviewed by Greptile

Comment thread apps/sim/lib/benchmarks/application/prepare-plan.ts
Comment thread apps/sim/lib/mothership/memory/application/read-scope.ts
Comment thread apps/sim/lib/benchmarks/application/stage-lease.ts
@github-actions github-actions Bot added the requires-mothership-merge Has a companion PR on the mothership/copilot side — merge in lockstep label Oct 5, 2026
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown

⚠️ Cross-repo companion check

One or more companion PRs aren't merged into staging yet. Merging this without them will leave copilot and sim out of sync — merge them in lockstep.

  • ❌ simstudioai/mothership#598 — OPEN, not merged (targets staging) — Add super-user Plan, private knowledge graphs, and benchmark orchestration

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 245 files

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.

Re-trigger cubic

Comment thread apps/sim/lib/mothership/tools/client/computer-tool-execution.ts
Comment thread apps/sim/app/o/[organizationId]/layout.tsx Outdated
Comment thread apps/sim/components/settings/navigation.ts
Comment thread packages/desktop-bridge/src/index.ts
Comment thread apps/sim/lib/mothership/chat/organization-chats.ts
Comment thread apps/sim/lib/benchmarks/application/stage-lease.ts
Comment thread apps/desktop/native/computer-use/Info.plist
Comment thread apps/sim/lib/benchmarks/worker.ts
Comment thread apps/sim/hooks/queries/computer-use.ts Outdated
Comment thread apps/sim/app/o/[organizationId]/benchmark/components/benchmark-results.tsx Outdated
@Sg312
Sg312 force-pushed the feat/plan-discovery-hillclimb branch from ff42b48 to 7931397 Compare October 6, 2026 00:36
@Sg312

Sg312 commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator Author

@greptile

@Sg312

Sg312 commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@Sg312 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

5 issues found across 252 files

Confidence score: 2/5

  • Plan eligibility revocation is not enforced on two paths: organization-chats.ts can still serve persisted Plan chats, and run-stage.ts can publish a generated spec after access is revoked. Recheck eligibility in both paths.
  • In computer-tool-execution.ts, a transient failure of the page-exit completion request leaves the server-side waiter stranded after unload removes its execution entry. Add a retry or recovery path for the completion request.
  • admin-move.ts can miss a chat created after its cleanup update, leaving that chat with the source memorySpaceId. Serialize chat creation with the move or add a follow-up cleanup.
  • In computer-use.tsx, an older permission refresh can overwrite a newer revoke result and make a revoked app reappear. Ignore stale responses or serialize refreshes.
Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="apps/sim/lib/workspaces/admin-move.ts">

<violation number="1" location="apps/sim/lib/workspaces/admin-move.ts:1366">
P2: This one-shot cleanup is racy with chat creation: a chat that resolves the source organization before the move can be inserted after this `UPDATE` commits and retain the source `memorySpaceId`. Serialize chat creation with the workspace move or re-read the workspace organization/selection at insert time so post-move chats cannot retain an invalid graph binding.</violation>
</file>

<file name="apps/sim/lib/mothership/chat/organization-chats.ts">

<violation number="1" location="apps/sim/lib/mothership/chat/organization-chats.ts:76">
P2: Persisted Plan chats bypass this eligibility check when loaded through the chat-detail and organization-page paths, because those callers omit `input.mode`; a user whose Plan eligibility is revoked can still read the Plan conversation. Authorize against the persisted chat mode rather than only the caller-supplied mode.</violation>
</file>

<file name="apps/sim/app/workspace/[workspaceId]/settings/components/desktop/computer-use.tsx">

<violation number="1" location="apps/sim/app/workspace/[workspaceId]/settings/components/desktop/computer-use.tsx:31">
P3: An in-flight permission refresh can overwrite a newer revoke result because `.then(setApps)` accepts every response. Ignore stale list responses or serialize the refreshes so a revoked app cannot reappear in the approved-apps list.</violation>
</file>

<file name="apps/sim/lib/benchmarks/application/run-stage.ts">

<violation number="1" location="apps/sim/lib/benchmarks/application/run-stage.ts:237">
P2: The final reauthorization does not recheck the selected target’s Plan eligibility. If Super User/Plan access is revoked while the planner runs, this path still publishes its generated spec; reauthorize the target’s Plan access before completion.</violation>
</file>

<file name="apps/sim/lib/mothership/tools/client/computer-tool-execution.ts">

<violation number="1" location="apps/sim/lib/mothership/tools/client/computer-tool-execution.ts:139">
P1: A transient failure of the single page-exit completion request strands the server-side computer-tool waiter because unloading destroys the in-memory `executions` entry and the catch only logs the error. Mirror the browser tool’s unload path by sending a compact result through `sendBeacon`, falling back to keepalive, and retaining the completion for redelivery when both fail.</violation>
</file>

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.

Re-trigger cubic

Comment thread apps/sim/hooks/queries/benchmarks.ts
Comment thread apps/sim/lib/benchmarks/application/prepare-plan.ts
}
const onPageHide = () => {
cancel()
void reportClientToolCompletionOnPageExit(

@cubic-dev-ai cubic-dev-ai Bot Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: A transient failure of the single page-exit completion request strands the server-side computer-tool waiter because unloading destroys the in-memory executions entry and the catch only logs the error. Mirror the browser tool’s unload path by sending a compact result through sendBeacon, falling back to keepalive, and retaining the completion for redelivery when both fail.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/sim/lib/mothership/tools/client/computer-tool-execution.ts, line 139:

<comment>A transient failure of the single page-exit completion request strands the server-side computer-tool waiter because unloading destroys the in-memory `executions` entry and the catch only logs the error. Mirror the browser tool’s unload path by sending a compact result through `sendBeacon`, falling back to keepalive, and retaining the completion for redelivery when both fail.</comment>

<file context>
@@ -0,0 +1,211 @@
+  }
+  const onPageHide = () => {
+    cancel()
+    void reportClientToolCompletionOnPageExit(
+      toolCallId,
+      ASYNC_TOOL_CONFIRMATION_STATUS.error,
</file context>
Fix with cubic

Comment thread apps/sim/lib/benchmarks/application/stage-lease.ts

// Private graph contents stay with their original organization when a workspace moves.
await tx
.update(copilotChats)

@cubic-dev-ai cubic-dev-ai Bot Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: This one-shot cleanup is racy with chat creation: a chat that resolves the source organization before the move can be inserted after this UPDATE commits and retain the source memorySpaceId. Serialize chat creation with the workspace move or re-read the workspace organization/selection at insert time so post-move chats cannot retain an invalid graph binding.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/sim/lib/workspaces/admin-move.ts, line 1366:

<comment>This one-shot cleanup is racy with chat creation: a chat that resolves the source organization before the move can be inserted after this `UPDATE` commits and retain the source `memorySpaceId`. Serialize chat creation with the workspace move or re-read the workspace organization/selection at insert time so post-move chats cannot retain an invalid graph binding.</comment>

<file context>
@@ -1360,6 +1361,17 @@ export async function moveWorkspaceToOrganization(params: {
 
+        // Private graph contents stay with their original organization when a workspace moves.
+        await tx
+          .update(copilotChats)
+          .set({ memorySpaceId: null })
+          .where(
</file context>
Fix with cubic

if (input.mode === 'agent' || input.mode === 'plan') await requireBuildPermission(context)
if (input.mode === 'agent' || input.mode === 'plan')
await requireOrganizationBuildPermission(context)
if (input.mode === 'plan' && !(await isPlanModeEnabled(context.userId)))

@cubic-dev-ai cubic-dev-ai Bot Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: Persisted Plan chats bypass this eligibility check when loaded through the chat-detail and organization-page paths, because those callers omit input.mode; a user whose Plan eligibility is revoked can still read the Plan conversation. Authorize against the persisted chat mode rather than only the caller-supplied mode.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/sim/lib/mothership/chat/organization-chats.ts, line 76:

<comment>Persisted Plan chats bypass this eligibility check when loaded through the chat-detail and organization-page paths, because those callers omit `input.mode`; a user whose Plan eligibility is revoked can still read the Plan conversation. Authorize against the persisted chat mode rather than only the caller-supplied mode.</comment>

<file context>
@@ -66,7 +71,10 @@ export const authorizeOrganizationChat = {
-    if (input.mode === 'agent' || input.mode === 'plan') await requireBuildPermission(context)
+    if (input.mode === 'agent' || input.mode === 'plan')
+      await requireOrganizationBuildPermission(context)
+    if (input.mode === 'plan' && !(await isPlanModeEnabled(context.userId)))
+      throw new OrchestrationError('not_found', 'Plan mode is unavailable')
     return context
</file context>
Fix with cubic

(signal) => performStage(principal, claimed, input.stage, signal)
)
request?.signal?.throwIfAborted()
await requireBenchmarkCaseAccess(principal, input)

@cubic-dev-ai cubic-dev-ai Bot Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: The final reauthorization does not recheck the selected target’s Plan eligibility. If Super User/Plan access is revoked while the planner runs, this path still publishes its generated spec; reauthorize the target’s Plan access before completion.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/sim/lib/benchmarks/application/run-stage.ts, line 237:

<comment>The final reauthorization does not recheck the selected target’s Plan eligibility. If Super User/Plan access is revoked while the planner runs, this path still publishes its generated spec; reauthorize the target’s Plan access before completion.</comment>

<file context>
@@ -0,0 +1,271 @@
+        (signal) => performStage(principal, claimed, input.stage, signal)
+      )
+      request?.signal?.throwIfAborted()
+      await requireBenchmarkCaseAccess(principal, input)
+      return {
+        benchmark: await completeBenchmarkStage({
</file context>
Fix with cubic

Comment thread apps/sim/hooks/queries/benchmarks.ts
if (!bridge || !availability.data?.enabled) return
void bridge
.listAppPermissions()
.then(setApps)

@cubic-dev-ai cubic-dev-ai Bot Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: An in-flight permission refresh can overwrite a newer revoke result because .then(setApps) accepts every response. Ignore stale list responses or serialize the refreshes so a revoked app cannot reappear in the approved-apps list.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/sim/app/workspace/[workspaceId]/settings/components/desktop/computer-use.tsx, line 31:

<comment>An in-flight permission refresh can overwrite a newer revoke result because `.then(setApps)` accepts every response. Ignore stale list responses or serialize the refreshes so a revoked app cannot reappear in the approved-apps list.</comment>

<file context>
@@ -0,0 +1,122 @@
+    if (!bridge || !availability.data?.enabled) return
+    void bridge
+      .listAppPermissions()
+      .then(setApps)
+      .catch(() => toast.error('Could not load approved apps'))
+  }, [bridge, availability.data?.enabled, status?.activeAction])
</file context>
Fix with cubic

Copy link
Copy Markdown
Collaborator

@greptile

Copy link
Copy Markdown
Collaborator

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

Copy link
Copy Markdown
Collaborator

@greptile

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

4 issues found across 261 files

Confidence score: 3/5

  • In computer-tool-execution.ts, an 8 MiB screenshot can exceed the completion endpoint’s JSON body cap, and retries send the same oversized image, so the task may never complete. Bound or omit oversized screenshots before submitting them.
  • In benchmark.tsx, a failed “Load older benchmarks” request hides already-loaded results and the retry button. Keep cached pages visible and allow the request to be retried.
  • In native-client.ts, oversized requests rejected by ComputerUse.swift use an error ID this client ignores, so calls can time out for schema-valid text with enough escaped control characters. Handle invalid-request responses.
  • In benchmark-score-chart.tsx, screen-reader users cannot tell which run is selected because the buttons expose no selected state. Add aria-pressed to the selected button.
Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="apps/sim/app/o/[organizationId]/benchmark/benchmark.tsx">

<violation number="1" location="apps/sim/app/o/[organizationId]/benchmark/benchmark.tsx:68">
P2: A failed “Load older benchmarks” request sets `error` but retains earlier pages, so this branch hides the list and retry button. Keep cached pages visible on next-page errors and let the button retry.</violation>
</file>

<file name="apps/desktop/src/main/computer-use/native-client.ts">

<violation number="1" location="apps/desktop/src/main/computer-use/native-client.ts:48">
P2: `ComputerUse.swift` rejects requests over 128 KiB under ID `invalid-request`, which this client ignores. Schema-valid text with enough escaped control characters can exceed that limit, leaving the call to time out and tear down the helper; reject oversized serialized requests before writing.</violation>
</file>

<file name="apps/sim/app/o/[organizationId]/benchmark/components/benchmark-score-chart.tsx">

<violation number="1" location="apps/sim/app/o/[organizationId]/benchmark/components/benchmark-score-chart.tsx:40">
P2: The chart marks the selected run only visually, so screen-reader users cannot distinguish it from the other buttons. Add `aria-pressed` to expose the selected state.</violation>
</file>

<file name="apps/sim/lib/mothership/tools/client/computer-tool-execution.ts">

<violation number="1" location="apps/sim/lib/mothership/tools/client/computer-tool-execution.ts:182">
P2: Large but valid screenshots cannot reach the completion endpoint: an 8 MiB PNG base64-encodes above the 10 MiB JSON body cap, and retries leave the screenshot unchanged. Bound or omit oversized screenshots before reporting so the tool call can settle.</violation>
</file>

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.

Turn on auto-fix | Re-trigger cubic

Comment thread apps/sim/lib/mothership/agent-cli/index.ts
Comment thread apps/sim/lib/mothership/tools/desktop-tools.ts
Comment thread apps/sim/lib/computer-use/application/authorize.ts
/>
) : (
<>
{benchmarks.error ? (

@cubic-dev-ai cubic-dev-ai Bot Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: A failed “Load older benchmarks” request sets error but retains earlier pages, so this branch hides the list and retry button. Keep cached pages visible on next-page errors and let the button retry.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/sim/app/o/[organizationId]/benchmark/benchmark.tsx, line 68:

<comment>A failed “Load older benchmarks” request sets `error` but retains earlier pages, so this branch hides the list and retry button. Keep cached pages visible on next-page errors and let the button retry.</comment>

<file context>
@@ -0,0 +1,120 @@
+        />
+      ) : (
+        <>
+          {benchmarks.error ? (
+            <p role='alert' className='text-[var(--text-error)] text-small'>
+              {benchmarks.error.message}
</file context>
Suggested change
{benchmarks.error ? (
{benchmarks.error && !benchmarks.isFetchNextPageError ? (
Fix with cubic

this.stopWithError(new Error('Computer Use timed out; inspect the app before retrying.'))
}, REQUEST_TIMEOUT_MS)
this.pending.set(id, { resolve, reject, timer })
child.stdin.write(`${JSON.stringify({ id, method, params })}\n`, (error) => {

@cubic-dev-ai cubic-dev-ai Bot Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: ComputerUse.swift rejects requests over 128 KiB under ID invalid-request, which this client ignores. Schema-valid text with enough escaped control characters can exceed that limit, leaving the call to time out and tear down the helper; reject oversized serialized requests before writing.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/desktop/src/main/computer-use/native-client.ts, line 48:

<comment>`ComputerUse.swift` rejects requests over 128 KiB under ID `invalid-request`, which this client ignores. Schema-valid text with enough escaped control characters can exceed that limit, leaving the call to time out and tear down the helper; reject oversized serialized requests before writing.</comment>

<file context>
@@ -0,0 +1,142 @@
+        this.stopWithError(new Error('Computer Use timed out; inspect the app before retrying.'))
+      }, REQUEST_TIMEOUT_MS)
+      this.pending.set(id, { resolve, reject, timer })
+      child.stdin.write(`${JSON.stringify({ id, method, params })}\n`, (error) => {
+        if (error && this.child === child)
+          this.stopWithError(new Error('Computer Use helper disconnected.'))
</file context>
Fix with cubic

Comment thread apps/sim/lib/mothership/request/lifecycle/run.ts
Comment thread apps/desktop/src/main/ipc.ts
Comment thread apps/sim/lib/desktop/index.ts
Comment thread apps/sim/lib/benchmarks/evidence.ts
: result.kind === 'action' && !result.verified
? 'Input was dispatched. Inspect the returned observation or the app to verify its effect.'
: 'Computer observation completed',
data: computerToolResultForModel(result),

@cubic-dev-ai cubic-dev-ai Bot Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: Large but valid screenshots cannot reach the completion endpoint: an 8 MiB PNG base64-encodes above the 10 MiB JSON body cap, and retries leave the screenshot unchanged. Bound or omit oversized screenshots before reporting so the tool call can settle.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At apps/sim/lib/mothership/tools/client/computer-tool-execution.ts, line 182:

<comment>Large but valid screenshots cannot reach the completion endpoint: an 8 MiB PNG base64-encodes above the 10 MiB JSON body cap, and retries leave the screenshot unchanged. Bound or omit oversized screenshots before reporting so the tool call can settle.</comment>

<file context>
@@ -0,0 +1,211 @@
+                  : result.kind === 'action' && !result.verified
+                    ? 'Input was dispatched. Inspect the returned observation or the app to verify its effect.'
+                    : 'Computer observation completed',
+            data: computerToolResultForModel(result),
+          }
+    } else
</file context>
Fix with cubic

import { benchmarkOperations } from '@/lib/benchmarks/application/operations'
import { runBenchmarkComparison } from '@/lib/benchmarks/application/run-comparison'

export const POST = defineInternalJsonRoute({

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Comparison request can expire If the deployment limits how long this request may run, a comparison can be terminated before all selected models finish. The new endpoint runs up to six planners through Plan, reconstruction, and grading sequentially in one request, without a duration provision for the full sequence. Completed runs remain saved, but the console cannot reliably produce the requested comparison.

Copy link
Copy Markdown
Collaborator

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

Sg312 and others added 24 commits October 7, 2026 17:37
@icecrasher321
icecrasher321 force-pushed the feat/plan-discovery-hillclimb branch from faff0a8 to df7a02b Compare October 8, 2026 00:48

Copy link
Copy Markdown
Collaborator

@greptile

Copy link
Copy Markdown
Collaborator

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 269 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.

Turn on auto-fix | Re-trigger cubic

This branch was successfully deployed

1 active deployment
Preview — df7a02bf Deployed Oct 8, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

requires-mothership-merge Has a companion PR on the mothership/copilot side — merge in lockstep

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants