Strategic Improvement
Platform health scan shows 48 hardcoded values blocking true self-improvement. Build a scanner that extracts hardcoded tunables (timeouts, thresholds, limits, retry counts) from scripts, migrates them to config/policy.json with defaults, and adds runtime override support. Each value gets: config key, default, env var override, adaptive hint (which intelligence module might tune it). This is foundational for the platform to improve itself - current hardcoding prevents learning-based optimization. Targets top 20 highest-impact tunables first (identified via git blame frequency + intelligence module references).
Acceptance Criteria
- Scanner identifies hardcoded numeric thresholds, timeouts, limits in all scripts
- Generates config/policy.json with structured schema (section → key → {default, env_var, adaptive_hint, rationale})
- Refactors top 20 highest-impact scripts to read from config with fallback to env vars
- Helper function
_policy_int <section> <key> [default] added to lib/compat.sh
- Documents migration path for remaining 28 values
- All tests pass after migration (validates backward compatibility)
- Adds config validation to
shipwright doctor
Context
- Priority: P6
- Complexity: full
- Generated by: Strategic Intelligence Agent
- Strategy alignment: P6: Platform Self-Improvement (AGI-Level Readiness)
Strategic Improvement
Platform health scan shows 48 hardcoded values blocking true self-improvement. Build a scanner that extracts hardcoded tunables (timeouts, thresholds, limits, retry counts) from scripts, migrates them to config/policy.json with defaults, and adds runtime override support. Each value gets: config key, default, env var override, adaptive hint (which intelligence module might tune it). This is foundational for the platform to improve itself - current hardcoding prevents learning-based optimization. Targets top 20 highest-impact tunables first (identified via git blame frequency + intelligence module references).
Acceptance Criteria
_policy_int <section> <key> [default]added to lib/compat.shshipwright doctorContext