delay_reason_stats
Get delay reason distribution for NYC capital projects, including counts of delayed items with and without reasons. Filter by current/lifetime scope and agency role.
Instructions
Distribution of reason-for-delay (only populated when variance>0). Defaults to current
period; pass scope='all_history' for lifetime. Carries a coverage block (delayed_total /
with_reason / without_reason — the denominator for the distribution, counting delayed rows
by bare variance_day>0). agency_role ('auto'|'sponsor'|'managing') picks owner vs builder
lens.
Interpretation rules:
[period_basis] Reporting-period basis: state the returned period for every count, total or ranking and both periods for comparisons. Period aggregates default to the latest complete snapshot, which may precede a partially published newer period. fms_location, fms_sponsor and lifetime_budget_variance are all-history dimensions without reporting_period: use them for enrichment or lifetime figures, never as a single period's inventory.
[agency_roles] Agency attribution is role-aware: an agency's projects mean its sponsor (owner) view, except DDC/DCAS/EDC default to managing (builder). State the returned agency_scope. managing_agency is the executor on schedules and the budget-holder on budgets; a budget-only holder is not a schedule executor. list_agencies exposes is_schedule_executor. For sponsor-scoped budget totals, use a semi-join to fms_sponsor; a value-bearing join can multiply lines. Co-owner totals can overlap and must not be added together.
[schedule_coverage] Schedule totals and cumulative variance use dashboard-aligned schedule_history. source_schedule_history retains native observations absent from that population; schedule_source_coverage reconciles them. State the schedule universe and cumulative basis. Parenthesized phases are no-schedule reasons. Respect excluded variance artifacts and missing/invalid-duration counts; forward duration statistics exclude reversed dates.
[signed_values] Report neutral, SIGNED changes: "moved 45 days later" or "budget decreased $2M". Do not echo loaded terms in the answer. "slippage" means positive schedule change and "overrun" means positive budget growth; neither includes the decreasing side. Preserve the returned direction and metric basis.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| scope | No | current | |
| agency | No | ||
| period | No | current | |
| agency_role | No | auto |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| reasons | Yes | ||
| coverage | Yes | ||
| provenance | Yes | ||
| interpretation_rules | Yes |