@askexenow/exe-os 0.9.384 → 0.9.389
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/deploy/compose/.env.askexe-control-plane.example +6 -0
- package/deploy/compose/.env.customer.example +1 -1
- package/deploy/compose/.env.example +1 -1
- package/deploy/compose/docker-compose.yml +16 -0
- package/deploy/compose/generate-env.ts +1 -1
- package/deploy/compose/sso-edge/sso-redirect.conf +18 -3
- package/deploy/stack-manifests/v0.9.json +1160 -1
- package/dist/.dist-verified.json +3 -3
- package/dist/{active-agent-F5V4E4UL.js → active-agent-RZ24KSJN.js} +8 -6
- package/dist/{active-agent-YTBB4ZQM.js → active-agent-YWSWPIEA.js} +8 -6
- package/dist/{agent-defs-generator-7TFISIJQ.js → agent-defs-generator-GY3UBREJ.js} +8 -6
- package/dist/{agent-heartbeat-CQPGJIFF.js → agent-heartbeat-GUVUUQVM.js} +1 -1
- package/dist/{agent-loop-EZ7LDAGD.js → agent-loop-HPNCH3HK.js} +1 -1
- package/dist/{agentic-ontology-XVTUVV7W.js → agentic-ontology-RHYNXEKE.js} +1 -1
- package/dist/{artifact-backup-TF6YWQT2.js → artifact-backup-HGUFSIJH.js} +19 -6
- package/dist/{backfill-metadata-J6MXIDCW.js → backfill-metadata-XLFASEOD.js} +11 -9
- package/dist/{backup-verify-6DVBQMDP.js → backup-verify-TUQEICWA.js} +1 -1
- package/dist/{behavior-injection-XDA7ZCYN.js → behavior-injection-GXO7ERGN.js} +14 -12
- package/dist/{behavior-promotion-4VLQ7LXK.js → behavior-promotion-V63WIZ4N.js} +13 -11
- package/dist/{behaviors-SCCZP7RZ.js → behaviors-RMLDPLOF.js} +18 -11
- package/dist/bin/agentic-ontology-backfill.js +12 -10
- package/dist/bin/agentic-reflection-backfill.js +13 -11
- package/dist/bin/agentic-semantic-label.js +12 -10
- package/dist/bin/backfill-conversations.js +11 -9
- package/dist/bin/backfill-responses.js +11 -9
- package/dist/bin/backfill-vectors.js +13 -11
- package/dist/bin/bulk-sync-postgres.js +20 -18
- package/dist/bin/cc-doctor.js +15 -13
- package/dist/bin/cleanup-stale-review-tasks.js +44 -32
- package/dist/bin/cli.js +109 -30
- package/dist/bin/customer-readiness.js +55 -25
- package/dist/bin/deferred-daemon-restart.js +111 -108
- package/dist/bin/exe-actions.js +7 -1
- package/dist/bin/exe-agent-config.js +8 -6
- package/dist/bin/exe-agent.js +18 -16
- package/dist/bin/exe-assign.js +13 -11
- package/dist/bin/exe-boot.js +49 -47
- package/dist/bin/exe-call.js +9 -7
- package/dist/bin/exe-cicd.js +19 -8
- package/dist/bin/exe-cloud.js +59 -25
- package/dist/bin/exe-config-dump.js +8 -6
- package/dist/bin/exe-dispatch.js +23 -21
- package/dist/bin/exe-doctor.js +11 -8
- package/dist/bin/exe-export-behaviors.js +16 -14
- package/dist/bin/exe-forget.js +14 -12
- package/dist/bin/exe-gateway.js +12 -10
- package/dist/bin/exe-grant.js +6 -6
- package/dist/bin/exe-healthcheck.js +15 -13
- package/dist/bin/exe-heartbeat.js +28 -26
- package/dist/bin/exe-kill.js +28 -26
- package/dist/bin/exe-launch-agent.js +35 -33
- package/dist/bin/exe-mcp.js +9 -7
- package/dist/bin/exe-memory-reads.js +11 -9
- package/dist/bin/exe-new-employee.js +13 -11
- package/dist/bin/exe-os-mcp-proxy.js +9 -7
- package/dist/bin/exe-pending-messages.js +23 -21
- package/dist/bin/exe-pending-notifications.js +22 -20
- package/dist/bin/exe-pending-reviews.js +23 -21
- package/dist/bin/exe-preflight.js +1 -1
- package/dist/bin/exe-rename.js +9 -7
- package/dist/bin/exe-review.js +59 -55
- package/dist/bin/exe-search-quality.js +16 -3
- package/dist/bin/exe-search.js +13 -11
- package/dist/bin/exe-session-cleanup.js +29 -27
- package/dist/bin/exe-settings.js +22 -20
- package/dist/bin/exe-start-codex.js +23 -21
- package/dist/bin/exe-start-opencode.js +21 -19
- package/dist/bin/exe-status.js +24 -22
- package/dist/bin/exe-support.js +3 -3
- package/dist/bin/exe-team.js +8 -6
- package/dist/bin/exe-verify-running-images.js +644 -17
- package/dist/bin/git-sweep.js +24 -22
- package/dist/bin/graph-backfill.js +12 -10
- package/dist/bin/graph-export.js +12 -10
- package/dist/bin/hooks-cli.js +4 -4
- package/dist/bin/import-history.js +16 -14
- package/dist/bin/install.js +113 -110
- package/dist/bin/intercom-check.js +5 -5
- package/dist/bin/mcp-sessions.js +2 -2
- package/dist/bin/orchestration-metrics.js +8 -6
- package/dist/bin/postgres-agentic-reflection-backfill.js +2 -2
- package/dist/bin/postgres-agentic-semantic-backfill.js +1 -1
- package/dist/bin/pre-build-guard.js +55 -16
- package/dist/bin/pre-publish.js +1 -1
- package/dist/bin/prune-orphan-chunks.js +154 -28
- package/dist/bin/reconcile-backlog.js +5 -3
- package/dist/bin/registry-proxy.js +1 -1
- package/dist/bin/repair-document-chunks.js +11 -9
- package/dist/bin/scan-tasks.js +23 -21
- package/dist/bin/setup.js +3 -3
- package/dist/bin/shard-migrate.js +12 -10
- package/dist/bin/stack-update.js +622 -43
- package/dist/bin/verify-stack.js +2 -2
- package/dist/bin/vps-health-gate.js +1 -1
- package/dist/{boot-generation-Q7LGQ3AO.js → boot-generation-VCQXVYGT.js} +7 -5
- package/dist/{boot-review-sections-G5774FR5.js → boot-review-sections-3QO6Q7MP.js} +21 -19
- package/dist/{branch-hygiene-44WLSOZR.js → branch-hygiene-DDXXI6ZA.js} +59 -21
- package/dist/bug-landed-reconciler-TQVNOUCU.js +353 -0
- package/dist/build-manifest.json +1269 -1194
- package/dist/{capability-cards-I3RHCF4F.js → capability-cards-XPDLT6LU.js} +6 -4
- package/dist/{capacity-monitor-7I7GDONU.js → capacity-monitor-N3AW242L.js} +23 -21
- package/dist/{catchup-brief-3T5PARIR.js → catchup-brief-3PKX7FUP.js} +29 -27
- package/dist/{chunk-C5ISP5FO.js → chunk-2BKJAOO4.js} +11 -1
- package/dist/{chunk-JJTPPAZY.js → chunk-2CUQHG6H.js} +1609 -1356
- package/dist/{chunk-HU3VD4MQ.js → chunk-2Q2GGYBX.js} +1 -1
- package/dist/{chunk-CHIUS5QB.js → chunk-36LMIOVU.js} +9 -9
- package/dist/{chunk-46VSBDUW.js → chunk-3DCBDG4T.js} +2 -2
- package/dist/{chunk-W3KPQE7H.js → chunk-3GL3E4TD.js} +3 -3
- package/dist/{chunk-GL47M7NY.js → chunk-3UD3OF3X.js} +202 -117
- package/dist/{chunk-WNBZJSQT.js → chunk-3VW5ZP2F.js} +1 -1
- package/dist/{chunk-JDDM6C57.js → chunk-3X74IQBU.js} +1 -1
- package/dist/{chunk-NVFNADTX.js → chunk-3ZL4MDQ6.js} +18 -4
- package/dist/{chunk-R5E7WNAC.js → chunk-4ESNDGMB.js} +3 -3
- package/dist/{chunk-CYCIX7AW.js → chunk-4FLLIQRQ.js} +2 -2
- package/dist/{chunk-3RGTLZNO.js → chunk-4GAKF7KR.js} +99 -74
- package/dist/{chunk-RVO5O5SR.js → chunk-4S3A52AV.js} +38 -10
- package/dist/{chunk-7J2ZQ4XN.js → chunk-4VQ3QR6B.js} +29 -28
- package/dist/{chunk-MROSARM5.js → chunk-5BJBTFFQ.js} +7 -1
- package/dist/chunk-5LQZABW5.js +6 -0
- package/dist/chunk-5ONMHTNI.js +236 -0
- package/dist/{chunk-APL7HUE3.js → chunk-5QQJUO3F.js} +200 -31
- package/dist/{chunk-UOPCVFVR.js → chunk-5RK75SWH.js} +205 -278
- package/dist/{chunk-T5FEAQES.js → chunk-5TYJYGS5.js} +1 -1
- package/dist/{chunk-P3QQ52QK.js → chunk-5U6EOTZV.js} +3 -3
- package/dist/{chunk-ALRHGEAJ.js → chunk-637FL62O.js} +1 -1
- package/dist/{chunk-PUBA5B4M.js → chunk-6L4VIYLZ.js} +33 -19
- package/dist/{chunk-VF2KRROX.js → chunk-754P2UXM.js} +1 -1
- package/dist/{chunk-CM7N5MBY.js → chunk-7FZG7WP4.js} +5 -5
- package/dist/{chunk-NYLJQ2M2.js → chunk-7NEBFB3L.js} +4 -4
- package/dist/{chunk-E7C2WNR5.js → chunk-AEIOFFFX.js} +5 -5
- package/dist/{chunk-VOVFUKEB.js → chunk-AIB2EWO2.js} +5 -5
- package/dist/{chunk-EGOEB42T.js → chunk-AP2C4OGS.js} +3 -3
- package/dist/{chunk-MPZ2AVNS.js → chunk-ATNV3BVZ.js} +1 -1
- package/dist/{chunk-F4BBMIPG.js → chunk-B4XJQBQB.js} +2 -2
- package/dist/{chunk-BPVFZ6Q4.js → chunk-B5EGDNG6.js} +2 -2
- package/dist/{chunk-AGC2V7JS.js → chunk-B6CBN6EF.js} +1 -1
- package/dist/{chunk-KTKIFXIP.js → chunk-B7FDRN7G.js} +1 -1
- package/dist/{chunk-C5HUMAA7.js → chunk-B7WVYLAQ.js} +67 -15
- package/dist/chunk-BGVP5RMT.js +185 -0
- package/dist/{chunk-FVLNNNH6.js → chunk-BNI4LIU5.js} +35 -4
- package/dist/{chunk-P4XLIPB7.js → chunk-BU5JRLZT.js} +1 -1
- package/dist/{chunk-PHUHIVD5.js → chunk-C6U7XWOC.js} +34 -5
- package/dist/chunk-C7GHNJPW.js +8 -0
- package/dist/{chunk-4AR5XKCH.js → chunk-CL2MU3OX.js} +1 -1
- package/dist/{chunk-ZPP63JSQ.js → chunk-CL3AB7Z2.js} +1 -1
- package/dist/{chunk-FHIFTSPL.js → chunk-CP7XUSOF.js} +8 -3
- package/dist/{chunk-3OX34OC3.js → chunk-CUDNRHHT.js} +30 -10
- package/dist/chunk-CYUUNIEL.js +21 -0
- package/dist/{chunk-P2UY34XE.js → chunk-D4C57S2H.js} +5 -5
- package/dist/{chunk-XSUALA32.js → chunk-DDYFNBYV.js} +3 -3
- package/dist/{chunk-LSNBTGW4.js → chunk-DPYZW42H.js} +1 -1
- package/dist/{chunk-FMIYFHLE.js → chunk-E2PRXEZK.js} +9 -3
- package/dist/{chunk-L63V25HS.js → chunk-E54SPUYJ.js} +3 -3
- package/dist/{chunk-DMUOTCDN.js → chunk-E5CKRHIZ.js} +1 -1
- package/dist/{chunk-BV2IET6B.js → chunk-EVMOKRBC.js} +15 -2
- package/dist/{chunk-YLFCH3VA.js → chunk-FDWI3T6I.js} +133 -31
- package/dist/{chunk-PWC3C5ME.js → chunk-FNJTCJGY.js} +4 -4
- package/dist/{chunk-TNS63ATU.js → chunk-FWRPDSO3.js} +350 -50
- package/dist/{chunk-JA3Y5TV6.js → chunk-GDLB6BPM.js} +141 -74
- package/dist/{chunk-IGJMS7C5.js → chunk-GOVGG7HU.js} +2 -2
- package/dist/{chunk-MB47DRF5.js → chunk-GP7CTIUK.js} +2 -2
- package/dist/{chunk-L5EPGGDP.js → chunk-GWAN2BDB.js} +4 -4
- package/dist/{chunk-YRQ26MNP.js → chunk-H3YF7X4J.js} +12 -5
- package/dist/{chunk-VLBHZ6TF.js → chunk-H6PLIFUE.js} +2 -2
- package/dist/{chunk-GSLFH4AI.js → chunk-HRNM3N4Y.js} +6 -15
- package/dist/chunk-IG2ISRTF.js +48 -0
- package/dist/{chunk-MWEIBVBS.js → chunk-IJCWBYA5.js} +14 -1
- package/dist/{chunk-NKEFYE4R.js → chunk-IPTUKX3N.js} +1 -1
- package/dist/{chunk-RB3J2WYQ.js → chunk-IVE7H6KA.js} +1 -1
- package/dist/{chunk-HA63SH5W.js → chunk-IWY2OGQG.js} +1 -1
- package/dist/{chunk-BQEZPRUC.js → chunk-IZWMWJZT.js} +64 -46
- package/dist/{chunk-AHESD3KW.js → chunk-J4UVI652.js} +1 -1
- package/dist/{chunk-PLII76NJ.js → chunk-JBUCA4OX.js} +33 -6
- package/dist/{chunk-2PZTMSMG.js → chunk-JOF4HQDF.js} +5 -5
- package/dist/{chunk-OBBO6EJR.js → chunk-JQN3QGSF.js} +1 -1
- package/dist/{chunk-P4PIZOL2.js → chunk-JWYIH5DR.js} +3 -3
- package/dist/{chunk-3XY57PKT.js → chunk-KZLKE7I3.js} +210 -48
- package/dist/{chunk-DYVLEMKS.js → chunk-L3GXMYBK.js} +1 -1
- package/dist/{chunk-72V3S44T.js → chunk-LUA4SLJY.js} +46 -19
- package/dist/{chunk-ZT4LFTUJ.js → chunk-LW3JCBXP.js} +20 -3
- package/dist/{chunk-YLB365YX.js → chunk-M5XHN4OM.js} +3 -3
- package/dist/{chunk-VHHX4UCP.js → chunk-MDTWARSF.js} +22 -93
- package/dist/{chunk-JFJP6ATJ.js → chunk-MWKXQSF6.js} +3 -2
- package/dist/{chunk-VJEJ7JNB.js → chunk-N32DVIKY.js} +1 -1
- package/dist/{chunk-MUCNYSJP.js → chunk-NRLJOV7M.js} +32 -4
- package/dist/{chunk-PL4CFSQ7.js → chunk-NSXJOSH7.js} +1 -1
- package/dist/{chunk-NF5FOSLD.js → chunk-NVTG66CK.js} +1 -1
- package/dist/chunk-O45GBJEH.js +1500 -0
- package/dist/{chunk-4AAMFWJT.js → chunk-OHZSTZXN.js} +4 -2
- package/dist/chunk-OSIS7ZQW.js +344 -0
- package/dist/{chunk-E3ZM32LF.js → chunk-P22VFGFK.js} +14 -5
- package/dist/{chunk-KILR4FBR.js → chunk-PAFLR7WD.js} +3 -3
- package/dist/{chunk-R3CZWFFC.js → chunk-PEYQ6MWO.js} +15 -3
- package/dist/{chunk-RDWIKDMY.js → chunk-PZR54BEI.js} +8 -20
- package/dist/{chunk-2FKU4ZEO.js → chunk-QDBKMEYY.js} +9 -9
- package/dist/{chunk-7UHZBVP3.js → chunk-QDVLVLXP.js} +97 -31
- package/dist/{chunk-PRDDPQLC.js → chunk-QLXEQRHD.js} +5 -5
- package/dist/{chunk-MUAWCFW6.js → chunk-QNPDXV5V.js} +5 -2
- package/dist/{chunk-LR5O2XWZ.js → chunk-QUZYLDNJ.js} +5 -5
- package/dist/chunk-RBQUXHYK.js +48 -0
- package/dist/{chunk-3SUPEE6H.js → chunk-RDMBSHGG.js} +3 -3
- package/dist/{chunk-I5XIW2BP.js → chunk-RGUM474V.js} +7 -7
- package/dist/{chunk-OAFENIHN.js → chunk-RJ67XAJU.js} +76 -28
- package/dist/{chunk-LFUBEHFW.js → chunk-RT57D7C4.js} +39 -1
- package/dist/{chunk-MKM6D7JM.js → chunk-RWG7DLOG.js} +42 -5
- package/dist/{chunk-P3UX5EH4.js → chunk-RWKAHHIX.js} +3 -3
- package/dist/{chunk-XEBKIWI7.js → chunk-RYNT3HB7.js} +12 -12
- package/dist/{chunk-EUGEFBGV.js → chunk-S2V272KJ.js} +3 -3
- package/dist/{chunk-W6BZ4UGA.js → chunk-SGYEM2PD.js} +1 -1
- package/dist/{chunk-VROK4X2L.js → chunk-SJP57MQM.js} +1 -1
- package/dist/{chunk-5MVKTNZP.js → chunk-SL4JWAMQ.js} +54 -4
- package/dist/{chunk-MOANZQXF.js → chunk-SLMKLEU6.js} +1 -1
- package/dist/{chunk-RZN2LEAK.js → chunk-SQA7XCYI.js} +3 -3
- package/dist/{chunk-4YNA3CM6.js → chunk-SSFS4NCH.js} +262 -56
- package/dist/{chunk-6FIC57PH.js → chunk-T4P2G3PO.js} +1 -1
- package/dist/{chunk-5U2IJBFV.js → chunk-TA3B4N24.js} +1 -1
- package/dist/{chunk-ZOTTYCP5.js → chunk-TEWWBVQP.js} +40 -4
- package/dist/{chunk-SDYWZRPN.js → chunk-TLSFGXXE.js} +1 -1
- package/dist/{chunk-L3VUW5M4.js → chunk-TQS2YHLB.js} +1 -1
- package/dist/{chunk-KXYKSLW4.js → chunk-TU4M757W.js} +399 -116
- package/dist/{chunk-MC4IM2CC.js → chunk-TYD4F4XU.js} +6 -6
- package/dist/{chunk-TKS5GMYA.js → chunk-U44Y7RC7.js} +2 -0
- package/dist/{chunk-B7AMNZTC.js → chunk-UKBPEEEQ.js} +2 -2
- package/dist/{chunk-ZBPZDADW.js → chunk-UWVXQEQQ.js} +467 -78
- package/dist/{chunk-P2VVMGMI.js → chunk-V4WH3FV7.js} +35 -16
- package/dist/{worktree-ownership-guard-O6JQF2CL.js → chunk-V6F4I2XY.js} +13 -14
- package/dist/{chunk-JFTUAV4J.js → chunk-VBKUESIW.js} +1 -1
- package/dist/{chunk-AZSTIAVL.js → chunk-VBPYYJPC.js} +1 -1
- package/dist/{chunk-LKTN22L6.js → chunk-VIP4LKLO.js} +57 -24
- package/dist/{chunk-L5CGXEZC.js → chunk-WAAGVFFN.js} +63 -71
- package/dist/{chunk-D3LXVAIQ.js → chunk-WC7AE3PT.js} +244 -103
- package/dist/{chunk-EOTZSAQL.js → chunk-WUCUDHKR.js} +1 -1
- package/dist/{chunk-VF3BZOZK.js → chunk-X7HZHKY4.js} +50 -3
- package/dist/{chunk-LFBLQE2P.js → chunk-XCAKYVKI.js} +1 -1
- package/dist/{chunk-UXN4BICC.js → chunk-XMX5J52Z.js} +1 -1
- package/dist/{chunk-6YDY6ZTD.js → chunk-XTCXGWTV.js} +9 -4
- package/dist/{chunk-XUZK23V7.js → chunk-XW2FW6LS.js} +2 -2
- package/dist/{chunk-CH7BUBP3.js → chunk-XWVHUDEK.js} +5 -4
- package/dist/{chunk-S26CV7BE.js → chunk-YA5LK6KB.js} +45 -8
- package/dist/{chunk-ELCRJGCH.js → chunk-YMRQIENV.js} +2 -2
- package/dist/{chunk-QNZ4562V.js → chunk-Z3LXWCB7.js} +1 -1
- package/dist/{chunk-EYMFVITZ.js → chunk-Z7I6NQMA.js} +2 -2
- package/dist/{chunk-6BJCDWSM.js → chunk-ZB4FS2EG.js} +1 -1
- package/dist/{chunk-ZAEUEDTN.js → chunk-ZD6FZ3WL.js} +1 -1
- package/dist/{chunk-FEU6QEEL.js → chunk-ZM6EZAVY.js} +1 -0
- package/dist/{chunk-2KY7WZZF.js → chunk-ZPA4R2UI.js} +1 -1
- package/dist/chunk-ZPPPHVSU.js +285 -0
- package/dist/{chunk-ELEGH4DX.js → chunk-ZUGQPYUY.js} +51 -4
- package/dist/{chunk-UX2EO653.js → chunk-ZZWFZ46U.js} +66 -8
- package/dist/{cleanup-graph-garbage-VQAJ2RBT.js → cleanup-graph-garbage-HFUD5ZQT.js} +12 -10
- package/dist/{cloud-sync-command-J7NEFUY7.js → cloud-sync-command-3JHJJKPN.js} +25 -3
- package/dist/{cloud-sync-db-init-KWEMNMGA.js → cloud-sync-db-init-2LHIQOSF.js} +1 -1
- package/dist/{cloud-sync-shutdown-P63AUTUI.js → cloud-sync-shutdown-ZXAXA3Z7.js} +6 -4
- package/dist/{cloud-sync-state-QF3TMMJ4.js → cloud-sync-state-VSQFGPP6.js} +1 -1
- package/dist/{co-activation-7IHRPBZN.js → co-activation-NX4EH4AP.js} +6 -4
- package/dist/{co-occurrence-R5AG4OAU.js → co-occurrence-5LBYCW3U.js} +10 -8
- package/dist/{consent-passphrase-5ZBDJ5G7.js → consent-passphrase-65W3DJIJ.js} +2 -2
- package/dist/{content-extractor-ZLXC6GNR.js → content-extractor-OGXETBOX.js} +2 -2
- package/dist/{conversation-entity-extractor-7FRKLLBD.js → conversation-entity-extractor-FQCOAH4F.js} +5 -4
- package/dist/conversations-retention-XTBFJBUM.js +166 -0
- package/dist/{crdt-sync-IFRZOEIS.js → crdt-sync-7TDUBTLH.js} +4 -4
- package/dist/{crm-webhook-L2S63ASV.js → crm-webhook-776JTY55.js} +2 -2
- package/dist/{cto-delegation-gate-3WU7OHX7.js → cto-delegation-gate-ZNUWVYCN.js} +25 -23
- package/dist/{daemon-orchestration-3VQYKLOR.js → daemon-orchestration-76BOFDEP.js} +30 -24
- package/dist/{doc-graph-extractor-YIR5E7OF.js → doc-graph-extractor-F724KZJX.js} +10 -8
- package/dist/{documents-QEHPTYIY.js → documents-Q24V4GRD.js} +13 -11
- package/dist/{dreaming-LNFE7DTN.js → dreaming-IY6NQTSP.js} +27 -25
- package/dist/{employee-boot-brief-ZTXDYNWM.js → employee-boot-brief-CCTXO5DQ.js} +35 -29
- package/dist/{entity-boost-R5N6JWXD.js → entity-boost-XGOB7HDM.js} +1 -1
- package/dist/{exe-drift-WYSJVZFO.js → exe-drift-NEPXLNGP.js} +7 -5
- package/dist/{exe-export-GOLNAEAV.js → exe-export-ZHJQFKR2.js} +14 -12
- package/dist/{exe-import-U4BSI6OH.js → exe-import-7SVNI4FW.js} +14 -12
- package/dist/{exe-key-V42G3NGO.js → exe-key-QJKU56WZ.js} +119 -108
- package/dist/{exe-org-U4GLQ6OP.js → exe-org-SJXHLV6K.js} +76 -51
- package/dist/{exe-snapshot-U7ONBYNY.js → exe-snapshot-EFWPXTXE.js} +45 -36
- package/dist/{fast-db-init-W3NGKAEU.js → fast-db-init-BQZOQNT3.js} +1 -1
- package/dist/{founder-context-ZSIBRVDM.js → founder-context-KG2ZAOXY.js} +2 -2
- package/dist/{founder-monitor-envelope-L3IWZLFY.js → founder-monitor-envelope-NYB5LLU4.js} +4 -4
- package/dist/gateway/index.js +20 -18
- package/dist/{gateway-client-DJFCVIPT.js → gateway-client-ODMUXUL3.js} +1 -1
- package/dist/{git-staleness-OF24QXFZ.js → git-staleness-OPGEAJA7.js} +6 -4
- package/dist/{global-procedures-WSIOWO43.js → global-procedures-3KXY4LL6.js} +8 -6
- package/dist/{graph-auto-extract-IEVVN3L3.js → graph-auto-extract-I7H2F5NJ.js} +10 -8
- package/dist/{graph-query-JDZWAVCU.js → graph-query-E7JBSNY5.js} +1 -1
- package/dist/{graph-rag-BKAD2XQA.js → graph-rag-H24CMFP2.js} +5 -4
- package/dist/{hook-integrity-TPWDGX2M.js → hook-integrity-PGQ3OX4S.js} +1 -1
- package/dist/{hook-prefetch-FD6VGJJA.js → hook-prefetch-7AZJER6Z.js} +23 -21
- package/dist/hook-registration-liveness-NGQRFKAA.js +11 -0
- package/dist/hooks/bug-report-worker.js +26 -24
- package/dist/hooks/codex-stop-task-finalizer.js +28 -26
- package/dist/hooks/commit-complete.js +26 -24
- package/dist/hooks/error-recall.js +16 -14
- package/dist/hooks/exe-heartbeat-hook.js +9 -7
- package/dist/hooks/ingest-worker.js +12 -10
- package/dist/hooks/ingest.js +22 -17
- package/dist/hooks/instructions-loaded.js +11 -9
- package/dist/hooks/manifest.json +20 -20
- package/dist/hooks/notification.js +10 -8
- package/dist/hooks/post-compact.js +9 -7
- package/dist/hooks/post-tool-combined.js +14 -14
- package/dist/hooks/pre-compact.js +26 -24
- package/dist/hooks/pre-tool-use.js +2 -2
- package/dist/hooks/prompt-submit.js +47 -41
- package/dist/hooks/session-end.js +38 -42
- package/dist/hooks/session-start.js +26 -18
- package/dist/hooks/stop.js +29 -27
- package/dist/hooks/subagent-stop.js +29 -27
- package/dist/hooks/summary-worker.js +32 -30
- package/dist/index.js +37 -35
- package/dist/{installer-OTI5SA43.js → installer-2ZS3LHCU.js} +12 -9
- package/dist/{installer-NMOBSEZ2.js → installer-NH3A3HWC.js} +14 -9
- package/dist/{installer-SRJGE4GU.js → installer-UJ73PGRD.js} +21 -9
- package/dist/{intercom-queue-4FFXCBHO.js → intercom-queue-OE25GJF2.js} +21 -19
- package/dist/lib/agent-config.js +2 -2
- package/dist/lib/cloud-sync.js +24 -18
- package/dist/lib/consolidation.js +13 -11
- package/dist/lib/crypto.js +3 -3
- package/dist/lib/database.js +6 -4
- package/dist/lib/db-backup.js +1 -1
- package/dist/lib/db-write-worker-client.js +3 -1
- package/dist/lib/db-write-worker.js +65 -89
- package/dist/lib/db.js +6 -4
- package/dist/lib/delivery-truth.js +5 -1
- package/dist/lib/device-registry.js +1 -1
- package/dist/lib/embedder.js +2 -2
- package/dist/lib/employee-templates.js +9 -7
- package/dist/lib/employees.js +6 -4
- package/dist/lib/exe-daemon.js +425 -314
- package/dist/lib/file-grep.js +15 -21
- package/dist/lib/hybrid-search.js +19 -13
- package/dist/lib/identity-templates.js +1 -1
- package/dist/lib/identity.js +6 -4
- package/dist/lib/keychain.js +1 -1
- package/dist/lib/license.js +22 -6
- package/dist/lib/messaging.js +22 -20
- package/dist/lib/post-tool-memory.js +10 -8
- package/dist/lib/registry-proxy.js +1 -1
- package/dist/lib/reminders.js +7 -5
- package/dist/lib/runtime-table.js +1 -1
- package/dist/lib/schedules.js +12 -10
- package/dist/lib/session-registry.js +8 -6
- package/dist/lib/skill-learning.js +13 -11
- package/dist/lib/status-brief.js +2 -2
- package/dist/lib/store.js +17 -9
- package/dist/lib/task-router.js +7 -5
- package/dist/lib/tasks.js +23 -21
- package/dist/lib/tmux-routing.js +21 -19
- package/dist/lib/tmux-status.js +4 -1
- package/dist/lib/token-spend.js +7 -5
- package/dist/lib/ws-client.js +1 -1
- package/dist/{license-gate-R4JWTWM4.js → license-gate-XQ2KN5I5.js} +3 -3
- package/dist/{license-recheck-3MBJ4IJX.js → license-recheck-IIBKR2V5.js} +1 -1
- package/dist/{license-sync-BVSG3WMW.js → license-sync-76JVI2M5.js} +151 -8
- package/dist/{local-secret-inventory-JWNBHZZ4.js → local-secret-inventory-MJT7NJLY.js} +2 -2
- package/dist/{mailbox-inbox-MTAT4MXX.js → mailbox-inbox-BPZP4GIZ.js} +1 -1
- package/dist/maintenance-worker-54VZTFIK.js +371 -0
- package/dist/mcp/register-tools.js +110 -107
- package/dist/mcp/server.js +113 -110
- package/dist/mcp/tools/complete-reminder.js +8 -6
- package/dist/mcp/tools/create-reminder.js +8 -6
- package/dist/mcp/tools/create-task.js +26 -24
- package/dist/mcp/tools/deactivate-behavior.js +15 -13
- package/dist/mcp/tools/list-reminders.js +8 -6
- package/dist/mcp/tools/list-tasks.js +26 -24
- package/dist/mcp/tools/send-message.js +25 -23
- package/dist/mcp/tools/update-task.js +24 -22
- package/dist/{mcp-child-registry-TIZERM7O.js → mcp-child-registry-5VUG5ATZ.js} +1 -1
- package/dist/{mcp-http-config-VUMSFWFH.js → mcp-http-config-SKXESWHA.js} +9 -7
- package/dist/{mcp-session-identity-DZHWEJRV.js → mcp-session-identity-HYMLJXXA.js} +21 -19
- package/dist/{memory-cards-JVXTMSAT.js → memory-cards-PAZDUQ3B.js} +16 -32
- package/dist/{memory-graph-extractor-PPBJMYFJ.js → memory-graph-extractor-BC6QKBY6.js} +11 -9
- package/dist/{memory-poisoning-defense-K5Q74XQ4.js → memory-poisoning-defense-BRGIHF6J.js} +9 -7
- package/dist/{memory-pressure-watchdog-YMJH5CSA.js → memory-pressure-watchdog-HR6TPOMT.js} +22 -20
- package/dist/{memory-reflection-7BZWIHRE.js → memory-reflection-LO7VFBL3.js} +38 -59
- package/dist/memory-write-repository-J25USX63.js +16 -0
- package/dist/{monitor-grants-Q7X3MYQP.js → monitor-grants-YQTO6NWR.js} +3 -3
- package/dist/{monitor-identity-ZQB4IXEE.js → monitor-identity-POVTG76Y.js} +2 -2
- package/dist/{notification-ledger-XRAXL5OI.js → notification-ledger-KLD6GZTG.js} +22 -20
- package/dist/{notifications-JE3PX55X.js → notifications-3R6HNHDR.js} +21 -19
- package/dist/{orchestration-events-JCQ5F5IJ.js → orchestration-events-CHY3GOJD.js} +7 -5
- package/dist/{orchestrator-X65INDTR.js → orchestrator-GAL3HOAD.js} +23 -21
- package/dist/{org-brief-session-3PQ22UIX.js → org-brief-session-LQ2DBYVF.js} +17 -15
- package/dist/{org-consent-policy-VGELJ7K7.js → org-consent-policy-KFUP7QPG.js} +5 -5
- package/dist/{org-join-6TO5ZYUZ.js → org-join-MXZCIQWX.js} +8 -8
- package/dist/{org-key-admin-XHYVRRAZ.js → org-key-admin-4UK6QUT7.js} +9 -9
- package/dist/{org-key-pin-TTTYGTQL.js → org-key-pin-ZOX4OM3O.js} +3 -3
- package/dist/{org-membership-Y7T2BS57.js → org-membership-D5TPN45F.js} +4 -4
- package/dist/{org-partner-config-OP4NEUNF.js → org-partner-config-3FXSYPQA.js} +7 -7
- package/dist/{org-partner-runtime-YNVUNT2R.js → org-partner-runtime-TH3LMPII.js} +20 -16
- package/dist/{org-row-visibility-JBBXNYXD.js → org-row-visibility-Y5R33C5U.js} +1 -1
- package/dist/{pipeline-router-EIBB7QNG.js → pipeline-router-E2JZLDK6.js} +7 -5
- package/dist/{plan-limits-MEWXYLEN.js → plan-limits-NYI6R4IK.js} +9 -7
- package/dist/{platform-procedures-Z7ZGBJWN.js → platform-procedures-RTD5E3BD.js} +5 -3
- package/dist/{pre-tool-use-impl-C6KJY22W.js → pre-tool-use-impl-LT4FRXBP.js} +127 -83
- package/dist/{project-boot-VEYFCCSL.js → project-boot-LIMXQKAF.js} +25 -17
- package/dist/{project-name-UYORSNGE.js → project-name-V62GWALX.js} +7 -5
- package/dist/{projection-worker-WYFDWS57.js → projection-worker-KLE3IZQ2.js} +5 -2
- package/dist/{prospective-memory-E6XBQFJA.js → prospective-memory-HRN7JFT2.js} +6 -4
- package/dist/{push-notifications-M7YU63FY.js → push-notifications-XC6EQEXF.js} +22 -20
- package/dist/{reproject-worktree-memories-B5XMGJSD.js → reproject-worktree-memories-4CAVZSFE.js} +21 -19
- package/dist/{reranker-SRA4BR7N.js → reranker-2RU6IIX2.js} +1 -1
- package/dist/{retrieval-health-P2JPZUPV.js → retrieval-health-4Q5TOV2S.js} +1 -1
- package/dist/{review-polling-KQPN7IQE.js → review-polling-WOWIMBCL.js} +22 -20
- package/dist/runtime/index.js +30 -28
- package/dist/{session-events-6LDDKKY3.js → session-events-OPMS2C5F.js} +22 -20
- package/dist/{session-kill-telemetry-5DSRGWCL.js → session-kill-telemetry-3GWATSIX.js} +22 -20
- package/dist/{session-scope-XG5R3P3D.js → session-scope-TIRGR4MH.js} +21 -19
- package/dist/{setup-wizard-7QFLZIKT.js → setup-wizard-B2JBVGNH.js} +3 -3
- package/dist/{shard-manager-HHHHV2KZ.js → shard-manager-C7LYX6E4.js} +5 -1
- package/dist/{skill-refinement-I5RMAHSC.js → skill-refinement-FWQFYNBI.js} +7 -5
- package/dist/skill-retrieval-PPLFC5RY.js +166 -0
- package/dist/skill-usage-NDB67PU2.js +25 -0
- package/dist/{stack-generate-manifest-AKMZ3AUX.js → stack-generate-manifest-AXI55MEQ.js} +6 -6
- package/dist/{stack-promote-34CE2HHF.js → stack-promote-6N23OGZY.js} +6 -6
- package/dist/stack-release-2CXFYVWM.js +2770 -0
- package/dist/{stack-update-ZQQ5YYPJ.js → stack-update-U53FBVCQ.js} +13 -5
- package/dist/{steward-gate-AQJ6KT2C.js → steward-gate-TUA3QCN7.js} +7 -5
- package/dist/{subagent-brief-injection-3GU7YAWY.js → subagent-brief-injection-N52RWYFZ.js} +34 -32
- package/dist/{subagent-spawn-ledger-52I66CLW.js → subagent-spawn-ledger-OI23OT4I.js} +1 -1
- package/dist/support-bug-actions-XWCJI6S5.js +30 -0
- package/dist/support-inbox-MMVTCXRX.js +77 -0
- package/dist/{support-outbox-KNI3FR3G.js → support-outbox-2TG2UV6J.js} +2 -2
- package/dist/{task-enforcement-CAA6D2MH.js → task-enforcement-JDMBAAOY.js} +22 -20
- package/dist/{task-request-inbox-QBZVU66E.js → task-request-inbox-PKJCYKJV.js} +9 -5
- package/dist/{task-scope-NHXB4ZRN.js → task-scope-32HQEV6W.js} +27 -19
- package/dist/{tasks-crud-JHSWL5NM.js → tasks-crud-CYKUKS3F.js} +21 -19
- package/dist/{tasks-notify-7PBE4U7T.js → tasks-notify-YND5MKWJ.js} +22 -20
- package/dist/{tasks-review-PPPVEE62.js → tasks-review-CG2A5GM3.js} +23 -19
- package/dist/{telemetry-upload-YU2VRNHX.js → telemetry-upload-WLUMEFAB.js} +11 -9
- package/dist/{token-budget-QCMWKG3K.js → token-budget-3YHAY5LL.js} +7 -5
- package/dist/{tool-capability-index-7AWQAJRP.js → tool-capability-index-2ADOWH43.js} +2 -2
- package/dist/{tool-gates-5Q3RSQEG.js → tool-gates-7ENOOYMR.js} +5 -3
- package/dist/{tool-gates-QD26D2NE.js → tool-gates-EKJTLVGN.js} +1 -1
- package/dist/{tool-telemetry-LTOIC64I.js → tool-telemetry-VUP7S6HC.js} +1 -1
- package/dist/tui/App.js +59 -35
- package/dist/{tui-data-NDBXD6U7.js → tui-data-BOQTOW2G.js} +25 -23
- package/dist/{update-support-BMJM4NG7.js → update-support-WT3S3AQ4.js} +21 -21
- package/dist/{whatsapp-QQLDAHUX.js → whatsapp-OZGIF2EM.js} +2 -2
- package/dist/{wiki-acl-W6WDCVCP.js → wiki-acl-LTEQJVDA.js} +1 -1
- package/dist/{work-claims-6DM32MGO.js → work-claims-CMV2GWIW.js} +8 -6
- package/dist/{work-state-heartbeat-HG7D4AWJ.js → work-state-heartbeat-S45TXK4M.js} +1 -1
- package/dist/{worker-gate-FTMW7GBB.js → worker-gate-7Z6NMM3G.js} +1 -1
- package/dist/{workflow-engine-ZWC6CCXE.js → workflow-engine-ZSQDXZQ7.js} +2 -2
- package/dist/{worktree-EMQCPGFE.js → worktree-NMWDVT6N.js} +8 -6
- package/dist/worktree-ownership-guard-ZVIWJAOP.js +35 -0
- package/dist/{worktree-sweep-XVUJZBXV.js → worktree-sweep-Q62ZIT3U.js} +9 -7
- package/package.json +14 -8
- package/release-notes.json +7 -41
- package/src/commands/exe/afk.md +6 -0
- package/src/commands/exe/call.md +6 -0
- package/src/commands/exe/employee-heartbeat.md +6 -0
- package/src/commands/exe/intercom.md +6 -0
- package/src/commands/exe/kill.md +6 -0
- package/src/commands/exe/launch.md +6 -0
- package/src/commands/exe/logs.md +1 -1
- package/src/commands/exe/sessions.md +6 -0
- package/src/commands/exe/setup.md +7 -3
- package/src/commands/exe/status.md +6 -0
- package/src/commands/exe-reference.md +25 -36
- package/src/commands/exe.md +19 -28
- package/stack.release.json +11 -11
- package/dist/chunk-3B6FLNLV.js +0 -30
- package/dist/chunk-FXU7JOXK.js +0 -6
- package/dist/chunk-QFAFKEB5.js +0 -820
- package/dist/conversations-retention-C4BLKFEL.js +0 -54
- package/dist/stack-release-5PGWV5D4.js +0 -1607
- package/dist/support-inbox-NY5TB3FN.js +0 -51
- /package/dist/{chunk-U2D6PJ5T.js → chunk-65G7ZTGE.js} +0 -0
- /package/dist/{chunk-DN3ZR3UE.js → chunk-CP7Z35MJ.js} +0 -0
- /package/dist/{chunk-XDVOGDBC.js → chunk-KBBWALJV.js} +0 -0
- /package/dist/{chunk-JRIH6I7D.js → chunk-LZXYPTY4.js} +0 -0
- /package/dist/{chunk-GIRD7O5X.js → chunk-MCWEW2SG.js} +0 -0
- /package/dist/{chunk-TKAU7IJ2.js → chunk-MQHUJLCA.js} +0 -0
- /package/dist/{chunk-M4XY4JRK.js → chunk-O53LTOXK.js} +0 -0
- /package/dist/{chunk-DZN7SDY2.js → chunk-OSVTH3SG.js} +0 -0
- /package/dist/{chunk-AJK2PVQW.js → chunk-QXXEXGX3.js} +0 -0
- /package/dist/{chunk-AWWDKF22.js → chunk-SFWNTO2F.js} +0 -0
- /package/dist/{chunk-2Q2CD6CD.js → chunk-WC5HF2FN.js} +0 -0
- /package/dist/{core-memory-O6D5UC3T.js → core-memory-MMMW3TF3.js} +0 -0
- /package/dist/{memory-isolation-EBFFC6HF.js → memory-isolation-67ACKQ2M.js} +0 -0
- /package/dist/{oauth-server-ZKBUHDFI.js → oauth-server-OILIKR7D.js} +0 -0
|
@@ -1,15 +1,151 @@
|
|
|
1
1
|
// src/lib/verification-evidence.ts
|
|
2
2
|
import { execFileSync } from "child_process";
|
|
3
3
|
|
|
4
|
+
// src/shared/observation-anchoring.ts
|
|
5
|
+
var ANCHOR_MIN_SHARED_TOKENS = 2;
|
|
6
|
+
var ANCHOR_MIN_TOKEN_CHARS = 4;
|
|
7
|
+
var ANCHOR_DIGIT = /[0-9]/;
|
|
8
|
+
var ANCHOR_MIN_OUTPUT_NUMBER_CHARS = 2;
|
|
9
|
+
var ANCHOR_STOPWORDS = /* @__PURE__ */ new Set([
|
|
10
|
+
"that",
|
|
11
|
+
"this",
|
|
12
|
+
"these",
|
|
13
|
+
"those",
|
|
14
|
+
"with",
|
|
15
|
+
"from",
|
|
16
|
+
"have",
|
|
17
|
+
"has",
|
|
18
|
+
"had",
|
|
19
|
+
"been",
|
|
20
|
+
"being",
|
|
21
|
+
"does",
|
|
22
|
+
"done",
|
|
23
|
+
"then",
|
|
24
|
+
"than",
|
|
25
|
+
"when",
|
|
26
|
+
"where",
|
|
27
|
+
"which",
|
|
28
|
+
"while",
|
|
29
|
+
"there",
|
|
30
|
+
"their",
|
|
31
|
+
"them",
|
|
32
|
+
"they",
|
|
33
|
+
"what",
|
|
34
|
+
"were",
|
|
35
|
+
"was",
|
|
36
|
+
"into",
|
|
37
|
+
"over",
|
|
38
|
+
"under",
|
|
39
|
+
"only",
|
|
40
|
+
"also",
|
|
41
|
+
"still",
|
|
42
|
+
"just",
|
|
43
|
+
"more",
|
|
44
|
+
"most",
|
|
45
|
+
"some",
|
|
46
|
+
"such",
|
|
47
|
+
"each",
|
|
48
|
+
"both",
|
|
49
|
+
"after",
|
|
50
|
+
"before",
|
|
51
|
+
"again",
|
|
52
|
+
"does",
|
|
53
|
+
"will",
|
|
54
|
+
"would",
|
|
55
|
+
"could",
|
|
56
|
+
"should",
|
|
57
|
+
"must",
|
|
58
|
+
"shall",
|
|
59
|
+
"here",
|
|
60
|
+
"about",
|
|
61
|
+
"because",
|
|
62
|
+
"since",
|
|
63
|
+
"until",
|
|
64
|
+
"during",
|
|
65
|
+
"through",
|
|
66
|
+
"without",
|
|
67
|
+
"within",
|
|
68
|
+
"above",
|
|
69
|
+
"below",
|
|
70
|
+
"same",
|
|
71
|
+
"other",
|
|
72
|
+
"another",
|
|
73
|
+
"every",
|
|
74
|
+
"very",
|
|
75
|
+
"much",
|
|
76
|
+
"many",
|
|
77
|
+
"like",
|
|
78
|
+
"make",
|
|
79
|
+
"made",
|
|
80
|
+
"take",
|
|
81
|
+
"used",
|
|
82
|
+
"using",
|
|
83
|
+
"note",
|
|
84
|
+
"true",
|
|
85
|
+
"false",
|
|
86
|
+
"null",
|
|
87
|
+
"none"
|
|
88
|
+
]);
|
|
89
|
+
function str(value) {
|
|
90
|
+
return typeof value === "string" ? value.trim() : "";
|
|
91
|
+
}
|
|
92
|
+
function isRecord(value) {
|
|
93
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
94
|
+
}
|
|
95
|
+
function anchorTokens(text, minChars = ANCHOR_MIN_TOKEN_CHARS, keepGrammarWords = false) {
|
|
96
|
+
const tokens = /* @__PURE__ */ new Set();
|
|
97
|
+
for (const raw of text.toLowerCase().split(/[^a-z0-9]+/)) {
|
|
98
|
+
if (!raw) continue;
|
|
99
|
+
if (ANCHOR_DIGIT.test(raw)) {
|
|
100
|
+
tokens.add(raw);
|
|
101
|
+
continue;
|
|
102
|
+
}
|
|
103
|
+
if (raw.length < minChars) continue;
|
|
104
|
+
if (!keepGrammarWords && ANCHOR_STOPWORDS.has(raw)) continue;
|
|
105
|
+
tokens.add(raw.endsWith("s") && raw.length > ANCHOR_MIN_TOKEN_CHARS ? raw.slice(0, -1) : raw);
|
|
106
|
+
}
|
|
107
|
+
return tokens;
|
|
108
|
+
}
|
|
109
|
+
function outputAnchorTokens(output) {
|
|
110
|
+
const full = anchorTokens(output);
|
|
111
|
+
if (full.size > 0) return full;
|
|
112
|
+
const whole = anchorTokens(output, 1, true);
|
|
113
|
+
return whole.size === 1 ? whole : full;
|
|
114
|
+
}
|
|
115
|
+
function isObservationAnchored(observation, probes) {
|
|
116
|
+
if (!Array.isArray(probes)) return false;
|
|
117
|
+
const outputAnchors = /* @__PURE__ */ new Set();
|
|
118
|
+
const outputNumbers = /* @__PURE__ */ new Set();
|
|
119
|
+
for (const probe of probes) {
|
|
120
|
+
if (!isRecord(probe)) continue;
|
|
121
|
+
for (const token of outputAnchorTokens(str(probe.output))) {
|
|
122
|
+
outputAnchors.add(token);
|
|
123
|
+
if (ANCHOR_DIGIT.test(token) && token.length >= ANCHOR_MIN_OUTPUT_NUMBER_CHARS) {
|
|
124
|
+
outputNumbers.add(token);
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
if (outputAnchors.size === 0) return false;
|
|
129
|
+
const bar = Math.min(ANCHOR_MIN_SHARED_TOKENS, outputAnchors.size);
|
|
130
|
+
let shared = 0;
|
|
131
|
+
for (const token of anchorTokens(observation, 1, true)) {
|
|
132
|
+
if (!outputAnchors.has(token)) continue;
|
|
133
|
+
if (outputNumbers.has(token)) return true;
|
|
134
|
+
shared += 1;
|
|
135
|
+
if (shared >= bar) return true;
|
|
136
|
+
}
|
|
137
|
+
return false;
|
|
138
|
+
}
|
|
139
|
+
|
|
4
140
|
// src/shared/attribution.ts
|
|
5
141
|
var ok = { ok: true, code: "ok", message: "attributed" };
|
|
6
142
|
function deny(code, message) {
|
|
7
143
|
return { ok: false, code, message };
|
|
8
144
|
}
|
|
9
|
-
function
|
|
145
|
+
function isRecord2(value) {
|
|
10
146
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
11
147
|
}
|
|
12
|
-
function
|
|
148
|
+
function str2(value) {
|
|
13
149
|
return typeof value === "string" ? value.trim() : "";
|
|
14
150
|
}
|
|
15
151
|
var PLACEHOLDER_IDENTITIES = /* @__PURE__ */ new Set([
|
|
@@ -87,7 +223,7 @@ var MODEL_FAMILIES = [
|
|
|
87
223
|
var MODEL_SHAPE = /^[a-z][a-z0-9]*(?:[-._][a-z0-9]+)*$/i;
|
|
88
224
|
var HAS_VERSION = /\d/;
|
|
89
225
|
function assessModel(raw) {
|
|
90
|
-
const model =
|
|
226
|
+
const model = str2(raw).toLowerCase();
|
|
91
227
|
if (!model) {
|
|
92
228
|
return deny("attribution_model_missing", "attribution requires the model that produced this record");
|
|
93
229
|
}
|
|
@@ -117,7 +253,7 @@ function assessModel(raw) {
|
|
|
117
253
|
}
|
|
118
254
|
var FUTURE_SKEW_MS = 5 * 60 * 1e3;
|
|
119
255
|
function assessObservedAt(raw, now) {
|
|
120
|
-
const text =
|
|
256
|
+
const text = str2(raw);
|
|
121
257
|
if (!text) {
|
|
122
258
|
return deny(
|
|
123
259
|
"attribution_observed_at_missing",
|
|
@@ -149,10 +285,10 @@ function assessAttribution(raw, purpose, context = {}) {
|
|
|
149
285
|
return deny("attribution_malformed", "attribution must be valid JSON");
|
|
150
286
|
}
|
|
151
287
|
}
|
|
152
|
-
if (!
|
|
288
|
+
if (!isRecord2(attribution)) {
|
|
153
289
|
return deny("attribution_malformed", "attribution must be an object");
|
|
154
290
|
}
|
|
155
|
-
const agent =
|
|
291
|
+
const agent = str2(attribution.agent);
|
|
156
292
|
if (!agent) {
|
|
157
293
|
return deny("attribution_agent_missing", "attribution requires the agent identity that produced this record");
|
|
158
294
|
}
|
|
@@ -174,7 +310,7 @@ function assessAttribution(raw, purpose, context = {}) {
|
|
|
174
310
|
const observedResult = assessObservedAt(attribution.observed_at, now);
|
|
175
311
|
if (!observedResult.ok) return observedResult;
|
|
176
312
|
if (purpose === "verdict") {
|
|
177
|
-
const ref =
|
|
313
|
+
const ref = str2(attribution.evidence_ref);
|
|
178
314
|
if (!ref) {
|
|
179
315
|
return deny(
|
|
180
316
|
"attribution_evidence_ref_missing",
|
|
@@ -187,18 +323,18 @@ function assessAttribution(raw, purpose, context = {}) {
|
|
|
187
323
|
}
|
|
188
324
|
const second = attribution.second_opinion;
|
|
189
325
|
if (second !== void 0 && second !== null && second !== "") {
|
|
190
|
-
if (!
|
|
326
|
+
if (!isRecord2(second)) {
|
|
191
327
|
return deny("second_opinion_malformed", "second_opinion must be an object with model and verdict");
|
|
192
328
|
}
|
|
193
329
|
const secondModel = assessModel(second.model);
|
|
194
330
|
if (!secondModel.ok) {
|
|
195
331
|
return deny("second_opinion_malformed", `second_opinion model: ${secondModel.message}`);
|
|
196
332
|
}
|
|
197
|
-
const verdict =
|
|
333
|
+
const verdict = str2(second.verdict);
|
|
198
334
|
if (verdict !== "confirmed" && verdict !== "refuted") {
|
|
199
335
|
return deny("second_opinion_malformed", "second_opinion.verdict must be 'confirmed' or 'refuted'");
|
|
200
336
|
}
|
|
201
|
-
if (
|
|
337
|
+
if (str2(second.model).toLowerCase() === str2(attribution.model).toLowerCase()) {
|
|
202
338
|
return deny(
|
|
203
339
|
"second_opinion_same_model",
|
|
204
340
|
"second_opinion.model must differ from the model that produced the record \u2014 a model confirming itself is not an adversarial review"
|
|
@@ -225,17 +361,17 @@ function deny2(code, message) {
|
|
|
225
361
|
}
|
|
226
362
|
var HEX_SHA2 = /^[0-9a-f]{7,64}$/i;
|
|
227
363
|
var MIN_OBSERVATION_CHARS = 40;
|
|
228
|
-
function
|
|
364
|
+
function isRecord3(value) {
|
|
229
365
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
230
366
|
}
|
|
231
|
-
function
|
|
367
|
+
function str3(value) {
|
|
232
368
|
return typeof value === "string" ? value.trim() : "";
|
|
233
369
|
}
|
|
234
370
|
function num(value) {
|
|
235
371
|
return typeof value === "number" && Number.isFinite(value) ? value : null;
|
|
236
372
|
}
|
|
237
373
|
function isSubstantiveCommit(substance) {
|
|
238
|
-
if (!
|
|
374
|
+
if (!isRecord3(substance)) return false;
|
|
239
375
|
const added = num(substance.added);
|
|
240
376
|
const deleted = num(substance.deleted);
|
|
241
377
|
const substantive = num(substance.substantive_added);
|
|
@@ -248,7 +384,7 @@ function isSubstantiveCommit(substance) {
|
|
|
248
384
|
return true;
|
|
249
385
|
}
|
|
250
386
|
function isSubstantiveTestFix(substance) {
|
|
251
|
-
if (!
|
|
387
|
+
if (!isRecord3(substance)) return false;
|
|
252
388
|
const added = num(substance.added);
|
|
253
389
|
const deleted = num(substance.deleted);
|
|
254
390
|
const testFiles = num(substance.test_files);
|
|
@@ -263,7 +399,7 @@ function isSubstantiveTestFix(substance) {
|
|
|
263
399
|
var VERDICT_ONLY_OBSERVATION = /^(?:it(?:'s| is)? |the bug (?:is|was) |this (?:is|was) )?(?:fixed|resolved|working|done|good|ok|verified|closed)\b/i;
|
|
264
400
|
var HEDGED_OBSERVATION = /\b(?:looks?|look|seems?|appears?)\s+(?:to\s+be\s+)?(?:fine|good|ok|okay|right|healthy|correct|normal)\b|\ball\s+(?:good|fine|clear)\b|\bno\s+issues\b|\bseems?\s+fine\b/i;
|
|
265
401
|
function assessObservation(raw) {
|
|
266
|
-
const observation =
|
|
402
|
+
const observation = str3(raw).replace(/\s+/g, " ");
|
|
267
403
|
if (observation.length < MIN_OBSERVATION_CHARS) {
|
|
268
404
|
return deny2(
|
|
269
405
|
"manual_observation_too_thin",
|
|
@@ -279,7 +415,7 @@ function assessObservation(raw) {
|
|
|
279
415
|
return ok2;
|
|
280
416
|
}
|
|
281
417
|
function assessVerifier(raw, context) {
|
|
282
|
-
const verifier =
|
|
418
|
+
const verifier = str3(raw);
|
|
283
419
|
if (!verifier) {
|
|
284
420
|
return deny2("manual_verifier_missing", "this close requires a named verifier");
|
|
285
421
|
}
|
|
@@ -289,7 +425,7 @@ function assessVerifier(raw, context) {
|
|
|
289
425
|
`"${verifier}" is a role, not an identity. Records attested by "admin" are exactly why past verdicts cannot be traced to anyone \u2014 name the actual person or employee`
|
|
290
426
|
);
|
|
291
427
|
}
|
|
292
|
-
const authors = (context.authorIdentities ?? []).map((a) =>
|
|
428
|
+
const authors = (context.authorIdentities ?? []).map((a) => str3(a).toLowerCase()).filter(Boolean);
|
|
293
429
|
if (authors.includes(verifier.toLowerCase())) {
|
|
294
430
|
return deny2(
|
|
295
431
|
"manual_verifier_is_author",
|
|
@@ -299,7 +435,7 @@ function assessVerifier(raw, context) {
|
|
|
299
435
|
return ok2;
|
|
300
436
|
}
|
|
301
437
|
function parseTimestamp(raw) {
|
|
302
|
-
const text =
|
|
438
|
+
const text = str3(raw);
|
|
303
439
|
if (!text) return null;
|
|
304
440
|
const ms = Date.parse(text);
|
|
305
441
|
return Number.isFinite(ms) ? ms : null;
|
|
@@ -315,19 +451,19 @@ function assessProbes(raw, claimType) {
|
|
|
315
451
|
for (let i = 0; i < raw.length; i += 1) {
|
|
316
452
|
const probe = raw[i];
|
|
317
453
|
const where = `probe ${i + 1}`;
|
|
318
|
-
if (!
|
|
454
|
+
if (!isRecord3(probe)) {
|
|
319
455
|
return deny2("ops_probe_malformed", `${where} is not an object`);
|
|
320
456
|
}
|
|
321
|
-
if (!
|
|
457
|
+
if (!str3(probe.command)) {
|
|
322
458
|
return deny2("ops_probe_malformed", `${where} has no command \u2014 record the command verbatim, as typed`);
|
|
323
459
|
}
|
|
324
|
-
if (!
|
|
460
|
+
if (!str3(probe.output)) {
|
|
325
461
|
return deny2(
|
|
326
462
|
"ops_probe_malformed",
|
|
327
463
|
`${where} has no command output \u2014 paste the output verbatim; a probe with nothing to show is a summary, not evidence`
|
|
328
464
|
);
|
|
329
465
|
}
|
|
330
|
-
if (!
|
|
466
|
+
if (!str3(probe.host)) {
|
|
331
467
|
return deny2("ops_probe_malformed", `${where} does not name the host or system it ran against`);
|
|
332
468
|
}
|
|
333
469
|
const ts = parseTimestamp(probe.ran_at);
|
|
@@ -359,17 +495,17 @@ function assessVerificationArtifact(raw, context = {}) {
|
|
|
359
495
|
return deny2("artifact_malformed", "verification artifact must be valid JSON");
|
|
360
496
|
}
|
|
361
497
|
}
|
|
362
|
-
if (!
|
|
498
|
+
if (!isRecord3(artifact)) {
|
|
363
499
|
return deny2("artifact_malformed", "verification artifact must be an object");
|
|
364
500
|
}
|
|
365
|
-
const kind =
|
|
501
|
+
const kind = str3(artifact.kind);
|
|
366
502
|
if (kind !== "regression_test" && kind !== "manual" && kind !== "ops_transcript") {
|
|
367
503
|
return deny2("artifact_unknown_kind", "verification artifact kind must be regression_test, manual or ops_transcript");
|
|
368
504
|
}
|
|
369
505
|
if (kind === "ops_transcript") {
|
|
370
506
|
return assessOpsTranscript(artifact, context);
|
|
371
507
|
}
|
|
372
|
-
const declaredLayer =
|
|
508
|
+
const declaredLayer = str3(artifact.defect_layer) || "production";
|
|
373
509
|
if (declaredLayer !== "production" && declaredLayer !== "test_harness") {
|
|
374
510
|
return deny2("artifact_malformed", "defect_layer must be production or test_harness");
|
|
375
511
|
}
|
|
@@ -380,13 +516,13 @@ function assessVerificationArtifact(raw, context = {}) {
|
|
|
380
516
|
"defect_layer=test_harness was declared, but the fix commit changes no executable test/harness code (comment-only, whitespace-only or docs-only diffs are not fixes at any layer)"
|
|
381
517
|
);
|
|
382
518
|
}
|
|
383
|
-
if (!
|
|
519
|
+
if (!str3(artifact.test_id)) {
|
|
384
520
|
return deny2(
|
|
385
521
|
"test_fix_missing_assertion",
|
|
386
|
-
"defect_layer=test_harness requires
|
|
522
|
+
"defect_layer=test_harness requires regression_test_id \u2014 name the test whose behaviour is the evidence"
|
|
387
523
|
);
|
|
388
524
|
}
|
|
389
|
-
if (
|
|
525
|
+
if (str3(artifact.reverted_result) !== "fail") {
|
|
390
526
|
return deny2(
|
|
391
527
|
"test_fix_missing_assertion",
|
|
392
528
|
"defect_layer=test_harness requires reverted_result='fail' \u2014 the observed result of re-running the named test with the fix reverted. A test-only diff that does not go red when removed evidences nothing"
|
|
@@ -395,38 +531,44 @@ function assessVerificationArtifact(raw, context = {}) {
|
|
|
395
531
|
} else if (!isSubstantiveCommit(artifact.substance)) {
|
|
396
532
|
return deny2(
|
|
397
533
|
"commit_not_substantive",
|
|
398
|
-
"the fix commit changes no executable production source (comment-only, whitespace-only, or test-only diffs are not fixes). If the DEFECT ITSELF is in the test/harness layer, declare defect_layer='test_harness' and supply
|
|
534
|
+
"the fix commit changes no executable production source (comment-only, whitespace-only, or test-only diffs are not fixes). If the DEFECT ITSELF is in the test/harness layer, declare defect_layer='test_harness' and supply regression_test_id and reverted_result"
|
|
399
535
|
);
|
|
400
536
|
}
|
|
401
537
|
if (kind === "regression_test") {
|
|
402
|
-
const testId =
|
|
403
|
-
const fixCommit =
|
|
404
|
-
const parentCommit =
|
|
538
|
+
const testId = str3(artifact.test_id);
|
|
539
|
+
const fixCommit = str3(artifact.fix_commit);
|
|
540
|
+
const parentCommit = str3(artifact.parent_commit);
|
|
405
541
|
if (!testId || !HEX_SHA2.test(fixCommit) || !HEX_SHA2.test(parentCommit)) {
|
|
406
|
-
return deny2(
|
|
542
|
+
return deny2(
|
|
543
|
+
"artifact_malformed",
|
|
544
|
+
"regression_test requires regression_test_id and fix_commit. (The parent commit is not a parameter \u2014 it is derived from fix_commit's first parent.)"
|
|
545
|
+
);
|
|
407
546
|
}
|
|
408
547
|
if (fixCommit.toLowerCase() === parentCommit.toLowerCase()) {
|
|
409
|
-
return deny2(
|
|
548
|
+
return deny2(
|
|
549
|
+
"parent_equals_fix",
|
|
550
|
+
"the parent resolved to the same commit as fix_commit. The parent is derived from fix_commit's first parent, so this means fix_commit is not the commit the fix landed in \u2014 name the fix commit, not its parent."
|
|
551
|
+
);
|
|
410
552
|
}
|
|
411
|
-
if (
|
|
553
|
+
if (str3(artifact.parent_result) !== "fail") {
|
|
412
554
|
return deny2(
|
|
413
555
|
"test_did_not_fail_at_parent",
|
|
414
556
|
"the named test must FAIL at the parent commit \u2014 a test that already passed does not detect the defect"
|
|
415
557
|
);
|
|
416
558
|
}
|
|
417
|
-
if (
|
|
559
|
+
if (str3(artifact.fix_result) !== "pass") {
|
|
418
560
|
return deny2("test_did_not_pass_at_fix", "the named test must PASS at the fix commit");
|
|
419
561
|
}
|
|
420
562
|
return ok2;
|
|
421
563
|
}
|
|
422
564
|
const verifierResult = assessVerifier(artifact.verifier, context);
|
|
423
565
|
if (!verifierResult.ok) return verifierResult;
|
|
424
|
-
if (!
|
|
566
|
+
if (!str3(artifact.method)) {
|
|
425
567
|
return deny2("artifact_malformed", "manual verification requires a method");
|
|
426
568
|
}
|
|
427
569
|
const observationResult = assessObservation(artifact.observation);
|
|
428
570
|
if (!observationResult.ok) return observationResult;
|
|
429
|
-
if (!HEX_SHA2.test(
|
|
571
|
+
if (!HEX_SHA2.test(str3(artifact.fix_commit))) {
|
|
430
572
|
return deny2("artifact_malformed", "manual verification requires a fix_commit");
|
|
431
573
|
}
|
|
432
574
|
return ok2;
|
|
@@ -434,7 +576,7 @@ function assessVerificationArtifact(raw, context = {}) {
|
|
|
434
576
|
function assessOpsTranscript(artifact, context) {
|
|
435
577
|
const verifierResult = assessVerifier(artifact.verifier, context);
|
|
436
578
|
if (!verifierResult.ok) return verifierResult;
|
|
437
|
-
const claimType =
|
|
579
|
+
const claimType = str3(artifact.claim_type);
|
|
438
580
|
if (claimType !== "point_in_time" && claimType !== "ongoing_state") {
|
|
439
581
|
return deny2(
|
|
440
582
|
"artifact_malformed",
|
|
@@ -445,14 +587,26 @@ function assessOpsTranscript(artifact, context) {
|
|
|
445
587
|
if (!probeResult.ok) return probeResult;
|
|
446
588
|
const observationResult = assessObservation(artifact.observation);
|
|
447
589
|
if (!observationResult.ok) return observationResult;
|
|
448
|
-
|
|
590
|
+
if (!isObservationAnchored(str3(artifact.observation), artifact.probes)) {
|
|
591
|
+
return deny2(
|
|
592
|
+
"observation_not_anchored",
|
|
593
|
+
"the observation does not quote anything the probes actually returned. State what the output SHOWS that makes the defect absent, in the output's own words \u2014 a description of the activity ('probing whether ...', 'testing if ...') or of the change made is not an observation of absence"
|
|
594
|
+
);
|
|
595
|
+
}
|
|
596
|
+
const fixCommit = str3(artifact.fix_commit);
|
|
449
597
|
if (fixCommit && !HEX_SHA2.test(fixCommit)) {
|
|
450
598
|
return deny2("artifact_malformed", "ops_transcript fix_commit, when supplied, must be a commit sha");
|
|
451
599
|
}
|
|
600
|
+
if (fixCommit && !isSubstantiveCommit(artifact.substance)) {
|
|
601
|
+
return deny2(
|
|
602
|
+
"commit_not_substantive",
|
|
603
|
+
"this ops_transcript names a fix_commit whose diff changes no executable production source (comment-only, whitespace-only, test-only or docs-only diffs are not fixes). Either name the commit that carries the fix, or omit fix_commit \u2014 an ops transcript does not require one"
|
|
604
|
+
);
|
|
605
|
+
}
|
|
452
606
|
return ok2;
|
|
453
607
|
}
|
|
454
608
|
function assessDisposition(disposition, input) {
|
|
455
|
-
const reason =
|
|
609
|
+
const reason = str3(input.disposition_reason).replace(/\s+/g, " ");
|
|
456
610
|
if (!reason) {
|
|
457
611
|
return deny2(
|
|
458
612
|
"disposition_reason_missing",
|
|
@@ -478,7 +632,7 @@ function assessDisposition(disposition, input) {
|
|
|
478
632
|
);
|
|
479
633
|
}
|
|
480
634
|
if (disposition === "superseded") {
|
|
481
|
-
if (!
|
|
635
|
+
if (!str3(input.superseded_by)) {
|
|
482
636
|
return deny2(
|
|
483
637
|
"superseded_by_missing",
|
|
484
638
|
"closing as superseded requires superseded_by \u2014 name the record that replaces this one, so the claim is checkable"
|
|
@@ -508,7 +662,7 @@ function assessSupersedingCoverage(input) {
|
|
|
508
662
|
if (thin.length > 0) {
|
|
509
663
|
return deny2(
|
|
510
664
|
"superseded_coverage_evidence_missing",
|
|
511
|
-
`${thin.length} symptom(s) are listed as covered with no evidence naming WHERE ${
|
|
665
|
+
`${thin.length} symptom(s) are listed as covered with no evidence naming WHERE ${str3(input.superseded_by)} covers them: ${thin.map((e) => e.id).join(", ")}`
|
|
512
666
|
);
|
|
513
667
|
}
|
|
514
668
|
const covered = new Set(entries.map((e) => e.id));
|
|
@@ -516,7 +670,7 @@ function assessSupersedingCoverage(input) {
|
|
|
516
670
|
if (survivors.length > 0) {
|
|
517
671
|
return deny2(
|
|
518
672
|
"superseded_coverage_incomplete",
|
|
519
|
-
`${survivors.length} of ${declared.length} symptoms are NOT covered by ${
|
|
673
|
+
`${survivors.length} of ${declared.length} symptoms are NOT covered by ${str3(input.superseded_by)}: ${survivors.join(", ")}. Partial coverage supersedes nothing \u2014 keep this record open with those symptoms as its remaining scope, or supply coverage evidence for each`
|
|
520
674
|
);
|
|
521
675
|
}
|
|
522
676
|
return ok2;
|
|
@@ -534,10 +688,10 @@ function parseCoverageEntries(raw) {
|
|
|
534
688
|
if (!Array.isArray(value)) return [];
|
|
535
689
|
const entries = [];
|
|
536
690
|
for (const entry of value) {
|
|
537
|
-
if (!
|
|
538
|
-
const id =
|
|
691
|
+
if (!isRecord3(entry)) continue;
|
|
692
|
+
const id = str3(entry.id);
|
|
539
693
|
if (!id) continue;
|
|
540
|
-
entries.push({ id, evidence:
|
|
694
|
+
entries.push({ id, evidence: str3(entry.evidence) });
|
|
541
695
|
}
|
|
542
696
|
return entries;
|
|
543
697
|
}
|
|
@@ -555,7 +709,7 @@ function parseSymptomIds(raw) {
|
|
|
555
709
|
const ids = [];
|
|
556
710
|
for (const entry of value) {
|
|
557
711
|
if (typeof entry === "string" && entry.trim()) ids.push(entry.trim());
|
|
558
|
-
else if (
|
|
712
|
+
else if (isRecord3(entry) && str3(entry.id)) ids.push(str3(entry.id));
|
|
559
713
|
}
|
|
560
714
|
return ids;
|
|
561
715
|
}
|
|
@@ -563,13 +717,14 @@ function parseSymptomIds(raw) {
|
|
|
563
717
|
// src/lib/verification-evidence.ts
|
|
564
718
|
var TEST_PATH = /(?:^|\/)(?:tests?|__tests__|__mocks__|e2e|fixtures)\//i;
|
|
565
719
|
var TEST_FILE = /\.(?:test|spec)\.[cm]?[jt]sx?$/i;
|
|
566
|
-
var NON_SOURCE_FILE = /\.(?:md|mdx|txt|rst|adoc|snap
|
|
720
|
+
var NON_SOURCE_FILE = /\.(?:md|mdx|txt|rst|adoc|snap)$/i;
|
|
721
|
+
var DERIVED_PATH = /(?:^|\/)(?:docs|exe\/output)\//i;
|
|
567
722
|
var COMMENT_LINE = /^(?:\/\/|\/\*|\*\/|\*(?!\/)|#|--|<!--|-->)/;
|
|
568
723
|
function isTestPath(path) {
|
|
569
724
|
return TEST_PATH.test(path) || TEST_FILE.test(path);
|
|
570
725
|
}
|
|
571
726
|
function isNonSourcePath(path) {
|
|
572
|
-
return NON_SOURCE_FILE.test(path);
|
|
727
|
+
return NON_SOURCE_FILE.test(path) || DERIVED_PATH.test(path);
|
|
573
728
|
}
|
|
574
729
|
function isCommentOrBlank(line) {
|
|
575
730
|
const trimmed = line.trim();
|
|
@@ -700,6 +855,32 @@ function resolveCommit(sha, cwd) {
|
|
|
700
855
|
return null;
|
|
701
856
|
}
|
|
702
857
|
}
|
|
858
|
+
function repoField(cwd) {
|
|
859
|
+
const name = cwd ? resolveRepoName(cwd) : null;
|
|
860
|
+
return name ? { repo: name } : {};
|
|
861
|
+
}
|
|
862
|
+
function resolveRepoName(cwd) {
|
|
863
|
+
try {
|
|
864
|
+
const remote = execFileSync("git", ["remote", "get-url", "origin"], {
|
|
865
|
+
cwd,
|
|
866
|
+
encoding: "utf8",
|
|
867
|
+
timeout: 1e4,
|
|
868
|
+
stdio: ["ignore", "pipe", "pipe"]
|
|
869
|
+
}).trim();
|
|
870
|
+
let remotePath;
|
|
871
|
+
if (/^(?:https|ssh):\/\//i.test(remote)) {
|
|
872
|
+
remotePath = new URL(remote).pathname;
|
|
873
|
+
} else {
|
|
874
|
+
const scp = /^(?:[^/@:\s]+@)?[^/:\s]+:(.+)$/.exec(remote);
|
|
875
|
+
if (!scp) return null;
|
|
876
|
+
remotePath = scp[1];
|
|
877
|
+
}
|
|
878
|
+
const name = remotePath.replace(/\/+$/, "").split("/").pop()?.replace(/\.git$/, "");
|
|
879
|
+
return name && /^[A-Za-z0-9._-]{1,64}$/.test(name) ? name : null;
|
|
880
|
+
} catch {
|
|
881
|
+
return null;
|
|
882
|
+
}
|
|
883
|
+
}
|
|
703
884
|
function checkVerifierName(raw) {
|
|
704
885
|
const verifier = (raw ?? "").trim();
|
|
705
886
|
if (!verifier) {
|
|
@@ -740,6 +921,29 @@ function buildOpsTranscript(request, context) {
|
|
|
740
921
|
"the observation must describe what the output SHOWS that makes the defect absent \u2014 not that the bug is 'fixed'"
|
|
741
922
|
);
|
|
742
923
|
}
|
|
924
|
+
let substance = { added: 0, deleted: 0, substantive_added: 0, source_files: 0 };
|
|
925
|
+
const declaredCommit = (request.fix_commit ?? "").trim();
|
|
926
|
+
if (declaredCommit) {
|
|
927
|
+
const repo = (request.repo_path ?? "").trim();
|
|
928
|
+
if (!repo) {
|
|
929
|
+
return fail(
|
|
930
|
+
"repo_path_missing",
|
|
931
|
+
"repo_path is required when an ops_transcript names a fix_commit: a commit offered as the fix is measured, not described. Omit fix_commit if the work was not a commit."
|
|
932
|
+
);
|
|
933
|
+
}
|
|
934
|
+
const resolved = resolveCommit(declaredCommit, repo);
|
|
935
|
+
if (!resolved) {
|
|
936
|
+
return fail(
|
|
937
|
+
"fix_commit_unresolvable",
|
|
938
|
+
`fix_commit ${declaredCommit} is not a commit in ${repo} \u2014 verification evidence cannot be measured, and will not be guessed`
|
|
939
|
+
);
|
|
940
|
+
}
|
|
941
|
+
const measured = measureCommitSubstance(resolved, repo);
|
|
942
|
+
if (!measured) {
|
|
943
|
+
return fail("commit_not_measurable", `git could not diff ${resolved} in ${repo}`);
|
|
944
|
+
}
|
|
945
|
+
substance = measured;
|
|
946
|
+
}
|
|
743
947
|
const artifact = {
|
|
744
948
|
kind: "ops_transcript",
|
|
745
949
|
verifier: verifierCheck.verifier,
|
|
@@ -751,15 +955,12 @@ function buildOpsTranscript(request, context) {
|
|
|
751
955
|
ran_at: (p?.ran_at ?? "").trim()
|
|
752
956
|
})),
|
|
753
957
|
observation,
|
|
754
|
-
|
|
958
|
+
// Bug cc539242: a sha is only resolvable evidence alongside the repo it lives in.
|
|
959
|
+
...declaredCommit ? { fix_commit: declaredCommit, substance, ...repoField((request.repo_path ?? "").trim()) } : {}
|
|
755
960
|
};
|
|
756
961
|
const assessed = assessVerificationArtifact(artifact, context);
|
|
757
962
|
if (!assessed.ok) return fail(assessed.code, assessed.message);
|
|
758
|
-
return {
|
|
759
|
-
ok: true,
|
|
760
|
-
artifact,
|
|
761
|
-
substance: { added: 0, deleted: 0, substantive_added: 0, source_files: 0 }
|
|
762
|
-
};
|
|
963
|
+
return { ok: true, artifact, substance };
|
|
763
964
|
}
|
|
764
965
|
function buildVerificationArtifact(request, context = {}) {
|
|
765
966
|
if (request.kind === "ops_transcript") {
|
|
@@ -819,6 +1020,9 @@ function buildVerificationArtifact(request, context = {}) {
|
|
|
819
1020
|
kind: "regression_test",
|
|
820
1021
|
test_id: testId,
|
|
821
1022
|
fix_commit: fixCommit,
|
|
1023
|
+
// Bug cc539242: record WHICH repo the sha is in, so a reader never resolves it
|
|
1024
|
+
// against the repo the record happens to be filed under.
|
|
1025
|
+
...repoField(repo),
|
|
822
1026
|
parent_commit: parentCommit,
|
|
823
1027
|
parent_result: parentResult,
|
|
824
1028
|
fix_result: fixResult,
|
|
@@ -848,6 +1052,8 @@ function buildVerificationArtifact(request, context = {}) {
|
|
|
848
1052
|
method,
|
|
849
1053
|
observation,
|
|
850
1054
|
fix_commit: fixCommit,
|
|
1055
|
+
// Bug cc539242 — see the regression_test branch.
|
|
1056
|
+
...repoField(repo),
|
|
851
1057
|
substance,
|
|
852
1058
|
...defectLayer === "test_harness" ? { defect_layer: defectLayer, test_id: (request.test_id ?? "").trim(), reverted_result: revertedResult } : {}
|
|
853
1059
|
};
|
|
@@ -703,7 +703,7 @@ function parseRetiredMasterKeys(raw) {
|
|
|
703
703
|
}
|
|
704
704
|
async function retiredKeyShardUsage(hexKeys) {
|
|
705
705
|
try {
|
|
706
|
-
const { countShardsPerKey } = await import("./shard-manager-
|
|
706
|
+
const { countShardsPerKey } = await import("./shard-manager-C7LYX6E4.js");
|
|
707
707
|
return await countShardsPerKey(hexKeys);
|
|
708
708
|
} catch {
|
|
709
709
|
return null;
|