@lssm-tech/module.company-metrics
CompanyOS-owned, provider-neutral metrics domain. It defines deterministic comparison windows, core templates, source and persistence ports, governed discovery, polling safety, alerts, digests, access grants, immutable publications, and Pactena's scope-bound peer contract.
AI may propose mappings and explain referenced snapshots. It never calculates values, changes approved bindings, or authorizes collection. Raw provider payloads, credentials, prompts, SQL, shell fragments, and direct personal identifiers are outside this package.
The feature is guarded by company-metrics-v1. Consumers must require fresh CompanyOS authority and one of metrics.read_live, metrics.manage, metrics.collect, metrics.publish, metrics.deliver, or metrics.audit.
Browser projection consumers can import companyMetricsMessages from the existing
/peer-client subpath (en/fr/es: title, unavailable, provisional, stale, growthNew, configure, evidence, denied). It reuses the canonical display catalogs without importing server governance or persistence. The root export remains compatible.
The /ui subpath is the reusable executive dashboard for hosts and bundles:
createCompanyMetricsBrowserClient({ basePath }) is the typed same-origin operation client (credentialed dashboard read; mutations send one idempotency key in the idempotency-key header and body plus a correlation id; 401/403 map to denied, any other failure to unavailable without inferring values), and
CompanyMetricsLiveDashboard({ client, locale }) renders the live projection, core-template enablement and governed discovery with en/fr/es copy (companyMetricsLiveMessages). Hosts keep only the route base path.