codebaseiq 0.1.0
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/CHANGELOG.md +481 -0
- package/LICENSE +202 -0
- package/README.md +349 -0
- package/dist/augment-vue-worker.js +2 -0
- package/dist/call-graph-evidence-gNsxjCW8.d.ts +16 -0
- package/dist/change-analysis-types-CCtoCHbC.d.ts +9 -0
- package/dist/chunk-2Q2LW5JW.js +14 -0
- package/dist/chunk-2X7V4HS4.js +88 -0
- package/dist/chunk-34WBMAYK.js +2 -0
- package/dist/chunk-35NLDRZC.js +2 -0
- package/dist/chunk-362QOSFD.js +3 -0
- package/dist/chunk-3IER7Q6H.js +12 -0
- package/dist/chunk-3JSXXYTZ.js +345 -0
- package/dist/chunk-3LCDIREB.js +4 -0
- package/dist/chunk-476NR5B7.js +2 -0
- package/dist/chunk-4FC325IF.js +30 -0
- package/dist/chunk-4WKDMDEW.js +9 -0
- package/dist/chunk-4XTAUQFD.js +2 -0
- package/dist/chunk-5PUWMSDU.js +26 -0
- package/dist/chunk-5VKBFZZU.js +3 -0
- package/dist/chunk-6BQ3DSPK.js +2 -0
- package/dist/chunk-6CS3UQTN.js +3 -0
- package/dist/chunk-6MUIJMVL.js +6 -0
- package/dist/chunk-6NW7MU72.js +40 -0
- package/dist/chunk-6OAHRI2D.js +6 -0
- package/dist/chunk-6YTSKJJ3.js +2 -0
- package/dist/chunk-7FND7D7N.js +2 -0
- package/dist/chunk-7MGU3HPH.js +2 -0
- package/dist/chunk-7NVGT435.js +2 -0
- package/dist/chunk-7XAN6GKB.js +2 -0
- package/dist/chunk-AAQQPKCU.js +2 -0
- package/dist/chunk-ADTBPVUZ.js +21 -0
- package/dist/chunk-AKB7V7TV.js +2 -0
- package/dist/chunk-ANFVSJWQ.js +11 -0
- package/dist/chunk-B2OB55RR.js +3 -0
- package/dist/chunk-B3UYV66Z.js +4 -0
- package/dist/chunk-B75HZHUP.js +2 -0
- package/dist/chunk-BFFZDZQV.js +2 -0
- package/dist/chunk-BGBBVSH4.js +2 -0
- package/dist/chunk-BH5F2Q4O.js +2 -0
- package/dist/chunk-BJ6SQAEN.js +2 -0
- package/dist/chunk-BMYOV5GP.js +77 -0
- package/dist/chunk-BVAJLC5A.js +7 -0
- package/dist/chunk-C6SBF2WH.js +4 -0
- package/dist/chunk-C74PPYLA.js +3 -0
- package/dist/chunk-C7QOQX32.js +8 -0
- package/dist/chunk-CAUCPUOF.js +7 -0
- package/dist/chunk-CO5R3UNA.js +2 -0
- package/dist/chunk-CQP3THUZ.js +7 -0
- package/dist/chunk-CVYSU6BX.js +16 -0
- package/dist/chunk-CWONGW6P.js +3 -0
- package/dist/chunk-DDZ7VHWV.js +20 -0
- package/dist/chunk-DGXRDLV5.js +2 -0
- package/dist/chunk-DO6WQD2T.js +3 -0
- package/dist/chunk-DQMDCD24.js +2 -0
- package/dist/chunk-DR2LURYU.js +3 -0
- package/dist/chunk-DRENNWRG.js +2 -0
- package/dist/chunk-ECQBG7PW.js +564 -0
- package/dist/chunk-EF2R3WNQ.js +2 -0
- package/dist/chunk-ELNRLMC5.js +29 -0
- package/dist/chunk-EMNIHCRB.js +18 -0
- package/dist/chunk-ENCCHKM6.js +5 -0
- package/dist/chunk-EZNMUY67.js +5 -0
- package/dist/chunk-FAJQ7LWY.js +3 -0
- package/dist/chunk-FDGD5AB5.js +2 -0
- package/dist/chunk-FETNQCFO.js +117 -0
- package/dist/chunk-FM5BPL4V.js +60 -0
- package/dist/chunk-FQKZWM4L.js +49 -0
- package/dist/chunk-FW53T7EB.js +2 -0
- package/dist/chunk-G6XFR4ZL.js +4 -0
- package/dist/chunk-GCHRX4YW.js +4 -0
- package/dist/chunk-GTIYTDRE.js +562 -0
- package/dist/chunk-GTXSJDCO.js +2 -0
- package/dist/chunk-GW6Z3WGY.js +2 -0
- package/dist/chunk-H3LGFZVK.js +2 -0
- package/dist/chunk-HKQUXIFO.js +2 -0
- package/dist/chunk-HOA5YGOH.js +3 -0
- package/dist/chunk-HPJRBHVT.js +3 -0
- package/dist/chunk-HRWGYWRJ.js +49 -0
- package/dist/chunk-I2T2LLK2.js +4 -0
- package/dist/chunk-ICFDQHAM.js +3 -0
- package/dist/chunk-ID63777H.js +4 -0
- package/dist/chunk-IJ4HMYBE.js +3 -0
- package/dist/chunk-ILMHV3KM.js +2 -0
- package/dist/chunk-IOP6FWIM.js +2 -0
- package/dist/chunk-IRQOAM5G.js +2 -0
- package/dist/chunk-J77SU6VA.js +38 -0
- package/dist/chunk-JE3WZ6II.js +2 -0
- package/dist/chunk-JEJLSICM.js +4 -0
- package/dist/chunk-JOIRNPPY.js +2 -0
- package/dist/chunk-JSOYNVWH.js +3 -0
- package/dist/chunk-KMITESMT.js +2 -0
- package/dist/chunk-KUW32IRO.js +2 -0
- package/dist/chunk-KWVHSKHK.js +31 -0
- package/dist/chunk-L4NRUAGJ.js +18 -0
- package/dist/chunk-L57ZKWVG.js +6 -0
- package/dist/chunk-LTA3BRZX.js +2 -0
- package/dist/chunk-LU3BMVH2.js +10 -0
- package/dist/chunk-LZYFLFEH.js +2 -0
- package/dist/chunk-MOVBWNIP.js +16 -0
- package/dist/chunk-MVB3DAEY.js +3 -0
- package/dist/chunk-N3IQCBCF.js +29 -0
- package/dist/chunk-NAUD7LCA.js +2 -0
- package/dist/chunk-NCZUNH3E.js +109 -0
- package/dist/chunk-NE6IU5ZD.js +5 -0
- package/dist/chunk-NEDP5RFQ.js +60 -0
- package/dist/chunk-NMTSZXCL.js +2 -0
- package/dist/chunk-NNJ2KZZG.js +4 -0
- package/dist/chunk-NNO6A2PO.js +2 -0
- package/dist/chunk-NNOKTMZT.js +20 -0
- package/dist/chunk-O6QTXQPJ.js +13 -0
- package/dist/chunk-OANDYLJQ.js +2 -0
- package/dist/chunk-OFBE4NGP.js +2 -0
- package/dist/chunk-OGTFJ3XD.js +2 -0
- package/dist/chunk-OL6KJP3N.js +16 -0
- package/dist/chunk-OLF4MA5W.js +8 -0
- package/dist/chunk-OTOKVOJ3.js +2 -0
- package/dist/chunk-OVTS4DKB.js +2 -0
- package/dist/chunk-OZYRSMSH.js +3 -0
- package/dist/chunk-P5XHIJHI.js +2 -0
- package/dist/chunk-PBI2LFKH.js +2 -0
- package/dist/chunk-PIOMTC27.js +2 -0
- package/dist/chunk-PTAWHLVJ.js +6 -0
- package/dist/chunk-PX4RYAAK.js +2 -0
- package/dist/chunk-PYAB5SM6.js +7 -0
- package/dist/chunk-Q5ELPRKQ.js +2 -0
- package/dist/chunk-Q65CQ4XL.js +2 -0
- package/dist/chunk-Q72QSKXC.js +308 -0
- package/dist/chunk-QCN62RTF.js +3 -0
- package/dist/chunk-QDCCHMVZ.js +2 -0
- package/dist/chunk-QHRNXP3C.js +3 -0
- package/dist/chunk-QKPLA6IC.js +2 -0
- package/dist/chunk-QOKYJ33H.js +2 -0
- package/dist/chunk-QW7EP6WI.js +21 -0
- package/dist/chunk-R2NOK63J.js +4 -0
- package/dist/chunk-RBAS5ZHI.js +2 -0
- package/dist/chunk-RDBI2RXU.js +9 -0
- package/dist/chunk-RKEJ6VTF.js +73 -0
- package/dist/chunk-RR7SX44N.js +35 -0
- package/dist/chunk-RU65DDUP.js +215 -0
- package/dist/chunk-SELM5MER.js +2 -0
- package/dist/chunk-SGX43S2L.js +2 -0
- package/dist/chunk-SMRBZ6EC.js +2 -0
- package/dist/chunk-SNNWPCN7.js +4 -0
- package/dist/chunk-ST7V3SKN.js +2 -0
- package/dist/chunk-SWHMHUKF.js +2 -0
- package/dist/chunk-SYDJMPES.js +2 -0
- package/dist/chunk-SZD2KF7Q.js +2 -0
- package/dist/chunk-T3DGWPXM.js +3 -0
- package/dist/chunk-TFZB6XTM.js +239 -0
- package/dist/chunk-TIIC3ZE7.js +2 -0
- package/dist/chunk-TRRC4ZJ7.js +2 -0
- package/dist/chunk-TXXOEMZJ.js +2 -0
- package/dist/chunk-UBGWN7I4.js +2 -0
- package/dist/chunk-UCD3H3UZ.js +5 -0
- package/dist/chunk-UDS562V4.js +5 -0
- package/dist/chunk-UNBY47BC.js +3 -0
- package/dist/chunk-UP3BUZR5.js +74 -0
- package/dist/chunk-UXM43C7T.js +3 -0
- package/dist/chunk-UZGZB3VB.js +3 -0
- package/dist/chunk-VE5AVNMP.js +2 -0
- package/dist/chunk-VEXUL62T.js +2 -0
- package/dist/chunk-VFY6Y2H6.js +61 -0
- package/dist/chunk-VUIYB2V3.js +2 -0
- package/dist/chunk-VXYS3FZD.js +23 -0
- package/dist/chunk-WE5RZHZ7.js +5 -0
- package/dist/chunk-WMPRTGH2.js +2 -0
- package/dist/chunk-WOQBZPIF.js +2 -0
- package/dist/chunk-XLQ3GLWZ.js +2 -0
- package/dist/chunk-XME3HPXZ.js +2 -0
- package/dist/chunk-XMQ23E27.js +2 -0
- package/dist/chunk-XWUOUWYI.js +2 -0
- package/dist/chunk-XZEE23VG.js +5 -0
- package/dist/chunk-Y6KHROC3.js +7 -0
- package/dist/chunk-YESXMKX3.js +3 -0
- package/dist/chunk-YMGZZEW4.js +2 -0
- package/dist/chunk-YSNONTJ2.js +2 -0
- package/dist/chunk-YUKYB54I.js +1 -0
- package/dist/chunk-YVCIMIOC.js +12 -0
- package/dist/chunk-Z54RD7VL.js +3 -0
- package/dist/chunk-ZKX2FRS6.js +15 -0
- package/dist/chunk-ZMI2JSX2.js +2 -0
- package/dist/chunk-ZV3JV5G5.js +8 -0
- package/dist/chunk-ZZ3MWF33.js +4 -0
- package/dist/chunk-ZZXSWSN6.js +2 -0
- package/dist/cli-context-3SNLDYBM.js +3 -0
- package/dist/cli-context-T3B7W6GG.js +2 -0
- package/dist/cli-program-YNOXO72B.js +7 -0
- package/dist/cli.js +3 -0
- package/dist/code-DlqpBDd0.d.ts +121 -0
- package/dist/command-descriptors-6AOUKWW7.js +346 -0
- package/dist/command-descriptors-ZFKJSRUP.js +344 -0
- package/dist/command-panels-SZONPMLJ.js +3 -0
- package/dist/config-types-BNoC96J3.d.ts +560 -0
- package/dist/db-D7sauVFH.d.ts +95 -0
- package/dist/direct-navigation-DP4LVMRX.js +3 -0
- package/dist/direct-navigation-FLUS3BT6.js +2 -0
- package/dist/exploration-topology-BG4v30HZ.d.ts +256 -0
- package/dist/file-dep-graph-Bqg3t3Px.d.ts +4 -0
- package/dist/file-kind-BKCVMNUf.d.ts +10 -0
- package/dist/frontend-behavior-evidence-EfM4_9bc.d.ts +4 -0
- package/dist/git-history-ChNHbfZQ.d.ts +13 -0
- package/dist/graph-evidence-BIFqyisO.d.ts +131 -0
- package/dist/health-DJaZXg8I.d.ts +340 -0
- package/dist/index.d.ts +183 -0
- package/dist/index.js +2 -0
- package/dist/invocation-command-descriptors-QT2JMY5J.js +3 -0
- package/dist/invocation-command-descriptors-YN4QJEAX.js +2 -0
- package/dist/next-anchor-candidates-BwMczMvX.d.ts +90 -0
- package/dist/output-continuation-command-2V2SL4TD.js +2 -0
- package/dist/output-continuation-command-65J5IP3O.js +3 -0
- package/dist/postinstall.js +3 -0
- package/dist/project-reindex-5JOKXAXT.js +2 -0
- package/dist/project-reindex-UQBIKO4M.js +3 -0
- package/dist/queries/affected.d.ts +40 -0
- package/dist/queries/affected.js +2 -0
- package/dist/queries/anchors.d.ts +123 -0
- package/dist/queries/anchors.js +2 -0
- package/dist/queries/architecture.d.ts +166 -0
- package/dist/queries/architecture.js +2 -0
- package/dist/queries/bottlenecks.d.ts +68 -0
- package/dist/queries/bottlenecks.js +2 -0
- package/dist/queries/by-kind.d.ts +27 -0
- package/dist/queries/by-kind.js +2 -0
- package/dist/queries/call-graph.d.ts +52 -0
- package/dist/queries/call-graph.js +2 -0
- package/dist/queries/change-surface.d.ts +55 -0
- package/dist/queries/change-surface.js +2 -0
- package/dist/queries/cleanup-plan.d.ts +66 -0
- package/dist/queries/cleanup-plan.js +2 -0
- package/dist/queries/co-change.d.ts +90 -0
- package/dist/queries/co-change.js +2 -0
- package/dist/queries/code.d.ts +6 -0
- package/dist/queries/code.js +2 -0
- package/dist/queries/complexity-hotspots.d.ts +61 -0
- package/dist/queries/complexity-hotspots.js +2 -0
- package/dist/queries/complexity.d.ts +74 -0
- package/dist/queries/complexity.js +2 -0
- package/dist/queries/context.d.ts +146 -0
- package/dist/queries/context.js +2 -0
- package/dist/queries/convergence.d.ts +33 -0
- package/dist/queries/convergence.js +2 -0
- package/dist/queries/coupling.d.ts +32 -0
- package/dist/queries/coupling.js +2 -0
- package/dist/queries/cycles.d.ts +66 -0
- package/dist/queries/cycles.js +2 -0
- package/dist/queries/dataflow.d.ts +77 -0
- package/dist/queries/dataflow.js +2 -0
- package/dist/queries/dead.d.ts +58 -0
- package/dist/queries/dead.js +2 -0
- package/dist/queries/decorative-checkers.d.ts +34 -0
- package/dist/queries/decorative-checkers.js +2 -0
- package/dist/queries/deep-chains.d.ts +5 -0
- package/dist/queries/deep-chains.js +2 -0
- package/dist/queries/dependence-slice.d.ts +46 -0
- package/dist/queries/dependence-slice.js +2 -0
- package/dist/queries/dependency-depth.d.ts +49 -0
- package/dist/queries/dependency-depth.js +2 -0
- package/dist/queries/deps.d.ts +15 -0
- package/dist/queries/deps.js +2 -0
- package/dist/queries/diff-impact.d.ts +165 -0
- package/dist/queries/diff-impact.js +2 -0
- package/dist/queries/doc-drift.d.ts +115 -0
- package/dist/queries/doc-drift.js +2 -0
- package/dist/queries/drift.d.ts +79 -0
- package/dist/queries/drift.js +2 -0
- package/dist/queries/duplicate-bodies.d.ts +55 -0
- package/dist/queries/duplicate-bodies.js +2 -0
- package/dist/queries/entry-map.d.ts +121 -0
- package/dist/queries/entry-map.js +2 -0
- package/dist/queries/evidence.d.ts +70 -0
- package/dist/queries/evidence.js +2 -0
- package/dist/queries/extract-candidates.d.ts +52 -0
- package/dist/queries/extract-candidates.js +2 -0
- package/dist/queries/fan.d.ts +53 -0
- package/dist/queries/fan.js +2 -0
- package/dist/queries/files.d.ts +20 -0
- package/dist/queries/files.js +2 -0
- package/dist/queries/health.d.ts +8 -0
- package/dist/queries/health.js +2 -0
- package/dist/queries/hierarchy.d.ts +21 -0
- package/dist/queries/hierarchy.js +2 -0
- package/dist/queries/hotspots.d.ts +42 -0
- package/dist/queries/hotspots.js +2 -0
- package/dist/queries/imports.d.ts +34 -0
- package/dist/queries/imports.js +2 -0
- package/dist/queries/incomplete-migration.d.ts +90 -0
- package/dist/queries/incomplete-migration.js +2 -0
- package/dist/queries/index.d.ts +180 -0
- package/dist/queries/index.js +2 -0
- package/dist/queries/isolated.d.ts +24 -0
- package/dist/queries/isolated.js +2 -0
- package/dist/queries/locality-candidates.d.ts +51 -0
- package/dist/queries/locality-candidates.js +2 -0
- package/dist/queries/members.d.ts +21 -0
- package/dist/queries/members.js +2 -0
- package/dist/queries/methods.d.ts +43 -0
- package/dist/queries/methods.js +2 -0
- package/dist/queries/not-implemented.d.ts +33 -0
- package/dist/queries/not-implemented.js +2 -0
- package/dist/queries/outline.d.ts +22 -0
- package/dist/queries/outline.js +2 -0
- package/dist/queries/passthrough-candidates.d.ts +41 -0
- package/dist/queries/passthrough-candidates.js +2 -0
- package/dist/queries/plan-context.d.ts +33 -0
- package/dist/queries/plan-context.js +2 -0
- package/dist/queries/react-component-duplicates.d.ts +39 -0
- package/dist/queries/react-component-duplicates.js +2 -0
- package/dist/queries/react-hook-candidates.d.ts +44 -0
- package/dist/queries/react-hook-candidates.js +2 -0
- package/dist/queries/react-large-component-pressure.d.ts +34 -0
- package/dist/queries/react-large-component-pressure.js +2 -0
- package/dist/queries/recent-duplicates.d.ts +79 -0
- package/dist/queries/recent-duplicates.js +2 -0
- package/dist/queries/redundant-reexports.d.ts +37 -0
- package/dist/queries/redundant-reexports.js +2 -0
- package/dist/queries/reference-neighborhood.d.ts +4 -0
- package/dist/queries/reference-neighborhood.js +2 -0
- package/dist/queries/reference-reachability.d.ts +48 -0
- package/dist/queries/reference-reachability.js +2 -0
- package/dist/queries/refs.d.ts +13 -0
- package/dist/queries/refs.js +2 -0
- package/dist/queries/self-audit.d.ts +65 -0
- package/dist/queries/self-audit.js +2 -0
- package/dist/queries/similar-chains.d.ts +48 -0
- package/dist/queries/similar-chains.js +2 -0
- package/dist/queries/similar-files.d.ts +35 -0
- package/dist/queries/similar-files.js +2 -0
- package/dist/queries/similar-signatures.d.ts +46 -0
- package/dist/queries/similar-signatures.js +2 -0
- package/dist/queries/similar.d.ts +187 -0
- package/dist/queries/similar.js +2 -0
- package/dist/queries/slice.d.ts +4 -0
- package/dist/queries/slice.js +2 -0
- package/dist/queries/source-inspection.d.ts +209 -0
- package/dist/queries/source-inspection.js +2 -0
- package/dist/queries/source-search.d.ts +85 -0
- package/dist/queries/source-search.js +2 -0
- package/dist/queries/stale-abstractions.d.ts +72 -0
- package/dist/queries/stale-abstractions.js +2 -0
- package/dist/queries/stats.d.ts +15 -0
- package/dist/queries/stats.js +2 -0
- package/dist/queries/surface.d.ts +22 -0
- package/dist/queries/surface.js +2 -0
- package/dist/queries/symbols.d.ts +14 -0
- package/dist/queries/symbols.js +2 -0
- package/dist/queries/system-map.d.ts +449 -0
- package/dist/queries/system-map.js +2 -0
- package/dist/queries/system.d.ts +21 -0
- package/dist/queries/system.js +2 -0
- package/dist/queries/test-quality.d.ts +56 -0
- package/dist/queries/test-quality.js +2 -0
- package/dist/queries/trace.d.ts +68 -0
- package/dist/queries/trace.js +2 -0
- package/dist/queries/twin-ab.d.ts +66 -0
- package/dist/queries/twin-ab.js +2 -0
- package/dist/queries/twin-drift.d.ts +119 -0
- package/dist/queries/twin-drift.js +2 -0
- package/dist/queries/unused-imports.d.ts +4 -0
- package/dist/queries/unused-imports.js +2 -0
- package/dist/queries/unused-params.d.ts +38 -0
- package/dist/queries/unused-params.js +2 -0
- package/dist/queries/value-flow.d.ts +42 -0
- package/dist/queries/value-flow.js +2 -0
- package/dist/queries/vue-component-duplicates.d.ts +43 -0
- package/dist/queries/vue-component-duplicates.js +2 -0
- package/dist/queries/vue-composable-candidates.d.ts +44 -0
- package/dist/queries/vue-composable-candidates.js +2 -0
- package/dist/queries/vue-large-view-pressure.d.ts +41 -0
- package/dist/queries/vue-large-view-pressure.js +2 -0
- package/dist/queries/wrapper-candidates.d.ts +34 -0
- package/dist/queries/wrapper-candidates.js +2 -0
- package/dist/reindex-worker.js +3 -0
- package/dist/reindex.d.ts +254 -0
- package/dist/reindex.js +298 -0
- package/dist/repository-text-C0Q8VYdN.d.ts +19 -0
- package/dist/runtime.d.ts +555 -0
- package/dist/runtime.js +4 -0
- package/dist/rust-semantic-session-server.js +2 -0
- package/dist/rust-semantic-session-worker.js +2 -0
- package/dist/rust-semantic-worker.js +2 -0
- package/dist/scip-cli-B7N3haxa.d.ts +67 -0
- package/dist/source-snippet-_wrcgmZc.d.ts +15 -0
- package/dist/symbol-types-BIQwfoAx.d.ts +74 -0
- package/dist/typescript-mailbox-worker.js +2 -0
- package/dist/watch-server.js +8 -0
- package/docs/AGENT_GUIDE.md +148 -0
- package/docs/AI_FAILURE_MODES.md +43 -0
- package/docs/API.md +40 -0
- package/docs/API_EVOLUTION.md +77 -0
- package/docs/CLI_JSON_OUTPUT.md +389 -0
- package/docs/COMMAND_REFERENCE.md +294 -0
- package/docs/CONFIGURATION_WRITE_SAFETY.md +131 -0
- package/docs/DETECTOR_GUIDE.md +46 -0
- package/docs/DURABILITY.md +159 -0
- package/docs/INDEX_GENERATIONS.md +167 -0
- package/docs/LOCK_PROTOCOL.md +133 -0
- package/docs/MAILBOX_LIFECYCLE.md +224 -0
- package/docs/REGEX_POLICY.md +36 -0
- package/docs/REINDEX_METADATA_COMPATIBILITY.md +104 -0
- package/docs/RUST_DURABLE_SESSION_PROTOCOL.md +126 -0
- package/docs/SECURITY_MODEL.md +125 -0
- package/docs/TELEMETRY_RETENTION.md +84 -0
- package/docs/TIME_SEMANTICS.md +77 -0
- package/docs/WATCH_REFRESH_REQUESTS.md +123 -0
- package/docs/WINDOWS_SIDECAR_RELEASE.md +424 -0
- package/docs/accuracy-audit-checklist.md +304 -0
- package/docs/accuracy-hardening-goal.md +500 -0
- package/docs/analyzer-inventory.md +78 -0
- package/docs/analyzer-validation-protocol.md +84 -0
- package/docs/architecture-coherence-vision.md +254 -0
- package/docs/assets/codebaseiq-logo-dark.svg +21 -0
- package/docs/assets/codebaseiq-logo.svg +24 -0
- package/docs/locality-analyzer-design.md +193 -0
- package/docs/schemas/cli-json-envelope.schema.json +237 -0
- package/docs/schemas/cli-output-page.schema.json +104 -0
- package/docs/schemas/npm-release-state.schema.json +146 -0
- package/docs/schemas/observation-receipt.schema.json +164 -0
- package/docs/schemas/project-config.schema.json +318 -0
- package/docs/schemas/suppression-record.schema.json +79 -0
- package/docs/schemas/windows-sidecar-provenance.schema.json +137 -0
- package/package.json +482 -0
- package/scripts/build-codebaseiq-windows.mjs +197 -0
- package/scripts/codebaseiq-windows-provenance.mjs +364 -0
- package/scripts/evidence-product-contract.mjs +197 -0
- package/scripts/verify-codebaseiq-windows.mjs +29 -0
- package/skills/codebaseiq/SKILL.md +75 -0
- package/skills/codebaseiq/agents/openai.yaml +4 -0
- package/skills/codebaseiq-explore/SKILL.md +34 -0
- package/skills/codebaseiq-explore/agents/openai.yaml +4 -0
- package/skills/concrete-plan/SKILL.md +79 -0
- package/skills/concrete-plan/agents/openai.yaml +4 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
type ReactLargeComponentPressureAxis = 'component' | 'file' | 'jsx-structure' | 'hook-behavior';
|
|
6
|
+
type ReactLargeComponentContextKind = 'component' | 'route-page';
|
|
7
|
+
type ReactLargeComponentRecommendationKind = 'behavior-extraction' | 'component-decomposition' | 'file-decomposition' | 'jsx-decomposition' | 'route-page-decomposition';
|
|
8
|
+
interface ReactLargeComponentPressureResult {
|
|
9
|
+
file: string;
|
|
10
|
+
component: string;
|
|
11
|
+
componentLines: number;
|
|
12
|
+
fileLines: number;
|
|
13
|
+
jsxTokens: number;
|
|
14
|
+
behaviorTokens: number;
|
|
15
|
+
dominantPressure: ReactLargeComponentPressureAxis;
|
|
16
|
+
pressureKinds: ReactLargeComponentPressureAxis[];
|
|
17
|
+
contextKind: ReactLargeComponentContextKind;
|
|
18
|
+
recommendationKind: ReactLargeComponentRecommendationKind;
|
|
19
|
+
recommendation: string;
|
|
20
|
+
reasons: string[];
|
|
21
|
+
loc: number;
|
|
22
|
+
}
|
|
23
|
+
declare function reactLargeComponentPressure(db: ScipDatabase, opts?: {
|
|
24
|
+
minComponentLines?: number;
|
|
25
|
+
minFileLines?: number;
|
|
26
|
+
minJsxTokens?: number;
|
|
27
|
+
minBehaviorTokens?: number;
|
|
28
|
+
limit?: number;
|
|
29
|
+
scope?: string;
|
|
30
|
+
scanLimit?: number;
|
|
31
|
+
filePattern?: string;
|
|
32
|
+
}): ReactLargeComponentPressureResult[];
|
|
33
|
+
|
|
34
|
+
export { type ReactLargeComponentContextKind, type ReactLargeComponentPressureAxis, type ReactLargeComponentPressureResult, type ReactLargeComponentRecommendationKind, reactLargeComponentPressure };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-7NVGT435.js";import"../chunk-OTOKVOJ3.js";import"../chunk-NMTSZXCL.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as reactLargeComponentPressure};
|
|
2
|
+
//# sourceMappingURL=react-large-component-pressure.js.map
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import { G as GitHistoryMode } from '../git-history-ChNHbfZQ.js';
|
|
3
|
+
import 'better-sqlite3';
|
|
4
|
+
import '../config-types-BNoC96J3.js';
|
|
5
|
+
|
|
6
|
+
type RecentDuplicateDomain = 'callable' | 'react-component' | 'react-hook' | 'vue-component' | 'vue-composable';
|
|
7
|
+
type RecentDuplicateBasis = 'callees' | 'source-tokens' | 'jsx-structure' | 'react-behavior' | 'vue-template' | 'vue-behavior';
|
|
8
|
+
interface RecentDuplicateFinding {
|
|
9
|
+
/** 'echo': recent code duplicating established code. 'twin': both sides are new. */
|
|
10
|
+
kind: 'echo' | 'twin';
|
|
11
|
+
domain: RecentDuplicateDomain;
|
|
12
|
+
basis: RecentDuplicateBasis;
|
|
13
|
+
/** Stable grouping key for repeated pairwise rows behind one review item. */
|
|
14
|
+
groupKey?: string;
|
|
15
|
+
/** Stable root-cause identity without the analyzer prefix. */
|
|
16
|
+
rootCauseKey?: string;
|
|
17
|
+
echoSymbol: string;
|
|
18
|
+
echoFile: string;
|
|
19
|
+
/** Commits ago the echo's file was added. */
|
|
20
|
+
echoAgeCommits: number;
|
|
21
|
+
establishedSymbol: string;
|
|
22
|
+
establishedFile: string;
|
|
23
|
+
/** Commits ago the established file was added; null = older than the window. */
|
|
24
|
+
establishedAgeCommits: number | null;
|
|
25
|
+
similarity: number;
|
|
26
|
+
/** Domain-specific shared evidence. For callables this mirrors sharedCallees. */
|
|
27
|
+
sharedEvidence: string[];
|
|
28
|
+
/** Backwards-compatible callable evidence field. Empty for non-callable frontend domains. */
|
|
29
|
+
sharedCallees: string[];
|
|
30
|
+
}
|
|
31
|
+
interface RecentDuplicateRootCauseGroup {
|
|
32
|
+
groupKey: string;
|
|
33
|
+
rootCauseKey: string;
|
|
34
|
+
kind: 'echo' | 'twin';
|
|
35
|
+
domain: RecentDuplicateDomain;
|
|
36
|
+
basis: RecentDuplicateBasis;
|
|
37
|
+
count: number;
|
|
38
|
+
maxSimilarity: number;
|
|
39
|
+
findingIndexes: number[];
|
|
40
|
+
echoFiles: string[];
|
|
41
|
+
establishedFile?: string;
|
|
42
|
+
establishedSymbol?: string;
|
|
43
|
+
relatedFiles: string[];
|
|
44
|
+
sharedEvidence: string[];
|
|
45
|
+
recommendation: string;
|
|
46
|
+
}
|
|
47
|
+
interface RecentDuplicatesResult {
|
|
48
|
+
/** False when git history is unavailable. */
|
|
49
|
+
available: boolean;
|
|
50
|
+
windowCommits: number;
|
|
51
|
+
findings: RecentDuplicateFinding[];
|
|
52
|
+
/** Root-cause review items derived from the pairwise findings above. */
|
|
53
|
+
rootCauseGroups?: RecentDuplicateRootCauseGroup[];
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Recent re-implementations: AI agents (and humans in a hurry) write new
|
|
57
|
+
* helpers that duplicate code they didn't know existed. Generic similarity
|
|
58
|
+
* finds the pairs; this makes them DIRECTIONAL using git file ages — which
|
|
59
|
+
* side is the established original, which is the recent echo.
|
|
60
|
+
*
|
|
61
|
+
* 'echo' → the new code should probably use or extend the established code;
|
|
62
|
+
* delete the echo.
|
|
63
|
+
* 'twin' → both sides landed recently (often one agent session duplicating
|
|
64
|
+
* itself); pick one and consolidate before they diverge.
|
|
65
|
+
*
|
|
66
|
+
* Pairs where both sides are established are ordinary `similar` territory
|
|
67
|
+
* and are skipped here.
|
|
68
|
+
*/
|
|
69
|
+
declare function recentDuplicates(db: ScipDatabase, opts?: {
|
|
70
|
+
windowCommits?: number;
|
|
71
|
+
minSimilarity?: number;
|
|
72
|
+
limit?: number;
|
|
73
|
+
scope?: string;
|
|
74
|
+
scanLimit?: number;
|
|
75
|
+
semantic?: boolean;
|
|
76
|
+
historyMode?: GitHistoryMode;
|
|
77
|
+
}): RecentDuplicatesResult;
|
|
78
|
+
|
|
79
|
+
export { type RecentDuplicateBasis, type RecentDuplicateDomain, type RecentDuplicateFinding, type RecentDuplicateRootCauseGroup, type RecentDuplicatesResult, recentDuplicates };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-H3LGFZVK.js";import"../chunk-DQMDCD24.js";import"../chunk-RBAS5ZHI.js";import"../chunk-XWUOUWYI.js";import"../chunk-SYDJMPES.js";import"../chunk-IRQOAM5G.js";import"../chunk-OTOKVOJ3.js";import"../chunk-4WKDMDEW.js";import"../chunk-UDS562V4.js";import"../chunk-NMTSZXCL.js";import"../chunk-B75HZHUP.js";import"../chunk-7FND7D7N.js";import"../chunk-BGBBVSH4.js";import"../chunk-JOIRNPPY.js";import"../chunk-6CS3UQTN.js";import"../chunk-P5XHIJHI.js";import"../chunk-J77SU6VA.js";import"../chunk-UCD3H3UZ.js";import"../chunk-CVYSU6BX.js";import"../chunk-ELNRLMC5.js";import"../chunk-UZGZB3VB.js";import"../chunk-ZKX2FRS6.js";import"../chunk-C7QOQX32.js";import"../chunk-TIIC3ZE7.js";import"../chunk-YUKYB54I.js";import"../chunk-OANDYLJQ.js";import"../chunk-NNOKTMZT.js";import"../chunk-SGX43S2L.js";import"../chunk-FETNQCFO.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as recentDuplicates};
|
|
2
|
+
//# sourceMappingURL=recent-duplicates.js.map
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
type RedundantReexportActionTier = 'direct' | 'signal';
|
|
6
|
+
interface RedundantReexport {
|
|
7
|
+
barrelFile: string;
|
|
8
|
+
symbol: string;
|
|
9
|
+
shortName: string;
|
|
10
|
+
originalFile: string;
|
|
11
|
+
/** How many consumers import through the barrel */
|
|
12
|
+
barrelConsumers: number;
|
|
13
|
+
/** How many consumers import directly from the source */
|
|
14
|
+
directConsumers: number;
|
|
15
|
+
actionTier: RedundantReexportActionTier;
|
|
16
|
+
surfaceEvidence: string[];
|
|
17
|
+
recommendation: string;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Find barrel re-exports that no consumer actually imports through.
|
|
21
|
+
*
|
|
22
|
+
* If `queries/index.ts` re-exports `byKind` from `by-kind.ts`, but every
|
|
23
|
+
* consumer of `byKind` imports it directly from `by-kind.ts` (not through
|
|
24
|
+
* `index.ts`), the re-export in the barrel is dead weight.
|
|
25
|
+
*
|
|
26
|
+
* Algorithm:
|
|
27
|
+
* 1. Find all barrel files (index.ts / index.js)
|
|
28
|
+
* 2. For each barrel, find symbols it re-exports (defined elsewhere, referenced in barrel with role=0)
|
|
29
|
+
* 3. For each re-exported symbol, count consumers through the barrel vs direct from the source
|
|
30
|
+
* 4. If zero consumers go through the barrel, the re-export is redundant
|
|
31
|
+
*/
|
|
32
|
+
declare function redundantReexports(db: ScipDatabase, opts?: {
|
|
33
|
+
scope?: string;
|
|
34
|
+
limit?: number;
|
|
35
|
+
}): RedundantReexport[];
|
|
36
|
+
|
|
37
|
+
export { type RedundantReexport, type RedundantReexportActionTier, redundantReexports };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-UP3BUZR5.js";import"../chunk-7FND7D7N.js";import"../chunk-BGBBVSH4.js";import"../chunk-JOIRNPPY.js";import"../chunk-6CS3UQTN.js";import"../chunk-P5XHIJHI.js";import"../chunk-J77SU6VA.js";import"../chunk-UCD3H3UZ.js";import"../chunk-CVYSU6BX.js";import"../chunk-ELNRLMC5.js";import"../chunk-UZGZB3VB.js";import"../chunk-ZKX2FRS6.js";import"../chunk-C7QOQX32.js";import"../chunk-TIIC3ZE7.js";import"../chunk-YUKYB54I.js";import"../chunk-OANDYLJQ.js";import"../chunk-NNOKTMZT.js";import"../chunk-SGX43S2L.js";import"../chunk-FETNQCFO.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as redundantReexports};
|
|
2
|
+
//# sourceMappingURL=redundant-reexports.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a,b}from"../chunk-LZYFLFEH.js";import"../chunk-B75HZHUP.js";import"../chunk-BGBBVSH4.js";import"../chunk-JOIRNPPY.js";import"../chunk-6CS3UQTN.js";import"../chunk-P5XHIJHI.js";import"../chunk-J77SU6VA.js";import"../chunk-UCD3H3UZ.js";import"../chunk-CVYSU6BX.js";import"../chunk-ELNRLMC5.js";import"../chunk-UZGZB3VB.js";import"../chunk-ZKX2FRS6.js";import"../chunk-NNOKTMZT.js";import"../chunk-SGX43S2L.js";import"../chunk-FETNQCFO.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{b as dataflow,a as referenceNeighborhood};
|
|
2
|
+
//# sourceMappingURL=reference-neighborhood.js.map
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
interface SliceResult {
|
|
6
|
+
symbol: string;
|
|
7
|
+
shortName: string;
|
|
8
|
+
direction: 'backward' | 'forward';
|
|
9
|
+
/** Backward: symbols referenced in the same function as the target's definition (inputs) */
|
|
10
|
+
/** Forward: symbols defined by functions that reference the target (outputs) */
|
|
11
|
+
connectedSymbols: Array<{
|
|
12
|
+
symbol: string;
|
|
13
|
+
shortName: string;
|
|
14
|
+
file: string;
|
|
15
|
+
relationship: string;
|
|
16
|
+
}>;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Historical reference/call reachability projection.
|
|
20
|
+
*
|
|
21
|
+
* Backward slice: "What feeds into this?" — transitive closure of callees.
|
|
22
|
+
* Depth 1 = direct callees, depth 2 = their callees, etc.
|
|
23
|
+
*
|
|
24
|
+
* Forward slice: "What does this feed into?" — at each site where the target
|
|
25
|
+
* is referenced, find the enclosing function, then find what that function
|
|
26
|
+
* exports/defines. These are the outputs/consumers.
|
|
27
|
+
*
|
|
28
|
+
* This is not a program slice: call reachability does not establish data or
|
|
29
|
+
* control dependence. It remains available under an honest name so existing
|
|
30
|
+
* callers can migrate without losing behavior.
|
|
31
|
+
*/
|
|
32
|
+
declare function referenceReachability(db: ScipDatabase, symbolPattern: string, opts?: {
|
|
33
|
+
direction?: 'backward' | 'forward';
|
|
34
|
+
maxDepth?: number;
|
|
35
|
+
semantic?: boolean;
|
|
36
|
+
}): SliceResult | null;
|
|
37
|
+
/**
|
|
38
|
+
* @deprecated The historical implementation traverses calls and reference
|
|
39
|
+
* owners, not a program-dependence graph. Use `referenceReachability` for that
|
|
40
|
+
* legacy projection and `dependenceSlice` for data/control slicing.
|
|
41
|
+
*/
|
|
42
|
+
declare function slice(db: ScipDatabase, symbolPattern: string, opts?: {
|
|
43
|
+
direction?: 'backward' | 'forward';
|
|
44
|
+
maxDepth?: number;
|
|
45
|
+
semantic?: boolean;
|
|
46
|
+
}): SliceResult | null;
|
|
47
|
+
|
|
48
|
+
export { type SliceResult, referenceReachability, slice };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a,b}from"../chunk-XME3HPXZ.js";import"../chunk-7FND7D7N.js";import"../chunk-BGBBVSH4.js";import"../chunk-JOIRNPPY.js";import"../chunk-6CS3UQTN.js";import"../chunk-P5XHIJHI.js";import"../chunk-J77SU6VA.js";import"../chunk-UCD3H3UZ.js";import"../chunk-CVYSU6BX.js";import"../chunk-ELNRLMC5.js";import"../chunk-UZGZB3VB.js";import"../chunk-ZKX2FRS6.js";import"../chunk-C7QOQX32.js";import"../chunk-TIIC3ZE7.js";import"../chunk-YUKYB54I.js";import"../chunk-OANDYLJQ.js";import"../chunk-NNOKTMZT.js";import"../chunk-SGX43S2L.js";import"../chunk-FETNQCFO.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as referenceReachability,b as slice};
|
|
2
|
+
//# sourceMappingURL=reference-reachability.js.map
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
interface RefResult {
|
|
6
|
+
relativePath: string;
|
|
7
|
+
line: number;
|
|
8
|
+
}
|
|
9
|
+
declare function refs(db: ScipDatabase, symbolPattern: string, opts?: {
|
|
10
|
+
semantic?: boolean;
|
|
11
|
+
}): RefResult[];
|
|
12
|
+
|
|
13
|
+
export { type RefResult, refs };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-IJ4HMYBE.js";import"../chunk-JOIRNPPY.js";import"../chunk-6CS3UQTN.js";import"../chunk-P5XHIJHI.js";import"../chunk-UCD3H3UZ.js";import"../chunk-CVYSU6BX.js";import"../chunk-ELNRLMC5.js";import"../chunk-UZGZB3VB.js";import"../chunk-ZKX2FRS6.js";import"../chunk-NNOKTMZT.js";import"../chunk-FETNQCFO.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as refs};
|
|
2
|
+
//# sourceMappingURL=refs.js.map
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
type AuditQuestion = 'references' | 'callees';
|
|
6
|
+
type AuditOracleKind = 'semantic' | 'source';
|
|
7
|
+
interface AuditDisagreement {
|
|
8
|
+
symbol: string;
|
|
9
|
+
question: AuditQuestion;
|
|
10
|
+
/** Files only the cheap evidence path reported (potential false positives). */
|
|
11
|
+
cheapOnly: string[];
|
|
12
|
+
/** Files only the compiler oracle reported (potential misses). */
|
|
13
|
+
oracleOnly: string[];
|
|
14
|
+
}
|
|
15
|
+
interface AuditQuestionScore {
|
|
16
|
+
question: AuditQuestion;
|
|
17
|
+
/** Symbols where both paths produced a comparable (non-empty) answer. */
|
|
18
|
+
comparedSymbols: number;
|
|
19
|
+
/**
|
|
20
|
+
* Null when the oracle is partial for this question (it confirms positives
|
|
21
|
+
* but doesn't enumerate all of them), so "cheap-only" answers are
|
|
22
|
+
* unverified rather than wrong and no precision claim is valid.
|
|
23
|
+
*/
|
|
24
|
+
precision: number | null;
|
|
25
|
+
recall: number;
|
|
26
|
+
/** Cheap-path answers the oracle could not confirm (only meaningful when precision is null). */
|
|
27
|
+
unverified: number;
|
|
28
|
+
/** Samples skipped because the oracle is partial and produced no comparable answer. */
|
|
29
|
+
skippedOraclePartial: number;
|
|
30
|
+
/** Samples skipped because compiler-backed oracle evidence was incomplete or unavailable. */
|
|
31
|
+
skippedOracleUnavailable: number;
|
|
32
|
+
}
|
|
33
|
+
interface SelfAuditResult {
|
|
34
|
+
/** False when no semantic or source-backed oracle is available. */
|
|
35
|
+
available: boolean;
|
|
36
|
+
sampleSize: number;
|
|
37
|
+
/** Fraction of sampled symbols the oracle could answer at all. */
|
|
38
|
+
oracleCoverage: number;
|
|
39
|
+
/** Semantic means compiler-backed; source means language source-fact-backed. */
|
|
40
|
+
oracleKind?: AuditOracleKind;
|
|
41
|
+
scores: AuditQuestionScore[];
|
|
42
|
+
/** Largest divergences — the actionable debugging targets. */
|
|
43
|
+
topDisagreements: AuditDisagreement[];
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Accuracy oracle: score the cheap evidence paths (SCIP + source heuristics)
|
|
47
|
+
* against the embedded TypeScript compiler (ts-morph) on a deterministic
|
|
48
|
+
* sample of symbols.
|
|
49
|
+
*
|
|
50
|
+
* This measures *agreement with compiler semantics*, not absolute truth —
|
|
51
|
+
* the compiler misses dynamic dispatch too. Comparison is at file-set
|
|
52
|
+
* granularity ("which files reference/are called by this symbol") because
|
|
53
|
+
* symbol-identity schemes differ between providers while file attribution
|
|
54
|
+
* does not.
|
|
55
|
+
*
|
|
56
|
+
* The point: "make every command as accurate as possible" is only meaningful
|
|
57
|
+
* once accuracy is a number you can track. This is that number.
|
|
58
|
+
*/
|
|
59
|
+
declare function selfAudit(db: ScipDatabase, opts?: {
|
|
60
|
+
samples?: number;
|
|
61
|
+
scope?: string;
|
|
62
|
+
maxDisagreements?: number;
|
|
63
|
+
}): SelfAuditResult;
|
|
64
|
+
|
|
65
|
+
export { type AuditDisagreement, type AuditOracleKind, type AuditQuestion, type AuditQuestionScore, type SelfAuditResult, selfAudit };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-VEXUL62T.js";import"../chunk-7FND7D7N.js";import"../chunk-BGBBVSH4.js";import"../chunk-JOIRNPPY.js";import"../chunk-6CS3UQTN.js";import"../chunk-P5XHIJHI.js";import"../chunk-J77SU6VA.js";import"../chunk-UCD3H3UZ.js";import"../chunk-CVYSU6BX.js";import"../chunk-ELNRLMC5.js";import"../chunk-UZGZB3VB.js";import"../chunk-ZKX2FRS6.js";import"../chunk-C7QOQX32.js";import"../chunk-TIIC3ZE7.js";import"../chunk-YUKYB54I.js";import"../chunk-OANDYLJQ.js";import"../chunk-NNOKTMZT.js";import"../chunk-SGX43S2L.js";import"../chunk-FETNQCFO.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as selfAudit};
|
|
2
|
+
//# sourceMappingURL=self-audit.js.map
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
interface SimilarChainResult {
|
|
6
|
+
chainA: string[];
|
|
7
|
+
chainB: string[];
|
|
8
|
+
/** Fraction of nodes shared (0-1) */
|
|
9
|
+
similarity: number;
|
|
10
|
+
/** Edit distance between the two chains */
|
|
11
|
+
editDistance: number;
|
|
12
|
+
/** Indices where the chains diverge — the consolidation targets */
|
|
13
|
+
divergencePoints: Array<{
|
|
14
|
+
index: number;
|
|
15
|
+
nodeA: string;
|
|
16
|
+
nodeB: string;
|
|
17
|
+
}>;
|
|
18
|
+
/** Shared prefix */
|
|
19
|
+
commonPrefix: string[];
|
|
20
|
+
/** Shared suffix */
|
|
21
|
+
commonSuffix: string[];
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Find end-to-end dependency flows that are structurally similar
|
|
25
|
+
* but diverge at a few points — indicating duplicated pipelines
|
|
26
|
+
* that could be consolidated.
|
|
27
|
+
*
|
|
28
|
+
* Uses infrastructure-filtered chain comparison:
|
|
29
|
+
*
|
|
30
|
+
* 1. Build all dependency chains via DFS
|
|
31
|
+
* 2. Compute node frequency across all chains
|
|
32
|
+
* 3. Filter out infrastructure nodes (appearing in >50% of chains)
|
|
33
|
+
* 4. Compare the filtered chains — what's left is the unique pipeline
|
|
34
|
+
* 5. Edit distance on filtered chains finds real structural duplicates
|
|
35
|
+
*
|
|
36
|
+
* Two chains that both pass through db.ts → types.ts is meaningless.
|
|
37
|
+
* Two chains that both pass through userValidation → userRepo → emailService
|
|
38
|
+
* after filtering is a strong consolidation signal.
|
|
39
|
+
*/
|
|
40
|
+
declare function similarChains(db: ScipDatabase, opts?: {
|
|
41
|
+
minSimilarity?: number;
|
|
42
|
+
limit?: number;
|
|
43
|
+
scope?: string;
|
|
44
|
+
minChainLength?: number;
|
|
45
|
+
maxChainLength?: number;
|
|
46
|
+
}): SimilarChainResult[];
|
|
47
|
+
|
|
48
|
+
export { type SimilarChainResult, similarChains };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-CO5R3UNA.js";import"../chunk-NNOKTMZT.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as similarChains};
|
|
2
|
+
//# sourceMappingURL=similar-chains.js.map
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
interface SimilarFileResult {
|
|
6
|
+
fileA: string;
|
|
7
|
+
fileB: string;
|
|
8
|
+
/** Jaccard similarity of dependency sets (0-1) */
|
|
9
|
+
similarity: number;
|
|
10
|
+
sharedDeps: string[];
|
|
11
|
+
uniqueToA: string[];
|
|
12
|
+
uniqueToB: string[];
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Find files with similar dependency profiles.
|
|
16
|
+
*
|
|
17
|
+
* Two files that depend on (import from) the same set of other files
|
|
18
|
+
* are structurally doing similar work. High Jaccard similarity between
|
|
19
|
+
* their dependency sets = likely copy-paste variants or consolidation candidates.
|
|
20
|
+
*
|
|
21
|
+
* Evidence policy: a pair must share at least two *distinctive* deps —
|
|
22
|
+
* deps with low global fan-in. Files that overlap only on family
|
|
23
|
+
* infrastructure (the modules everyone in their directory imports) are
|
|
24
|
+
* not copy-paste variants; adapter families sharing an SDK scored 100%
|
|
25
|
+
* before this gate while differing in everything that matters.
|
|
26
|
+
*/
|
|
27
|
+
declare function similarFiles(db: ScipDatabase, opts?: {
|
|
28
|
+
minSimilarity?: number;
|
|
29
|
+
limit?: number;
|
|
30
|
+
scope?: string;
|
|
31
|
+
minDeps?: number;
|
|
32
|
+
filePattern?: string;
|
|
33
|
+
}): SimilarFileResult[];
|
|
34
|
+
|
|
35
|
+
export { type SimilarFileResult, similarFiles };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-Q65CQ4XL.js";import"../chunk-IRQOAM5G.js";import"../chunk-NMTSZXCL.js";import"../chunk-NNOKTMZT.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as similarFiles};
|
|
2
|
+
//# sourceMappingURL=similar-files.js.map
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
type SignatureLocBand = '<=5' | '6-20' | '>20';
|
|
6
|
+
type SimilarSignatureFunction = {
|
|
7
|
+
symbol: string;
|
|
8
|
+
shortName: string;
|
|
9
|
+
file: string;
|
|
10
|
+
startLine: number;
|
|
11
|
+
endLine: number;
|
|
12
|
+
loc: number;
|
|
13
|
+
};
|
|
14
|
+
interface SimilarSignatureGroup {
|
|
15
|
+
/** The normalized signature shared by all functions in the group */
|
|
16
|
+
signature: string;
|
|
17
|
+
/** Size band used to avoid mixing tiny helpers with larger implementations. */
|
|
18
|
+
locBand: SignatureLocBand;
|
|
19
|
+
/** True when an over-common shape was kept because the bodies match exactly. */
|
|
20
|
+
exactBody: boolean;
|
|
21
|
+
/** Functions that share this signature */
|
|
22
|
+
functions: SimilarSignatureFunction[];
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Find functions with near-identical type signatures (same parameter types
|
|
26
|
+
* and return type) but different names. These are "same shape" functions
|
|
27
|
+
* that may be doing similar work even if their internal implementation differs.
|
|
28
|
+
*
|
|
29
|
+
* The SCIP `documentation` field often contains the full type signature
|
|
30
|
+
* after a `|` delimiter. When that data is missing or too thin, we fall
|
|
31
|
+
* back to the declaration head from source. We normalize the result
|
|
32
|
+
* (strip the function name, normalize whitespace and case), then group
|
|
33
|
+
* by signature shape.
|
|
34
|
+
*
|
|
35
|
+
* Groups with 2+ functions = same-shape candidates.
|
|
36
|
+
*/
|
|
37
|
+
declare function similarSignatures(db: ScipDatabase, opts?: {
|
|
38
|
+
scope?: string;
|
|
39
|
+
minLoc?: number;
|
|
40
|
+
limit?: number;
|
|
41
|
+
scanLimit?: number;
|
|
42
|
+
semantic?: boolean;
|
|
43
|
+
maxShapeFrequency?: number;
|
|
44
|
+
}): SimilarSignatureGroup[];
|
|
45
|
+
|
|
46
|
+
export { type SimilarSignatureGroup, similarSignatures };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../chunk-7XAN6GKB.js";import"../chunk-T3DGWPXM.js";import"../chunk-4WKDMDEW.js";import"../chunk-B75HZHUP.js";import"../chunk-BGBBVSH4.js";import"../chunk-6CS3UQTN.js";import"../chunk-P5XHIJHI.js";import"../chunk-UCD3H3UZ.js";import"../chunk-ELNRLMC5.js";import"../chunk-ZKX2FRS6.js";import"../chunk-NNOKTMZT.js";import"../chunk-SGX43S2L.js";import"../chunk-FETNQCFO.js";import"../chunk-O6QTXQPJ.js";import"../chunk-ADTBPVUZ.js";import"../chunk-BMYOV5GP.js";import"../chunk-CWONGW6P.js";import"../chunk-3LCDIREB.js";import"../chunk-NNJ2KZZG.js";export{a as similarSignatures};
|
|
2
|
+
//# sourceMappingURL=similar-signatures.js.map
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
import { S as ScipDatabase } from '../db-D7sauVFH.js';
|
|
2
|
+
import 'better-sqlite3';
|
|
3
|
+
import '../config-types-BNoC96J3.js';
|
|
4
|
+
|
|
5
|
+
interface SimilarSymbolResult {
|
|
6
|
+
symbolA: string;
|
|
7
|
+
shortNameA: string;
|
|
8
|
+
fileA: string;
|
|
9
|
+
symbolB: string;
|
|
10
|
+
shortNameB: string;
|
|
11
|
+
fileB: string;
|
|
12
|
+
/** Similarity score (0-1). Basis says what evidence was compared. */
|
|
13
|
+
similarity: number;
|
|
14
|
+
/** Evidence used for similarity: call graph callees or lexical source tokens. */
|
|
15
|
+
similarityBasis?: 'callees' | 'source-tokens';
|
|
16
|
+
/** Shared callees or source tokens, depending on similarityBasis. */
|
|
17
|
+
sharedCallees: string[];
|
|
18
|
+
/** Callees or source tokens unique to A, depending on similarityBasis. */
|
|
19
|
+
uniqueToA: string[];
|
|
20
|
+
/** Callees or source tokens unique to B, depending on similarityBasis. */
|
|
21
|
+
uniqueToB: string[];
|
|
22
|
+
evidenceClass: SimilarEvidenceClass;
|
|
23
|
+
actionTier: SimilarActionTier;
|
|
24
|
+
evidenceClassReasons: string[];
|
|
25
|
+
recommendation: string;
|
|
26
|
+
}
|
|
27
|
+
interface SimilarConsolidationPlan {
|
|
28
|
+
symbolA: {
|
|
29
|
+
symbol: string;
|
|
30
|
+
shortName: string;
|
|
31
|
+
file: string;
|
|
32
|
+
loc: number;
|
|
33
|
+
};
|
|
34
|
+
symbolB: {
|
|
35
|
+
symbol: string;
|
|
36
|
+
shortName: string;
|
|
37
|
+
file: string;
|
|
38
|
+
loc: number;
|
|
39
|
+
};
|
|
40
|
+
similarity: number;
|
|
41
|
+
similarityBasis: NonNullable<SimilarSymbolResult['similarityBasis']>;
|
|
42
|
+
sharedEvidence: string[];
|
|
43
|
+
uniqueToA: string[];
|
|
44
|
+
uniqueToB: string[];
|
|
45
|
+
evidenceClass: SimilarEvidenceClass;
|
|
46
|
+
actionTier: SimilarActionTier;
|
|
47
|
+
recommendation: string;
|
|
48
|
+
consolidationStrategy: string;
|
|
49
|
+
}
|
|
50
|
+
type SimilarEvidenceClass = 'access-query-scaffolding' | 'domain-behavior' | 'framework-scaffolding' | 'mixed' | 'structural-overlap';
|
|
51
|
+
type SimilarActionTier = 'direct' | 'signal';
|
|
52
|
+
interface SimilarEvidenceClassification {
|
|
53
|
+
evidenceClass: SimilarEvidenceClass;
|
|
54
|
+
actionTier: SimilarActionTier;
|
|
55
|
+
evidenceClassReasons: string[];
|
|
56
|
+
recommendation: string;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* Find functions with similar callee fingerprints using TF-IDF weighted
|
|
60
|
+
* cosine similarity.
|
|
61
|
+
*
|
|
62
|
+
* Plain Jaccard similarity inflates scores when functions share ubiquitous
|
|
63
|
+
* infrastructure imports (db, types, shortenSymbol). TF-IDF fixes this by
|
|
64
|
+
* weighting each shared callee by how rare it is:
|
|
65
|
+
*
|
|
66
|
+
* - A callee used by 2 functions (rare) gets high weight → strong signal
|
|
67
|
+
* - A callee used by 30 functions (common) gets low weight → noise
|
|
68
|
+
*
|
|
69
|
+
* This means two functions sharing `sendWelcomeEmail()` (rare) score
|
|
70
|
+
* much higher than two functions sharing `db.all()` (ubiquitous), even
|
|
71
|
+
* though both are "shared callees."
|
|
72
|
+
*/
|
|
73
|
+
declare function similar(db: ScipDatabase, symbolPattern: string, opts?: {
|
|
74
|
+
minSimilarity?: number;
|
|
75
|
+
limit?: number;
|
|
76
|
+
scanLimit?: number;
|
|
77
|
+
semantic?: boolean;
|
|
78
|
+
sourceCandidateMode?: SourceCandidateMode;
|
|
79
|
+
}): SimilarSymbolResult[];
|
|
80
|
+
declare function similarConsolidationPlan(db: ScipDatabase, symbolPatternA: string, symbolPatternB: string, opts?: {
|
|
81
|
+
semantic?: boolean;
|
|
82
|
+
scanLimit?: number;
|
|
83
|
+
}): SimilarConsolidationPlan | null;
|
|
84
|
+
declare function targetSpecificIdfWeights(target: SymbolFingerprint, index: Pick<CalleeFingerprintIndex, 'corpus' | 'docFreq'>): Map<string, number>;
|
|
85
|
+
interface ComparePairOptions {
|
|
86
|
+
minSimilarity: number;
|
|
87
|
+
/** Pair is dropped when significantShared.length < this AND sharedCount < requireSharedCount. */
|
|
88
|
+
requireSignificantShared: number;
|
|
89
|
+
requireSharedCount: number;
|
|
90
|
+
medianIdf?: number;
|
|
91
|
+
magnitudeA?: number;
|
|
92
|
+
magnitudeB?: number;
|
|
93
|
+
}
|
|
94
|
+
declare function comparePair(a: SymbolFingerprint, b: SymbolFingerprint, idfWeights: ReadonlyMap<string, number>, opts: ComparePairOptions): SimilarSymbolResult | null;
|
|
95
|
+
/**
|
|
96
|
+
* Find similar symbols across the entire codebase.
|
|
97
|
+
* Uses TF-IDF weighted similarity to filter out infrastructure noise.
|
|
98
|
+
*/
|
|
99
|
+
declare function similarAll(db: ScipDatabase, opts?: {
|
|
100
|
+
minSimilarity?: number;
|
|
101
|
+
limit?: number;
|
|
102
|
+
scope?: string;
|
|
103
|
+
minCallees?: number;
|
|
104
|
+
crossFileOnly?: boolean;
|
|
105
|
+
scanLimit?: number;
|
|
106
|
+
semantic?: boolean;
|
|
107
|
+
focusFiles?: ReadonlySet<string>;
|
|
108
|
+
}): SimilarSymbolResult[];
|
|
109
|
+
declare function similarAllCount(db: ScipDatabase, opts?: {
|
|
110
|
+
minSimilarity?: number;
|
|
111
|
+
scope?: string;
|
|
112
|
+
minCallees?: number;
|
|
113
|
+
crossFileOnly?: boolean;
|
|
114
|
+
scanLimit?: number;
|
|
115
|
+
semantic?: boolean;
|
|
116
|
+
focusFiles?: ReadonlySet<string>;
|
|
117
|
+
}): number;
|
|
118
|
+
interface SymbolFingerprint {
|
|
119
|
+
symbol: string;
|
|
120
|
+
file: string;
|
|
121
|
+
callees: Set<string>;
|
|
122
|
+
paramCount: number;
|
|
123
|
+
}
|
|
124
|
+
type SourceCandidateMode = 'full' | 'target-pruned';
|
|
125
|
+
interface CalleeFingerprintCorpusOptions {
|
|
126
|
+
minCallees: number;
|
|
127
|
+
scope?: string;
|
|
128
|
+
excludeSymbol?: string;
|
|
129
|
+
scanLimit?: number;
|
|
130
|
+
semantic?: boolean;
|
|
131
|
+
}
|
|
132
|
+
interface CalleeFingerprintIndexOptions {
|
|
133
|
+
minCallees: number;
|
|
134
|
+
scope?: string;
|
|
135
|
+
scanLimit?: number;
|
|
136
|
+
semantic?: boolean;
|
|
137
|
+
}
|
|
138
|
+
interface SourceFingerprintOptions {
|
|
139
|
+
scanLimit?: number;
|
|
140
|
+
}
|
|
141
|
+
interface SourceFingerprintCandidateOptions extends SourceFingerprintOptions {
|
|
142
|
+
minSimilarity: number;
|
|
143
|
+
candidateMode?: SourceCandidateMode;
|
|
144
|
+
}
|
|
145
|
+
interface SimilarityFingerprintProduct {
|
|
146
|
+
calleeCorpus(opts: CalleeFingerprintCorpusOptions): SymbolFingerprint[];
|
|
147
|
+
calleeIndex(opts: CalleeFingerprintIndexOptions): CalleeFingerprintIndex;
|
|
148
|
+
sourceCorpus(opts?: SourceFingerprintOptions): SourceFingerprint[];
|
|
149
|
+
sourceIndex(opts?: SourceFingerprintOptions): SourceFingerprintIndex;
|
|
150
|
+
sourceCandidates(target: SourceFingerprint, opts: SourceFingerprintCandidateOptions): SourceFingerprint[];
|
|
151
|
+
}
|
|
152
|
+
interface CalleeFingerprintIndex {
|
|
153
|
+
corpus: readonly SymbolFingerprint[];
|
|
154
|
+
candidateIndexesByCallee: ReadonlyMap<string, readonly number[]>;
|
|
155
|
+
docFreq: ReadonlyMap<string, number>;
|
|
156
|
+
idfWeights: ReadonlyMap<string, number>;
|
|
157
|
+
weightedMagnitudes: readonly number[];
|
|
158
|
+
medianIdf: number;
|
|
159
|
+
ubiquityThreshold: number;
|
|
160
|
+
}
|
|
161
|
+
interface SourceFingerprint {
|
|
162
|
+
symbol: string;
|
|
163
|
+
file: string;
|
|
164
|
+
tokens: Set<string>;
|
|
165
|
+
}
|
|
166
|
+
interface SourceFingerprintIndex {
|
|
167
|
+
corpus: readonly SourceFingerprint[];
|
|
168
|
+
candidateByToken: ReadonlyMap<string, readonly SourceFingerprint[]>;
|
|
169
|
+
docFreq: ReadonlyMap<string, number>;
|
|
170
|
+
ubiquityThreshold: number;
|
|
171
|
+
}
|
|
172
|
+
interface RankedSimilarResult {
|
|
173
|
+
result: SimilarSymbolResult;
|
|
174
|
+
order: number;
|
|
175
|
+
}
|
|
176
|
+
declare function insertTopSimilarResult(top: RankedSimilarResult[], result: SimilarSymbolResult, limit: number, order: number): void;
|
|
177
|
+
declare function getAllCalleeFingerprints(db: ScipDatabase, opts: CalleeFingerprintCorpusOptions): SymbolFingerprint[];
|
|
178
|
+
declare function getCalleeFingerprintIndex(db: ScipDatabase, opts: CalleeFingerprintIndexOptions): CalleeFingerprintIndex;
|
|
179
|
+
declare function similarityFingerprintProduct(db: ScipDatabase): SimilarityFingerprintProduct;
|
|
180
|
+
declare function buildCalleeFingerprintIndex(corpus: readonly SymbolFingerprint[]): CalleeFingerprintIndex;
|
|
181
|
+
declare function candidateFingerprintsForTarget(target: SymbolFingerprint, index: CalleeFingerprintIndex): SymbolFingerprint[];
|
|
182
|
+
declare const SAME_FILE_SIBLING_SATURATION_THRESHOLD = 5;
|
|
183
|
+
declare function trimSameFileSiblingSaturatedCallees(fingerprints: readonly SymbolFingerprint[]): SymbolFingerprint[];
|
|
184
|
+
declare function meaningfulCallees(callees: Iterable<string>): Set<string>;
|
|
185
|
+
declare function classifySimilarityEvidence(sharedEvidence: readonly string[], basis: NonNullable<SimilarSymbolResult['similarityBasis']>): SimilarEvidenceClassification;
|
|
186
|
+
|
|
187
|
+
export { type CalleeFingerprintCorpusOptions, type CalleeFingerprintIndex, type CalleeFingerprintIndexOptions, type RankedSimilarResult, SAME_FILE_SIBLING_SATURATION_THRESHOLD, type SimilarActionTier, type SimilarConsolidationPlan, type SimilarEvidenceClass, type SimilarEvidenceClassification, type SimilarSymbolResult, type SimilarityFingerprintProduct, type SourceCandidateMode, type SourceFingerprint, type SourceFingerprintCandidateOptions, type SourceFingerprintIndex, type SourceFingerprintOptions, type SymbolFingerprint, buildCalleeFingerprintIndex, candidateFingerprintsForTarget, classifySimilarityEvidence, comparePair, getAllCalleeFingerprints, getCalleeFingerprintIndex, insertTopSimilarResult, meaningfulCallees, similar, similarAll, similarAllCount, similarConsolidationPlan, similarityFingerprintProduct, targetSpecificIdfWeights, trimSameFileSiblingSaturatedCallees };
|