{"_id":"@adjudicate/drift","_rev":"7-2d5bcd0532da82b0c4f8ed6a89947d0e","name":"@adjudicate/drift","dist-tags":{"latest":"0.2.6"},"versions":{"0.2.0":{"name":"@adjudicate/drift","version":"0.2.0","_id":"@adjudicate/drift@0.2.0","maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"dist":{"shasum":"f24d60d1fa9796d0a2529bb80b62c6da9cdf0d30","tarball":"https://registry.npmjs.org/@adjudicate/drift/-/drift-0.2.0.tgz","fileCount":33,"integrity":"sha512-Tnp7RzZwRdFwvYg7meNWtmxxiE0pXXNMa+A1EY6I/8Ru9F/UvpgfZNRHhndx8dz82OEn3P9E0h5vfQ31uXztKQ==","signatures":[{"sig":"MEQCIBfYXLm4GtEXSQ3XPy9QG6Iq1yqrS39ag8keh17e6aprAiBVogeedmu2xlW6O7LxW9kc0lpWUSL4mIk27OfX6gWnlQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":69060},"main":"./dist/index.js","type":"module","_from":"file:adjudicate-drift-0.2.0.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"scripts":{"lint":"tsc --noEmit","test":"vitest run","build":"tsc --outDir dist"},"_npmUser":{"name":"brunoro","email":"bnocesar@gmail.com"},"_resolved":"/private/var/folders/qy/5nvvb1h93ks26dzx6fzypss80000gn/T/3fb737e9823c22213103dece2aa8b45e/adjudicate-drift-0.2.0.tgz","_integrity":"sha512-Tnp7RzZwRdFwvYg7meNWtmxxiE0pXXNMa+A1EY6I/8Ru9F/UvpgfZNRHhndx8dz82OEn3P9E0h5vfQ31uXztKQ==","_npmVersion":"11.10.0","description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","directories":{},"_nodeVersion":"25.6.1","dependencies":{"@adjudicate/core":"1.3.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^3.2.0","fast-check":"^3.23.1","typescript":"^5.9.0","@vitest/coverage-v8":"^3.2.0"},"_npmOperationalInternal":{"tmp":"tmp/drift_0.2.0_1780863186145_0.7362956237726439","host":"s3://npm-registry-packages-npm-production"}},"0.2.1":{"name":"@adjudicate/drift","version":"0.2.1","_id":"@adjudicate/drift@0.2.1","maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"dist":{"shasum":"75b15a13e5feb2c8a4f24db49e61c11179294236","tarball":"https://registry.npmjs.org/@adjudicate/drift/-/drift-0.2.1.tgz","fileCount":33,"integrity":"sha512-KyDjGh3cKTPbGEUmK0wAIKynleIJPD1kM1FITGDcrC0krW3DFvHVZbs65ui11AEIn2d3Z0hQVm923fE9bOQvdw==","signatures":[{"sig":"MEUCIQDw4NZBsNBTqDS9f7INzEputgd88FrWyyOR8UUKEKzRugIgUrS84LTg1maVtmTnAlK8fIynYvdJsTgQS6K9V+znraI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":69150},"main":"./dist/index.js","type":"module","_from":"file:adjudicate-drift-0.2.1.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"scripts":{"lint":"tsc --noEmit","test":"vitest run","build":"tsc --outDir dist"},"_npmUser":{"name":"brunoro","email":"bnocesar@gmail.com"},"_resolved":"/private/var/folders/qy/5nvvb1h93ks26dzx6fzypss80000gn/T/9ec7795cf8cf9040ac9c10d8d9c156ae/adjudicate-drift-0.2.1.tgz","_integrity":"sha512-KyDjGh3cKTPbGEUmK0wAIKynleIJPD1kM1FITGDcrC0krW3DFvHVZbs65ui11AEIn2d3Z0hQVm923fE9bOQvdw==","_npmVersion":"11.10.0","description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","directories":{},"_nodeVersion":"25.6.1","dependencies":{"@adjudicate/core":"1.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^3.2.0","fast-check":"^3.23.1","typescript":"^5.9.0","@vitest/coverage-v8":"^3.2.0"},"_npmOperationalInternal":{"tmp":"tmp/drift_0.2.1_1781667671357_0.8124049843113685","host":"s3://npm-registry-packages-npm-production"}},"0.2.2":{"name":"@adjudicate/drift","version":"0.2.2","_id":"@adjudicate/drift@0.2.2","maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"dist":{"shasum":"8d264ad76f3f3d96242ec8e3fc703af7311ede9b","tarball":"https://registry.npmjs.org/@adjudicate/drift/-/drift-0.2.2.tgz","fileCount":39,"integrity":"sha512-QC4nprVCLFHag+czT5RL/9r9K7mQi1grsUNMNMxlUIhk9EFAKkNhZ88HcKHI6XEyEsXcX52UaGVGPwaJ7jLLmA==","signatures":[{"sig":"MEUCIQDLL0leyCKQO62+lZkvxtK15WY+e9AkJbB24hf3Tn62PQIgH6OJEeLudoCat5SiHLPmaDi4iXm7LFuT+MBtqfDGUR4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":113309},"main":"./dist/index.js","type":"module","_from":"file:adjudicate-drift-0.2.2.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"scripts":{"lint":"tsc --noEmit","test":"vitest run","build":"tsc --outDir dist"},"_npmUser":{"name":"brunoro","email":"bnocesar@gmail.com"},"_resolved":"/private/var/folders/qy/5nvvb1h93ks26dzx6fzypss80000gn/T/1428bad0f97c497122038106b37a4b0b/adjudicate-drift-0.2.2.tgz","_integrity":"sha512-QC4nprVCLFHag+czT5RL/9r9K7mQi1grsUNMNMxlUIhk9EFAKkNhZ88HcKHI6XEyEsXcX52UaGVGPwaJ7jLLmA==","_npmVersion":"11.10.0","description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","directories":{},"_nodeVersion":"25.6.1","dependencies":{"@adjudicate/core":"1.5.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^3.2.0","fast-check":"^3.23.1","typescript":"^5.9.0","@vitest/coverage-v8":"^3.2.0"},"_npmOperationalInternal":{"tmp":"tmp/drift_0.2.2_1782275513779_0.9574601152479367","host":"s3://npm-registry-packages-npm-production"}},"0.2.3":{"name":"@adjudicate/drift","version":"0.2.3","_id":"@adjudicate/drift@0.2.3","maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"dist":{"shasum":"cd8bf509f780be4ba99789f6288e8690b2d13514","tarball":"https://registry.npmjs.org/@adjudicate/drift/-/drift-0.2.3.tgz","fileCount":39,"integrity":"sha512-4cDz3S5wuuxc2qY3tvYMgRmSbs2qqOAgOAG8JL7uRbbBrxwlrPzOYAJmjc+KTccH++lppwGCgFvRZagt6xdI9Q==","signatures":[{"sig":"MEUCIQC6jro7PH+as5qd0GSzlr1Eua1TjVjqJb1kHFkxYJKKDAIgf0ZnB23q1DU4UxQE4ntw2TQq7fKoMpPyK5ZwNFEQtCU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":113399},"main":"./dist/index.js","type":"module","_from":"file:adjudicate-drift-0.2.3.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"scripts":{"lint":"tsc --noEmit","test":"vitest run","build":"tsc --outDir dist"},"_npmUser":{"name":"brunoro","email":"bnocesar@gmail.com"},"_resolved":"/private/var/folders/qy/5nvvb1h93ks26dzx6fzypss80000gn/T/3ec5ac8dedb688e96255c53547ff54a8/adjudicate-drift-0.2.3.tgz","_integrity":"sha512-4cDz3S5wuuxc2qY3tvYMgRmSbs2qqOAgOAG8JL7uRbbBrxwlrPzOYAJmjc+KTccH++lppwGCgFvRZagt6xdI9Q==","_npmVersion":"11.10.0","description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","directories":{},"_nodeVersion":"25.6.1","dependencies":{"@adjudicate/core":"1.6.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^3.2.0","fast-check":"^3.23.1","typescript":"^5.9.0","@vitest/coverage-v8":"^3.2.0"},"_npmOperationalInternal":{"tmp":"tmp/drift_0.2.3_1782443650843_0.305450436805329","host":"s3://npm-registry-packages-npm-production"}},"0.2.4":{"name":"@adjudicate/drift","version":"0.2.4","_id":"@adjudicate/drift@0.2.4","maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"dist":{"shasum":"29e2cb95ce412f1131854929b6c71491089cd4be","tarball":"https://registry.npmjs.org/@adjudicate/drift/-/drift-0.2.4.tgz","fileCount":39,"integrity":"sha512-1awkpsBf8941ZIgnHvDnU5BzAq2PaZEptVYj09i8poZ396Tp776t/s2rHIEi/Hujzb92ozjixhjnaaodoANSfw==","signatures":[{"sig":"MEQCIFsP9Q330tg4qsUsnP6rij1bH9tDc7xj/vYpaSrJxfOhAiBKiavtIxVVPfeLe4bopBMXcgtlV/TY6Tavgt/1hph3gQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":113489},"main":"./dist/index.js","type":"module","_from":"file:adjudicate-drift-0.2.4.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"scripts":{"lint":"tsc --noEmit","test":"vitest run","build":"tsc --outDir dist"},"_npmUser":{"name":"brunoro","email":"bnocesar@gmail.com"},"_resolved":"/tmp/5b682acd3d071be251534a606f159155/adjudicate-drift-0.2.4.tgz","_integrity":"sha512-1awkpsBf8941ZIgnHvDnU5BzAq2PaZEptVYj09i8poZ396Tp776t/s2rHIEi/Hujzb92ozjixhjnaaodoANSfw==","_npmVersion":"10.9.8","description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","directories":{},"_nodeVersion":"22.23.0","dependencies":{"@adjudicate/core":"1.7.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^3.2.0","fast-check":"^3.23.1","typescript":"^5.9.0","@vitest/coverage-v8":"^3.2.0"},"_npmOperationalInternal":{"tmp":"tmp/drift_0.2.4_1782665449823_0.12033309381956858","host":"s3://npm-registry-packages-npm-production"}},"0.2.5":{"name":"@adjudicate/drift","version":"0.2.5","_id":"@adjudicate/drift@0.2.5","maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"dist":{"shasum":"8e5cbce06b05cf3dfa1206cef677e496f9c2bd8a","tarball":"https://registry.npmjs.org/@adjudicate/drift/-/drift-0.2.5.tgz","fileCount":39,"integrity":"sha512-X465zRBK2UZDYdarDLtN3LI33RKmJkNExF0VTuXFSfDP9AwrA3gmdwLtzqx05h4tIVsKgFF2NTFgM1IcBrTYww==","signatures":[{"sig":"MEQCIBPjpsN2Pz5mtQjHpAEVqE+ocn7gCUuuwET8znP4Xq+5AiBYhhhBZl2nEdUOQVM7BNAo9xS4z5HmBNJZayiP11tPNw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":113579},"main":"./dist/index.js","type":"module","_from":"file:adjudicate-drift-0.2.5.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"scripts":{"lint":"tsc --noEmit","test":"vitest run","build":"tsc --outDir dist"},"_npmUser":{"name":"brunoro","email":"bnocesar@gmail.com"},"_resolved":"/tmp/336edc139a09e293b7b7d1fc7d41bb6b/adjudicate-drift-0.2.5.tgz","_integrity":"sha512-X465zRBK2UZDYdarDLtN3LI33RKmJkNExF0VTuXFSfDP9AwrA3gmdwLtzqx05h4tIVsKgFF2NTFgM1IcBrTYww==","_npmVersion":"10.9.8","description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","directories":{},"_nodeVersion":"22.23.0","dependencies":{"@adjudicate/core":"1.8.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^3.2.0","fast-check":"^3.23.1","typescript":"^5.9.0","@vitest/coverage-v8":"^3.2.0"},"_npmOperationalInternal":{"tmp":"tmp/drift_0.2.5_1782870190492_0.617933946949631","host":"s3://npm-registry-packages-npm-production"}},"0.2.6":{"name":"@adjudicate/drift","version":"0.2.6","description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","publishConfig":{"access":"public"},"type":"module","main":"./dist/index.js","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"dependencies":{"@adjudicate/core":"1.9.0"},"devDependencies":{"@vitest/coverage-v8":"^3.2.0","fast-check":"^3.23.1","typescript":"^5.9.0","vitest":"^3.2.0"},"scripts":{"build":"tsc --outDir dist","lint":"tsc --noEmit","test":"vitest run"},"_id":"@adjudicate/drift@0.2.6","_integrity":"sha512-kik5nLZt1Z/6QGmfEuLUYRUCZUIOixlQToFjqlzWc4sPuA415pnrZdhVEYMLiUF8fKXQtJ+FR5Vy75a+GoUoWw==","_resolved":"/tmp/4d8420d866bf17557ef8f81a3c22a852/adjudicate-drift-0.2.6.tgz","_from":"file:adjudicate-drift-0.2.6.tgz","_nodeVersion":"22.23.1","_npmVersion":"10.9.8","dist":{"integrity":"sha512-kik5nLZt1Z/6QGmfEuLUYRUCZUIOixlQToFjqlzWc4sPuA415pnrZdhVEYMLiUF8fKXQtJ+FR5Vy75a+GoUoWw==","shasum":"0ab0afb1fc05be04336730c34a4e4de172e821d7","tarball":"https://registry.npmjs.org/@adjudicate/drift/-/drift-0.2.6.tgz","fileCount":39,"unpackedSize":113669,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCeF8b6MOJ9SuSIpM2tnqg9wMTAwuonmGoc/4M+SIMQaAIhAKMsHuVyVi8F0ex9k3DCsiu5J8rR1RhxzMEC/luie4/N"}]},"_npmUser":{"name":"brunoro","email":"bnocesar@gmail.com"},"directories":{},"maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/drift_0.2.6_1783002064652_0.5410573625718855"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-07T20:13:06.044Z","modified":"2026-07-02T14:21:04.985Z","0.2.0":"2026-06-07T20:13:06.276Z","0.2.1":"2026-06-17T03:41:11.484Z","0.2.2":"2026-06-24T04:31:53.906Z","0.2.3":"2026-06-26T03:14:10.987Z","0.2.4":"2026-06-28T16:50:49.986Z","0.2.5":"2026-07-01T01:43:10.657Z","0.2.6":"2026-07-02T14:21:04.827Z"},"description":"Opt-in behavioral/statistical drift detection over the AuditEventBus — running decision-distribution comparison with bounded cardinality. Never touches the decision path.","maintainers":[{"name":"brunoro","email":"bnocesar@gmail.com"}],"readme":"# @adjudicate/drift\n\nOpt-in behavioral / statistical drift detection over the `AuditEventBus`. A pure\nobserver that compares a frozen **baseline** decision distribution against a\ntrailing **recent** window and raises alerts when the distribution shifts.\n\n```ts\nimport { createDriftDetector } from \"@adjudicate/drift\";\n\nconst detector = createDriftDetector({\n  baselineWindow: 500,\n  recentWindow: 100,\n  alertThreshold: 0.25,\n  dimensions: [\"decision.kind\", \"intent.kind\", \"basis\"],\n  onDrift: (alert) => console.warn(\"drift\", alert),\n});\n\nconst unsubscribe = detector.attach(auditEventBus); // observe() per record\n// ...later, on a schedule the adopter owns:\ndetector.evaluate();          // recompute + fire onDrift\nconst snap = detector.snapshot(); // distributions + TVD + alerts (drives the console)\n```\n\n## Signals\n\n- `distribution_shift` — total-variation distance ≥ `alertThreshold`.\n- `new_category` — a recent key never seen in the baseline (e.g. a new intent kind).\n- `proportion_spike` — a single category's recent share exceeds its baseline share by `alertThreshold` (e.g. a REFUSE spike).\n\n## Guarantees\n\n- **Pure observer.** `observe(record)` is synchronous, total, no-throw, no-I/O —\n  safe as a bus handler. `evaluate()` is the only method that fires `onDrift`.\n- **Deterministic.** Count-based windows (no wall-clock), no RNG. Same record\n  sequence → byte-identical `snapshot()`. The kernel never imports this package;\n  nothing reaches `intentHash` or the decision path.\n- **Bounded cardinality.** `maxCategoriesPerDimension` (default 64); over-cap keys\n  fall into an `__overflow__` bucket.\n- **Not** the operational `DriftPanel` (integrity codes) — this is statistical\n  decision-distribution drift.\n","readmeFilename":"README.md"}