{"archetypes":{"question":"Do buildings fall into a few recurring maintenance profiles across the 8 pillars?","method":"k-means (numpy, k-means++ init, 10 restarts, seed 20260923) on the 8 pillar scores of each building's latest evaluation (0-100, unscaled; a refused area is a separate flag, a provisional choice); k from 2-6 chosen by mean silhouette on a fixed random sample of 1,500 buildings.","buildings_used":3575,"buildings_skipped_missing_a_pillar":13,"k_search":[{"k":2,"silhouette_on_1500_sample":0.3581,"inertia":2653192.9},{"k":3,"silhouette_on_1500_sample":0.3164,"inertia":2239557.7},{"k":4,"silhouette_on_1500_sample":0.1983,"inertia":2029475.8},{"k":5,"silhouette_on_1500_sample":0.1891,"inertia":1880648.7},{"k":6,"silhouette_on_1500_sample":0.1871,"inertia":1786459.8}],"k_chosen":2,"city_mean_profile":{"envelope":86.283294,"grounds":89.683591,"entry":95.172459,"systems":94.695729,"stairs":87.408845,"interiors":89.809179,"waste":93.414648,"paperwork":91.922173},"clusters":[{"cluster":1,"n_buildings":2660,"share":0.7441,"centroid":{"envelope":89.484545,"grounds":92.055961,"entry":97.147224,"systems":97.04537,"stairs":91.279536,"interiors":93.665358,"waste":95.802188,"paperwork":96.930808},"gap_vs_city_mean":{"envelope":3.20125,"grounds":2.37237,"entry":1.974765,"systems":2.349641,"stairs":3.870692,"interiors":3.856179,"waste":2.38754,"paperwork":5.008634},"weakest_pillar_vs_city":"entry","mean_city_score":93.645865,"pct_green":99.511278,"by_district_share":{"Etobicoke York":0.2199,"North York":0.2797,"Toronto and East York":0.3816,"Scarborough":0.1188}},{"cluster":0,"n_buildings":915,"share":0.2559,"centroid":{"envelope":76.976928,"grounds":82.786865,"entry":89.431611,"systems":87.86508,"stairs":76.156342,"interiors":78.598865,"waste":86.473822,"paperwork":77.361553},"gap_vs_city_mean":{"envelope":-9.306367,"grounds":-6.896726,"entry":-5.740848,"systems":-6.830649,"stairs":-11.252502,"interiors":-11.210314,"waste":-6.940826,"paperwork":-14.56062},"weakest_pillar_vs_city":"paperwork","mean_city_score":81.266667,"pct_green":33.879781,"by_district_share":{"Etobicoke York":0.2339,"North York":0.1978,"Toronto and East York":0.4164,"Scarborough":0.1519}}],"pillar_correlation":{"pillars":["envelope","grounds","entry","systems","stairs","interiors","waste","paperwork"],"matrix":[[1.0,0.375,0.242,0.268,0.272,0.347,0.242,0.157],[0.375,1.0,0.287,0.315,0.268,0.398,0.33,0.153],[0.242,0.287,1.0,0.244,0.251,0.376,0.22,0.285],[0.268,0.315,0.244,1.0,0.308,0.406,0.312,0.184],[0.272,0.268,0.251,0.308,1.0,0.443,0.303,0.217],[0.347,0.398,0.376,0.406,0.443,1.0,0.424,0.215],[0.242,0.33,0.22,0.312,0.303,0.424,1.0,0.124],[0.157,0.153,0.285,0.184,0.217,0.215,0.124,1.0]]},"shape_variant":{"method":"Same k-means and silhouette search on row-centred profiles (each pillar minus the building's own mean across the 8 pillars), so clusters follow which pillar lags, not the overall level.","k_search":[{"k":2,"silhouette_on_1500_sample":0.3667,"inertia":1823311.8},{"k":3,"silhouette_on_1500_sample":0.1791,"inertia":1604052.8},{"k":4,"silhouette_on_1500_sample":0.1611,"inertia":1439912.6},{"k":5,"silhouette_on_1500_sample":0.1571,"inertia":1355426.7},{"k":6,"silhouette_on_1500_sample":0.1538,"inertia":1290383.9}],"k_chosen":2,"clusters":[{"cluster":0,"n_buildings":3144,"share":0.8794,"deviation_from_own_mean":{"envelope":-5.467448,"grounds":-2.101059,"entry":3.757731,"systems":3.099904,"stairs":-4.002831,"interiors":-1.738667,"waste":1.675221,"paperwork":4.777148},"lagging_pillar":"envelope","mean_level":91.880545,"mean_city_score":91.256043,"pct_green":86.354962},{"cluster":1,"n_buildings":431,"share":0.1206,"deviation_from_own_mean":{"envelope":0.355429,"grounds":4.003068,"entry":6.793475,"systems":7.637796,"stairs":-0.992402,"interiors":2.401248,"waste":7.404237,"paperwork":-27.60285},"lagging_pillar":"paperwork","mean_level":84.980998,"mean_city_score":84.798144,"pct_green":56.148492}],"null_silhouette":{"raw":0.31,"shape":0.3028,"k":2,"k_raw":2,"seed":20260924,"sample":1500,"method":"Each pillar column shuffled independently across buildings (seed 20260924), then the same k-means and silhouette on the same 1,500-building sample. It shows how high a silhouette gets with no profile structure at all."},"one_line_rule":{"pillar":"paperwork","threshold":-11.5,"agreement":0.9972,"cluster_buildings":431,"rule_buildings":429,"rule":"the paperwork pillar more than 11.5 points below the building's own average across the 8 pillars","threshold_search":"best threshold on a 0.5-point grid from -40 to 0"}},"limits":["Cluster names are for the reader to assign; archetypes are descriptive, not causal.","Low silhouette values mean the clusters overlap; the score is reported so readers can judge.","Buildings missing any pillar (all items N/A or refused) are left out.","No distinct archetypes: the best split of the profiles (k = 2) has a silhouette of 0.37, against 0.30 for the same data with each pillar shuffled (no structure at all). The split is one pillar: a single rule (the paperwork pillar more than 11.5 points below the building's own average across the 8 pillars) reproduces 99.7% of it."]},"control_chart":{"question":"Did the citywide average evaluation score shift in any month beyond normal variation?","method":"Monthly mean PROACTIVE BUILDING SCORE of evaluations completed that month (post-2023). Centre = median of monthly means (months with n >= 20); limits = centre +/- 3 x MAD x 1.4826. Run rule: 8 or more months in a row (n >= 20) on the same side of the centre are flagged as a sustained shift.","centre":89.22,"lower":80.622,"upper":97.818,"points":[{"month":"2023-06","mean_score":90.182,"n":225,"flag":""},{"month":"2023-07","mean_score":88.17,"n":382,"flag":"run below centre"},{"month":"2023-08","mean_score":88.327,"n":441,"flag":"run below centre"},{"month":"2023-09","mean_score":86.772,"n":337,"flag":"run below centre"},{"month":"2023-10","mean_score":85.096,"n":345,"flag":"run below centre"},{"month":"2023-11","mean_score":86.235,"n":17,"flag":"low n"},{"month":"2023-12","mean_score":82.5,"n":2,"flag":"low n"},{"month":"2024-06","mean_score":87.394,"n":284,"flag":"run below centre"},{"month":"2024-07","mean_score":87.287,"n":568,"flag":"run below centre"},{"month":"2024-08","mean_score":87.33,"n":442,"flag":"run below centre"},{"month":"2024-09","mean_score":86.718,"n":471,"flag":"run below centre"},{"month":"2024-10","mean_score":85.871,"n":31,"flag":"run below centre"},{"month":"2024-11","mean_score":91.7,"n":10,"flag":"low n"},{"month":"2025-06","mean_score":92.343,"n":166,"flag":""},{"month":"2025-07","mean_score":91.363,"n":350,"flag":""},{"month":"2025-08","mean_score":91.915,"n":200,"flag":""},{"month":"2025-09","mean_score":90.126,"n":262,"flag":""},{"month":"2025-10","mean_score":90.398,"n":299,"flag":""},{"month":"2025-11","mean_score":90.882,"n":399,"flag":""},{"month":"2025-12","mean_score":91.271,"n":70,"flag":""},{"month":"2026-05","mean_score":57.0,"n":1,"flag":"low n"},{"month":"2026-06","mean_score":89.012,"n":81,"flag":""},{"month":"2026-07","mean_score":89.22,"n":359,"flag":""},{"month":"2026-08","mean_score":91.211,"n":573,"flag":""},{"month":"2026-09","mean_score":91.383,"n":366,"flag":""}],"run_rule":{"min_run":8,"rule":"8 or more eligible months in a row on the same side of the centre (Western Electric run rule); months with n < 20 are skipped and a month on the centre ends a run"},"runs":[{"first_month":"2023-07","last_month":"2024-10","side":"below","months":9}],"min_n":20,"eligible_months":21,"months_beyond_limits":0,"yearly_means":{"2023":87.567238,"2024":87.166113,"2025":91.054983,"2026":90.584783},"limits":["Evaluations are scheduled, not random: the mix of buildings evaluated changes by month, so a flag is a prompt to look, not evidence of a citywide change.","Months with fewer than 20 evaluations are shown but not flagged; 21 of the 25 months have at least 20.","The limits come from month-to-month swings that already include the change in which buildings are due, so they are wide (plus or minus 8.6 points) and no eligible month (20 or more evaluations) crosses them.","The run rule catches what the limits miss: 2023-07 to 2024-10 (9 months) all sit below the centre. The yearly averages moved from 87.2 in 2024 to 91.1 in 2025."]},"survival":{"status":"[unrun]","note":"Kaplan-Meier green-to-first-yellow was not run in stage 1."},"stage":"stage 2: NorthLedger-cleaned frames (engine 19ec81d19e0d), then this script's domain rules","data_as_of":"2026-09-21","built_at":"2026-09-26T12:43:42Z"}