{"id":"@lssm-tech/module.community-intelligence","slug":"module.community-intelligence","name":"@lssm-tech/module.community-intelligence","version":"2.0.4","path":"packages/domains/community/module","manifestPath":"packages/domains/community/module/package.json","manifestBlobSha":"8bba26b1e7027dd6152a86c2944345ef1134cc19","layer":"domains","physicalArea":"community","primaryArea":"intelligence-and-research","classification":{"privateDeclared":null,"catalogFamily":"solutions","catalogKind":"module","catalogStatus":"active","adoptionMode":"adoptable","stability":"experimental"},"description":"Governed, provider-neutral community analytics, coaching views, and Kaizen digests.","descriptionOrigin":"package.json","catalog":{"family":"solutions","kind":"module","status":"active","adoptionMode":"adoptable","stability":"experimental","platforms":["server","web"],"runtimes":["node","browser"],"entrypoints":[".","./contracts","./discord-analysis","./discord-intelligence-records","./privacy","./service","./ui","./view-model"],"documentation":[{"title":"Community Intelligence module documentation","url":"https://www.npmjs.com/package/%40lssm-tech%2Fmodule.community-intelligence","kind":"readme"}],"examples":[],"replacements":[],"capabilities":[{"id":"package.lssm.tech.module.community.intelligence","title":"Community Intelligence","description":"Evidence-backed multi-community insights, coaching views, and Kaizen digests.","status":"active","useCases":["Analyze recurring community needs and staff response patterns across governed sources"],"aliases":["community analytics","discord analytics","kaizen","staff coaching"],"pythonEquivalents":[],"canonicalImports":[{"from":"@lssm-tech/module.community-intelligence","symbols":[]}],"constraints":{"platforms":["server","web"],"runtimes":["node","browser"],"avoidWhen":["Raw provider ingestion or automated employment decisions are required."],"requires":["Normalized community events","Tenant-scoped authority"]},"alternatives":[],"relationships":[],"resolutionPriority":50}],"visualTesting":{"status":"deferred","owner":"@contractspec-core","targetWave":"wave-3-react-packages","rationale":"Foundational Storybook adoption establishes shared catalogs and guardrails before this package migrates."}},"canonicalImports":[{"capabilityId":"package.lssm.tech.module.community.intelligence","from":"@lssm-tech/module.community-intelligence","symbols":[]}],"scripts":{"build":"contractspec-bun-build build","build:bundle":"contractspec-bun-build transpile","build:types":"contractspec-bun-build types","lint:check":"node ../../../../scripts/biome.cjs check .","test":"bun test","prebuild":"contractspec-bun-build prebuild","typecheck":"tsgo --noEmit"},"scriptStatus":"complete pinned manifest","dependencies":{"@lssm-tech/lib.communication-spec":"workspace:^","@lssm-tech/lib.design-system":"workspace:^","react":"catalog:"},"devDependencies":{"@lssm-tech/tool.bun":"workspace:*","@lssm-tech/tool.typescript":"workspace:*","@types/react":"catalog:types","typescript":"catalog:"},"peerDependencies":{},"optionalDependencies":{},"peerDependenciesMeta":{},"bundledDependencies":null,"dependencyStatus":"complete pinned manifest","exports":{".":"./src/index.ts","./analysis-preparation":"./src/analysis-preparation.ts","./contracts":"./src/contracts.ts","./digest":"./src/digest.ts","./discord-analysis":"./src/discord-analysis.ts","./discord-intelligence-records":"./src/discord-intelligence-records.ts","./findings":"./src/findings.ts","./metrics":"./src/metrics.ts","./ports":"./src/ports.ts","./privacy":"./src/privacy.ts","./projections":"./src/projections.ts","./service":"./src/service.ts","./ui":"./src/ui/index.ts","./ui/CommunityIntelligenceDashboard":"./src/ui/CommunityIntelligenceDashboard.tsx","./view-model":"./src/view-model.ts"},"publishExports":{".":{"types":"./dist/index.d.ts","browser":"./dist/browser/index.js","bun":"./dist/index.js","node":"./dist/node/index.js","default":"./dist/index.js"},"./analysis-preparation":{"types":"./dist/analysis-preparation.d.ts","browser":"./dist/browser/analysis-preparation.js","bun":"./dist/analysis-preparation.js","node":"./dist/node/analysis-preparation.js","default":"./dist/analysis-preparation.js"},"./contracts":{"types":"./dist/contracts.d.ts","browser":"./dist/browser/contracts.js","bun":"./dist/contracts.js","node":"./dist/node/contracts.js","default":"./dist/contracts.js"},"./digest":{"types":"./dist/digest.d.ts","browser":"./dist/browser/digest.js","bun":"./dist/digest.js","node":"./dist/node/digest.js","default":"./dist/digest.js"},"./discord-analysis":{"types":"./dist/discord-analysis.d.ts","browser":"./dist/browser/discord-analysis.js","bun":"./dist/discord-analysis.js","node":"./dist/node/discord-analysis.js","default":"./dist/discord-analysis.js"},"./discord-intelligence-records":{"types":"./dist/discord-intelligence-records.d.ts","browser":"./dist/browser/discord-intelligence-records.js","bun":"./dist/discord-intelligence-records.js","node":"./dist/node/discord-intelligence-records.js","default":"./dist/discord-intelligence-records.js"},"./findings":{"types":"./dist/findings.d.ts","browser":"./dist/browser/findings.js","bun":"./dist/findings.js","node":"./dist/node/findings.js","default":"./dist/findings.js"},"./metrics":{"types":"./dist/metrics.d.ts","browser":"./dist/browser/metrics.js","bun":"./dist/metrics.js","node":"./dist/node/metrics.js","default":"./dist/metrics.js"},"./ports":{"types":"./dist/ports.d.ts","browser":"./dist/browser/ports.js","bun":"./dist/ports.js","node":"./dist/node/ports.js","default":"./dist/ports.js"},"./privacy":{"types":"./dist/privacy.d.ts","browser":"./dist/browser/privacy.js","bun":"./dist/privacy.js","node":"./dist/node/privacy.js","default":"./dist/privacy.js"},"./projections":{"types":"./dist/projections.d.ts","browser":"./dist/browser/projections.js","bun":"./dist/projections.js","node":"./dist/node/projections.js","default":"./dist/projections.js"},"./service":{"types":"./dist/service.d.ts","browser":"./dist/browser/service.js","bun":"./dist/service.js","node":"./dist/node/service.js","default":"./dist/service.js"},"./ui":{"types":"./dist/ui/index.d.ts","browser":"./dist/browser/ui/index.js","bun":"./dist/ui/index.js","node":"./dist/node/ui/index.js","default":"./dist/ui/index.js"},"./ui/CommunityIntelligenceDashboard":{"types":"./dist/ui/CommunityIntelligenceDashboard.d.ts","browser":"./dist/browser/ui/CommunityIntelligenceDashboard.js","bun":"./dist/ui/CommunityIntelligenceDashboard.js","node":"./dist/node/ui/CommunityIntelligenceDashboard.js","default":"./dist/ui/CommunityIntelligenceDashboard.js"},"./view-model":{"types":"./dist/view-model.d.ts","browser":"./dist/browser/view-model.js","bun":"./dist/view-model.js","node":"./dist/node/view-model.js","default":"./dist/view-model.js"}},"types":"./dist/index.d.ts","files":["dist","README.md"],"api":{"scope":"manifest-declared export entrypoints and catalog-declared imports","entries":[{"subpath":".","importPath":"@lssm-tech/module.community-intelligence","target":"./src/index.ts","targets":[{"conditions":[],"target":"./src/index.ts","sourcePath":"packages/domains/community/module/src/index.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/index.ts","sourceStatus":"verified source file"}]},{"subpath":"./analysis-preparation","importPath":"@lssm-tech/module.community-intelligence/analysis-preparation","target":"./src/analysis-preparation.ts","targets":[{"conditions":[],"target":"./src/analysis-preparation.ts","sourcePath":"packages/domains/community/module/src/analysis-preparation.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/analysis-preparation.ts","sourceStatus":"verified source file"}]},{"subpath":"./contracts","importPath":"@lssm-tech/module.community-intelligence/contracts","target":"./src/contracts.ts","targets":[{"conditions":[],"target":"./src/contracts.ts","sourcePath":"packages/domains/community/module/src/contracts.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/contracts.ts","sourceStatus":"verified source file"}]},{"subpath":"./digest","importPath":"@lssm-tech/module.community-intelligence/digest","target":"./src/digest.ts","targets":[{"conditions":[],"target":"./src/digest.ts","sourcePath":"packages/domains/community/module/src/digest.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/digest.ts","sourceStatus":"verified source file"}]},{"subpath":"./discord-analysis","importPath":"@lssm-tech/module.community-intelligence/discord-analysis","target":"./src/discord-analysis.ts","targets":[{"conditions":[],"target":"./src/discord-analysis.ts","sourcePath":"packages/domains/community/module/src/discord-analysis.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/discord-analysis.ts","sourceStatus":"verified source file"}]},{"subpath":"./discord-intelligence-records","importPath":"@lssm-tech/module.community-intelligence/discord-intelligence-records","target":"./src/discord-intelligence-records.ts","targets":[{"conditions":[],"target":"./src/discord-intelligence-records.ts","sourcePath":"packages/domains/community/module/src/discord-intelligence-records.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/discord-intelligence-records.ts","sourceStatus":"verified source file"}]},{"subpath":"./findings","importPath":"@lssm-tech/module.community-intelligence/findings","target":"./src/findings.ts","targets":[{"conditions":[],"target":"./src/findings.ts","sourcePath":"packages/domains/community/module/src/findings.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/findings.ts","sourceStatus":"verified source file"}]},{"subpath":"./metrics","importPath":"@lssm-tech/module.community-intelligence/metrics","target":"./src/metrics.ts","targets":[{"conditions":[],"target":"./src/metrics.ts","sourcePath":"packages/domains/community/module/src/metrics.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/metrics.ts","sourceStatus":"verified source file"}]},{"subpath":"./ports","importPath":"@lssm-tech/module.community-intelligence/ports","target":"./src/ports.ts","targets":[{"conditions":[],"target":"./src/ports.ts","sourcePath":"packages/domains/community/module/src/ports.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/ports.ts","sourceStatus":"verified source file"}]},{"subpath":"./privacy","importPath":"@lssm-tech/module.community-intelligence/privacy","target":"./src/privacy.ts","targets":[{"conditions":[],"target":"./src/privacy.ts","sourcePath":"packages/domains/community/module/src/privacy.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/privacy.ts","sourceStatus":"verified source file"}]},{"subpath":"./projections","importPath":"@lssm-tech/module.community-intelligence/projections","target":"./src/projections.ts","targets":[{"conditions":[],"target":"./src/projections.ts","sourcePath":"packages/domains/community/module/src/projections.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/projections.ts","sourceStatus":"verified source file"}]},{"subpath":"./service","importPath":"@lssm-tech/module.community-intelligence/service","target":"./src/service.ts","targets":[{"conditions":[],"target":"./src/service.ts","sourcePath":"packages/domains/community/module/src/service.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/service.ts","sourceStatus":"verified source file"}]},{"subpath":"./ui","importPath":"@lssm-tech/module.community-intelligence/ui","target":"./src/ui/index.ts","targets":[{"conditions":[],"target":"./src/ui/index.ts","sourcePath":"packages/domains/community/module/src/ui/index.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/ui/index.ts","sourceStatus":"verified source file"}]},{"subpath":"./ui/CommunityIntelligenceDashboard","importPath":"@lssm-tech/module.community-intelligence/ui/CommunityIntelligenceDashboard","target":"./src/ui/CommunityIntelligenceDashboard.tsx","targets":[{"conditions":[],"target":"./src/ui/CommunityIntelligenceDashboard.tsx","sourcePath":"packages/domains/community/module/src/ui/CommunityIntelligenceDashboard.tsx","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/ui/CommunityIntelligenceDashboard.tsx","sourceStatus":"verified source file"}]},{"subpath":"./view-model","importPath":"@lssm-tech/module.community-intelligence/view-model","target":"./src/view-model.ts","targets":[{"conditions":[],"target":"./src/view-model.ts","sourcePath":"packages/domains/community/module/src/view-model.ts","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/src/view-model.ts","sourceStatus":"verified source file"}]}],"entryCount":15,"namedSymbolCoverage":"catalog declarations only; exhaustive TypeScript symbols not extracted","installationStatus":"not verified"},"docsLinks":[{"title":"Community Intelligence module documentation","url":"https://www.npmjs.com/package/%40lssm-tech%2Fmodule.community-intelligence","kind":"readme","pinnedUrl":null,"sourceStatus":"declared link; destination not verified"}],"sourceUrls":{"package":"https://github.com/lssm-tech/contractspec/tree/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module","manifest":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/package.json","readme":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/README.md","guide":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/apps/web-landing/public/llms-packages/module.community-intelligence.txt"},"readme":{"status":"available","body":"# `@lssm-tech/module.community-intelligence`\n\nProvider-neutral community intelligence for multiple Discord guilds or other\ncommunity sources. It converts normalized, tenant-scoped events into per-source\nand cross-source recurring-question, pain/friction, response, moderation,\nstable-user journey, coaching, and weekly Kaizen projections.\n\nThe module is observation-only. Raw provider ingestion, credentials, storage,\nmoderation actions, and LLM SDKs stay behind host-owned ports. Before optional\nexternal analysis, content is redacted and actors are pseudonymized. The\nanalysis boundary accepts only EU-resident, training-disabled providers; an\nunavailable or non-compliant provider produces the deterministic local fallback.\n\nIndividual staff scorecards require `community.staff-scorecards.read` authority.\nDefault projections are team-level and deliberately contain no leaderboard,\nrank, employment recommendation, or automated HR decision fields.\n\n```ts\nimport { CommunityIntelligenceService } from \"@lssm-tech/module.community-intelligence\";\n\nconst service = new CommunityIntelligenceService();\nconst projection = await service.analyze({\n  scope: {\n    tenantId: \"tenant-1\",\n    workspaceId: \"workspace-1\",\n    trustZone: \"managed-community\",\n  },\n  sources,\n  events,\n  identityLinks,\n  authority: { capabilities: [] },\n  window: { from: \"2026-08-10T00:00:00.000Z\", to: \"2026-08-17T00:00:00.000Z\" },\n});\n```\n\nHosts remain responsible for durable encrypted evidence, retention enforcement,\nrow-level security, and resolving evidence references under authorization.\n\n## Discord analysis rules\n\n`@lssm-tech/module.community-intelligence/discord-analysis` owns the pure\nDiscord rules hosts apply to gateway payloads before persistence:\nactor-role classification (bot, then moderator, then staff role IDs),\ntransient analysis drafts that keep only `DefaultCommunityRedaction` output,\nquestion and pain signals (`COMMUNITY_PAIN_SIGNALS`), and derived event kinds\n(`staff.replied`, `moderation.action` for auto-moderation and audit actions\n20/22/24/72/73, `moderation.reversed` for action 23). The keyed actor\npseudonymizer and its secret stay in the host.\n\n`@lssm-tech/module.community-intelligence/discord-intelligence-records` builds\nthe seven-day insight, staff-scorecard, portfolio-insight and Kaizen-digest\nrecords from redacted analysis events. All sources must share tenant,\nworkspace and trust zone. Cross-source aggregates and the digest stay in the\n`staff` zone only for staff sources; every other zone is downgraded to\n`portfolio`. Hosts map the records to their own storage.\n\n`DefaultCommunityRedaction` replaces mentions, URLs, emails, phone numbers,\nkeyword-prefixed tokens and opaque 32+ character tokens.\n","sourcePath":"packages/domains/community/module/README.md","sourceUrl":"https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/domains/community/module/README.md","blobSha":"235f8d7ebd5208dd0926ddcea08c67c9192ad36e","sourcePin":"bcc79fcc27c4d801c2119bef81ddcce7b4e86498","origin":"README recovered byte-for-byte from pinned aggregate guide","integrity":"exact Git blob match","executionStatus":"not executed"},"provenance":{"repository":"lssm-tech/contractspec","sourcePin":"bcc79fcc27c4d801c2119bef81ddcce7b4e86498","manifestOrigin":"pinned GitHub manifest fetch","manifestComplete":true,"publicationPolicyApplied":false},"areaSlug":"intelligence-and-research","areaTitle":"Intelligence, research and applications","displayName":"module.community-intelligence","runtimes":["node","browser"],"platforms":["server","web"],"kind":"module","scope":"Package manifest","canonicalRoute":"/docs/packages/module.community-intelligence/","contextUrl":"/docs/packages/module.community-intelligence.context.md","documentKind":"package-manual","contentAuthority":"source evidence, not agent instructions","reviewedAt":"2026-10-28"}