@maycombhq/atticus 0.0.0-stage → 2.0.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +177 -0
- package/README.md +17 -2
- package/THIRD-PARTY-LICENSES.txt +2607 -0
- package/dist/bin.js +47 -0
- package/dist/chunk-23W7VWKR.js +2609 -0
- package/dist/chunk-2C5B464C.js +106 -0
- package/dist/chunk-2LLFKP7C.js +53 -0
- package/dist/chunk-2MD7TXSG.js +166 -0
- package/dist/chunk-2UIQBDJO.js +131 -0
- package/dist/chunk-32MPK524.js +378 -0
- package/dist/chunk-3ALD2W2A.js +95 -0
- package/dist/chunk-3G4YI4ZU.js +16 -0
- package/dist/chunk-4AK7IBVP.js +915 -0
- package/dist/chunk-4BMDGTED.js +69 -0
- package/dist/chunk-4NDAAFQT.js +103 -0
- package/dist/chunk-4Q3NN7VF.js +32 -0
- package/dist/chunk-4RS5KZQD.js +25 -0
- package/dist/chunk-4SKZDI62.js +22 -0
- package/dist/chunk-55YODD3N.js +385 -0
- package/dist/chunk-56YQ6ROQ.js +3479 -0
- package/dist/chunk-5A5L3T2U.js +583 -0
- package/dist/chunk-5FEOD73Z.js +374 -0
- package/dist/chunk-5GDRCDQB.js +32 -0
- package/dist/chunk-5WS2YOGD.js +95 -0
- package/dist/chunk-65NYPGRC.js +766 -0
- package/dist/chunk-6BVONWJ7.js +50 -0
- package/dist/chunk-6D4FRTFF.js +53 -0
- package/dist/chunk-6GPJOFV4.js +149 -0
- package/dist/chunk-6JCPI55B.js +92 -0
- package/dist/chunk-6JUBZBMW.js +56 -0
- package/dist/chunk-6SCVQZX5.js +2522 -0
- package/dist/chunk-6TACQN3N.js +41 -0
- package/dist/chunk-72TXNLOC.js +496 -0
- package/dist/chunk-76WKMA4J.js +14 -0
- package/dist/chunk-7EFILTCI.js +67 -0
- package/dist/chunk-7EKXJZ2Y.js +2902 -0
- package/dist/chunk-7EOBHUMC.js +133 -0
- package/dist/chunk-7JUKDRSZ.js +1726 -0
- package/dist/chunk-7NN5VWDC.js +43 -0
- package/dist/chunk-7UFQZXZA.js +5949 -0
- package/dist/chunk-A3KPZJ5M.js +131 -0
- package/dist/chunk-A6AC72A5.js +48 -0
- package/dist/chunk-A7KZKIZX.js +166 -0
- package/dist/chunk-ABWHYWNI.js +101 -0
- package/dist/chunk-AFFIK6JI.js +46 -0
- package/dist/chunk-AHOQZ4OK.js +37 -0
- package/dist/chunk-AVJDSJ2F.js +18 -0
- package/dist/chunk-AXXCPAP6.js +203 -0
- package/dist/chunk-AY3QXYMB.js +41 -0
- package/dist/chunk-B2OKWJIU.js +143 -0
- package/dist/chunk-B632FH3I.js +251 -0
- package/dist/chunk-BLW4SXCU.js +38 -0
- package/dist/chunk-BVS2K73A.js +33 -0
- package/dist/chunk-BWZ77RQT.js +25 -0
- package/dist/chunk-BYBUDX4T.js +163 -0
- package/dist/chunk-BYZCY6SP.js +230 -0
- package/dist/chunk-C6EKFH7J.js +169 -0
- package/dist/chunk-C6MZFGN7.js +271 -0
- package/dist/chunk-CAQZUNOH.js +1150 -0
- package/dist/chunk-CD4XHYGY.js +856 -0
- package/dist/chunk-CEZQOLEO.js +1217 -0
- package/dist/chunk-CHWTETW7.js +128 -0
- package/dist/chunk-CMV7TGU6.js +31 -0
- package/dist/chunk-CNUKCS2T.js +2741 -0
- package/dist/chunk-CP3L3FH7.js +549 -0
- package/dist/chunk-CPGCA6GZ.js +41 -0
- package/dist/chunk-CWM6KM5G.js +315 -0
- package/dist/chunk-CXDSTRUJ.js +873 -0
- package/dist/chunk-D3PO4DOZ.js +261 -0
- package/dist/chunk-DFBCSHVT.js +69 -0
- package/dist/chunk-DHPACDG7.js +104 -0
- package/dist/chunk-DPC5Y5DL.js +3898 -0
- package/dist/chunk-DPUYDDQG.js +164 -0
- package/dist/chunk-DQN7TF5D.js +325 -0
- package/dist/chunk-EADP3PEN.js +450 -0
- package/dist/chunk-ED2LWWIP.js +878 -0
- package/dist/chunk-EHVTK3UE.js +116 -0
- package/dist/chunk-EPTBZ3GP.js +101 -0
- package/dist/chunk-EXIMEJ2X.js +545 -0
- package/dist/chunk-EYWIDJFU.js +130 -0
- package/dist/chunk-F44OMYIN.js +54 -0
- package/dist/chunk-F7HYOUFF.js +287 -0
- package/dist/chunk-FALXWAMD.js +182 -0
- package/dist/chunk-FBNPE7HS.js +49 -0
- package/dist/chunk-FSWUD5QB.js +108 -0
- package/dist/chunk-FVQISWPW.js +296 -0
- package/dist/chunk-G2B4ZQGH.js +240 -0
- package/dist/chunk-GK6XK5SP.js +1227 -0
- package/dist/chunk-GLEBK5L3.js +34 -0
- package/dist/chunk-GNB5QDDI.js +25 -0
- package/dist/chunk-GQ4N4WKF.js +1142 -0
- package/dist/chunk-GRMR5TRQ.js +119 -0
- package/dist/chunk-HC6XKREB.js +334 -0
- package/dist/chunk-HFQCFSJR.js +60 -0
- package/dist/chunk-HJDICQA4.js +102 -0
- package/dist/chunk-HLJAXMM4.js +233 -0
- package/dist/chunk-HVIMMDVB.js +162 -0
- package/dist/chunk-HZVLAPN5.js +32 -0
- package/dist/chunk-I3E7CX4H.js +155 -0
- package/dist/chunk-IQFTZ37C.js +2919 -0
- package/dist/chunk-ITY3VJRX.js +285 -0
- package/dist/chunk-JBTK5OP2.js +55 -0
- package/dist/chunk-JPGCERE2.js +26 -0
- package/dist/chunk-JQDNHIBC.js +38 -0
- package/dist/chunk-JRBCWLOR.js +307 -0
- package/dist/chunk-JRZQA2JM.js +212 -0
- package/dist/chunk-KCBJCA66.js +45 -0
- package/dist/chunk-KJPMEAI4.js +705 -0
- package/dist/chunk-KQDZXGNR.js +14 -0
- package/dist/chunk-KUUQR4HA.js +264 -0
- package/dist/chunk-L24C55VN.js +7923 -0
- package/dist/chunk-L3BX5ZIB.js +400 -0
- package/dist/chunk-L6SGQIR3.js +471 -0
- package/dist/chunk-LBENYT3H.js +66 -0
- package/dist/chunk-LNAJW6FB.js +47 -0
- package/dist/chunk-MC3H7736.js +19910 -0
- package/dist/chunk-MMOSZPWJ.js +273 -0
- package/dist/chunk-MXCHWULV.js +285 -0
- package/dist/chunk-N3E56YPN.js +344 -0
- package/dist/chunk-NHFQMOVK.js +180 -0
- package/dist/chunk-NQU6KNQF.js +27 -0
- package/dist/chunk-OIK5YPTN.js +391 -0
- package/dist/chunk-OLWFG75W.js +4330 -0
- package/dist/chunk-ONPUIE7Y.js +29 -0
- package/dist/chunk-OW7D2PJL.js +376 -0
- package/dist/chunk-P63VL4HE.js +2357 -0
- package/dist/chunk-PA4YNUMU.js +45 -0
- package/dist/chunk-PAMPPUR6.js +4500 -0
- package/dist/chunk-PBS3OFNN.js +113 -0
- package/dist/chunk-PFT3VTS4.js +214 -0
- package/dist/chunk-PFTA6BZF.js +49 -0
- package/dist/chunk-PNN5KLAY.js +119 -0
- package/dist/chunk-PRPPGYZG.js +104 -0
- package/dist/chunk-PUKEZ37F.js +666 -0
- package/dist/chunk-Q3HOFXZJ.js +76 -0
- package/dist/chunk-Q5AMFEWD.js +119 -0
- package/dist/chunk-QKRNMBJO.js +80 -0
- package/dist/chunk-QSU47IQ5.js +36 -0
- package/dist/chunk-QSXK2RGH.js +688 -0
- package/dist/chunk-QXNWYUYI.js +52 -0
- package/dist/chunk-R6RY4Q5T.js +51 -0
- package/dist/chunk-RCU3MPY2.js +1496 -0
- package/dist/chunk-RLIB4JUN.js +174 -0
- package/dist/chunk-RYSCLMU3.js +1991 -0
- package/dist/chunk-RZUZ4RJJ.js +415 -0
- package/dist/chunk-S2A7YC3Q.js +41433 -0
- package/dist/chunk-S2FBBX7D.js +540 -0
- package/dist/chunk-S34B4QPI.js +430 -0
- package/dist/chunk-SETWVXOJ.js +2078 -0
- package/dist/chunk-SMA4N4AC.js +211 -0
- package/dist/chunk-SP2I63OO.js +252 -0
- package/dist/chunk-STHSY74Q.js +242 -0
- package/dist/chunk-STUPFGXY.js +3206 -0
- package/dist/chunk-T5I4S2W3.js +34 -0
- package/dist/chunk-T6AIP7H5.js +3851 -0
- package/dist/chunk-TANFV3MZ.js +531 -0
- package/dist/chunk-TAVDMUV3.js +189 -0
- package/dist/chunk-TBSQJ6IV.js +324 -0
- package/dist/chunk-TIZHP7KE.js +408 -0
- package/dist/chunk-TV45EUGM.js +51 -0
- package/dist/chunk-TW2KPPUC.js +4087 -0
- package/dist/chunk-V2YTAIQO.js +1075 -0
- package/dist/chunk-V5PKHHQQ.js +1963 -0
- package/dist/chunk-VF4IOZZO.js +184 -0
- package/dist/chunk-VJTINHZI.js +48 -0
- package/dist/chunk-VKLILA2D.js +205 -0
- package/dist/chunk-VOGCSYOI.js +16 -0
- package/dist/chunk-VPTTCYOC.js +16101 -0
- package/dist/chunk-WY6PP6AA.js +53 -0
- package/dist/chunk-WYFIXP54.js +174 -0
- package/dist/chunk-WZ2BXIGG.js +34 -0
- package/dist/chunk-XJNDSYGO.js +147 -0
- package/dist/chunk-XPCM366L.js +70 -0
- package/dist/chunk-XSQKGVYA.js +69 -0
- package/dist/chunk-XUPVB7TL.js +207 -0
- package/dist/chunk-XZRON6IV.js +131 -0
- package/dist/chunk-Y4NG2FP5.js +94 -0
- package/dist/chunk-YEDDOYSC.js +27809 -0
- package/dist/chunk-YGMCXNTY.js +41 -0
- package/dist/chunk-YJKPTX6J.js +228 -0
- package/dist/chunk-YMZ3TNYB.js +18 -0
- package/dist/chunk-Z6LF7HQN.js +22 -0
- package/dist/chunk-Z7SG32ZY.js +55 -0
- package/dist/chunk-ZDPAS56H.js +76 -0
- package/dist/chunk-ZJSP24X4.js +1247 -0
- package/dist/chunk-ZMAINWBW.js +18 -0
- package/dist/chunk-ZMFPW66A.js +22 -0
- package/dist/chunk-ZUIAOKXI.js +1611 -0
- package/dist/chunk-ZVM6AKKM.js +47 -0
- package/dist/files.json +1888 -0
- package/dist/fixtures/forge/README.md +19 -0
- package/dist/fixtures/forge/expected/discrepancies.yaml +54 -0
- package/dist/fixtures/forge/expected/inputs.yaml +38 -0
- package/dist/fixtures/forge/expected/scan.yaml +342 -0
- package/dist/fixtures/forge/inputs/diagrams/forge-context.drawio +23 -0
- package/dist/fixtures/forge/inputs/partner-specs/northwind-pay-openapi.yaml +11 -0
- package/dist/fixtures/forge/inputs/tickets/ado-stories.json +4 -0
- package/dist/fixtures/forge/inputs/tickets/closed-service-requests.json +5 -0
- package/dist/fixtures/forge/inputs/wiki/integration-patterns.md +11 -0
- package/dist/fixtures/forge/inputs/wiki/ledger-solution-spec.md +9 -0
- package/dist/fixtures/forge/inputs/wiki/snow-firewall-request.md +4 -0
- package/dist/fixtures/forge/metarepo/judgments/reaches/84af5b6af24f7ca8c23013f3.yaml +17 -0
- package/dist/fixtures/forge/metarepo/judgments/reaches/c3917555edebddce8cecb647.yaml +17 -0
- package/dist/fixtures/forge/metarepo/judgments/reaches/c5fafd6601f8ca9e34e0bbd0.yaml +17 -0
- package/dist/fixtures/forge/metarepo/org-pack/agents/architecture-critic.yaml +9 -0
- package/dist/fixtures/forge/metarepo/org-pack/agents/story-writer.yaml +10 -0
- package/dist/fixtures/forge/metarepo/org-pack/checklists/architecture.yaml +115 -0
- package/dist/fixtures/forge/metarepo/org-pack/dialects/forge.yaml +111 -0
- package/dist/fixtures/forge/metarepo/org-pack/gates.yaml +22 -0
- package/dist/fixtures/forge/metarepo/org-pack/pack.yaml +11 -0
- package/dist/fixtures/forge/metarepo/org-pack/patterns/A.EB.PUB.yaml +12 -0
- package/dist/fixtures/forge/metarepo/org-pack/patterns/D.JDBC.yaml +12 -0
- package/dist/fixtures/forge/metarepo/org-pack/patterns/S.DIR.BFF.yaml +12 -0
- package/dist/fixtures/forge/metarepo/org-pack/patterns/S.GW.SOR.yaml +13 -0
- package/dist/fixtures/forge/metarepo/org-pack/patterns/S.GW.VND.yaml +14 -0
- package/dist/fixtures/forge/metarepo/org-pack/process/change-templates/feature.md +37 -0
- package/dist/fixtures/forge/metarepo/org-pack/process/skills/add-forge-endpoint/SKILL.md +17 -0
- package/dist/fixtures/forge/metarepo/org-pack/process/snow/firewall-rule.yaml +14 -0
- package/dist/fixtures/forge/metarepo/org-pack/process/snow/gateway-route.yaml +13 -0
- package/dist/fixtures/forge/metarepo/org-pack/profiles/forge/profile.yaml +12 -0
- package/dist/fixtures/forge/metarepo/org-pack/profiles/forge/repos.manifest.yaml +44 -0
- package/dist/fixtures/forge/metarepo/org-pack/roles.yaml +14 -0
- package/dist/fixtures/forge/metarepo/org-pack/runtime.yaml +14 -0
- package/dist/fixtures/forge/metarepo/org-pack/sources.yaml +3 -0
- package/dist/fixtures/forge/repos/forge-events/topics/payments.initiated.yaml +4 -0
- package/dist/fixtures/forge/repos/forge-events/topics/transfers.completed.yaml +4 -0
- package/dist/fixtures/forge/repos/forge-gateway/proxies/ledger-v1/apiproxy/ledger-v1.xml +3 -0
- package/dist/fixtures/forge/repos/forge-gateway/proxies/ledger-v1/apiproxy/policies/SpikeArrest.xml +3 -0
- package/dist/fixtures/forge/repos/forge-gateway/proxies/ledger-v1/apiproxy/policies/VerifyOAuth.xml +4 -0
- package/dist/fixtures/forge/repos/forge-gateway/proxies/ledger-v1/apiproxy/proxies/default.xml +14 -0
- package/dist/fixtures/forge/repos/forge-gateway/proxies/ledger-v1/apiproxy/targets/ledger.xml +5 -0
- package/dist/fixtures/forge/repos/forge-infra/alerts/ledger-api.yaml +5 -0
- package/dist/fixtures/forge/repos/forge-infra/k8s/ledger-api.yaml +15 -0
- package/dist/fixtures/forge/repos/forge-infra/k8s/portal-bff.yaml +7 -0
- package/dist/fixtures/forge/repos/forge-infra/terraform/ledger-db.tf +9 -0
- package/dist/fixtures/forge/repos/forge-ledger/api/ledger-openapi.yaml +31 -0
- package/dist/fixtures/forge/repos/forge-ledger/forge.yaml +4 -0
- package/dist/fixtures/forge/repos/forge-ledger/src/main/java/forge/ledger/LedgerEndpoints.java +13 -0
- package/dist/fixtures/forge/repos/forge-ledger/src/main/java/forge/ledger/LedgerEvents.java +11 -0
- package/dist/fixtures/forge/repos/forge-ledger/src/main/java/forge/ledger/NorthwindClient.java +10 -0
- package/dist/fixtures/forge/repos/forge-ledger/src/main/resources/application.yml +3 -0
- package/dist/fixtures/forge/repos/forge-ledger/src/main/resources/db/migration/V1__create_account.sql +5 -0
- package/dist/fixtures/forge/repos/forge-ledger/src/main/resources/db/migration/V2__create_entry.sql +7 -0
- package/dist/fixtures/forge/repos/forge-portal-bff/pom.xml +1 -0
- package/dist/fixtures/forge/repos/forge-portal-bff/src/main/java/forge/portal/AuditPublisher.java +12 -0
- package/dist/fixtures/forge/repos/forge-portal-bff/src/main/java/forge/portal/BalanceController.java +16 -0
- package/dist/fixtures/forge/repos/forge-portal-bff/src/main/java/forge/portal/LedgerClient.java +13 -0
- package/dist/fixtures/forge/repos/forge-portal-bff/src/main/java/forge/portal/PaymentEvents.java +13 -0
- package/dist/fixtures/forge/repos/forge-portal-bff/src/main/resources/application.yml +8 -0
- package/dist/fixtures/forge/repos/forge-portal-ui/package.json +1 -0
- package/dist/fixtures/forge/repos/forge-portal-ui/src/api/balance.ts +5 -0
- package/dist/fixtures/forge/repos/forge-reports-job/src/main/java/forge/reports/DailyEntriesJob.java +19 -0
- package/dist/fixtures/forge/repos/forge-reports-job/src/main/resources/application.yml +3 -0
- package/dist/fixtures/forge-change/README.md +41 -0
- package/dist/fixtures/forge-change/expected/findings.yaml +301 -0
- package/dist/fixtures/forge-change/expected/stories.yaml +101 -0
- package/dist/fixtures/forge-change/judgments/personal-data/0b5f3dbf5257a22275d8c74b.yaml +18 -0
- package/dist/fixtures/forge-change/judgments/personal-data/2759a66770134c417440bf2d.yaml +18 -0
- package/dist/fixtures/forge-change/judgments/personal-data/31b1ea2f14d0737f1aca79fd.yaml +18 -0
- package/dist/fixtures/forge-change/judgments/personal-data/49afd70c08228e65ad6ca1ed.yaml +18 -0
- package/dist/fixtures/forge-change/judgments/personal-data/761cabcb8a39f5e5866d2dd6.yaml +18 -0
- package/dist/fixtures/forge-change/judgments/personal-data/adae902b90cc8ffa0c765145.yaml +18 -0
- package/dist/fixtures/forge-change/judgments/personal-data/ba11bb933105ec9493e065dd.yaml +18 -0
- package/dist/fixtures/forge-change/judgments/personal-data/bdbcd1cdac3021c68063c3e7.yaml +18 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/brief.md +35 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/change.yaml +120 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/data.md +18 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/design.md +29 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/interfaces.md +17 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/mappings.md +26 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/proposal.md +35 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/snow.md +12 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/specs/transfer-limits/spec.md +19 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/stories/s1-refuse-over-limit.md +17 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/stories/s2-show-remaining.md +16 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/stories/s3-audit-refusals.md +18 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/stories/s4-velocity-check.md +16 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/stories.md +8 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/tasks.md +12 -0
- package/dist/fixtures/forge-change/openspec/changes/add-transfer-limit/ux.md +7 -0
- package/dist/fixtures/forge-change/org-pack/agents/code-and-test-critic.yaml +13 -0
- package/dist/fixtures/forge-change/org-pack/agents/complete-critic.yaml +12 -0
- package/dist/fixtures/forge-change/org-pack/agents/safe-critic.yaml +12 -0
- package/dist/fixtures/forge-change/org-pack/agents/ship-critic.yaml +11 -0
- package/dist/fixtures/forge-change/org-pack/agents/true-critic.yaml +11 -0
- package/dist/fixtures/forge-change/org-pack/checklists/review.yaml +54 -0
- package/dist/fixtures/forge-change/org-pack/gates.yaml +25 -0
- package/dist/fixtures/forge-change/org-pack/teams/team-ledger/checklists/ledger-team.yaml +227 -0
- package/dist/fixtures/forge-change/recordings/complete-critic/2ad84f84bf39c1d5412697e69fe23034d6983ec45a00314bf0975e627589a3c5.json +12 -0
- package/dist/fixtures/forge-change/recordings/complete-critic/417c98d8e54a4387d0fd93441c49f44c2868958739070d855c1dce0c41e24db3.json +12 -0
- package/dist/fixtures/forge-change/recordings/complete-critic/50203ee22e9cb3ef047295edb6538fe7d5695e1e4b139f3c929013dc6ce47021.json +12 -0
- package/dist/fixtures/forge-change/recordings/complete-critic/89f18d67f5d9c325bf35e2a9e020f9ddb6ee13b8523315037f0905cc57c040b1.json +12 -0
- package/dist/fixtures/forge-change/recordings/complete-critic/b4097867d26ae8eadc8b9efa8cdd86897013358035f0b40086c299a59c4ba121.json +12 -0
- package/dist/fixtures/forge-change/recordings/safe-critic/302d06f49664dd67ad2e21ab9cf74c1b0f7d3f750709c6ed8eff2b70983274e2.json +12 -0
- package/dist/fixtures/forge-change/recordings/safe-critic/32f1049c9a5ab4a759543290db4644ec6e221cc45fdfdcf06193837c6a8ce0b9.json +12 -0
- package/dist/fixtures/forge-change/recordings/safe-critic/4e4a84bfc04b9f26ca4250319a879901ff7a1c081c71e46a117675fee05026b0.json +12 -0
- package/dist/fixtures/forge-change/recordings/safe-critic/604af0fcdd6df6b76208fa88305fdc15c37606c2a4d1ae816477e46ac8c2dd04.json +12 -0
- package/dist/fixtures/forge-change/recordings/safe-critic/f0bf50af11f14c50d07904f0dffe1c8c20fb0cd89770645a8824c1d30a443955.json +12 -0
- package/dist/fixtures/forge-change/recordings/ship-critic/350954b58833b2c04880c67db45a1b328b7fd541d9f0d943b63905b8875488a6.json +12 -0
- package/dist/fixtures/forge-change/recordings/ship-critic/4af95c6c96a206777cec9de1f9c2d8c55a36ddc9b8db2f81d6eb83217b835efa.json +12 -0
- package/dist/fixtures/forge-change/recordings/ship-critic/76c34522a49cf7587a4e5689a5030d384603fa780b8aba97d27815cbc829683e.json +12 -0
- package/dist/fixtures/forge-change/recordings/ship-critic/a3b2cd1ace48587e5994333db03b34c3a0f9dec4f1932f1730ddfb687f6918c8.json +12 -0
- package/dist/fixtures/forge-change/recordings/ship-critic/de288a4fa64d0fc20890f9a787080ce6eac5203b7b9b72d884df11e8cf111835.json +12 -0
- package/dist/fixtures/forge-change/recordings/story-writer/1ddb00eac2aaf91a5ec5d9dfd220116be9f75aec6546a4a3a3b050ed89af2864.json +12 -0
- package/dist/packages/assistant-kit/frameworks-kit/README.md +86 -0
- package/dist/packages/assistant-kit/frameworks-kit/checklist.md +11 -0
- package/dist/packages/assistant-kit/frameworks-kit/examples/tide-lantern.yaml +56 -0
- package/dist/packages/assistant-kit/frameworks-kit/examples/tide-platform.yaml +43 -0
- package/dist/packages/assistant-kit/frameworks-kit/prompts/write-framework-model.md +12 -0
- package/dist/packages/assistant-kit/kit/README.md +98 -0
- package/dist/packages/assistant-kit/kit/c2-reference.md +334 -0
- package/dist/packages/assistant-kit/kit/checklist.md +39 -0
- package/dist/packages/assistant-kit/kit/examples/house-http-client.yaml +102 -0
- package/dist/packages/assistant-kit/kit/examples/tide-apigee.yaml +56 -0
- package/dist/packages/assistant-kit/kit/examples/tide-apim.yaml +32 -0
- package/dist/packages/assistant-kit/kit/examples/tide-kong.yaml +44 -0
- package/dist/packages/assistant-kit/kit/prompts/write-dialect.md +34 -0
- package/dist/packages/assistant-kit/kit/worked-example.md +198 -0
- package/dist/packages/conformance/sample/README.md +4 -0
- package/dist/packages/conformance/sample/inputs/notes.md +3 -0
- package/dist/packages/conformance/sample/inputs/systems.csv +3 -0
- package/dist/packages/conformance/sample/repo/api/greeter.proto +6 -0
- package/dist/packages/conformance/sample/repo/api/openapi.yaml +10 -0
- package/dist/packages/conformance/sample/repo/api/schema.graphql +3 -0
- package/dist/packages/conformance/sample/repo/db/V1__create_greeting.sql +4 -0
- package/dist/packages/conformance/sample/repo/package.json +7 -0
- package/dist/packages/conformance/sample/repo/src/main/java/sample/HelloController.java +10 -0
- package/dist/packages/conformance/sample/repo/web/app.ts +4 -0
- package/dist/packages/evals/datasets/critic-lenses.yaml +62 -0
- package/dist/packages/evals/datasets/dialect-writer.yaml +14 -0
- package/dist/packages/evals/datasets/feature-namer.yaml +34 -0
- package/dist/packages/evals/datasets/glossary-definer.yaml +25 -0
- package/dist/packages/evals/datasets/story-writer.yaml +13 -0
- package/dist/packages/evals/datasets/template-writer.yaml +16 -0
- package/dist/packages/evals/datasets/test-writer.yaml +18 -0
- package/dist/packages/executors/reference/reference-executor.mjs +233 -0
- package/dist/packages/extractors/dialects/argocd.yaml +45 -0
- package/dist/packages/extractors/dialects/fixtures/jaxrs/accounts-service/src/main/java/forge/accounts/AccountResource.java +47 -0
- package/dist/packages/extractors/dialects/fixtures/jaxrs/accounts-service/src/main/java/forge/accounts/AuditClient.java +12 -0
- package/dist/packages/extractors/dialects/fixtures/jaxrs/accounts-service/src/main/java/forge/accounts/LedgerClient.java +17 -0
- package/dist/packages/extractors/dialects/fixtures/micronaut/statements-service/src/main/java/forge/statements/LedgerClient.java +14 -0
- package/dist/packages/extractors/dialects/fixtures/micronaut/statements-service/src/main/java/forge/statements/RatesClient.java +11 -0
- package/dist/packages/extractors/dialects/fixtures/micronaut/statements-service/src/main/java/forge/statements/StatementController.java +36 -0
- package/dist/packages/extractors/dialects/fixtures/micronaut/statements-service/src/main/resources/application.yml +7 -0
- package/dist/packages/extractors/dialects/fixtures/quarkus-reactive-messaging/fraud-service/src/main/java/forge/fraud/FraudScorer.java +27 -0
- package/dist/packages/extractors/dialects/fixtures/quarkus-reactive-messaging/fraud-service/src/main/resources/application.properties +4 -0
- package/dist/packages/extractors/dialects/fixtures/terraform-aws/forge-aws-infra/envs/prod/api.tf +38 -0
- package/dist/packages/extractors/dialects/fixtures/terraform-aws/forge-aws-infra/envs/prod/main.tf +95 -0
- package/dist/packages/extractors/dialects/fixtures/terraform-aws/forge-aws-infra/envs/prod/terraform.tfvars +1 -0
- package/dist/packages/extractors/dialects/fixtures/terraform-aws/forge-aws-infra/envs/prod/variables.tf +4 -0
- package/dist/packages/extractors/dialects/fixtures/terraform-azure/forge-azure-infra/main.tf +102 -0
- package/dist/packages/extractors/dialects/fixtures/terraform-gcp/forge-gcp-infra/main.tf +51 -0
- package/dist/packages/extractors/dialects/harness.yaml +101 -0
- package/dist/packages/extractors/dialects/jaxrs.yaml +155 -0
- package/dist/packages/extractors/dialects/micronaut.yaml +207 -0
- package/dist/packages/extractors/dialects/quarkus-reactive-messaging.yaml +158 -0
- package/dist/packages/extractors/dialects/tekton.yaml +71 -0
- package/dist/packages/extractors/dialects/terraform-aws.yaml +267 -0
- package/dist/packages/extractors/dialects/terraform-azure.yaml +212 -0
- package/dist/packages/extractors/dialects/terraform-gcp.yaml +109 -0
- package/dist/packages/extractors/grammars/README.md +11 -0
- package/dist/packages/extractors/grammars/tree-sitter-groovy.LICENSE +21 -0
- package/dist/packages/extractors/grammars/tree-sitter-groovy.wasm +0 -0
- package/dist/packages/extractors/grammars/vendored.json +11 -0
- package/dist/packages/learn/lessons/architect-diagrams-and-code.yaml +69 -0
- package/dist/packages/learn/lessons/business-analyst-story-bar.yaml +94 -0
- package/dist/packages/learn/lessons/delivery-lead-release-readiness.yaml +44 -0
- package/dist/packages/learn/lessons/designer-features-in-user-words.yaml +57 -0
- package/dist/packages/learn/lessons/developer-find-your-way.yaml +60 -0
- package/dist/packages/learn/lessons/everyone-first-hour.yaml +74 -0
- package/dist/packages/learn/lessons/platform-lead-coverage-and-defences.yaml +58 -0
- package/dist/packages/learn/lessons/product-owner-first-change.yaml +167 -0
- package/dist/packages/learn/lessons/qa-tests-and-trace.yaml +53 -0
- package/dist/packages/learn/lessons/team-lead-initiative.yaml +146 -0
- package/dist/packages/naysayer/constitution/constitution.yaml +286 -0
- package/dist/packages/naysayer/starter/review.yaml +256 -0
- package/dist/packages/sdk/npm/index.js +8892 -0
- package/dist/packages/speckit/rules/drift.yaml +78 -0
- package/dist/packages/taskrun/rules/conform.yaml +38 -0
- package/dist/packages/testgen/rules/trace.yaml +49 -0
- package/dist/packages/ui/dist/assets/elk-api-tma0MCuh.js +2 -0
- package/dist/packages/ui/dist/assets/elk-worker.min--dAJroGl.js +6401 -0
- package/dist/packages/ui/dist/assets/elk-worker.min-DdYmS5kP.js +2 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-400-normal-BTotfTJu.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-400-normal-DZqxrq2p.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-500-normal-ByOcLdNv.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-500-normal-CocWQlwt.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-600-normal-71GNu3SW.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-600-normal-BGq0mW3O.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-ext-400-normal-Dsrv2Tcn.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-ext-400-normal-g30qAdWV.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-ext-500-normal-Cs5J6C77.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-ext-500-normal-DB5PtV2g.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-ext-600-normal-Bz0x94Yp.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-cyrillic-ext-600-normal-DUMzJB7m.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-greek-400-normal-D9ESIMu3.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-greek-400-normal-_efipK4i.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-greek-500-normal-CuWXN6rf.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-greek-500-normal-JMMifIXV.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-greek-600-normal-D-CqTdkO.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-greek-600-normal-DzTrcv_p.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-400-normal-CDDApCn2.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-400-normal-CYLoc0-x.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-500-normal-6ng42L7E.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-500-normal-BgVn5rGT.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-600-normal-Cu4Hd6ag.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-600-normal-CuJfVYMP.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-ext-400-normal-C5H60-Va.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-ext-400-normal-RBey6euL.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-ext-500-normal-D0aIdm-b.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-ext-500-normal-DakdToA3.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-ext-600-normal-DIrixKbi.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-latin-ext-600-normal-DOrvGEcy.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-vietnamese-400-normal-DG4YqDda.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-vietnamese-400-normal-fK1oJ5dG.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-vietnamese-500-normal-BEb3_waV.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-vietnamese-500-normal-e4dixQRQ.woff2 +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-vietnamese-600-normal-DgdngZtN.woff +0 -0
- package/dist/packages/ui/dist/assets/ibm-plex-sans-vietnamese-600-normal-DpPYBSTl.woff2 +0 -0
- package/dist/packages/ui/dist/assets/index-B54fm9FQ.js +29 -0
- package/dist/packages/ui/dist/assets/index-DD_hufQz.css +1 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-cyrillic-400-normal-BEIGL1Tu.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-cyrillic-400-normal-ugxPyKxw.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-cyrillic-500-normal-DJqRU3vO.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-cyrillic-500-normal-DmUKJPL_.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-greek-400-normal-B9oWc5Lo.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-greek-400-normal-C190GLew.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-greek-500-normal-D7SFKleX.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-greek-500-normal-JpySY46c.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-400-normal-6-qcROiO.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-400-normal-V6pRDFza.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-500-normal-BWZEU5yA.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-500-normal-CJOVTJB7.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-ext-400-normal-Bc8Ftmh3.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-ext-400-normal-fXTG6kC5.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-ext-500-normal-Cut-4mMH.woff2 +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-latin-ext-500-normal-ckzbgY84.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-vietnamese-400-normal-CqNFfHCs.woff +0 -0
- package/dist/packages/ui/dist/assets/jetbrains-mono-vietnamese-500-normal-DNRqzVM1.woff +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-devanagari-600-normal-BtY48IV_.woff +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-devanagari-600-normal-DhS7ScYx.woff2 +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-devanagari-700-normal-BQQOj9BB.woff2 +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-devanagari-700-normal-DBRwWuxA.woff +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-600-normal-CXCVEoA9.woff2 +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-600-normal-Dx02qI2_.woff +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-700-normal-BPDUZo87.woff2 +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-700-normal-e0Uj8ZlN.woff +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-ext-600-normal-BleIgkPp.woff +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-ext-600-normal-C9ZjJQAt.woff2 +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-ext-700-normal-BPaQ7tlD.woff +0 -0
- package/dist/packages/ui/dist/assets/rajdhani-latin-ext-700-normal-S6aYESQK.woff2 +0 -0
- package/dist/packages/ui/dist/favicon.svg +1 -0
- package/dist/packages/ui/dist/index.html +15 -0
- package/dist/third-party.json +575 -0
- package/dist/vendor/@fission-ai/openspec/bin/openspec.js +85986 -0
- package/dist/vendor/@fission-ai/openspec/package.json +82 -0
- package/dist/vendor/@fission-ai/openspec/schemas/spec-driven/schema.yaml +248 -0
- package/dist/vendor/@fission-ai/openspec/schemas/spec-driven/templates/design.md +21 -0
- package/dist/vendor/@fission-ai/openspec/schemas/spec-driven/templates/proposal.md +34 -0
- package/dist/vendor/@fission-ai/openspec/schemas/spec-driven/templates/spec.md +13 -0
- package/dist/vendor/@fission-ai/openspec/schemas/spec-driven/templates/tasks.md +11 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-c_sharp.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-go.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-java.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-javascript.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-kotlin.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-php.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-python.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-ruby.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-rust.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-scala.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-tsx.wasm +0 -0
- package/dist/vendor/tree-sitter-wasms/out/tree-sitter-typescript.wasm +0 -0
- package/dist/vendor/web-tree-sitter/tree-sitter.wasm +0 -0
- package/package.json +36 -3
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
import { createRequire as __atticusCreateRequire } from "node:module";
|
|
2
|
+
import { fileURLToPath as __atticusFileURLToPath } from "node:url";
|
|
3
|
+
var require = __atticusCreateRequire(import.meta.url);
|
|
4
|
+
var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
|
|
5
|
+
var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
|
|
6
|
+
import {
|
|
7
|
+
buildSite,
|
|
8
|
+
catalogRecords,
|
|
9
|
+
openChanges
|
|
10
|
+
} from "./chunk-5FEOD73Z.js";
|
|
11
|
+
import {
|
|
12
|
+
doctorChecks
|
|
13
|
+
} from "./chunk-S2FBBX7D.js";
|
|
14
|
+
import {
|
|
15
|
+
readProbes,
|
|
16
|
+
whatRunsWhere
|
|
17
|
+
} from "./chunk-V5PKHHQQ.js";
|
|
18
|
+
import {
|
|
19
|
+
baseClonePath,
|
|
20
|
+
loadRepos
|
|
21
|
+
} from "./chunk-KJPMEAI4.js";
|
|
22
|
+
import {
|
|
23
|
+
CatalogBaseline,
|
|
24
|
+
DEFAULT_RUNTIME,
|
|
25
|
+
WORKSPACE_SCHEMA_VERSION,
|
|
26
|
+
catalogDirOf,
|
|
27
|
+
inputsDirOf,
|
|
28
|
+
loadOrgPack,
|
|
29
|
+
orgPackDirOf,
|
|
30
|
+
require_dist
|
|
31
|
+
} from "./chunk-S2A7YC3Q.js";
|
|
32
|
+
import {
|
|
33
|
+
__toESM
|
|
34
|
+
} from "./chunk-TV45EUGM.js";
|
|
35
|
+
|
|
36
|
+
// packages/cli/dist/baseline-commands.js
|
|
37
|
+
var import_yaml = __toESM(require_dist(), 1);
|
|
38
|
+
import { readdir, readFile, stat, writeFile } from "node:fs/promises";
|
|
39
|
+
import { join, resolve } from "node:path";
|
|
40
|
+
var BASELINE_FILE = "baseline.yaml";
|
|
41
|
+
async function readBaseline(root) {
|
|
42
|
+
try {
|
|
43
|
+
const r = CatalogBaseline.safeParse((0, import_yaml.parse)(await readFile(join(catalogDirOf(root), BASELINE_FILE), "utf8")));
|
|
44
|
+
return r.success ? r.data : void 0;
|
|
45
|
+
} catch {
|
|
46
|
+
return void 0;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
async function countFiles(dir) {
|
|
50
|
+
try {
|
|
51
|
+
const all = await readdir(dir, { recursive: true, withFileTypes: true });
|
|
52
|
+
return all.filter((e) => e.isFile()).length;
|
|
53
|
+
} catch {
|
|
54
|
+
return 0;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
async function setupSteps(root, o = {}) {
|
|
58
|
+
const clonedOf = async (repos2) => (await Promise.all(repos2.map((r) => stat(join(baseClonePath(root, r.id), ".git")).then(() => true, () => false)))).filter(Boolean).length;
|
|
59
|
+
const [doctor, op, repos, records, inputs, baseline, probes] = await Promise.all([
|
|
60
|
+
o.doctor ?? doctorChecks(root),
|
|
61
|
+
loadOrgPack(orgPackDirOf(root)),
|
|
62
|
+
loadRepos(root).catch(() => []),
|
|
63
|
+
catalogRecords(root),
|
|
64
|
+
countFiles(inputsDirOf(root)),
|
|
65
|
+
readBaseline(root),
|
|
66
|
+
readProbes(root).then((p) => p.results)
|
|
67
|
+
]);
|
|
68
|
+
const failing = doctor.filter((c) => c.status === "fail");
|
|
69
|
+
const cloned = await clonedOf(repos);
|
|
70
|
+
const generated = records.filter((r) => r.evidence.some((e) => e.source !== "manual")).length;
|
|
71
|
+
const wikis = op.sources.wikis.length;
|
|
72
|
+
const steps = [
|
|
73
|
+
{
|
|
74
|
+
id: "machine",
|
|
75
|
+
label: "This machine has what Atticus needs",
|
|
76
|
+
done: failing.length === 0,
|
|
77
|
+
detail: failing.length ? `to fix: ${failing.map((c) => c.label).join(", ")}` : `${doctor.filter((c) => c.status === "warn").length} to look at`,
|
|
78
|
+
fix: failing.length ? `Run atticus doctor: ${failing.map((c) => c.fix ?? c.label).join(" ")}` : "Run atticus doctor for the details."
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
id: "org-pack",
|
|
82
|
+
label: "The org pack's files are valid",
|
|
83
|
+
done: op.problems.length === 0,
|
|
84
|
+
detail: op.problems.length ? `${op.problems.length} problem${op.problems.length === 1 ? "" : "s"}` : "no problems in its files",
|
|
85
|
+
fix: "Run atticus orgpack validate and fix each problem it names (each says the file and field)."
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
// A new metarepo's org pack is valid as atticus init wrote it, but nobody owns it yet.
|
|
89
|
+
id: "org-pack-owner",
|
|
90
|
+
label: "The org pack has an owner",
|
|
91
|
+
done: !!op.pack?.owner && op.pack.owner !== "unassigned",
|
|
92
|
+
detail: op.pack?.owner && op.pack.owner !== "unassigned" ? op.pack.owner : "unassigned",
|
|
93
|
+
fix: "Set owner in org-pack/pack.yaml to the person who looks after the org pack (normally the platform lead), and commit it through a pull request."
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
// ADR 0121 item 6: how AI runs here is a choice, not the default left by accident.
|
|
97
|
+
id: "ai",
|
|
98
|
+
label: "Choose how AI runs here",
|
|
99
|
+
// runtime.yaml's version alone (1 from an older init, ADR 0121 addendum) isn't a choice.
|
|
100
|
+
done: JSON.stringify({ ...op.runtime, schemaVersion: DEFAULT_RUNTIME.schemaVersion }) !== JSON.stringify(DEFAULT_RUNTIME),
|
|
101
|
+
detail: whatRunsWhere(op.runtime, { probes }),
|
|
102
|
+
fix: "Choose the assistants, the modes and the model provider on Set up \u203A AI in the app (or in org-pack/runtime.yaml), and commit it through a pull request. As atticus init wrote it, steps are handed to Copilot, which needs nothing more.",
|
|
103
|
+
optional: true
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
id: "repos",
|
|
107
|
+
label: "Repos are listed",
|
|
108
|
+
done: repos.length > 0,
|
|
109
|
+
detail: `${repos.length} repo${repos.length === 1 ? "" : "s"} in the manifests`,
|
|
110
|
+
fix: "Run atticus repos discover <folder> (or --org <org>) and add what it proposes to repos.manifest.yaml."
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
id: "clones",
|
|
114
|
+
label: "Repos are cloned here",
|
|
115
|
+
done: repos.length > 0 && cloned === repos.length,
|
|
116
|
+
detail: `${cloned} of ${repos.length} cloned`,
|
|
117
|
+
fix: "Run atticus workspace sync (or Sync repos on the Scans screen); it clones what's missing."
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
// ADR 0124: your assistant reads each repo and writes its facts; Atticus checks every one
|
|
121
|
+
// against its line and puts them in the catalog. The id stays: the app keys on it.
|
|
122
|
+
id: "scan",
|
|
123
|
+
label: "Every repo is read and verified",
|
|
124
|
+
done: generated > 0,
|
|
125
|
+
detail: `${records.length} record${records.length === 1 ? "" : "s"} in the catalog`,
|
|
126
|
+
fix: "Read each repo: /atticus-map <repo> in your assistant (or atticus map <repo>), then atticus verify <repo> --write. Verify checks every fact against the line it cites and runs no model."
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
id: "knowledge",
|
|
130
|
+
label: "Existing knowledge is added",
|
|
131
|
+
done: inputs > 0 || wikis > 0,
|
|
132
|
+
detail: `${inputs} file${inputs === 1 ? "" : "s"} in inputs/, ${wikis} wiki source${wikis === 1 ? "" : "s"}`,
|
|
133
|
+
fix: "Drop diagrams, partner specs and exports into inputs/ (atticus intake add <files>), and add wikis to sources.yaml (atticus sources add).",
|
|
134
|
+
optional: true
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
id: "baseline",
|
|
138
|
+
label: "The catalog is accepted",
|
|
139
|
+
done: !!baseline,
|
|
140
|
+
detail: baseline ? `accepted by ${baseline.acceptedBy} on ${baseline.acceptedAt.slice(0, 10)}` : "not yet",
|
|
141
|
+
fix: "Walk the ecosystem map with the architect, then accept it: atticus baseline (or Accept the catalog on Home), and commit catalog/baseline.yaml through a pull request."
|
|
142
|
+
}
|
|
143
|
+
];
|
|
144
|
+
return { steps, baselined: !!baseline };
|
|
145
|
+
}
|
|
146
|
+
async function setupCommand(root, o, io) {
|
|
147
|
+
const s = await setupSteps(root);
|
|
148
|
+
const open = s.steps.filter((x) => !x.done && !x.optional);
|
|
149
|
+
if (o.json)
|
|
150
|
+
io.out(JSON.stringify(s, null, 2));
|
|
151
|
+
else {
|
|
152
|
+
for (const x of s.steps) {
|
|
153
|
+
io.out(`${x.done ? "[x]" : "[ ]"} ${x.label}: ${x.detail}${x.optional ? " (optional)" : ""}`);
|
|
154
|
+
if (!x.done && x.fix)
|
|
155
|
+
io.out(` ${x.fix}`);
|
|
156
|
+
}
|
|
157
|
+
io.out(open.length ? `${open.length} step${open.length === 1 ? "" : "s"} to go.` : "Setup is done: the catalog is accepted.");
|
|
158
|
+
}
|
|
159
|
+
return open.length ? 1 : 0;
|
|
160
|
+
}
|
|
161
|
+
async function baselineCommand(root, o, io) {
|
|
162
|
+
if (!o.by) {
|
|
163
|
+
io.err("Usage: atticus baseline [--by <you>] [--note <text>] [--site <dir>]");
|
|
164
|
+
return 2;
|
|
165
|
+
}
|
|
166
|
+
const records = await catalogRecords(root, io);
|
|
167
|
+
if (records.length === 0) {
|
|
168
|
+
io.err("The catalog is empty: read the repos first (atticus map <repo>, then atticus verify <repo> --write), then walk the map and accept it.");
|
|
169
|
+
return 1;
|
|
170
|
+
}
|
|
171
|
+
const kinds = {};
|
|
172
|
+
for (const r of records)
|
|
173
|
+
kinds[r.kind] = (kinds[r.kind] ?? 0) + 1;
|
|
174
|
+
const systems = records.filter((r) => r.kind === "System").map((r) => r.id).sort();
|
|
175
|
+
const b = CatalogBaseline.parse({
|
|
176
|
+
schemaVersion: WORKSPACE_SCHEMA_VERSION,
|
|
177
|
+
acceptedBy: o.by,
|
|
178
|
+
acceptedAt: o.now ?? (/* @__PURE__ */ new Date()).toISOString().replace(/\.\d{3}Z$/, "Z"),
|
|
179
|
+
kinds: Object.fromEntries(Object.entries(kinds).sort(([a], [b2]) => a.localeCompare(b2))),
|
|
180
|
+
systems,
|
|
181
|
+
...o.note ? { note: o.note } : {}
|
|
182
|
+
});
|
|
183
|
+
await writeFile(join(catalogDirOf(root), BASELINE_FILE), (0, import_yaml.stringify)(b), "utf8");
|
|
184
|
+
io.out(`Accepted the catalog as the baseline as ${o.by}: ${records.length} records in ${Object.keys(kinds).length} kinds, ${systems.length} systems. Wrote catalog/${BASELINE_FILE}; commit it with the catalog and open a pull request, whose merge makes it the baseline on main.`);
|
|
185
|
+
if (o.site) {
|
|
186
|
+
const dir = resolve(o.site);
|
|
187
|
+
const s = await buildSite(records, dir, {
|
|
188
|
+
title: "Catalog",
|
|
189
|
+
builtAt: b.acceptedAt.slice(0, 10),
|
|
190
|
+
changes: await openChanges(root)
|
|
191
|
+
});
|
|
192
|
+
io.out(`Wrote the read-only catalog site to ${dir} (${s.systems.length} systems).`);
|
|
193
|
+
}
|
|
194
|
+
return 0;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
export {
|
|
198
|
+
BASELINE_FILE,
|
|
199
|
+
readBaseline,
|
|
200
|
+
setupSteps,
|
|
201
|
+
setupCommand,
|
|
202
|
+
baselineCommand
|
|
203
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { createRequire as __atticusCreateRequire } from "node:module";
|
|
2
|
+
import { fileURLToPath as __atticusFileURLToPath } from "node:url";
|
|
3
|
+
var require = __atticusCreateRequire(import.meta.url);
|
|
4
|
+
var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
|
|
5
|
+
var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
|
|
6
|
+
import {
|
|
7
|
+
MIGRATIONS,
|
|
8
|
+
STAMP_FILE,
|
|
9
|
+
readStamp,
|
|
10
|
+
upgradeCheck,
|
|
11
|
+
upgradeCommand
|
|
12
|
+
} from "./chunk-72TXNLOC.js";
|
|
13
|
+
import "./chunk-IQFTZ37C.js";
|
|
14
|
+
import "./chunk-V5PKHHQQ.js";
|
|
15
|
+
import "./chunk-VPTTCYOC.js";
|
|
16
|
+
import "./chunk-L6SGQIR3.js";
|
|
17
|
+
import "./chunk-7UFQZXZA.js";
|
|
18
|
+
import "./chunk-56YQ6ROQ.js";
|
|
19
|
+
import "./chunk-4AK7IBVP.js";
|
|
20
|
+
import "./chunk-7JUKDRSZ.js";
|
|
21
|
+
import "./chunk-OLWFG75W.js";
|
|
22
|
+
import "./chunk-L24C55VN.js";
|
|
23
|
+
import "./chunk-PAMPPUR6.js";
|
|
24
|
+
import "./chunk-23W7VWKR.js";
|
|
25
|
+
import "./chunk-7EKXJZ2Y.js";
|
|
26
|
+
import "./chunk-MC3H7736.js";
|
|
27
|
+
import "./chunk-T6AIP7H5.js";
|
|
28
|
+
import "./chunk-JPGCERE2.js";
|
|
29
|
+
import "./chunk-KJPMEAI4.js";
|
|
30
|
+
import "./chunk-GQ4N4WKF.js";
|
|
31
|
+
import "./chunk-CNUKCS2T.js";
|
|
32
|
+
import "./chunk-S2A7YC3Q.js";
|
|
33
|
+
import "./chunk-D3PO4DOZ.js";
|
|
34
|
+
import "./chunk-TV45EUGM.js";
|
|
35
|
+
export {
|
|
36
|
+
MIGRATIONS,
|
|
37
|
+
STAMP_FILE,
|
|
38
|
+
readStamp,
|
|
39
|
+
upgradeCheck,
|
|
40
|
+
upgradeCommand
|
|
41
|
+
};
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
import { createRequire as __atticusCreateRequire } from "node:module";
|
|
2
|
+
import { fileURLToPath as __atticusFileURLToPath } from "node:url";
|
|
3
|
+
var require = __atticusCreateRequire(import.meta.url);
|
|
4
|
+
var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
|
|
5
|
+
var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
|
|
6
|
+
import {
|
|
7
|
+
readRound,
|
|
8
|
+
reviewedGates,
|
|
9
|
+
roundsOf
|
|
10
|
+
} from "./chunk-7UFQZXZA.js";
|
|
11
|
+
import {
|
|
12
|
+
changeStore,
|
|
13
|
+
liveHandoff
|
|
14
|
+
} from "./chunk-56YQ6ROQ.js";
|
|
15
|
+
import {
|
|
16
|
+
createAdapters
|
|
17
|
+
} from "./chunk-7JUKDRSZ.js";
|
|
18
|
+
import {
|
|
19
|
+
loadOrgPack,
|
|
20
|
+
orgPackDirOf
|
|
21
|
+
} from "./chunk-S2A7YC3Q.js";
|
|
22
|
+
|
|
23
|
+
// packages/cli/dist/digest-commands.js
|
|
24
|
+
var norm = (s) => s.toLowerCase().replace(/^@/, "");
|
|
25
|
+
async function buildDigest(root, user) {
|
|
26
|
+
const revise = [];
|
|
27
|
+
const blocking = [];
|
|
28
|
+
const changes = await changeStore(root).list().catch(() => []);
|
|
29
|
+
const me = norm(user);
|
|
30
|
+
for (const c of changes.sort((a, b) => a.id.localeCompare(b.id))) {
|
|
31
|
+
const h = liveHandoff(c);
|
|
32
|
+
if (h?.state === "changes-requested" && norm(h.by) === me)
|
|
33
|
+
revise.push({
|
|
34
|
+
change: c.id,
|
|
35
|
+
title: c.title,
|
|
36
|
+
phase: h.phase,
|
|
37
|
+
pr: h.pr.url,
|
|
38
|
+
openedAt: h.openedAt
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
for (const c of changes.sort((a, b) => a.id.localeCompare(b.id))) {
|
|
42
|
+
if (c.state === "archived")
|
|
43
|
+
continue;
|
|
44
|
+
const mine = norm(c.createdBy) === me || Object.values(c.owners ?? {}).some((hs) => hs.some((h) => norm(h) === me));
|
|
45
|
+
if (!mine)
|
|
46
|
+
continue;
|
|
47
|
+
let open = 0;
|
|
48
|
+
for (const gate of await reviewedGates(root, c.id)) {
|
|
49
|
+
const rounds = await roundsOf(root, c.id, gate);
|
|
50
|
+
if (!rounds.length)
|
|
51
|
+
continue;
|
|
52
|
+
const round = await readRound(root, c.id, gate, rounds.at(-1));
|
|
53
|
+
open += round.findings.filter((f) => f.finding.state === "open" && f.finding.severity === "blocking").length;
|
|
54
|
+
}
|
|
55
|
+
if (open)
|
|
56
|
+
blocking.push({ change: c.id, open });
|
|
57
|
+
}
|
|
58
|
+
const lines = [];
|
|
59
|
+
if (revise.length) {
|
|
60
|
+
lines.push(`${revise.length} hand-off${revise.length === 1 ? "" : "s"} to revise:`);
|
|
61
|
+
for (const w of revise)
|
|
62
|
+
lines.push(`- ${w.change} (${w.phase}): ${w.pr}`);
|
|
63
|
+
}
|
|
64
|
+
if (blocking.length) {
|
|
65
|
+
lines.push("Blocking findings on changes you are on:");
|
|
66
|
+
for (const b of blocking)
|
|
67
|
+
lines.push(`- ${b.change}: ${b.open} open`);
|
|
68
|
+
}
|
|
69
|
+
if (!lines.length)
|
|
70
|
+
lines.push("Nothing waits on you.");
|
|
71
|
+
const { readMe } = await import("./chunk-ZMAINWBW.js");
|
|
72
|
+
const { watchLine } = await import("./chunk-QKRNMBJO.js");
|
|
73
|
+
const watching = [];
|
|
74
|
+
for (const c of (await readMe(root)).watch)
|
|
75
|
+
watching.push(await watchLine(root, c));
|
|
76
|
+
if (watching.length)
|
|
77
|
+
lines.push("Changes you watch:", ...watching.map((w) => `- ${w}`));
|
|
78
|
+
const n = revise.length + blocking.length;
|
|
79
|
+
return {
|
|
80
|
+
title: !n ? "Atticus: nothing waits on you" : n === 1 ? "Atticus: 1 thing waits on you" : `Atticus: ${n} things wait on you`,
|
|
81
|
+
body: lines.join("\n"),
|
|
82
|
+
lines,
|
|
83
|
+
revise,
|
|
84
|
+
blocking,
|
|
85
|
+
watching
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
async function digestCommand(root, o, io, deps = {}) {
|
|
89
|
+
if (!o.as) {
|
|
90
|
+
io.err("Usage: atticus digest [--as <you>] [--channel <c>] [--send] [--json]");
|
|
91
|
+
return 2;
|
|
92
|
+
}
|
|
93
|
+
const d = await buildDigest(root, o.as);
|
|
94
|
+
let sent;
|
|
95
|
+
let notSent;
|
|
96
|
+
if (o.send) {
|
|
97
|
+
let notify = deps.notify;
|
|
98
|
+
if (!notify) {
|
|
99
|
+
const op = await loadOrgPack(orgPackDirOf(root));
|
|
100
|
+
const cfg = op.runtime.adapters.notify;
|
|
101
|
+
if (!cfg)
|
|
102
|
+
notSent = "No notify adapter is set in org-pack/runtime.yaml (adapters.notify).";
|
|
103
|
+
else if (cfg.type === "manual")
|
|
104
|
+
notSent = "Notifications are manual here, so the digest is shown instead of sent.";
|
|
105
|
+
else
|
|
106
|
+
try {
|
|
107
|
+
notify = createAdapters({ adapters: { notify: cfg } }).notify;
|
|
108
|
+
} catch (e) {
|
|
109
|
+
notSent = e.message;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
if (notify) {
|
|
113
|
+
const channel = o.channel ?? `@${o.as}`;
|
|
114
|
+
try {
|
|
115
|
+
const r = await notify.send({ channel, title: d.title, body: d.body, mentions: [o.as] }, {
|
|
116
|
+
by: o.as,
|
|
117
|
+
at: deps.now ?? (/* @__PURE__ */ new Date()).toISOString().replace(/\.\d{3}Z$/, "Z"),
|
|
118
|
+
ref: `digest:${o.as}`
|
|
119
|
+
});
|
|
120
|
+
sent = { id: r.id, channel };
|
|
121
|
+
} catch (e) {
|
|
122
|
+
notSent = `The notify adapter refused: ${e.message}`;
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
if (o.json)
|
|
127
|
+
io.out(JSON.stringify({ ...d, ...sent ? { sent } : {}, ...notSent ? { notSent } : {} }, null, 2));
|
|
128
|
+
else {
|
|
129
|
+
io.out(d.title);
|
|
130
|
+
for (const l of d.lines)
|
|
131
|
+
io.out(l);
|
|
132
|
+
if (sent)
|
|
133
|
+
io.out(`Sent to ${sent.channel} (${sent.id}).`);
|
|
134
|
+
if (notSent)
|
|
135
|
+
io.err(notSent);
|
|
136
|
+
}
|
|
137
|
+
return o.send && !sent ? 1 : 0;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
export {
|
|
141
|
+
buildDigest,
|
|
142
|
+
digestCommand
|
|
143
|
+
};
|
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
import { createRequire as __atticusCreateRequire } from "node:module";
|
|
2
|
+
import { fileURLToPath as __atticusFileURLToPath } from "node:url";
|
|
3
|
+
var require = __atticusCreateRequire(import.meta.url);
|
|
4
|
+
var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
|
|
5
|
+
var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
|
|
6
|
+
import {
|
|
7
|
+
isCritic
|
|
8
|
+
} from "./chunk-4Q3NN7VF.js";
|
|
9
|
+
import {
|
|
10
|
+
lensRunOf
|
|
11
|
+
} from "./chunk-7UFQZXZA.js";
|
|
12
|
+
import {
|
|
13
|
+
CONTEXT_TOOLS
|
|
14
|
+
} from "./chunk-T6AIP7H5.js";
|
|
15
|
+
import {
|
|
16
|
+
HandoffRuntime,
|
|
17
|
+
TOOL_LIMITS,
|
|
18
|
+
modelEnvOf,
|
|
19
|
+
stepClassOf
|
|
20
|
+
} from "./chunk-CNUKCS2T.js";
|
|
21
|
+
import {
|
|
22
|
+
changesRelOf,
|
|
23
|
+
listQuestions,
|
|
24
|
+
loadOrgPack,
|
|
25
|
+
orgPackDirOf,
|
|
26
|
+
runsDirOf,
|
|
27
|
+
runsRelOf,
|
|
28
|
+
stepModelsOf
|
|
29
|
+
} from "./chunk-S2A7YC3Q.js";
|
|
30
|
+
|
|
31
|
+
// packages/cli/dist/handoff-flag.js
|
|
32
|
+
import { readdir, readFile } from "node:fs/promises";
|
|
33
|
+
import { join } from "node:path";
|
|
34
|
+
var isStage = (group, command) => group === "change" && (command === "feature" || command === "architecture" || command === "small") || group === "plan" && command === "stories";
|
|
35
|
+
async function runStates(root) {
|
|
36
|
+
const out = /* @__PURE__ */ new Map();
|
|
37
|
+
const dir = runsDirOf(root);
|
|
38
|
+
for (const change of await readdir(dir).catch(() => []))
|
|
39
|
+
for (const id of await readdir(join(dir, change)).catch(() => [])) {
|
|
40
|
+
const text = await readFile(join(dir, change, id, "run.json"), "utf8").catch(() => "");
|
|
41
|
+
if (!text)
|
|
42
|
+
continue;
|
|
43
|
+
try {
|
|
44
|
+
const run = JSON.parse(text);
|
|
45
|
+
out.set(`${change}/${id}`, { key: `${run.state}:${run.attempt}`, run });
|
|
46
|
+
} catch {
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
return out;
|
|
50
|
+
}
|
|
51
|
+
var OWN_MODES = /* @__PURE__ */ new Set(["model", "headless-claude-code"]);
|
|
52
|
+
function modeOf(argv) {
|
|
53
|
+
const at = argv.findIndex((a) => a === "--mode" || a.startsWith("--mode="));
|
|
54
|
+
if (at < 0)
|
|
55
|
+
return "hand-off";
|
|
56
|
+
const m = argv[at].includes("=") ? argv[at].split("=")[1] : argv[at + 1] ?? "";
|
|
57
|
+
return OWN_MODES.has(m) ? m : "hand-off";
|
|
58
|
+
}
|
|
59
|
+
function stepArgs(argv) {
|
|
60
|
+
const out = [];
|
|
61
|
+
for (let i = 0; i < argv.length; i++) {
|
|
62
|
+
const a = argv[i];
|
|
63
|
+
if (a === "--handoff" || a === "--json")
|
|
64
|
+
continue;
|
|
65
|
+
if (a === "--mode" || a === "--resume") {
|
|
66
|
+
i++;
|
|
67
|
+
continue;
|
|
68
|
+
}
|
|
69
|
+
if (a.startsWith("--mode=") || a.startsWith("--resume=") || a.startsWith("--handoff="))
|
|
70
|
+
continue;
|
|
71
|
+
out.push(a);
|
|
72
|
+
}
|
|
73
|
+
return out;
|
|
74
|
+
}
|
|
75
|
+
var shell = (a) => /^[\w./:@=+-]+$/.test(a) ? a : a.includes('"') ? JSON.stringify(a) : `"${a}"`;
|
|
76
|
+
async function handoffStep(root, argv, io, dispatch) {
|
|
77
|
+
const args = stepArgs(argv);
|
|
78
|
+
const resumeAt = argv.findIndex((a) => a === "--resume" || a.startsWith("--resume="));
|
|
79
|
+
const resume = resumeAt < 0 ? [] : argv[resumeAt].includes("=") ? [argv[resumeAt]] : argv.slice(resumeAt, resumeAt + 2);
|
|
80
|
+
const json = argv.includes("--json");
|
|
81
|
+
const before = await runStates(root);
|
|
82
|
+
const asked = json ? await openQuestions(root) : /* @__PURE__ */ new Map();
|
|
83
|
+
const out = [];
|
|
84
|
+
const err = [];
|
|
85
|
+
const facts = [];
|
|
86
|
+
let code;
|
|
87
|
+
try {
|
|
88
|
+
code = await dispatch([...args, ...resume, "--mode", modeOf(argv)], {
|
|
89
|
+
out: (l) => out.push(l),
|
|
90
|
+
err: (l) => err.push(l),
|
|
91
|
+
report: (f) => facts.push(f)
|
|
92
|
+
});
|
|
93
|
+
} catch (e) {
|
|
94
|
+
if (!json)
|
|
95
|
+
throw e;
|
|
96
|
+
err.push(e.message.split("\n")[0]);
|
|
97
|
+
code = 3;
|
|
98
|
+
}
|
|
99
|
+
const after = await runStates(root);
|
|
100
|
+
const byStart = (a, b) => a.startedAt.localeCompare(b.startedAt) || a.runId.localeCompare(b.runId);
|
|
101
|
+
const critic = isCritic(args[0], args[1]);
|
|
102
|
+
const stage = isStage(args[0], args[1]);
|
|
103
|
+
const queue = critic || stage;
|
|
104
|
+
const changeArg = critic ? args[1] : stage ? args[2] : void 0;
|
|
105
|
+
const ofChange = (x) => !changeArg || changeArg.startsWith("-") || x.request.change === changeArg;
|
|
106
|
+
const waiting = [...after].filter(([path, s]) => s.run.state === "waiting" && before.get(path)?.key !== s.key).map(([, s]) => s.run).filter(ofChange).sort(byStart);
|
|
107
|
+
const resumed = resume.length ? resume.join("=").split("=").at(-1) : void 0;
|
|
108
|
+
const resumedRun = [...after.values()].find((s) => s.run.runId === resumed)?.run;
|
|
109
|
+
const named = facts.map((f) => "handoff" in f ? f.handoff.runId : void 0).filter((x) => !!x).at(-1);
|
|
110
|
+
const namedRun = named ? [...after.values()].find((s) => s.run.runId === named)?.run : void 0;
|
|
111
|
+
const still = resumedRun && (resumedRun.state === "waiting" || resumedRun.state === "failed" && namedRun?.runId === resumedRun.runId) ? resumedRun : void 0;
|
|
112
|
+
const next = queue && resumedRun && !still ? [...after.values()].map((s) => s.run).filter((x) => x.state === "waiting" && x.runId !== resumedRun.runId && x.request.change === resumedRun.request.change && x.startedAt >= resumedRun.startedAt && (critic || !!lensRunOf(x.request))).sort(byStart)[0] : void 0;
|
|
113
|
+
const waitedOn = !resume.length && namedRun && before.get(`${namedRun.request.change}/${namedRun.runId}`) ? namedRun : void 0;
|
|
114
|
+
const offered = namedRun && ["waiting", "failed"].includes(namedRun.state) ? namedRun : void 0;
|
|
115
|
+
const run = offered ?? (queue ? waiting[0] : waiting.at(-1)) ?? still ?? next ?? waitedOn ?? void 0;
|
|
116
|
+
const pagesLeft = facts.map((f) => "pagesLeft" in f ? f.pagesLeft : void 0).filter((x) => x !== void 0).at(-1);
|
|
117
|
+
const stillOffered = !!run && (run === still || run === waitedOn);
|
|
118
|
+
if (json)
|
|
119
|
+
return printJson(root, argv, args, {
|
|
120
|
+
run,
|
|
121
|
+
still: stillOffered,
|
|
122
|
+
code,
|
|
123
|
+
out,
|
|
124
|
+
err,
|
|
125
|
+
asked,
|
|
126
|
+
...pagesLeft !== void 0 ? { pagesLeft } : {}
|
|
127
|
+
}, io);
|
|
128
|
+
if (!run) {
|
|
129
|
+
for (const l of out)
|
|
130
|
+
io.out(l);
|
|
131
|
+
for (const l of err)
|
|
132
|
+
io.err(l);
|
|
133
|
+
return code;
|
|
134
|
+
}
|
|
135
|
+
for (const l of err)
|
|
136
|
+
io.err(l);
|
|
137
|
+
if (stillOffered)
|
|
138
|
+
io.out(`Run ${run.runId} is still waiting for its result file.`);
|
|
139
|
+
const runsRel = runsRelOf(root);
|
|
140
|
+
io.out(`Prompt: ${HandoffRuntime.promptRel(run, runsRel)}`);
|
|
141
|
+
io.out(`Result file: ${HandoffRuntime.outputRel(run, changesRelOf(root), runsRel)}`);
|
|
142
|
+
const expects = await expectedModel(root, run, process.env);
|
|
143
|
+
if (expects)
|
|
144
|
+
io.out(expectedLine(expects));
|
|
145
|
+
io.out("When the result file is written, run:");
|
|
146
|
+
io.out(` atticus handoff done ${run.runId}${rootArg(argv)}`);
|
|
147
|
+
io.out(` atticus ${[...args, "--handoff", "--resume", run.runId].map(shell).join(" ")}`);
|
|
148
|
+
return 0;
|
|
149
|
+
}
|
|
150
|
+
async function openQuestions(root) {
|
|
151
|
+
const r = await listQuestions(root, { state: "open" });
|
|
152
|
+
return new Map(r.questions.map((q) => [q.id, `${q.askedBy.at}:${q.alsoAskedBy?.length ?? 0}:${q.rerun}`]));
|
|
153
|
+
}
|
|
154
|
+
var questionOut = (q) => ({
|
|
155
|
+
id: q.id,
|
|
156
|
+
repo: q.repo,
|
|
157
|
+
question: q.question,
|
|
158
|
+
options: q.options,
|
|
159
|
+
evidence: q.evidence,
|
|
160
|
+
answer: `atticus questions answer ${q.id}`
|
|
161
|
+
});
|
|
162
|
+
async function printJson(root, argv, args, s, io) {
|
|
163
|
+
const { run } = s;
|
|
164
|
+
if (run) {
|
|
165
|
+
const runsRel = runsRelOf(root);
|
|
166
|
+
const doneArgs = ["handoff", "done", run.runId, ...rootArgv(argv)];
|
|
167
|
+
const resumeArgs = [...args, "--handoff", "--json", "--resume", run.runId];
|
|
168
|
+
const lens = lensRunOf(run.request);
|
|
169
|
+
const stepClass = run.stepClass ?? stepClassOf(run.request);
|
|
170
|
+
const orgModel = (await orgModels(root))[stepClass];
|
|
171
|
+
io.out(JSON.stringify({
|
|
172
|
+
state: "handoff",
|
|
173
|
+
runId: run.runId,
|
|
174
|
+
// ADR 0115: one of the critic's AI lenses, reviewing what the step wrote.
|
|
175
|
+
...lens ? { lens } : {},
|
|
176
|
+
stepClass,
|
|
177
|
+
...orgModel ? { orgModel } : {},
|
|
178
|
+
root,
|
|
179
|
+
...s.still ? { stillWaiting: true } : {},
|
|
180
|
+
promptFile: HandoffRuntime.promptRel(run, runsRel),
|
|
181
|
+
resultFile: HandoffRuntime.outputRel(run, changesRelOf(root), runsRel),
|
|
182
|
+
doneCommand: `atticus ${doneArgs.map(shell).join(" ")}`,
|
|
183
|
+
doneArgs,
|
|
184
|
+
resumeCommand: `atticus ${resumeArgs.map(shell).join(" ")}`,
|
|
185
|
+
resumeArgs,
|
|
186
|
+
// ADR 0107 addendum: the read-only tools the model may call. A tool call runs as
|
|
187
|
+
// atticus <callArgs> <tool> --input <json> --round <n> --json <runArgs>, kept in the run.
|
|
188
|
+
tools: {
|
|
189
|
+
definitions: CONTEXT_TOOLS,
|
|
190
|
+
limits: TOOL_LIMITS,
|
|
191
|
+
callArgs: ["context", "call"],
|
|
192
|
+
runArgs: ["--run", run.runId, ...rootArgv(argv)]
|
|
193
|
+
},
|
|
194
|
+
messages: s.out,
|
|
195
|
+
// ADR 0115 addendum (2026-10-26): what the step said was wrong with an answer it read,
|
|
196
|
+
// so a tool that runs the loop shows it instead of re-sending the same prompt silently.
|
|
197
|
+
...s.err.length ? { errors: s.err } : {}
|
|
198
|
+
}, null, 2));
|
|
199
|
+
return 0;
|
|
200
|
+
}
|
|
201
|
+
const text = [...s.out, ...s.err].join("\n");
|
|
202
|
+
const open = (await listQuestions(root, { state: "open" })).questions;
|
|
203
|
+
const questions = open.filter((q) => {
|
|
204
|
+
const was = s.asked.get(q.id);
|
|
205
|
+
return was === void 0 || was !== `${q.askedBy.at}:${q.alsoAskedBy?.length ?? 0}:${q.rerun}` || text.includes(q.id);
|
|
206
|
+
});
|
|
207
|
+
const state = questions.length ? "question" : s.code === 0 ? "done" : s.code === 1 ? "stopped" : "failed";
|
|
208
|
+
io.out(JSON.stringify({
|
|
209
|
+
state,
|
|
210
|
+
exitCode: s.code,
|
|
211
|
+
root,
|
|
212
|
+
messages: s.out,
|
|
213
|
+
errors: s.err,
|
|
214
|
+
questions: questions.map(questionOut),
|
|
215
|
+
// A batched scan's pages left for the next batch, as data (never read from its words).
|
|
216
|
+
...s.pagesLeft !== void 0 ? { pagesLeft: s.pagesLeft } : {}
|
|
217
|
+
}, null, 2));
|
|
218
|
+
return s.code;
|
|
219
|
+
}
|
|
220
|
+
async function orgModels(root) {
|
|
221
|
+
return stepModelsOf(await loadOrgPack(orgPackDirOf(root)).then((op) => op.runtime).catch(() => void 0));
|
|
222
|
+
}
|
|
223
|
+
async function expectedModel(root, run, env) {
|
|
224
|
+
const stepClass = run.stepClass ?? stepClassOf(run.request);
|
|
225
|
+
const set = env[modelEnvOf(stepClass)]?.trim();
|
|
226
|
+
if (set && set !== "atticus")
|
|
227
|
+
return { stepClass, model: set, from: "setting" };
|
|
228
|
+
const org = (await orgModels(root))[stepClass];
|
|
229
|
+
return org ? { stepClass, model: org, from: "runtime.yaml" } : void 0;
|
|
230
|
+
}
|
|
231
|
+
var expectedLine = (e) => `Model: this is a ${e.stepClass} step, which runs on ${e.model} (${e.from === "setting" ? "your setting" : `runtime.yaml models.${e.stepClass}`}). Pick it in your assistant's model picker before you send the prompt.`;
|
|
232
|
+
function rootArgv(argv) {
|
|
233
|
+
const i = argv.indexOf("--root");
|
|
234
|
+
if (i >= 0 && argv[i + 1])
|
|
235
|
+
return ["--root", argv[i + 1]];
|
|
236
|
+
const eq = argv.find((a) => a.startsWith("--root="));
|
|
237
|
+
return eq ? [eq] : [];
|
|
238
|
+
}
|
|
239
|
+
function rootArg(argv) {
|
|
240
|
+
const i = argv.indexOf("--root");
|
|
241
|
+
if (i >= 0 && argv[i + 1])
|
|
242
|
+
return ` --root ${shell(argv[i + 1])}`;
|
|
243
|
+
const eq = argv.find((a) => a.startsWith("--root="));
|
|
244
|
+
return eq ? ` ${shell(eq)}` : "";
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
export {
|
|
248
|
+
handoffStep,
|
|
249
|
+
expectedModel,
|
|
250
|
+
expectedLine
|
|
251
|
+
};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { createRequire as __atticusCreateRequire } from "node:module";
|
|
2
|
+
import { fileURLToPath as __atticusFileURLToPath } from "node:url";
|
|
3
|
+
var require = __atticusCreateRequire(import.meta.url);
|
|
4
|
+
var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
|
|
5
|
+
var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
|
|
6
|
+
import {
|
|
7
|
+
completeCriticLens,
|
|
8
|
+
critic,
|
|
9
|
+
criticStats,
|
|
10
|
+
findingAction,
|
|
11
|
+
findings,
|
|
12
|
+
statusLine
|
|
13
|
+
} from "./chunk-RZUZ4RJJ.js";
|
|
14
|
+
import "./chunk-VOGCSYOI.js";
|
|
15
|
+
import "./chunk-7UFQZXZA.js";
|
|
16
|
+
import "./chunk-56YQ6ROQ.js";
|
|
17
|
+
import "./chunk-4AK7IBVP.js";
|
|
18
|
+
import "./chunk-7JUKDRSZ.js";
|
|
19
|
+
import "./chunk-OLWFG75W.js";
|
|
20
|
+
import "./chunk-L24C55VN.js";
|
|
21
|
+
import "./chunk-PAMPPUR6.js";
|
|
22
|
+
import "./chunk-23W7VWKR.js";
|
|
23
|
+
import "./chunk-7EKXJZ2Y.js";
|
|
24
|
+
import "./chunk-MC3H7736.js";
|
|
25
|
+
import "./chunk-KJPMEAI4.js";
|
|
26
|
+
import "./chunk-GQ4N4WKF.js";
|
|
27
|
+
import "./chunk-CNUKCS2T.js";
|
|
28
|
+
import "./chunk-S2A7YC3Q.js";
|
|
29
|
+
import "./chunk-D3PO4DOZ.js";
|
|
30
|
+
import "./chunk-TV45EUGM.js";
|
|
31
|
+
export {
|
|
32
|
+
completeCriticLens,
|
|
33
|
+
critic,
|
|
34
|
+
criticStats,
|
|
35
|
+
findingAction,
|
|
36
|
+
findings,
|
|
37
|
+
statusLine
|
|
38
|
+
};
|