Purpose
Analyze and optimize continuous integration and deployment pipelines (GitHub Actions, GitLab CI, CircleCI) to dramatically cut build minutes, reduce compute costs, eliminate redundant jobs, and speed up developer feedback loops.
When to Use
- CI pipelines take >15 minutes, slowing down pull request velocity.
- GitHub Actions monthly billing bills are spiking.
- Investigating non-deterministic flaky steps or cache-miss penalties.
What to Analyze
- Dependency & Build Caching: Caching
node_modules,~/.cargo,~/.m2, Go build cache, Docker build layers (Buildx / GitHub Actions Cache backend). - Job Parallelization & Matrix Builds: Running lint, typecheck, unit tests, and E2E suites concurrently instead of sequentially.
- Change Path Filtering: Using
paths/paths-ignoreto skip backend builds when only frontend or docs change. - Test Sharding: Splitting heavy test suites across multiple parallel runner nodes.
- Fail-Fast Configuration: Immediately canceling sister jobs as soon as one test fails (
fail-fast: true).
Output Format
- Pipeline Bottleneck Diagnosis: Timeline waterfall analysis of current pipeline.
- Optimized Workflow YAML: Production-ready GitHub Actions / GitLab CI configuration.
- Expected Duration & Cost Savings: Projected time reduction (e.g. 18m $ ightarrow$ 3m30s).
Avoid
- Running expensive E2E suites on every trivial Markdown typo commit.
- Rebuilding identical Docker images without layer caching across CI runs.


