{"_id":"@aymenkits/review-core","name":"@aymenkits/review-core","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@aymenkits/review-core","version":"1.0.0","description":"Subject-generic review engine: transaction-anchored eligibility (verified reviews for free), per-subject-type policy (oncePer, edit window, reply/moderation permissions), aggregate snapshots with Bayesian small-sample smoothing, replies, reports. Seams: R","license":"MIT","main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"tsc -p tsconfig.json","typecheck":"tsc -p tsconfig.json --noEmit"},"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/aymenmokhtarikouki/review-kit.git","directory":"packages/core"},"keywords":["reviews","ratings","bayesian","moderation","marketplace","core"],"engines":{"node":">=18"},"sideEffects":false,"homepage":"https://github.com/aymenmokhtarikouki/review-kit#readme","bugs":{"url":"https://github.com/aymenmokhtarikouki/review-kit/issues"},"author":{"name":"Aymen Mokhtari"},"_id":"@aymenkits/review-core@1.0.0","gitHead":"7bec3ca2aea0218ba4e85ff23af3ffa08772bfa5","_nodeVersion":"22.14.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-DCRCmt0oXExabnVAKB13GcTzFEAH9Eo+8Z/WAksOzFvrzoMRL6rA/Yo+wL5SuwKDPebtLPR6Iw6zyeEh6LCmjA==","shasum":"4f1840e6a677577839d90fa21bd3198233c4727d","tarball":"https://registry.npmjs.org/@aymenkits/review-core/-/review-core-1.0.0.tgz","fileCount":23,"unpackedSize":51762,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQDMl5wx9GrITLLeL24nyurguhflO+2SYTTdmTAaYAUcogIhAOiUnuRkM40HpDiEZCBTn47qf43SYyazKkZuJmWPmAyB"}]},"_npmUser":{"name":"aymen-mokhtari","email":"ayman.mokhtari@proton.me"},"directories":{},"maintainers":[{"name":"aymen-mokhtari","email":"ayman.mokhtari@proton.me"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/review-core_1.0.0_1783791527726_0.12078287140459265"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-11T17:38:47.536Z","1.0.0":"2026-07-11T17:38:47.867Z","modified":"2026-07-11T17:38:48.027Z"},"maintainers":[{"name":"aymen-mokhtari","email":"ayman.mokhtari@proton.me"}],"description":"Subject-generic review engine: transaction-anchored eligibility (verified reviews for free), per-subject-type policy (oncePer, edit window, reply/moderation permissions), aggregate snapshots with Bayesian small-sample smoothing, replies, reports. Seams: R","homepage":"https://github.com/aymenmokhtarikouki/review-kit#readme","keywords":["reviews","ratings","bayesian","moderation","marketplace","core"],"repository":{"type":"git","url":"git+https://github.com/aymenmokhtarikouki/review-kit.git","directory":"packages/core"},"author":{"name":"Aymen Mokhtari"},"bugs":{"url":"https://github.com/aymenmokhtarikouki/review-kit/issues"},"license":"MIT","readme":"# @aymenkits/review-core\n\nSubject-generic, transaction-anchored reviews: per-subject-type policy (eligibility, once-per rules, edit window, reply/moderation permissions), Bayesian small-sample aggregates, owner replies, report-without-hiding moderation.\n\n## Install\n\n```bash\nnpm install @aymenkits/review-core\n```\n\nInstalls with it: nothing else — zero dependencies.\n\n## You provide\n\n- `ReviewStore` — your table(s) (an in-memory reference store is exported)\n- `policy.subjects` — YOUR eligibility answers (\"order completed, belongs to author\")\n- `AggregateSink` — where denormalized averages get written\n\nThe package never owns tables, never imports an ORM, HTTP framework, or\nprovider SDK it can take as a parameter — storage and delivery are seams your\napp implements on its own stack.\n\n## Quick example\n\n```ts\nimport { createReviewService } from '@aymenkits/review-core'\n\nconst reviews = createReviewService({ store, aggregates, notifier,\n  policy: { subjects: { cook: { eligibleWhen, oncePer: 'transaction',\n    subjectOwnerId, prior: { mean: 3.8, weight: 10 } } } } })\n```\n\n## Pairs with\n\n- `notifier` parameter is satisfied by `@aymenkits/notify-core` Notifier as-is\n- `@aymenkits/review-express` for routes\n\nKits pair **by shape, never by import** — pass the sibling kit, your own\nservice, or a stub in tests.\n\n## Docs\n\nFull contracts and integration guides live in the repo:\nhttps://github.com/aymenmokhtarikouki/review-kit (`contracts/`, `docs/`).\n\n## License\n\nMIT\n","readmeFilename":"README.md","_rev":"1-153b38c38597f468613cdbd103a58632"}