Centralize script path resolution
Objective
Create a single path-resolution module for scripts so file paths are no longer duplicated across script entrypoints.
Why this matters
Current scripts contain scattered hardcoded paths.
Centralized path helpers reduce drift and make later pipeline migration safer.
Parallelization metadata
Track
scripts
Depends on
Safe to run in parallel with
- pipeline node migration
- transcript pure-function extraction
Merge risk
Files in scope
Primary:
Avoid touching:
Required implementation
1. Add shared path helpers
Examples:
transcribeInput(cwd)
transcriptOutput(cwd)
projectFile(cwd)
artifactDir(cwd)
2. Normalize path construction
Use consistent project-root-relative resolution.
3. Keep helpers pure
No filesystem reads.
Constraints
- additive only
- no bulk script migration yet
Handoff contract
Later script migrations can depend on stable path helpers.
Acceptance criteria
Functional
Unit tests
Integration checks
Verification commands
node -e "require('./scripts/config/paths.ts')"
Expected result:
Explicitly out of scope
- migrating all scripts
- CLI parsing
Suggested branch
refactor/s4-paths
Suggested commit slug
phase-3-step-1-paths
Centralize script path resolution
Objective
Create a single path-resolution module for scripts so file paths are no longer duplicated across script entrypoints.
Why this matters
Current scripts contain scattered hardcoded paths.
Centralized path helpers reduce drift and make later pipeline migration safer.
Parallelization metadata
Track
scriptsDepends on
Safe to run in parallel with
Merge risk
Files in scope
Primary:
scripts/config/paths.tsAvoid touching:
Required implementation
1. Add shared path helpers
Examples:
transcribeInput(cwd)transcriptOutput(cwd)projectFile(cwd)artifactDir(cwd)2. Normalize path construction
Use consistent project-root-relative resolution.
3. Keep helpers pure
No filesystem reads.
Constraints
Handoff contract
Later script migrations can depend on stable path helpers.
Acceptance criteria
Functional
Unit tests
Integration checks
Verification commands
node -e "require('./scripts/config/paths.ts')"Expected result:
Explicitly out of scope
Suggested branch
refactor/s4-pathsSuggested commit slug
phase-3-step-1-paths