Load analysis context from the analysis pipeline output directory.
Scans {baseDir}/{date}/{articleTypeSlug}/ for a manifest.json and
analysis markdown files in known subdirectories. When the directory
does not exist or contains no analysis files, returns null for graceful
degradation — strategies then behave exactly as before.
Handles suffixed directories (e.g. breaking-2, breaking-3) by
scanning for the latest match.
Resolution order for base directory:
Explicit baseDir parameter (when non-default)
EP_ANALYSIS_DIR environment variable (set by orchestration)
Default 'analysis'
Resolution order for slug:
EP_ANALYSIS_SLUG environment variable (set by orchestration)
The articleTypeSlug parameter passed by each strategy
Load analysis context from the analysis pipeline output directory.
Scans
{baseDir}/{date}/{articleTypeSlug}/for amanifest.jsonand analysis markdown files in known subdirectories. When the directory does not exist or contains no analysis files, returnsnullfor graceful degradation — strategies then behave exactly as before.Handles suffixed directories (e.g.
breaking-2,breaking-3) by scanning for the latest match.Resolution order for base directory:
baseDirparameter (when non-default)EP_ANALYSIS_DIRenvironment variable (set by orchestration)'analysis'Resolution order for slug:
EP_ANALYSIS_SLUGenvironment variable (set by orchestration)articleTypeSlugparameter passed by each strategy