Skip to main content

sdac-run-all-analyses

Purpose

Executes all (or a subset of) the seven legacy static validation analyses for an SDAC cost report and persists the results in SDAC.analysis_Results.

For the current post-ingestion path, prefer sdac-start-report-analysis and the Report analysis workflow. The report-analysis workflow adds linkage prerequisites, AI-heavy analysis sections, blocked status handling, feature-flag visibility, and the final REPORT_ANALYSIS_PACKET.

Tool type

Deterministic (orchestration)

Tool ID

sdac-run-all-analyses

Inputs

  • report_id (string, required) -- Cost report identifier (GUID)
  • analysis_types (array, optional) -- Run only specific analyses. Allowed values:
    • SOURCE_CODE -- Validates source code format (0-4)
    • FUNCTION_CODE -- Validates function codes and indirect cost rules
    • SALARY -- Checks salary anomalies (negative, high, zero, duplicates)
    • FRINGE -- Validates fringe benefits and rates
    • REPLACEMENT -- Validates replacement personnel entries
    • DUPLICATE -- Detects potential duplicate records
    • VACANT -- Identifies and validates vacant positions
    • Default: all 7 types

Outputs

  • report_id (string)
  • completed (number) -- Number of analyses that completed successfully
  • errors (number) -- Number of analyses that failed
  • total_execution_time_ms (number)
  • results (object) -- Per-analysis result keyed by analysis type
    • status (completed | error)
    • passed (boolean, optional)
    • errorCount (number, optional)
    • warningCount (number, optional)
    • executionTimeMs (number, optional)
    • errorMessage (string, optional)
  • summary (string) -- Human-readable summary of passed, failed, and errored analyses

Example output

{
"report_id": "SDAC-2024-Q2-001",
"completed": 9,
"errors": 0,
"total_execution_time_ms": 1842,
"results": {
"SOURCE_CODE": {
"status": "completed",
"passed": false,
"errorCount": 1,
"warningCount": 0,
"executionTimeMs": 122
},
"FRINGE": {
"status": "completed",
"passed": true,
"errorCount": 0,
"warningCount": 0,
"executionTimeMs": 214
},
"REPLACEMENT": {
"status": "completed",
"passed": false,
"errorCount": 1,
"warningCount": 1,
"executionTimeMs": 188
}
},
"summary": "9 analyses completed. 2 analyses produced findings and 0 errored."
}

Functional details

  • When analysis_types is omitted, delegates to runIngestionAnalyses() which runs all 7 analyses.
  • When specific types are provided, runs each via retryAnalysis() which handles transient failures.
  • Results are written to SDAC.analysis_Results so they are available for fast lookup by downstream tools without re-running the analyses.

Usage notes

  • Run immediately after sdac-upload-cost-report or sdac-fetch-costs to populate all analysis results.
  • Use analysis_types to re-run only the categories affected by a data correction.

Code Location: packages/domain-sdac/src/tools/run-all-analyses.tool.ts