Function: recomputeAllFacilityScores()
recomputeAllFacilityScores(
svc,companyId,updatedBy):Promise<RecomputeSummary>
Defined in: src/server/services/facility-score.ts:150
Batch-score every facility, CALIBRATE tier cutoffs from the resulting distribution, persist them, and write back each facility's (score, tier) — skipping rows whose values are unchanged. Runs on the ingest cron so scores reflect new signals and the cohort stays correctly tiered.
Parameters
svc
SupabaseClient
companyId
string
updatedBy
string | null
Returns
Promise<RecomputeSummary>