
Apex Tier1
- 4 installs
- 2 repo stars
- Updated March 14, 2026
- othmanadi/apex
Autonomously execute a well-defined, low-risk task from acceptance criteria to a draft PR with a self-correcting validation loop.
About
Executes a well-defined, low-risk task autonomously from acceptance criteria to a draft PR with no human intervention. A developer uses it for fire-and-forget work like adding tests, fixing lint, or writing docs.
- For clear, low-risk tasks with objective pass/fail criteria
- Implements on a branch, runs a self-correcting loop, opens a draft PR
Apex Tier1 by the numbers
- 4 all-time installs (skills.sh)
- +1 installs in the week ending Aug 4, 2026 (Skillselion tracking)
- Ranked #1,780 of 2,715 Automation & Workflows skills by installs in the Skillselion catalog
- Data as of Aug 4, 2026 (Skillselion catalog sync)
npx skills add https://github.com/othmanadi/apex --skill apex-tier1Add your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 4 |
|---|---|
| repo stars | ★ 2 |
| Last updated | March 14, 2026 |
| Repository | othmanadi/apex ↗ |
What it does
Autonomously execute a well-defined, low-risk task from acceptance criteria to a draft PR with a self-correcting validation loop.
Files
APEX Tier 1 — Fire and Forget
Execute a well-defined task from start to finish without human intervention. Open a draft PR when done.
When to Use
Use Tier 1 when ALL of these are true:
- The task has clear, unambiguous acceptance criteria
- Failure is cheap (can be reverted easily)
- No architectural decisions are required
- The scope is small (one feature, one fix, one file group)
Do NOT use Tier 1 when:
- The task requires design decisions → use
apex-tier2orapex-tier3 - The task touches critical infrastructure → use
apex-tier3 - The requirements are vague → clarify first, then decide tier
Workflow
1. Parse the task into acceptance criteria 2. Create a working branch 3. Implement the change 4. Run the self-correcting loop 5. Open a draft PR
Step 1: Parse Task into Acceptance Criteria
Convert the task description into a checklist:
Task: "Add unit tests for the UserService class"
Acceptance Criteria:
- [ ] Tests cover all public methods of UserService
- [ ] Tests cover error/edge cases documented in the class
- [ ] All tests pass
- [ ] Coverage does not decrease
- [ ] Lint passesIf you cannot create at least 2 concrete acceptance criteria, the task is too vague for Tier 1. Ask the user to clarify or escalate to Tier 2.
Step 2: Create Working Branch
git checkout -b apex/{task-slug} && git push -u origin apex/{task-slug}Step 3: Implement the Change
Write the code. Follow project conventions from AGENTS.md. Do not refactor unrelated code. Do not change formatting outside your scope.
Step 4: Self-Correcting Loop
Run validation and iterate until clean:
Linux/Mac:
bash "${CLAUDE_SKILL_DIR}/scripts/validate.sh" <target-dir>Windows:
powershell -File "${CLAUDE_SKILL_DIR}/scripts/validate.ps1" <target-dir>Maximum 5 fix cycles. If still failing after 5 attempts, commit what you have, note the failures in the PR description, and flag for human review.
Step 5: Open Draft PR
gh pr create --draft --title "apex: {task description}" --body-file /tmp/apex-pr-body.mdThe PR body must include:
- Task description
- Acceptance criteria checklist (checked/unchecked)
- Validation results (lint, types, tests, build)
- Any unresolved issues flagged with
[NEEDS REVIEW]
Output
A draft PR on a feature branch with all acceptance criteria met and validation passing.
Example PR body:
## apex: Add unit tests for UserService
### Task
Add unit tests for the UserService class
### Acceptance Criteria
- [x] Tests cover all public methods of UserService
- [x] Tests cover error/edge cases documented in the class
- [x] All tests pass
- [x] Coverage does not decrease
- [x] Lint passes
### Validation Results
| Step | Status |
|------|--------|
| Lint | ✅ PASS |
| Types | ✅ PASS |
| Tests | ✅ PASS |
| Build | ✅ PASS |
### Files Changed
- `tests/services/user-service.test.ts` (new, 147 lines)# APEX — Self-Correcting Validation Chain (Windows)
# Runs linter, type checker, tests, and build in sequence.
# Usage: powershell -File validate.ps1 <project-dir>
param(
[Parameter(Position=0)]
[string]$ProjectDir = "."
)
$ErrorActionPreference = "Continue"
Set-Location $ProjectDir
Write-Host "=== APEX Validation Chain ==="
Write-Host "Project: $ProjectDir"
Write-Host "Date: $((Get-Date).ToUniversalTime().ToString('yyyy-MM-ddTHH:mm:ssZ'))"
Write-Host ""
$Pass = 0
$Fail = 0
$Results = @()
function Run-Step {
param([string]$StepName, [string]$Command)
Write-Host "--- Step: $StepName ---"
try {
$output = Invoke-Expression $Command 2>&1
$output | ForEach-Object { Write-Host $_ }
if ($LASTEXITCODE -eq 0 -or $null -eq $LASTEXITCODE) {
Write-Host "PASS: $StepName"
$script:Pass++
$script:Results += [PSCustomObject]@{Step=$StepName; Status="PASS"; Notes="—"}
} else {
Write-Host "FAIL: $StepName"
$script:Fail++
$script:Results += [PSCustomObject]@{Step=$StepName; Status="FAIL"; Notes="See output above"}
}
} catch {
Write-Host "FAIL: $StepName — $($_.Exception.Message)"
$script:Fail++
$script:Results += [PSCustomObject]@{Step=$StepName; Status="FAIL"; Notes=$_.Exception.Message}
}
Write-Host ""
}
# Detect project type
$packageJson = Join-Path $ProjectDir "package.json"
$pyproject = Join-Path $ProjectDir "pyproject.toml"
$requirements = Join-Path $ProjectDir "requirements.txt"
$goMod = Join-Path $ProjectDir "go.mod"
$cargoToml = Join-Path $ProjectDir "Cargo.toml"
if (Test-Path $packageJson) {
# Node.js project
$pkg = Get-Content $packageJson -Raw | ConvertFrom-Json
# Lint
if ($pkg.scripts.PSObject.Properties.Name -contains "lint") {
Run-Step "Lint" "npm run lint"
} elseif (Test-Path "eslint.config.*" -ErrorAction SilentlyContinue) {
Run-Step "Lint" "npx eslint . --max-warnings 0"
} else {
Write-Host "SKIP: No linter configured"
$Results += [PSCustomObject]@{Step="Lint"; Status="SKIP"; Notes="No config found"}
}
# Type check
if (Test-Path (Join-Path $ProjectDir "tsconfig.json")) {
Run-Step "Type Check" "npx tsc --noEmit"
} else {
Write-Host "SKIP: No TypeScript config"
$Results += [PSCustomObject]@{Step="Type Check"; Status="SKIP"; Notes="No tsconfig.json"}
}
# Tests
if ($pkg.scripts.PSObject.Properties.Name -contains "test") {
Run-Step "Tests" "npm run test -- --passWithNoTests"
} else {
Write-Host "SKIP: No test script"
$Results += [PSCustomObject]@{Step="Tests"; Status="SKIP"; Notes="No test script"}
}
# Build
if ($pkg.scripts.PSObject.Properties.Name -contains "build") {
Run-Step "Build" "npm run build"
} else {
Write-Host "SKIP: No build script"
$Results += [PSCustomObject]@{Step="Build"; Status="SKIP"; Notes="No build script"}
}
} elseif ((Test-Path $pyproject) -or (Test-Path $requirements)) {
# Python project
if (Get-Command ruff -ErrorAction SilentlyContinue) {
Run-Step "Lint (ruff)" "ruff check ."
} elseif (Get-Command flake8 -ErrorAction SilentlyContinue) {
Run-Step "Lint (flake8)" "flake8 ."
} else {
Write-Host "SKIP: No Python linter found"
$Results += [PSCustomObject]@{Step="Lint"; Status="SKIP"; Notes="Install ruff or flake8"}
}
if (Get-Command mypy -ErrorAction SilentlyContinue) {
Run-Step "Type Check (mypy)" "mypy ."
}
if (Get-Command pytest -ErrorAction SilentlyContinue) {
Run-Step "Tests (pytest)" "pytest -v"
}
} elseif (Test-Path $goMod) {
Run-Step "Lint (go vet)" "go vet ./..."
Run-Step "Build" "go build ./..."
Run-Step "Tests" "go test ./..."
} elseif (Test-Path $cargoToml) {
Run-Step "Lint (clippy)" "cargo clippy -- -D warnings"
Run-Step "Build" "cargo build"
Run-Step "Tests" "cargo test"
} else {
Write-Host "WARNING: Could not detect project type."
$Fail++
$Results += [PSCustomObject]@{Step="Detection"; Status="FAIL"; Notes="Unknown project type"}
}
Write-Host ""
Write-Host "=== Validation Summary ==="
$Results | Format-Table -AutoSize
Write-Host "Passed: $Pass | Failed: $Fail"
if ($Fail -gt 0) {
Write-Host ""
Write-Host "ACTION: Fix the failures above and re-run this script."
exit 1
} else {
Write-Host ""
Write-Host "All checks passed. Ready to commit."
exit 0
}
#!/usr/bin/env bash
# APEX — Self-Correcting Validation Chain (Linux/Mac)
# Runs linter, type checker, tests, and build in sequence.
# Exits with the first failure so the agent can fix and re-run.
# Usage: bash validate.sh <project-dir>
set -euo pipefail
PROJECT_DIR="${1:-.}"
cd "$PROJECT_DIR"
echo "=== APEX Validation Chain ==="
echo "Project: $PROJECT_DIR"
echo "Date: $(date -u +"%Y-%m-%dT%H:%M:%SZ")"
echo ""
PASS=0
FAIL=0
RESULTS=""
run_step() {
local step_name="$1"
local cmd="$2"
echo "--- Step: $step_name ---"
if eval "$cmd" 2>&1; then
echo "PASS: $step_name"
PASS=$((PASS + 1))
RESULTS="$RESULTS\n| $step_name | PASS | — |"
else
echo "FAIL: $step_name"
FAIL=$((FAIL + 1))
RESULTS="$RESULTS\n| $step_name | FAIL | See output above |"
return 1
fi
echo ""
}
# Detect project type and run appropriate tools
if [ -f "package.json" ]; then
# Node.js project
PM="npx"
[ -f "pnpm-lock.yaml" ] && PM="pnpm exec"
[ -f "yarn.lock" ] && PM="yarn"
# Step 1: Lint
if grep -q '"lint"' package.json 2>/dev/null; then
run_step "Lint" "$PM run lint 2>&1" || true
elif [ -f ".eslintrc.js" ] || [ -f ".eslintrc.json" ] || [ -f "eslint.config.js" ] || [ -f "eslint.config.mjs" ]; then
run_step "Lint" "npx eslint . --max-warnings 0 2>&1" || true
else
echo "SKIP: No linter configured"
RESULTS="$RESULTS\n| Lint | SKIP | No config found |"
fi
# Step 2: Type check
if [ -f "tsconfig.json" ]; then
run_step "Type Check" "npx tsc --noEmit 2>&1" || true
else
echo "SKIP: No TypeScript config"
RESULTS="$RESULTS\n| Type Check | SKIP | No tsconfig.json |"
fi
# Step 3: Tests
if grep -q '"test"' package.json 2>/dev/null; then
run_step "Tests" "$PM run test -- --passWithNoTests 2>&1" || true
else
echo "SKIP: No test script"
RESULTS="$RESULTS\n| Tests | SKIP | No test script |"
fi
# Step 4: Build
if grep -q '"build"' package.json 2>/dev/null; then
run_step "Build" "$PM run build 2>&1" || true
else
echo "SKIP: No build script"
RESULTS="$RESULTS\n| Build | SKIP | No build script |"
fi
elif [ -f "pyproject.toml" ] || [ -f "requirements.txt" ] || [ -f "setup.py" ]; then
# Python project
# Step 1: Lint
if command -v ruff &>/dev/null; then
run_step "Lint (ruff)" "ruff check . 2>&1" || true
elif command -v flake8 &>/dev/null; then
run_step "Lint (flake8)" "flake8 . 2>&1" || true
else
echo "SKIP: No Python linter found"
RESULTS="$RESULTS\n| Lint | SKIP | Install ruff or flake8 |"
fi
# Step 2: Type check
if command -v mypy &>/dev/null; then
run_step "Type Check (mypy)" "mypy . 2>&1" || true
else
echo "SKIP: mypy not installed"
RESULTS="$RESULTS\n| Type Check | SKIP | Install mypy |"
fi
# Step 3: Tests
if command -v pytest &>/dev/null; then
run_step "Tests (pytest)" "pytest -v 2>&1" || true
else
echo "SKIP: pytest not installed"
RESULTS="$RESULTS\n| Tests | SKIP | Install pytest |"
fi
# Step 4: Build
run_step "Build (syntax check)" "python -m py_compile *.py 2>&1 || true" || true
elif [ -f "go.mod" ]; then
# Go project
run_step "Lint (go vet)" "go vet ./... 2>&1" || true
run_step "Build" "go build ./... 2>&1" || true
run_step "Tests" "go test ./... 2>&1" || true
elif [ -f "Cargo.toml" ]; then
# Rust project
run_step "Lint (clippy)" "cargo clippy -- -D warnings 2>&1" || true
run_step "Build" "cargo build 2>&1" || true
run_step "Tests" "cargo test 2>&1" || true
else
echo "WARNING: Could not detect project type. No validation run."
RESULTS="$RESULTS\n| Detection | FAIL | Unknown project type |"
FAIL=$((FAIL + 1))
fi
echo ""
echo "=== Validation Summary ==="
echo "| Step | Status | Notes |"
echo "|------|--------|-------|"
echo -e "$RESULTS"
echo ""
echo "Passed: $PASS | Failed: $FAIL"
if [ "$FAIL" -gt 0 ]; then
echo ""
echo "ACTION: Fix the failures above and re-run this script."
exit 1
else
echo ""
echo "All checks passed. Ready to commit."
exit 0
fi