specrails-desktop 2.36.0 → 2.42.2
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.
- package/README.md +94 -247
- package/client/dist/assets/ActivityFeedPage-DoEMumQS.js +1 -0
- package/client/dist/assets/AgentBrowserCapture-DIh4K0gh.js +1 -0
- package/client/dist/assets/AgentModeAnalyticsPane-mbq4WEoO.js +2 -0
- package/client/dist/assets/AgentModeCodePane-CKh7zuA4.js +2 -0
- package/client/dist/assets/AgentModeJobsPane-BDokPiLJ.js +1 -0
- package/client/dist/assets/AgentsPage-BFVAZbBj.js +87 -0
- package/client/dist/assets/AnalyticsPage-3Y9LuWwz.js +1 -0
- package/client/dist/assets/CodePage-C9KyuV_C.js +3 -0
- package/client/dist/assets/DesktopAnalyticsPage-Bhi54bXQ.js +1 -0
- package/client/dist/assets/{DocsDialog-C76VdBJC.js → DocsDialog-Dj6mt4ga.js} +2 -2
- package/client/dist/assets/{DocsPage-ziMlj6B6.js → DocsPage-24yWglNI.js} +1 -1
- package/client/dist/assets/ExportDropdown-ophapHrT.js +1 -0
- package/client/dist/assets/InteractiveJobComposer-C1ucmxQh.js +19 -0
- package/client/dist/assets/JobDetailModal-DNWmgVHD.js +1 -0
- package/client/dist/assets/JobDetailPage-BcajZyuu.js +1 -0
- package/client/dist/assets/JobsPage-B9nTZw6e.js +1 -0
- package/client/dist/assets/LoopBuilderPage-Oc48iOFW.js +7 -0
- package/client/dist/assets/LoopPreviewModal-ae0Fr6SU.js +1 -0
- package/client/dist/assets/LoopsPage-CUEqzUBI.js +1 -0
- package/client/dist/assets/MinimizedChatsContext-Deg39peL.js +1 -0
- package/client/dist/assets/PluginsPage-C1xtARIx.js +2 -0
- package/client/dist/assets/ProjectSettingsDialog-JZzrXFBN.js +1 -0
- package/client/dist/assets/RepositoryDeliveries-CSDsiVUz.js +5 -0
- package/client/dist/assets/RepositoryScopeSelector-D-RCaknl.js +1 -0
- package/client/dist/assets/ReviewPacketPage-x5EfGTiL.js +1 -0
- package/client/dist/assets/TemplatePreviewModal-BSyuZxGq.js +1 -0
- package/client/dist/assets/TicketDetailModalContext-DqyF0so-.js +14 -0
- package/client/dist/assets/Trans-SnMX4MhW.js +1 -0
- package/client/dist/assets/agent-BdT0SB1D.js +1 -0
- package/client/dist/assets/agent-Bh9K7iEt.js +1 -0
- package/client/dist/assets/agent-C4ibdFk9.js +1 -0
- package/client/dist/assets/agent-CSFY22Zo.js +1 -0
- package/client/dist/assets/agent-DAnqxUn8.js +1 -0
- package/client/dist/assets/agent-DTQiu0Mi.js +1 -0
- package/client/dist/assets/agent-T54WuR_Y.js +1 -0
- package/client/dist/assets/agent-i75WDZOA.js +1 -0
- package/client/dist/assets/browser-05vRDg_y.js +1 -0
- package/client/dist/assets/browser-Bulb-cB1.js +1 -0
- package/client/dist/assets/browser-C7f-Jsg1.js +1 -0
- package/client/dist/assets/browser-CG0PE1j_.js +1 -0
- package/client/dist/assets/browser-CMzaqAjo.js +1 -0
- package/client/dist/assets/browser-DMajYdNX.js +1 -0
- package/client/dist/assets/browser-DxcOHrdP.js +1 -0
- package/client/dist/assets/browser-ObE7xVo3.js +1 -0
- package/client/dist/assets/builder-765NeYTp.js +1 -0
- package/client/dist/assets/builder-8MG3V6ea.js +1 -0
- package/client/dist/assets/builder-B-1UBs5K.js +1 -0
- package/client/dist/assets/builder-BTiGnPT0.js +1 -0
- package/client/dist/assets/builder-Cx9Rz-7u.js +1 -0
- package/client/dist/assets/builder-DKFMELBl.js +1 -0
- package/client/dist/assets/builder-OcmKrC0h.js +1 -0
- package/client/dist/assets/builder-P9qVBXFZ.js +1 -0
- package/client/dist/assets/{button-CJqFnUOL.js → button-DCBqEaZl.js} +1 -1
- package/client/dist/assets/{code-CkUuW4m9.js → code-B37GRg9C.js} +1 -1
- package/client/dist/assets/{code-B0O8-p8k.js → code-BBOEZbf9.js} +1 -1
- package/client/dist/assets/{code-B1VLZDhS.js → code-BRm-jcyx.js} +1 -1
- package/client/dist/assets/{code-Bpj4Ddml.js → code-CF7w62CR.js} +1 -1
- package/client/dist/assets/{code-BykBZ5-e.js → code-CLuvJt2r.js} +1 -1
- package/client/dist/assets/{code-B86IMAfz.js → code-D0RCm59f.js} +1 -1
- package/client/dist/assets/code-DaZ-ZwCT.js +1 -0
- package/client/dist/assets/{code-cAqaqMTx.js → code-iIHkGaCL.js} +1 -1
- package/client/dist/assets/commands-0XjAftla.js +1 -0
- package/client/dist/assets/commands-BAWSYHjQ.js +1 -0
- package/client/dist/assets/commands-BBwowgiE.js +1 -0
- package/client/dist/assets/commands-BacjIZLN.js +1 -0
- package/client/dist/assets/commands-Bs62IAZ3.js +1 -0
- package/client/dist/assets/commands-CLPdh-Hh.js +1 -0
- package/client/dist/assets/commands-DlbFzgrp.js +1 -0
- package/client/dist/assets/commands-LjPSsi5F.js +1 -0
- package/client/dist/assets/common-B5AZNYMH.js +1 -0
- package/client/dist/assets/common-BFZ0c_vN.js +1 -0
- package/client/dist/assets/common-BrlwEnL7.js +1 -0
- package/client/dist/assets/common-BttQx3z4.js +1 -0
- package/client/dist/assets/common-CM65k_-e.js +1 -0
- package/client/dist/assets/common-D4mvFFlu.js +1 -0
- package/client/dist/assets/common-TZ9Ny96S.js +1 -0
- package/client/dist/assets/common-nFpSF4GC.js +1 -0
- package/client/dist/assets/dashboard-B14uYXkG.js +1 -0
- package/client/dist/assets/dashboard-BK_mez-z.js +1 -0
- package/client/dist/assets/dashboard-BfBir_6o.js +1 -0
- package/client/dist/assets/dashboard-Bt0cCzeG.js +1 -0
- package/client/dist/assets/dashboard-BwkjxI6H.js +1 -0
- package/client/dist/assets/{dashboard-C8WOEiPu.js → dashboard-C3bDKf7s.js} +1 -1
- package/client/dist/assets/dashboard-CdvjGfog.js +1 -0
- package/client/dist/assets/dashboard-fRrP0Kv0.js +1 -0
- package/client/dist/assets/dialog-SRw01_QU.js +45 -0
- package/client/dist/assets/dist-js-CJ_2XX1Y.js +1 -0
- package/client/dist/assets/formatDistanceToNow-DSj5DprF.js +1 -0
- package/client/dist/assets/getTimezoneOffsetInMilliseconds-YhD8rIEs.js +1 -0
- package/client/dist/assets/index-DwAmL7m5.css +2 -0
- package/client/dist/assets/index-EzrkUb8B.js +76 -0
- package/client/dist/assets/{jira-api-B1-MUehg.js → jira-api-CSCqGr-Q.js} +1 -1
- package/client/dist/assets/{jobs-CN_zv4Gr.js → jobs-B8rrzfyZ.js} +1 -1
- package/client/dist/assets/{jobs-DUlWSYq2.js → jobs-BS6RTurf.js} +1 -1
- package/client/dist/assets/{jobs-Bpks6doU.js → jobs-BTT0Bsks.js} +1 -1
- package/client/dist/assets/{jobs-Bgq-PZkC.js → jobs-CezU69AE.js} +1 -1
- package/client/dist/assets/{jobs-SwYS2M-B.js → jobs-ClFJae0s.js} +1 -1
- package/client/dist/assets/{jobs-BAls3bWq.js → jobs-DJSFIFVy.js} +1 -1
- package/client/dist/assets/{jobs-DhxKgWFq.js → jobs-DhgGr8vm.js} +1 -1
- package/client/dist/assets/{jobs-B_TeSQxb.js → jobs-DzMjUcaN.js} +1 -1
- package/client/dist/assets/mcp-6rMoZfEO.js +1 -0
- package/client/dist/assets/mcp-BD8sL5mP.js +1 -0
- package/client/dist/assets/mcp-BkcA3I5s.js +1 -0
- package/client/dist/assets/mcp-CCpSelOh.js +1 -0
- package/client/dist/assets/mcp-CUAN6ORK.js +1 -0
- package/client/dist/assets/mcp-CqbRxRTE.js +1 -0
- package/client/dist/assets/mcp-DP2YfVhO.js +1 -0
- package/client/dist/assets/mcp-DUVQamDz.js +1 -0
- package/client/dist/assets/narration-B-ynWTpn.js +1 -0
- package/client/dist/assets/narration-Bj_laZwg.js +1 -0
- package/client/dist/assets/narration-BxHpmMv_.js +1 -0
- package/client/dist/assets/narration-C1Px0-0j.js +1 -0
- package/client/dist/assets/narration-CAXhGbzM.js +1 -0
- package/client/dist/assets/narration-DQ1l_Kq6.js +1 -0
- package/client/dist/assets/narration-XISXwqZd.js +1 -0
- package/client/dist/assets/narration-kwzfglQo.js +1 -0
- package/client/dist/assets/nav-1-Hh2kOz.js +1 -0
- package/client/dist/assets/nav-B34QkESm.js +1 -0
- package/client/dist/assets/nav-Bap_UXAq.js +1 -0
- package/client/dist/assets/{nav-pYuXq7sf.js → nav-BwxXIB24.js} +1 -1
- package/client/dist/assets/nav-Ch-zHBG5.js +1 -0
- package/client/dist/assets/nav-CygC_WN-.js +1 -0
- package/client/dist/assets/{nav-iwjCg5FR.js → nav-KnnLQtOQ.js} +1 -1
- package/client/dist/assets/nav-m00uxYUG.js +1 -0
- package/client/dist/assets/packet-BQ2tXfJI.js +1 -0
- package/client/dist/assets/packet-BdpOJ1Cy.js +1 -0
- package/client/dist/assets/packet-C3Ievb9R.js +1 -0
- package/client/dist/assets/packet-C4zJIG0Y.js +1 -0
- package/client/dist/assets/packet-Cx-zRuWn.js +1 -0
- package/client/dist/assets/packet-DUTGX52M.js +1 -0
- package/client/dist/assets/packet-DhsKtUPB.js +1 -0
- package/client/dist/assets/packet-z3LJ8Zyy.js +1 -0
- package/client/dist/assets/project-repositories-DYhTvwQ1.js +1 -0
- package/client/dist/assets/provider-capabilities-B-wOHfLP.js +1 -0
- package/client/dist/assets/settings-BBt2xtDQ.js +1 -0
- package/client/dist/assets/settings-BJB9RKJj.js +1 -0
- package/client/dist/assets/settings-CHwQR2rB.js +1 -0
- package/client/dist/assets/settings-CrMi3kSi.js +1 -0
- package/client/dist/assets/settings-DKyhDGD1.js +1 -0
- package/client/dist/assets/settings-Deupji9c.js +1 -0
- package/client/dist/assets/settings-DqRMmwAM.js +1 -0
- package/client/dist/assets/settings-J4rj6vo-.js +1 -0
- package/client/dist/assets/setup-2xGgu4Sk.js +1 -0
- package/client/dist/assets/setup-Ba11l2JA.js +1 -0
- package/client/dist/assets/setup-BzW4kMok.js +1 -0
- package/client/dist/assets/setup-COzwYhkJ.js +1 -0
- package/client/dist/assets/setup-CRVULhtF.js +1 -0
- package/client/dist/assets/setup-DgvlxwpE.js +1 -0
- package/client/dist/assets/setup-Dw_wYeEY.js +1 -0
- package/client/dist/assets/setup-ZPtEeJPW.js +1 -0
- package/client/dist/assets/spending-BqbdPm_4.js +1 -0
- package/client/dist/assets/square-Ci-PFcFe.js +1 -0
- package/client/dist/assets/{terminal-BFRZnMPP.js → terminal-BAzpHtpY.js} +1 -1
- package/client/dist/assets/{terminal-IahE4LW9.js → terminal-C7dHeR3x.js} +1 -1
- package/client/dist/assets/{terminal-tITa81iz.js → terminal-CMla5Qsz.js} +1 -1
- package/client/dist/assets/{terminal-BZiIu3rf.js → terminal-CdNXH-n9.js} +1 -1
- package/client/dist/assets/{terminal-ScjyXNxQ.js → terminal-Cw5bZsmV.js} +1 -1
- package/client/dist/assets/{terminal-C2NAd7BW.js → terminal-DFUP4eNv.js} +1 -1
- package/client/dist/assets/{terminal-d7GadXbN.js → terminal-DGqljeK_.js} +1 -1
- package/client/dist/assets/{terminal-QpXZU2Bn.js → terminal-cU70NodO.js} +1 -1
- package/client/dist/assets/useDesktop-RSMTyy7V.js +1 -0
- package/client/dist/assets/useSharedWebSocket-BOdS5_Iz.js +2 -0
- package/client/dist/index.html +34 -35
- package/docs/README.md +3 -0
- package/docs/agent-live-steering.md +57 -0
- package/docs/ci-cd.md +57 -0
- package/docs/code-explorer.md +48 -0
- package/docs/codex.md +12 -1
- package/docs/features/detachable-mission-windows.md +59 -0
- package/docs/guide/de/integrations/5-mcp-server.md +13 -9
- package/docs/guide/de/integrations/6-agent-chat.md +1 -0
- package/docs/guide/en/integrations/5-mcp-server.md +13 -9
- package/docs/guide/en/integrations/6-agent-chat.md +1 -0
- package/docs/guide/es/integrations/5-mcp-server.md +13 -9
- package/docs/guide/es/integrations/6-agent-chat.md +1 -0
- package/docs/guide/fr/integrations/5-mcp-server.md +13 -9
- package/docs/guide/fr/integrations/6-agent-chat.md +1 -0
- package/docs/guide/it/integrations/5-mcp-server.md +13 -9
- package/docs/guide/it/integrations/6-agent-chat.md +1 -0
- package/docs/guide/ja/integrations/5-mcp-server.md +13 -9
- package/docs/guide/ja/integrations/6-agent-chat.md +1 -0
- package/docs/guide/pt/integrations/5-mcp-server.md +13 -9
- package/docs/guide/pt/integrations/6-agent-chat.md +1 -0
- package/docs/guide/zh/integrations/5-mcp-server.md +13 -9
- package/docs/guide/zh/integrations/6-agent-chat.md +1 -0
- package/docs/internals/README.md +1 -0
- package/docs/internals/browser-capture-performance.md +55 -3
- package/docs/internals/browser-login-popups.md +45 -0
- package/docs/internals/browser-native-retina-audit.md +39 -0
- package/docs/internals/ci-cd-audit.md +39 -0
- package/docs/internals/core-runtime-updates.md +68 -0
- package/docs/internals/embedded-browser-native-webview-evaluation.md +2 -0
- package/docs/internals/implementation-reliability-audit.md +93 -0
- package/docs/internals/interactive-jobs.md +110 -6
- package/docs/internals/mcp-mission-audit.md +76 -0
- package/docs/internals/project-builder.md +404 -42
- package/docs/internals/safe-pr-review-flow.md +52 -10
- package/docs/internals/startup-recovery-audit.md +58 -0
- package/docs/mcp.md +74 -41
- package/docs/mission-processes.md +59 -0
- package/docs/multi-repo-projects.md +51 -0
- package/docs/platforms/windows-parity.md +70 -0
- package/docs/platforms/windows.md +13 -11
- package/docs/running-pipelines.md +14 -0
- package/mcp-bridge/dist/specrails-mcp.js +7186 -0
- package/package.json +9 -4
- package/server/dist/agent-chat-manager.js +537 -68
- package/server/dist/agent-chat-router.js +87 -6
- package/server/dist/agent-context-resolver.js +129 -25
- package/server/dist/agent-defaults.js +19 -11
- package/server/dist/agent-input-store.js +206 -0
- package/server/dist/agent-mcp-config.js +54 -15
- package/server/dist/agent-operator-prompt.js +255 -65
- package/server/dist/agent-spec-framing.js +202 -0
- package/server/dist/agent-steering.js +218 -0
- package/server/dist/agent-store.js +153 -0
- package/server/dist/api-not-found.js +8 -0
- package/server/dist/background-process-control.js +164 -0
- package/server/dist/background-process-service.js +61 -0
- package/server/dist/background-process-store.js +242 -0
- package/server/dist/background-windows-bootstrap.js +238 -0
- package/server/dist/blueprint-chat-manager.js +476 -62
- package/server/dist/blueprint-commit.js +21 -1
- package/server/dist/blueprint-draft-parser.js +122 -17
- package/server/dist/blueprint-generation.js +238 -0
- package/server/dist/blueprint-operator-prompt.js +91 -63
- package/server/dist/blueprint-router.js +55 -3
- package/server/dist/blueprint-spec-fixtures.js +85 -0
- package/server/dist/blueprint-spec-quality.js +57 -16
- package/server/dist/blueprint-store.js +92 -1
- package/server/dist/browser-capture-manager.js +86 -30
- package/server/dist/browser-playwright.js +168 -45
- package/server/dist/browser-viewport.js +26 -0
- package/server/dist/chat-manager.js +23 -15
- package/server/dist/chromium-archive.cjs +83 -0
- package/server/dist/chromium-resolver.js +72 -64
- package/server/dist/code-activity.js +145 -0
- package/server/dist/code-explorer-router.js +714 -114
- package/server/dist/core-compat.js +28 -1
- package/server/dist/core-execution.js +111 -0
- package/server/dist/core-package.js +4 -16
- package/server/dist/core-runtime.js +202 -0
- package/server/dist/core-update-manager.js +161 -60
- package/server/dist/core-update-state.js +29 -0
- package/server/dist/db.js +66 -35
- package/server/dist/delivery-evidence.js +142 -39
- package/server/dist/desktop-db.js +239 -43
- package/server/dist/desktop-router.js +109 -9
- package/server/dist/dev-ports.js +8 -3
- package/server/dist/file-provenance.js +34 -22
- package/server/dist/file-story-manager.js +62 -64
- package/server/dist/file-story.js +118 -35
- package/server/dist/file-summary-generator.js +46 -5
- package/server/dist/file-summary-manager.js +355 -106
- package/server/dist/framework-manager.js +98 -110
- package/server/dist/framework-reseed.js +76 -10
- package/server/dist/git-diagnostics.js +2 -2
- package/server/dist/headroom-manager.js +38 -3
- package/server/dist/host-control.js +52 -0
- package/server/dist/index.js +43 -2
- package/server/dist/interactive-job-session.js +149 -16
- package/server/dist/internal-api.js +48 -0
- package/server/dist/jira/jira-materializer.js +1 -0
- package/server/dist/json-tolerant.js +174 -0
- package/server/dist/legacy-migration.js +4 -2
- package/server/dist/loop-command-catalog.js +83 -21
- package/server/dist/loop-constants.js +6 -1
- package/server/dist/loop-decider.js +11 -1
- package/server/dist/loop-executors.js +194 -45
- package/server/dist/loop-factory.js +11 -4
- package/server/dist/loop-graph.js +90 -4
- package/server/dist/loop-run-manager.js +301 -69
- package/server/dist/loop-shell-invocation.js +21 -0
- package/server/dist/loop-step-idle.js +55 -0
- package/server/dist/loop-templates.js +31 -7
- package/server/dist/mcp/agent-capability.js +37 -4
- package/server/dist/mcp/guide.js +149 -36
- package/server/dist/mcp/mcp-admin-router.js +20 -4
- package/server/dist/mcp/mcp-server.js +89 -43
- package/server/dist/mcp/mcp-tiers.js +6 -5
- package/server/dist/mcp/mcp-token.js +3 -1
- package/server/dist/mcp/resources.js +5 -4
- package/server/dist/mcp/tools/catalog.js +4 -0
- package/server/dist/mcp/tools/code.js +125 -14
- package/server/dist/mcp/tools/context.js +153 -0
- package/server/dist/mcp/tools/git.js +15 -5
- package/server/dist/mcp/tools/jobs.js +84 -71
- package/server/dist/mcp/tools/loops.js +17 -6
- package/server/dist/mcp/tools/meta.js +74 -27
- package/server/dist/mcp/tools/mission.js +29 -0
- package/server/dist/mcp/tools/projects.js +22 -6
- package/server/dist/mcp/tools/rails.js +48 -11
- package/server/dist/mcp/tools/specs.js +86 -14
- package/server/dist/mcp/tools/support.js +1 -1
- package/server/dist/mcp/tools/types.js +117 -43
- package/server/dist/mcp/tools/watch.js +144 -51
- package/server/dist/milestone-chain-store.js +164 -0
- package/server/dist/milestone-chain.js +487 -0
- package/server/dist/milestone-progress.js +348 -0
- package/server/dist/mobile/mobile-devices.js +10 -7
- package/server/dist/mobile/mobile-gateway.js +2 -0
- package/server/dist/mobile/mobile-missions.js +214 -0
- package/server/dist/mobile/mobile-redact.js +17 -3
- package/server/dist/mobile/mobile-router.js +46 -4
- package/server/dist/mobile/mobile-ws.js +49 -4
- package/server/dist/multi-repo-bases.js +56 -0
- package/server/dist/multi-repo-checkout.js +101 -0
- package/server/dist/multi-repo-delivery.js +100 -0
- package/server/dist/multi-repo-execution-store.js +65 -0
- package/server/dist/multi-repo-execution.js +453 -0
- package/server/dist/offline-assemble.js +10 -8
- package/server/dist/openspec-runtime-plugin-commands.json +18 -0
- package/server/dist/openspec-runtime-plugin.js +120 -0
- package/server/dist/plugins/codex-spawn.js +49 -0
- package/server/dist/plugins/serena/manifest.js +2 -2
- package/server/dist/plugins/serena/templates/instructions.md +16 -0
- package/server/dist/pr-publisher.js +1 -1
- package/server/dist/profiles-router.js +3 -18
- package/server/dist/project-code-discovery.js +142 -0
- package/server/dist/project-git.js +19 -21
- package/server/dist/project-registry.js +272 -20
- package/server/dist/project-repositories.js +157 -0
- package/server/dist/project-repository-provenance.js +31 -0
- package/server/dist/project-router-background-processes.js +105 -0
- package/server/dist/project-router-git.js +75 -16
- package/server/dist/project-router-jobs.js +2 -126
- package/server/dist/project-router-loop-runs.js +72 -2
- package/server/dist/project-router-tickets.js +53 -8
- package/server/dist/project-router.js +239 -38
- package/server/dist/provider-detection.js +18 -6
- package/server/dist/provider-limit.js +64 -0
- package/server/dist/providers/claude-adapter.js +26 -1
- package/server/dist/providers/claude-background-tasks.js +18 -0
- package/server/dist/providers/claude-live-session.js +383 -0
- package/server/dist/providers/codex-adapter.js +19 -0
- package/server/dist/providers/codex-live-session.js +545 -0
- package/server/dist/providers/gemini-adapter.js +1 -0
- package/server/dist/providers/live-session-types.js +12 -0
- package/server/dist/providers/live-session.js +13 -0
- package/server/dist/providers/terminal-result.js +24 -0
- package/server/dist/queue-manager.js +2 -0
- package/server/dist/rail-isolated-launch.js +141 -16
- package/server/dist/rail-pr-decision.js +364 -99
- package/server/dist/rail-pr-store.js +24 -10
- package/server/dist/rail-worktree-release.js +34 -2
- package/server/dist/rail-worktrees-store.js +4 -4
- package/server/dist/rails-router.js +249 -55
- package/server/dist/repo-lock.js +92 -17
- package/server/dist/review-packet.js +23 -13
- package/server/dist/schemas/file-summary.v1.json +59 -59
- package/server/dist/schemas/profile.v1.json +137 -137
- package/server/dist/setup-manager.js +52 -8
- package/server/dist/shell-integration/bash-shim.bash +45 -0
- package/server/dist/shell-integration/fish-shim.fish +36 -0
- package/server/dist/shell-integration/powershell-shim.ps1 +48 -0
- package/server/dist/shell-integration/zsh-shim.zsh +47 -0
- package/server/dist/smash-runner.js +1 -0
- package/server/dist/spawn-lifecycle.js +44 -27
- package/server/dist/spec-contract-prompt.js +143 -0
- package/server/dist/spec-draft-parser.js +6 -1
- package/server/dist/spec-models.js +1 -0
- package/server/dist/stuck-run-detector.js +1 -0
- package/server/dist/terminal-manager.js +21 -1
- package/server/dist/terminal-shell-integration.js +4 -1
- package/server/dist/transient-children.js +619 -230
- package/server/dist/util/cli-prompt.js +78 -5
- package/server/dist/util/sqlite-migrations.js +20 -0
- package/server/dist/util/win-spawn.js +18 -3
- package/server/dist/util/windows-provider-shell.js +29 -0
- package/server/dist/verification-sentinel.js +14 -0
- package/server/dist/vitest-setup.js +2 -0
- package/server/dist/windows-job-supervisor.js +133 -0
- package/server/dist/workspace-manager.js +9 -30
- package/server/dist/worktree-manager.js +17 -2
- package/server/dist/worktree-overlay.js +3 -1
- package/client/dist/assets/ActivityFeedPage-tAQcWs1R.js +0 -1
- package/client/dist/assets/AgentBrowserCapture-BX8BNae5.js +0 -1
- package/client/dist/assets/AgentModeAnalyticsPane-BVAqCL0K.js +0 -2
- package/client/dist/assets/AgentModeCodePane-9XfqQc9c.js +0 -2
- package/client/dist/assets/AgentModeJobsPane-BCjLsPhc.js +0 -1
- package/client/dist/assets/AgentsPage-C8J_42sm.js +0 -87
- package/client/dist/assets/AnalyticsPage-BtQuyfJm.js +0 -1
- package/client/dist/assets/CodePage-BZ2MwdCu.js +0 -2
- package/client/dist/assets/DesktopAnalyticsPage-Bh_29V4g.js +0 -1
- package/client/dist/assets/ExportDropdown-BrtfWzEG.js +0 -1
- package/client/dist/assets/InteractiveJobComposer-BCZiSfzc.js +0 -19
- package/client/dist/assets/JobDetailModal-NAJmuYIT.js +0 -1
- package/client/dist/assets/JobDetailPage-fE0ZycUX.js +0 -1
- package/client/dist/assets/JobsPage-z5M_HVJG.js +0 -1
- package/client/dist/assets/LoopBuilderPage-j1FQS47c.js +0 -7
- package/client/dist/assets/LoopPreviewModal-DhDJjdCe.js +0 -1
- package/client/dist/assets/LoopsPage-Ll7zORZb.js +0 -1
- package/client/dist/assets/MinimizedChatsContext-Bd3OqR_S.js +0 -1
- package/client/dist/assets/PluginsPage-DN4kGvJt.js +0 -2
- package/client/dist/assets/ProjectSettingsDialog-OgsgxjzF.js +0 -1
- package/client/dist/assets/ReviewPacketPage-DFog4sXn.js +0 -1
- package/client/dist/assets/TemplatePreviewModal-L2XxqiOD.js +0 -1
- package/client/dist/assets/TicketDetailModal-CsF-AWZX.js +0 -14
- package/client/dist/assets/Trans-Bsz9_gyq.js +0 -1
- package/client/dist/assets/agent-BQgKv_2F.js +0 -1
- package/client/dist/assets/agent-C1NRDJqL.js +0 -1
- package/client/dist/assets/agent-CLNleiy6.js +0 -1
- package/client/dist/assets/agent-CmceArkQ.js +0 -1
- package/client/dist/assets/agent-D3UxQ3SR.js +0 -1
- package/client/dist/assets/agent-DB1JeE64.js +0 -1
- package/client/dist/assets/agent-DXkHcQ-D.js +0 -1
- package/client/dist/assets/agent-DjJJJ2M8.js +0 -1
- package/client/dist/assets/auth-D_5bQv5W.js +0 -1
- package/client/dist/assets/ban-E4EaZe3a.js +0 -1
- package/client/dist/assets/bot-DzuuuC5R.js +0 -1
- package/client/dist/assets/browser-BgqHDMXP.js +0 -1
- package/client/dist/assets/browser-CsKJtrpv.js +0 -1
- package/client/dist/assets/browser-Cu58EpZU.js +0 -1
- package/client/dist/assets/browser-CvXOJm-j.js +0 -1
- package/client/dist/assets/browser-DOrFh1c7.js +0 -1
- package/client/dist/assets/browser-DQv_Jo7x.js +0 -1
- package/client/dist/assets/browser-LPgxvJu2.js +0 -1
- package/client/dist/assets/browser-eL-3MIEI.js +0 -1
- package/client/dist/assets/builder-0IWtosUm.js +0 -1
- package/client/dist/assets/builder-Bf2N6XWn.js +0 -1
- package/client/dist/assets/builder-BnqaaBkT.js +0 -1
- package/client/dist/assets/builder-BxxfGgAO.js +0 -1
- package/client/dist/assets/builder-C5IIgWsq.js +0 -1
- package/client/dist/assets/builder-CHuahItu.js +0 -1
- package/client/dist/assets/builder-CjWosXL_.js +0 -1
- package/client/dist/assets/builder-CpCIOoKj.js +0 -1
- package/client/dist/assets/code-CHPkOkDS.js +0 -1
- package/client/dist/assets/commands-6tYQih5m.js +0 -1
- package/client/dist/assets/commands-BK2QinXN.js +0 -1
- package/client/dist/assets/commands-C2Nca76h.js +0 -1
- package/client/dist/assets/commands-CKdLihNX.js +0 -1
- package/client/dist/assets/commands-CYIBTAlc.js +0 -1
- package/client/dist/assets/commands-CjUtYJIM.js +0 -1
- package/client/dist/assets/commands-Cq_u_8y9.js +0 -1
- package/client/dist/assets/commands-D_ZHYQug.js +0 -1
- package/client/dist/assets/common-6MLbD-jM.js +0 -1
- package/client/dist/assets/common-BKGEu4rm.js +0 -1
- package/client/dist/assets/common-BNbnv8cE.js +0 -1
- package/client/dist/assets/common-BqGWtDbt.js +0 -1
- package/client/dist/assets/common-DBtTzeYm.js +0 -1
- package/client/dist/assets/common-DEW3Nr8n.js +0 -1
- package/client/dist/assets/common-DHsv9N5d.js +0 -1
- package/client/dist/assets/common-mkrEcW-Y.js +0 -1
- package/client/dist/assets/dashboard-B9GhC5ku.js +0 -1
- package/client/dist/assets/dashboard-CBnv6zOI.js +0 -1
- package/client/dist/assets/dashboard-CaP0fU87.js +0 -1
- package/client/dist/assets/dashboard-D4ZZ4x84.js +0 -1
- package/client/dist/assets/dashboard-DmuTQBX8.js +0 -1
- package/client/dist/assets/dashboard-DynLYj3d.js +0 -1
- package/client/dist/assets/dashboard-zj4gGFJ1.js +0 -1
- package/client/dist/assets/dialog-CdWCb02j.js +0 -45
- package/client/dist/assets/dist-bVqfYmby.js +0 -1
- package/client/dist/assets/dist-js-CWeUdf5Z.js +0 -1
- package/client/dist/assets/formatDistanceToNow-DQCvMgUc.js +0 -1
- package/client/dist/assets/getTimezoneOffsetInMilliseconds-C16cxSe1.js +0 -1
- package/client/dist/assets/git-refresh-wTW0rO0Z.js +0 -1
- package/client/dist/assets/i18n-hnX2DPmo.js +0 -2
- package/client/dist/assets/index-DIhMEAVw.js +0 -66
- package/client/dist/assets/index-DwygcU7s.css +0 -2
- package/client/dist/assets/mcp-B8X8wBLu.js +0 -1
- package/client/dist/assets/mcp-C2AojZZN.js +0 -1
- package/client/dist/assets/mcp-D8BT78_L.js +0 -1
- package/client/dist/assets/mcp-Df5RWBNk.js +0 -1
- package/client/dist/assets/mcp-Dj7BgMQW.js +0 -1
- package/client/dist/assets/mcp-Q7iT7rcz.js +0 -1
- package/client/dist/assets/mcp-YlvNvJbW.js +0 -1
- package/client/dist/assets/mcp-mKFpTSRb.js +0 -1
- package/client/dist/assets/narration-4Z2VUhZw.js +0 -1
- package/client/dist/assets/narration-BGuiEDj3.js +0 -1
- package/client/dist/assets/narration-BuSoqRmv.js +0 -1
- package/client/dist/assets/narration-CB9t29fy.js +0 -1
- package/client/dist/assets/narration-CU3x8FHD.js +0 -1
- package/client/dist/assets/narration-CWeXhfP5.js +0 -1
- package/client/dist/assets/narration-DRaDnhT5.js +0 -1
- package/client/dist/assets/narration-DtEbQgCw.js +0 -1
- package/client/dist/assets/nav-ApJVg3xu.js +0 -1
- package/client/dist/assets/nav-BKNky1Bg.js +0 -1
- package/client/dist/assets/nav-C6vWWKYx.js +0 -1
- package/client/dist/assets/nav-CXJ6Aw89.js +0 -1
- package/client/dist/assets/nav-CsmFBIDf.js +0 -1
- package/client/dist/assets/nav-DjkmQJjd.js +0 -1
- package/client/dist/assets/packet-B1IxaL5f.js +0 -1
- package/client/dist/assets/packet-Bh5kkbiB.js +0 -1
- package/client/dist/assets/packet-By8fqYxW.js +0 -1
- package/client/dist/assets/packet-CZdvA44E.js +0 -1
- package/client/dist/assets/packet-CrjHRQCP.js +0 -1
- package/client/dist/assets/packet-Dwi2pTtx.js +0 -1
- package/client/dist/assets/packet-_-ZIa0IR.js +0 -1
- package/client/dist/assets/packet-n0W6E1Hn.js +0 -1
- package/client/dist/assets/play-DNlrawbS.js +0 -1
- package/client/dist/assets/provider-capabilities-Doej9lfa.js +0 -1
- package/client/dist/assets/settings-Bd0x4TBa.js +0 -1
- package/client/dist/assets/settings-C1-7cXzC.js +0 -1
- package/client/dist/assets/settings-CAFaT38b.js +0 -1
- package/client/dist/assets/settings-Ct3v1nW2.js +0 -1
- package/client/dist/assets/settings-DHh7_IF5.js +0 -1
- package/client/dist/assets/settings-DQXAmdcv.js +0 -1
- package/client/dist/assets/settings-guzlhpup.js +0 -1
- package/client/dist/assets/settings-sZfTPMEH.js +0 -1
- package/client/dist/assets/setup-3jWaoVUO.js +0 -1
- package/client/dist/assets/setup-BjgRneb2.js +0 -1
- package/client/dist/assets/setup-BzFIjv-f.js +0 -1
- package/client/dist/assets/setup-C4VfQsxE.js +0 -1
- package/client/dist/assets/setup-DfUkpDbN.js +0 -1
- package/client/dist/assets/setup-ECe90Pmu.js +0 -1
- package/client/dist/assets/setup-dlqC4Jmm.js +0 -1
- package/client/dist/assets/setup-jwfLMiM2.js +0 -1
- package/client/dist/assets/spending-EC9xqio-.js +0 -1
- package/client/dist/assets/useDesktop-BQVt8lFd.js +0 -1
package/server/dist/repo-lock.js
CHANGED
|
@@ -1,25 +1,100 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
2
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.repositoryLockKey = repositoryLockKey;
|
|
3
37
|
exports.withRepoLock = withRepoLock;
|
|
38
|
+
exports.withRepoLocks = withRepoLocks;
|
|
4
39
|
exports.__resetRepoLocks = __resetRepoLocks;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
* a new call waits for the previous one on the same key before running. Used so
|
|
8
|
-
* concurrent rail merge-backs never run `git merge`/`reset` on the SAME base repo
|
|
9
|
-
* at the same time (two single-ticket rails launched together are concurrent
|
|
10
|
-
* writers). Different keys run in parallel.
|
|
11
|
-
*/
|
|
40
|
+
const fs = __importStar(require("fs"));
|
|
41
|
+
const path = __importStar(require("path"));
|
|
12
42
|
const chains = new Map();
|
|
13
|
-
function
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
43
|
+
function canonicalPath(value) {
|
|
44
|
+
try {
|
|
45
|
+
return fs.realpathSync.native(value);
|
|
46
|
+
}
|
|
47
|
+
catch {
|
|
48
|
+
return path.resolve(value);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
/** A worktree, symlink and main checkout share the same Git object/ref store.
|
|
52
|
+
* Resolve it on every admission: a moved checkout must not inherit a stale key. */
|
|
53
|
+
function repositoryLockKey(repositoryPath) {
|
|
54
|
+
if (!fs.existsSync(repositoryPath))
|
|
55
|
+
return canonicalPath(repositoryPath);
|
|
56
|
+
let current = canonicalPath(repositoryPath);
|
|
57
|
+
while (true) {
|
|
58
|
+
const dotGit = path.join(current, '.git');
|
|
59
|
+
try {
|
|
60
|
+
let gitDir = dotGit;
|
|
61
|
+
if (fs.statSync(dotGit).isFile()) {
|
|
62
|
+
const match = /^gitdir:\s*(.+)\s*$/m.exec(fs.readFileSync(dotGit, 'utf8'));
|
|
63
|
+
if (!match)
|
|
64
|
+
break;
|
|
65
|
+
gitDir = path.resolve(current, match[1].trim());
|
|
66
|
+
}
|
|
67
|
+
const commonFile = path.join(gitDir, 'commondir');
|
|
68
|
+
if (fs.existsSync(commonFile))
|
|
69
|
+
gitDir = path.resolve(gitDir, fs.readFileSync(commonFile, 'utf8').trim());
|
|
70
|
+
return canonicalPath(gitDir);
|
|
71
|
+
}
|
|
72
|
+
catch { /* walk upward for paths inside a checkout */ }
|
|
73
|
+
const parent = path.dirname(current);
|
|
74
|
+
if (parent === current)
|
|
75
|
+
break;
|
|
76
|
+
current = parent;
|
|
77
|
+
}
|
|
78
|
+
return canonicalPath(repositoryPath);
|
|
79
|
+
}
|
|
80
|
+
function withKeyLock(key, fn) {
|
|
81
|
+
const previous = chains.get(key) ?? Promise.resolve();
|
|
82
|
+
const run = previous.catch(() => undefined).then(fn);
|
|
83
|
+
const tail = run.then(() => undefined, () => undefined);
|
|
84
|
+
chains.set(key, tail);
|
|
85
|
+
void tail.then(() => { if (chains.get(key) === tail)
|
|
86
|
+
chains.delete(key); });
|
|
20
87
|
return run;
|
|
21
88
|
}
|
|
22
|
-
/**
|
|
23
|
-
function
|
|
24
|
-
|
|
89
|
+
/** Process-local mutex over the canonical Git common directory. */
|
|
90
|
+
function withRepoLock(repositoryPath, fn) {
|
|
91
|
+
return withKeyLock(repositoryLockKey(repositoryPath), fn);
|
|
92
|
+
}
|
|
93
|
+
/** Acquire each physical repository exactly once, in stable order. Callers must
|
|
94
|
+
* not re-enter withRepoLock from fn; compose effects under this one admission. */
|
|
95
|
+
function withRepoLocks(repositoryPaths, fn) {
|
|
96
|
+
const keys = [...new Set(repositoryPaths.map(repositoryLockKey))].sort();
|
|
97
|
+
const enter = (index) => index === keys.length ? Promise.resolve().then(fn) : withKeyLock(keys[index], () => enter(index + 1));
|
|
98
|
+
return enter(0);
|
|
25
99
|
}
|
|
100
|
+
function __resetRepoLocks() { chains.clear(); }
|
|
@@ -9,23 +9,31 @@ const delivery_evidence_1 = require("./delivery-evidence");
|
|
|
9
9
|
const rail_pr_store_1 = require("./rail-pr-store");
|
|
10
10
|
const pr_body_1 = require("./pr-body");
|
|
11
11
|
const ai_invocations_1 = require("./ai-invocations");
|
|
12
|
+
const project_repository_provenance_1 = require("./project-repository-provenance");
|
|
12
13
|
const TEST_FILE_RE = /(\.test\.|\.spec\.|(^|\/)__tests__\/)/;
|
|
13
|
-
function churnForRuns(db, runIds) {
|
|
14
|
+
function churnForRuns(db, runIds, repository) {
|
|
14
15
|
const ids = [...new Set(runIds.filter((id) => typeof id === 'string' && id.length > 0))];
|
|
15
16
|
if (ids.length === 0)
|
|
16
17
|
return [];
|
|
17
18
|
const placeholders = ids.map(() => '?').join(', ');
|
|
18
19
|
try {
|
|
20
|
+
const scope = (0, project_repository_provenance_1.provenanceRepositoryFilter)(db, repository, 'p');
|
|
21
|
+
const hasRepository = db.prepare('PRAGMA table_info(file_provenance)').all().some(column => column.name === 'repository_id');
|
|
19
22
|
return db.prepare(`
|
|
20
|
-
SELECT job_id, file_path, added_lines, removed_lines
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
23
|
+
SELECT c.job_id, c.file_path, c.added_lines, c.removed_lines,
|
|
24
|
+
${hasRepository ? 'p.repository_id' : 'NULL'} AS repository_id
|
|
25
|
+
FROM file_story_contributions c
|
|
26
|
+
LEFT JOIN file_provenance p ON p.id = c.provenance_id
|
|
27
|
+
WHERE c.job_id IN (${placeholders}) AND ${scope.sql}
|
|
28
|
+
`).all(...ids, ...scope.params);
|
|
24
29
|
}
|
|
25
30
|
catch {
|
|
26
31
|
return [];
|
|
27
32
|
}
|
|
28
33
|
}
|
|
34
|
+
function churnIdentity(row) {
|
|
35
|
+
return JSON.stringify([row.repository_id ?? null, row.file_path]);
|
|
36
|
+
}
|
|
29
37
|
/**
|
|
30
38
|
* Variant selection reads ONLY durable outcomes. `no-changes` must win over
|
|
31
39
|
* `success` (a run that changed nothing has nothing to show), and a mixed batch
|
|
@@ -57,8 +65,8 @@ exports.HUMAN_REVIEW_BAND = { min: 50, max: 69 };
|
|
|
57
65
|
function buildProof(units, evidence, churn, confidence) {
|
|
58
66
|
const proof = [];
|
|
59
67
|
// ── Tier 1: what Specrails measured itself ────────────────────────────────
|
|
60
|
-
const testFiles = [...new Set(churn.filter((row) => TEST_FILE_RE.test(row.file_path)).map(
|
|
61
|
-
const totalFiles = new Set(churn.map(
|
|
68
|
+
const testFiles = [...new Set(churn.filter((row) => TEST_FILE_RE.test(row.file_path)).map(churnIdentity))];
|
|
69
|
+
const totalFiles = new Set(churn.map(churnIdentity)).size;
|
|
62
70
|
const added = churn.reduce((sum, row) => sum + (row.added_lines || 0), 0);
|
|
63
71
|
const removed = churn.reduce((sum, row) => sum + (row.removed_lines || 0), 0);
|
|
64
72
|
if (totalFiles > 0) {
|
|
@@ -203,13 +211,14 @@ function computeDriftNudges(input) {
|
|
|
203
211
|
}
|
|
204
212
|
return nudges;
|
|
205
213
|
}
|
|
206
|
-
function composeReviewPacket({ db, row }) {
|
|
214
|
+
function composeReviewPacket({ db, row, repositoryId = row.repository_id ?? undefined, includeLegacyProvenance = false }) {
|
|
215
|
+
const repository = repositoryId ? { repositoryId, includeLegacy: includeLegacyProvenance } : undefined;
|
|
207
216
|
const ticketIds = safeParse(row.ticket_ids, []);
|
|
208
217
|
const units = safeParse(row.branches, []);
|
|
209
218
|
const runIds = safeParse(row.run_ids, []);
|
|
210
219
|
const snapshot = (0, rail_pr_store_1.readSpecSnapshot)(row.spec_snapshot);
|
|
211
220
|
const evidence = (0, delivery_evidence_1.readSettleEvidence)(row.settle_evidence);
|
|
212
|
-
const churn = churnForRuns(db, runIds);
|
|
221
|
+
const churn = churnForRuns(db, runIds, repository);
|
|
213
222
|
const variant = selectVariant(row, units);
|
|
214
223
|
const confidence = (evidence?.units ?? [])
|
|
215
224
|
.map((unit) => unit.confidence)
|
|
@@ -236,10 +245,10 @@ function composeReviewPacket({ db, row }) {
|
|
|
236
245
|
deliveryOutcome: unitRows[0]?.deliveryOutcome ?? null,
|
|
237
246
|
changed: unitRows[0]?.changed ?? null,
|
|
238
247
|
churn: unitChurn === null ? null : {
|
|
239
|
-
filesTouched: new Set(unitChurn.map(
|
|
248
|
+
filesTouched: new Set(unitChurn.map(churnIdentity)).size,
|
|
240
249
|
addedLines: unitChurn.reduce((sum, c) => sum + (c.added_lines || 0), 0),
|
|
241
250
|
removedLines: unitChurn.reduce((sum, c) => sum + (c.removed_lines || 0), 0),
|
|
242
|
-
testFilesTouched: [...new Set(unitChurn.filter((c) => TEST_FILE_RE.test(c.file_path)).map((c) => c.file_path))],
|
|
251
|
+
testFilesTouched: [...new Set(unitChurn.filter((c) => TEST_FILE_RE.test(c.file_path)).map((c) => !repositoryId && c.repository_id ? `${c.repository_id}:${c.file_path}` : c.file_path))],
|
|
243
252
|
},
|
|
244
253
|
runIds: unitRunIds,
|
|
245
254
|
};
|
|
@@ -270,15 +279,16 @@ function composeReviewPacket({ db, row }) {
|
|
|
270
279
|
// a revision touching mostly new files is the honest signal that the spec no
|
|
271
280
|
// longer describes the work.
|
|
272
281
|
const originalFiles = chain.length > 1
|
|
273
|
-
? new Set(churnForRuns(db, safeParse(chain[0].run_ids, [])).map(
|
|
282
|
+
? new Set(churnForRuns(db, safeParse(chain[0].run_ids, []), repository).map(churnIdentity))
|
|
274
283
|
: new Set();
|
|
275
284
|
const driftNudges = computeDriftNudges({
|
|
276
285
|
versions,
|
|
277
286
|
originalFileSet: originalFiles,
|
|
278
|
-
currentFiles: new Set(churn.map(
|
|
287
|
+
currentFiles: new Set(churn.map(churnIdentity)),
|
|
279
288
|
});
|
|
280
289
|
return {
|
|
281
290
|
schemaVersion: 1,
|
|
291
|
+
...(repositoryId ? { repositoryId } : {}),
|
|
282
292
|
prDeliveryId: row.id,
|
|
283
293
|
railIndex: row.rail_index,
|
|
284
294
|
variant,
|
|
@@ -1,62 +1,62 @@
|
|
|
1
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
|
-
}
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://raw.githubusercontent.com/fjpulidop/specrails-desktop/main/server/schemas/file-summary.v1.json",
|
|
4
|
+
"title": "specrails-desktop file summary (v1)",
|
|
5
|
+
"description": "On-disk JSON shape for an AI-generated file summary persisted under <project>/.specrails/file-summaries/<sha256-of-rel-path>.json.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": [
|
|
8
|
+
"schemaVersion",
|
|
9
|
+
"path",
|
|
10
|
+
"fileHash",
|
|
11
|
+
"summary",
|
|
12
|
+
"language",
|
|
13
|
+
"generatedAt",
|
|
14
|
+
"generatedBy",
|
|
15
|
+
"triggeredBy"
|
|
16
|
+
],
|
|
17
|
+
"additionalProperties": false,
|
|
18
|
+
"properties": {
|
|
19
|
+
"schemaVersion": {
|
|
20
|
+
"const": 1
|
|
21
|
+
},
|
|
22
|
+
"path": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"minLength": 1
|
|
25
|
+
},
|
|
26
|
+
"fileHash": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
29
|
+
},
|
|
30
|
+
"summary": {
|
|
31
|
+
"type": "string"
|
|
32
|
+
},
|
|
33
|
+
"language": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"enum": ["en", "es"]
|
|
36
|
+
},
|
|
37
|
+
"generatedAt": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"format": "date-time"
|
|
40
|
+
},
|
|
41
|
+
"generatedBy": {
|
|
42
|
+
"type": "object",
|
|
43
|
+
"required": ["model", "promptVersion"],
|
|
44
|
+
"additionalProperties": false,
|
|
45
|
+
"properties": {
|
|
46
|
+
"model": { "type": "string", "minLength": 1 },
|
|
47
|
+
"promptVersion": { "type": "integer", "minimum": 1 },
|
|
48
|
+
"truncated": { "type": "boolean" }
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"triggeredBy": {
|
|
52
|
+
"type": "object",
|
|
53
|
+
"required": ["kind", "id", "ticketId"],
|
|
54
|
+
"additionalProperties": false,
|
|
55
|
+
"properties": {
|
|
56
|
+
"kind": { "type": "string", "enum": ["job", "user"] },
|
|
57
|
+
"id": { "type": "string", "minLength": 1 },
|
|
58
|
+
"ticketId": { "type": ["integer", "null"] }
|
|
59
|
+
}
|
|
61
60
|
}
|
|
61
|
+
}
|
|
62
62
|
}
|
|
@@ -1,150 +1,150 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://raw.githubusercontent.com/fjpulidop/specrails-desktop/main/server/schemas/profile.v1.json",
|
|
4
|
+
"title": "specrails agent profile (v1)",
|
|
5
|
+
"description": "Declarative configuration for the specrails implement pipeline. Describes which agents participate, which models they run with, and how tasks are routed to specialists. Consumed by `implement.md` and produced by tools like specrails-desktop. This is specrails-desktop's derivative of specrails-core's canonical v1 profile schema: it adds the optional top-level `provider` field and relaxes `modelAlias` to any non-empty string (provider-catalog validation happens in profile-manager.validateStructural). Per core's schema-identity contract, a diverging vendored copy must carry its own $id — only byte-identical copies may share the canonical core $id.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["schemaVersion", "name", "orchestrator", "agents", "routing"],
|
|
8
|
+
"additionalProperties": false,
|
|
9
|
+
"properties": {
|
|
10
|
+
"schemaVersion": {
|
|
11
|
+
"const": 1,
|
|
12
|
+
"description": "Profile schema version. v1 is the only supported value at this time."
|
|
13
|
+
},
|
|
14
|
+
"name": {
|
|
15
|
+
"type": "string",
|
|
16
|
+
"pattern": "^[a-z0-9][a-z0-9-]*$",
|
|
17
|
+
"minLength": 1,
|
|
18
|
+
"maxLength": 64,
|
|
19
|
+
"description": "Human-readable identifier for this profile (kebab-case)."
|
|
20
|
+
},
|
|
21
|
+
"description": {
|
|
22
|
+
"type": "string",
|
|
23
|
+
"maxLength": 512,
|
|
24
|
+
"description": "Optional short summary of when to use this profile."
|
|
25
|
+
},
|
|
26
|
+
"provider": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"pattern": "^[a-z0-9][a-z0-9-]*$",
|
|
29
|
+
"description": "Optional registered provider id (for example `claude`, `codex`, `gemini`, or `kimi`). When set, the profile's model values are validated according to that provider adapter: normally against its catalog, while adapters that support configured aliases (such as Kimi) accept any schema-valid non-empty alias. When omitted, validation falls back to the project's resolved provider."
|
|
30
|
+
},
|
|
31
|
+
"orchestrator": {
|
|
32
|
+
"type": "object",
|
|
33
|
+
"required": ["model"],
|
|
34
|
+
"additionalProperties": false,
|
|
35
|
+
"properties": {
|
|
36
|
+
"model": {
|
|
37
|
+
"$ref": "#/$defs/modelAlias",
|
|
38
|
+
"description": "Model used to run the top-level implement orchestrator. The JSON schema accepts any non-empty string; provider-specific validation runs at the structural-check layer (see profile-manager.validateStructural)."
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"agents": {
|
|
43
|
+
"type": "array",
|
|
44
|
+
"minItems": 1,
|
|
45
|
+
"items": { "$ref": "#/$defs/agentEntry" },
|
|
46
|
+
"description": "Ordered chain of agents that participate in the pipeline when this profile is active. Every profile (default + custom) must include the baseline trio (sr-architect, sr-developer, sr-reviewer) — the pipeline depends on all three. Custom profiles add optional agents on top of the baseline. sr-merge-resolver is an optional utility agent and is no longer required.",
|
|
47
|
+
"allOf": [
|
|
48
|
+
{
|
|
49
|
+
"description": "Required baseline agent: sr-architect",
|
|
50
|
+
"contains": {
|
|
51
|
+
"type": "object",
|
|
52
|
+
"properties": { "id": { "const": "sr-architect" } },
|
|
53
|
+
"required": ["id"]
|
|
54
|
+
}
|
|
25
55
|
},
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
"
|
|
56
|
+
{
|
|
57
|
+
"description": "Required baseline agent: sr-developer",
|
|
58
|
+
"contains": {
|
|
59
|
+
"type": "object",
|
|
60
|
+
"properties": { "id": { "const": "sr-developer" } },
|
|
61
|
+
"required": ["id"]
|
|
62
|
+
}
|
|
30
63
|
},
|
|
31
|
-
|
|
64
|
+
{
|
|
65
|
+
"description": "Required baseline agent: sr-reviewer",
|
|
66
|
+
"contains": {
|
|
32
67
|
"type": "object",
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
68
|
+
"properties": { "id": { "const": "sr-reviewer" } },
|
|
69
|
+
"required": ["id"]
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
]
|
|
73
|
+
},
|
|
74
|
+
"routing": {
|
|
75
|
+
"type": "array",
|
|
76
|
+
"minItems": 0,
|
|
77
|
+
"description": "Ordered routing rules. The first rule whose `tags` intersects the task's tag set wins. If a `default: true` entry is present it MUST be the last element. Custom profiles may omit routing entirely — tasks then fall through to the first developer-shaped agent in the chain.",
|
|
78
|
+
"items": { "$ref": "#/$defs/routingRule" }
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
"$defs": {
|
|
82
|
+
"modelAlias": {
|
|
83
|
+
"type": "string",
|
|
84
|
+
"minLength": 1,
|
|
85
|
+
"description": "Accepted model alias. JSON schema accepts any non-empty string without truncating provider-configured aliases; provider-specific catalog enforcement runs at runtime (see profile-manager.validateStructural)."
|
|
86
|
+
},
|
|
87
|
+
"agentEntry": {
|
|
88
|
+
"type": "object",
|
|
89
|
+
"required": ["id"],
|
|
90
|
+
"additionalProperties": false,
|
|
91
|
+
"properties": {
|
|
92
|
+
"id": {
|
|
93
|
+
"type": "string",
|
|
94
|
+
"pattern": "^(sr|custom)-[a-z0-9][a-z0-9-]*$",
|
|
95
|
+
"description": "Agent identifier. MUST correspond to the selected provider's provider-native role artifact. File-based providers use their own agents catalog (for example `.claude/agents/<id>.md`); Kimi uses the directly discoverable `.kimi-code/skills/<id>/SKILL.md` layout."
|
|
41
96
|
},
|
|
42
|
-
"
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
"items": { "$ref": "#/$defs/agentEntry" },
|
|
46
|
-
"description": "Ordered chain of agents that participate in the pipeline when this profile is active. Every profile (default + custom) must include the baseline trio (sr-architect, sr-developer, sr-reviewer) — the pipeline depends on all three. Custom profiles add optional agents on top of the baseline. sr-merge-resolver is an optional utility agent and is no longer required.",
|
|
47
|
-
"allOf": [
|
|
48
|
-
{
|
|
49
|
-
"description": "Required baseline agent: sr-architect",
|
|
50
|
-
"contains": {
|
|
51
|
-
"type": "object",
|
|
52
|
-
"properties": { "id": { "const": "sr-architect" } },
|
|
53
|
-
"required": ["id"]
|
|
54
|
-
}
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
"description": "Required baseline agent: sr-developer",
|
|
58
|
-
"contains": {
|
|
59
|
-
"type": "object",
|
|
60
|
-
"properties": { "id": { "const": "sr-developer" } },
|
|
61
|
-
"required": ["id"]
|
|
62
|
-
}
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
"description": "Required baseline agent: sr-reviewer",
|
|
66
|
-
"contains": {
|
|
67
|
-
"type": "object",
|
|
68
|
-
"properties": { "id": { "const": "sr-reviewer" } },
|
|
69
|
-
"required": ["id"]
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
]
|
|
97
|
+
"model": {
|
|
98
|
+
"$ref": "#/$defs/modelAlias",
|
|
99
|
+
"description": "Model override for this agent when this profile is active. When omitted, the agent's frontmatter `model:` is used as a fallback."
|
|
73
100
|
},
|
|
74
|
-
"
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
"items": { "$ref": "#/$defs/routingRule" }
|
|
101
|
+
"required": {
|
|
102
|
+
"type": "boolean",
|
|
103
|
+
"default": false,
|
|
104
|
+
"description": "If true, the agent cannot be routed past. Baseline agents (sr-architect, sr-developer, sr-reviewer) SHOULD be marked required. sr-merge-resolver is optional and defaults to required: false."
|
|
79
105
|
}
|
|
106
|
+
}
|
|
80
107
|
},
|
|
81
|
-
"
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
"
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
"
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
"required": {
|
|
102
|
-
"type": "boolean",
|
|
103
|
-
"default": false,
|
|
104
|
-
"description": "If true, the agent cannot be routed past. Baseline agents (sr-architect, sr-developer, sr-reviewer) SHOULD be marked required. sr-merge-resolver is optional and defaults to required: false."
|
|
105
|
-
}
|
|
108
|
+
"routingRule": {
|
|
109
|
+
"oneOf": [
|
|
110
|
+
{
|
|
111
|
+
"type": "object",
|
|
112
|
+
"required": ["tags", "agent"],
|
|
113
|
+
"additionalProperties": false,
|
|
114
|
+
"properties": {
|
|
115
|
+
"tags": {
|
|
116
|
+
"type": "array",
|
|
117
|
+
"minItems": 1,
|
|
118
|
+
"items": {
|
|
119
|
+
"type": "string",
|
|
120
|
+
"pattern": "^[a-z0-9][a-z0-9-]*$"
|
|
121
|
+
},
|
|
122
|
+
"description": "Task tags that trigger this rule. Rule wins if any tag intersects."
|
|
123
|
+
},
|
|
124
|
+
"agent": {
|
|
125
|
+
"type": "string",
|
|
126
|
+
"pattern": "^(sr|custom)-[a-z0-9][a-z0-9-]*$",
|
|
127
|
+
"description": "Agent to route the task to when this rule wins."
|
|
106
128
|
}
|
|
129
|
+
}
|
|
107
130
|
},
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
},
|
|
124
|
-
"agent": {
|
|
125
|
-
"type": "string",
|
|
126
|
-
"pattern": "^(sr|custom)-[a-z0-9][a-z0-9-]*$",
|
|
127
|
-
"description": "Agent to route the task to when this rule wins."
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
},
|
|
131
|
-
{
|
|
132
|
-
"type": "object",
|
|
133
|
-
"required": ["default", "agent"],
|
|
134
|
-
"additionalProperties": false,
|
|
135
|
-
"properties": {
|
|
136
|
-
"default": {
|
|
137
|
-
"const": true,
|
|
138
|
-
"description": "Marks this rule as the terminal catch-all. Exactly one entry with `default: true` is allowed, and it MUST be the last element of `routing`."
|
|
139
|
-
},
|
|
140
|
-
"agent": {
|
|
141
|
-
"type": "string",
|
|
142
|
-
"pattern": "^(sr|custom)-[a-z0-9][a-z0-9-]*$",
|
|
143
|
-
"description": "Agent to route the task to when no earlier rule matched."
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
]
|
|
131
|
+
{
|
|
132
|
+
"type": "object",
|
|
133
|
+
"required": ["default", "agent"],
|
|
134
|
+
"additionalProperties": false,
|
|
135
|
+
"properties": {
|
|
136
|
+
"default": {
|
|
137
|
+
"const": true,
|
|
138
|
+
"description": "Marks this rule as the terminal catch-all. Exactly one entry with `default: true` is allowed, and it MUST be the last element of `routing`."
|
|
139
|
+
},
|
|
140
|
+
"agent": {
|
|
141
|
+
"type": "string",
|
|
142
|
+
"pattern": "^(sr|custom)-[a-z0-9][a-z0-9-]*$",
|
|
143
|
+
"description": "Agent to route the task to when no earlier rule matched."
|
|
144
|
+
}
|
|
145
|
+
}
|
|
148
146
|
}
|
|
147
|
+
]
|
|
149
148
|
}
|
|
149
|
+
}
|
|
150
150
|
}
|