@vamsiivarmaa/proofloop 0.0.0-stage → 1.0.0-rc.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +15 -0
- package/.claude-plugin/plugin.json +10 -0
- package/CHANGELOG.md +66 -0
- package/LICENSE +202 -0
- package/README.md +116 -2
- package/SECURITY.md +5 -0
- package/agents/architect.md +8 -0
- package/agents/browser-evaluator.md +8 -0
- package/agents/code-reviewer.md +8 -0
- package/agents/evidence-evaluator.md +8 -0
- package/agents/implementer.md +8 -0
- package/agents/product-discovery.md +8 -0
- package/agents/researcher.md +8 -0
- package/agents/security-reviewer.md +8 -0
- package/agents/test-designer.md +8 -0
- package/bin/proofloop +10 -0
- package/dist/cli.js +34520 -0
- package/docs/assets/hero.gif +0 -0
- package/examples/protocols/fastapi-feature.yaml +28 -0
- package/examples/protocols/generic-change.yaml +23 -0
- package/examples/protocols/nextjs-feature.yaml +29 -0
- package/examples/protocols/node-service-bugfix.yaml +24 -0
- package/hooks/hooks.json +37 -0
- package/package.json +70 -4
- package/protocols/bug.yaml +31 -0
- package/protocols/feature.yaml +34 -0
- package/protocols/idea-to-product.yaml +26 -0
- package/protocols/performance.yaml +30 -0
- package/protocols/refactor.yaml +31 -0
- package/protocols/security.yaml +29 -0
- package/protocols/test.yaml +23 -0
- package/protocols/troubleshooting.yaml +26 -0
- package/protocols/verify.yaml +18 -0
- package/skills/approve/SKILL.md +8 -0
- package/skills/audit/SKILL.md +20 -0
- package/skills/bug/SKILL.md +15 -0
- package/skills/cancel/SKILL.md +9 -0
- package/skills/diagnose/SKILL.md +15 -0
- package/skills/feature/SKILL.md +15 -0
- package/skills/ledger/SKILL.md +9 -0
- package/skills/performance/SKILL.md +15 -0
- package/skills/protocols/SKILL.md +9 -0
- package/skills/resume/SKILL.md +9 -0
- package/skills/setup/SKILL.md +9 -0
- package/skills/start-project/SKILL.md +18 -0
- package/skills/status/SKILL.md +9 -0
- package/skills/test/SKILL.md +23 -0
- package/skills/verify/SKILL.md +9 -0
- package/templates/architecture-decision-record.md +15 -0
- package/templates/blueprint.example.json +69 -0
- package/templates/issue-templates/task.md +11 -0
- package/templates/plan.md +20 -0
- package/templates/product-spec.md +9 -0
- package/templates/repository-contract.md +9 -0
|
Binary file
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# Python/FastAPI feature protocol: migrations and security scans are required earlier than the built-in feature protocol.
|
|
2
|
+
schemaVersion: 1
|
|
3
|
+
id: fastapi-feature
|
|
4
|
+
version: 1.0.0
|
|
5
|
+
title: FastAPI feature protocol
|
|
6
|
+
description: API feature work with contract, migration and dependency-scan gates.
|
|
7
|
+
engine: ">=0.7.0"
|
|
8
|
+
mode: existing-repo
|
|
9
|
+
defaultRisk: medium
|
|
10
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
11
|
+
requiredArtifacts: [intent-brief, impact-map, acceptance-criteria, implementation-plan, test-plan, approved-plan-record]
|
|
12
|
+
gates:
|
|
13
|
+
- { id: lint, kind: lint, required: true }
|
|
14
|
+
- { id: typecheck, kind: typecheck, required: true }
|
|
15
|
+
- { id: unit, kind: unit, required: true }
|
|
16
|
+
- { id: integration, kind: integration, required: true }
|
|
17
|
+
- { id: migration, kind: migration, required: true, minRisk: medium }
|
|
18
|
+
- { id: security-scan, kind: security-scan, required: true, minRisk: medium }
|
|
19
|
+
phases:
|
|
20
|
+
- { id: intake, title: Classify the request }
|
|
21
|
+
- { id: reconnaissance, title: "Inspect routers, schemas and migrations" }
|
|
22
|
+
- { id: plan, title: Plan endpoint contract and tests }
|
|
23
|
+
- { id: approval, title: Human plan approval }
|
|
24
|
+
- { id: implementation, title: Implement }
|
|
25
|
+
- { id: verification, title: Run gates, gates: [lint, typecheck, unit, integration, migration, security-scan] }
|
|
26
|
+
- { id: repair, title: Bounded repair loop }
|
|
27
|
+
- { id: review, title: Independent review }
|
|
28
|
+
- { id: delivery, title: Open the pull request with evidence }
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Generic starting point for any repository: copy to .proofloop/protocols/ and adjust.
|
|
2
|
+
schemaVersion: 1
|
|
3
|
+
id: generic-change
|
|
4
|
+
version: 1.0.0
|
|
5
|
+
title: Generic change
|
|
6
|
+
description: Plan, approve, implement, run whatever checks the repository has.
|
|
7
|
+
engine: ">=0.7.0"
|
|
8
|
+
mode: existing-repo
|
|
9
|
+
defaultRisk: medium
|
|
10
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
11
|
+
requiredArtifacts: [intent-brief, acceptance-criteria, implementation-plan, approved-plan-record]
|
|
12
|
+
gates:
|
|
13
|
+
- { id: lint, kind: lint, required: true }
|
|
14
|
+
- { id: unit, kind: unit, required: true }
|
|
15
|
+
- { id: build, kind: build, required: true }
|
|
16
|
+
phases:
|
|
17
|
+
- { id: intake, title: Capture the request }
|
|
18
|
+
- { id: plan, title: Plan }
|
|
19
|
+
- { id: approval, title: Human plan approval }
|
|
20
|
+
- { id: implementation, title: Implement }
|
|
21
|
+
- { id: verification, title: Run gates, gates: [lint, unit, build] }
|
|
22
|
+
- { id: repair, title: Bounded repair loop }
|
|
23
|
+
- { id: delivery, title: Open the pull request with evidence }
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# Next.js feature protocol: browser journeys are required from medium risk.
|
|
2
|
+
schemaVersion: 1
|
|
3
|
+
id: nextjs-feature
|
|
4
|
+
version: 1.0.0
|
|
5
|
+
title: Next.js feature protocol
|
|
6
|
+
description: Feature work in a Next.js app; typecheck, unit tests and a Playwright journey gate every UI change.
|
|
7
|
+
engine: ">=0.7.0"
|
|
8
|
+
mode: existing-repo
|
|
9
|
+
defaultRisk: medium
|
|
10
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
11
|
+
requiredArtifacts: [intent-brief, impact-map, acceptance-criteria, implementation-plan, test-plan, approved-plan-record]
|
|
12
|
+
personas: [ordinary-user, impatient-user, unauthorized-user, accessibility]
|
|
13
|
+
gates:
|
|
14
|
+
- { id: lint, kind: lint, required: true }
|
|
15
|
+
- { id: typecheck, kind: typecheck, required: true }
|
|
16
|
+
- { id: unit, kind: unit, required: true }
|
|
17
|
+
- { id: build, kind: build, required: true }
|
|
18
|
+
- { id: browser, kind: browser, required: true, minRisk: medium }
|
|
19
|
+
- { id: security-scan, kind: security-scan, required: true, minRisk: high }
|
|
20
|
+
phases:
|
|
21
|
+
- { id: intake, title: Classify the request }
|
|
22
|
+
- { id: reconnaissance, title: "Inspect routes, server actions and components" }
|
|
23
|
+
- { id: plan, title: Plan UI states and tests }
|
|
24
|
+
- { id: approval, title: Human plan approval }
|
|
25
|
+
- { id: implementation, title: Implement in an isolated worktree }
|
|
26
|
+
- { id: verification, title: Run gates, gates: [lint, typecheck, unit, build, browser, security-scan] }
|
|
27
|
+
- { id: repair, title: Bounded repair loop }
|
|
28
|
+
- { id: review, title: Independent review }
|
|
29
|
+
- { id: delivery, title: Open the pull request with evidence }
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Node service bug protocol: smaller than the built-in bug protocol, still proves the regression test fails first.
|
|
2
|
+
schemaVersion: 1
|
|
3
|
+
id: node-service-bugfix
|
|
4
|
+
version: 1.0.0
|
|
5
|
+
title: Node service bugfix
|
|
6
|
+
description: Reproduce, add a regression test that fails first, fix, verify.
|
|
7
|
+
engine: ">=0.7.0"
|
|
8
|
+
mode: existing-repo
|
|
9
|
+
defaultRisk: low
|
|
10
|
+
retry: { maxRepairAttempts: 2, stopOnIdenticalFailure: true }
|
|
11
|
+
requiredArtifacts: [reproduction-result, root-cause, regression-test, verification-report]
|
|
12
|
+
gates:
|
|
13
|
+
- { id: regression-test, kind: unit, required: true }
|
|
14
|
+
- { id: lint, kind: lint, required: true }
|
|
15
|
+
- { id: unit, kind: unit, required: true }
|
|
16
|
+
phases:
|
|
17
|
+
- { id: intake, title: Capture observed and expected behavior }
|
|
18
|
+
- { id: reconnaissance, title: Reproduce first }
|
|
19
|
+
- { id: plan, title: Smallest correct fix }
|
|
20
|
+
- { id: approval, title: Human plan approval }
|
|
21
|
+
- { id: implementation, title: Test then fix }
|
|
22
|
+
- { id: verification, title: Run gates, gates: [regression-test, lint, unit] }
|
|
23
|
+
- { id: repair, title: Bounded repair loop }
|
|
24
|
+
- { id: delivery, title: Open the pull request with evidence }
|
package/hooks/hooks.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
{
|
|
2
|
+
"description": "ProofLoop guard: agents cannot change approvals or state; protected paths and critical shell commands are policy-checked. A bare \"test\" prompt starts the ProofLoop testing protocol.",
|
|
3
|
+
"hooks": {
|
|
4
|
+
"PreToolUse": [
|
|
5
|
+
{
|
|
6
|
+
"matcher": "Bash|Write|Edit|MultiEdit|NotebookEdit|Read",
|
|
7
|
+
"hooks": [
|
|
8
|
+
{
|
|
9
|
+
"type": "command",
|
|
10
|
+
"command": "${CLAUDE_PLUGIN_ROOT}/bin/proofloop",
|
|
11
|
+
"args": [
|
|
12
|
+
"hook",
|
|
13
|
+
"pre-tool-use"
|
|
14
|
+
],
|
|
15
|
+
"timeout": 15,
|
|
16
|
+
"onFailure": "block"
|
|
17
|
+
}
|
|
18
|
+
]
|
|
19
|
+
}
|
|
20
|
+
],
|
|
21
|
+
"UserPromptSubmit": [
|
|
22
|
+
{
|
|
23
|
+
"hooks": [
|
|
24
|
+
{
|
|
25
|
+
"type": "command",
|
|
26
|
+
"command": "${CLAUDE_PLUGIN_ROOT}/bin/proofloop",
|
|
27
|
+
"args": [
|
|
28
|
+
"hook",
|
|
29
|
+
"user-prompt"
|
|
30
|
+
],
|
|
31
|
+
"timeout": 10
|
|
32
|
+
}
|
|
33
|
+
]
|
|
34
|
+
}
|
|
35
|
+
]
|
|
36
|
+
}
|
|
37
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,72 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vamsiivarmaa/proofloop",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "1.0.0-rc.6",
|
|
4
|
+
"description": "Protocol-driven, evidence-based engineering harness and Claude Code plugin",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"packageManager": "pnpm@10.11.0",
|
|
8
|
+
"engines": {
|
|
9
|
+
"node": ">=22.13"
|
|
10
|
+
},
|
|
11
|
+
"bin": {
|
|
12
|
+
"proofloop": "bin/proofloop"
|
|
13
|
+
},
|
|
14
|
+
"scripts": {
|
|
15
|
+
"build": "node scripts/build.mjs",
|
|
16
|
+
"typecheck": "tsc --noEmit",
|
|
17
|
+
"lint": "eslint . --max-warnings 0",
|
|
18
|
+
"test": "vitest run",
|
|
19
|
+
"test:cov": "vitest run --coverage",
|
|
20
|
+
"check": "pnpm typecheck && pnpm lint && pnpm test:cov && pnpm build",
|
|
21
|
+
"prepack": "node scripts/build.mjs"
|
|
22
|
+
},
|
|
23
|
+
"devDependencies": {
|
|
24
|
+
"@playwright/test": "1.64.1",
|
|
25
|
+
"@types/node": "^26.6.5",
|
|
26
|
+
"@vitest/coverage-v8": "^5.0.5",
|
|
27
|
+
"esbuild": "^0.28.2",
|
|
28
|
+
"eslint": "^10.13.0",
|
|
29
|
+
"tsx": "^4.23.15",
|
|
30
|
+
"typescript": "6.0.3",
|
|
31
|
+
"typescript-eslint": "^8.72.0",
|
|
32
|
+
"vitest": "^5.0.5"
|
|
33
|
+
},
|
|
34
|
+
"dependencies": {
|
|
35
|
+
"yaml": "^2.9.1",
|
|
36
|
+
"zod": "^4.6.7"
|
|
37
|
+
},
|
|
38
|
+
"repository": {
|
|
39
|
+
"type": "git",
|
|
40
|
+
"url": "git+https://github.com/vamsivarma27/proofloop.git"
|
|
41
|
+
},
|
|
42
|
+
"homepage": "https://github.com/vamsivarma27/proofloop#readme",
|
|
43
|
+
"keywords": [
|
|
44
|
+
"claude-code",
|
|
45
|
+
"claude-code-plugin",
|
|
46
|
+
"agent",
|
|
47
|
+
"harness",
|
|
48
|
+
"verification",
|
|
49
|
+
"evidence",
|
|
50
|
+
"ai-coding"
|
|
51
|
+
],
|
|
52
|
+
"files": [
|
|
53
|
+
"dist",
|
|
54
|
+
"bin",
|
|
55
|
+
"skills",
|
|
56
|
+
"agents",
|
|
57
|
+
"hooks",
|
|
58
|
+
"protocols",
|
|
59
|
+
"templates",
|
|
60
|
+
"examples",
|
|
61
|
+
".claude-plugin",
|
|
62
|
+
"docs/assets/hero.gif",
|
|
63
|
+
"README.md",
|
|
64
|
+
"LICENSE",
|
|
65
|
+
"CHANGELOG.md",
|
|
66
|
+
"SECURITY.md"
|
|
67
|
+
],
|
|
68
|
+
"publishConfig": {
|
|
69
|
+
"access": "public",
|
|
70
|
+
"tag": "next"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: bug
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Bug protocol
|
|
5
|
+
description: Reproduce, root-cause and fix a defect with a regression test that fails before and passes after.
|
|
6
|
+
engine: ">=0.1.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: medium
|
|
9
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
10
|
+
requiredArtifacts: [reproduction-result, root-cause, blast-radius-map, regression-test, verification-report]
|
|
11
|
+
gates:
|
|
12
|
+
- { id: regression-test, kind: unit, required: true, description: Regression test that failed before the fix }
|
|
13
|
+
- { id: lint, kind: lint, required: true }
|
|
14
|
+
- { id: typecheck, kind: typecheck, required: true }
|
|
15
|
+
- { id: unit, kind: unit, required: true }
|
|
16
|
+
- { id: build, kind: build, required: true }
|
|
17
|
+
- { id: integration, kind: integration, required: true, minRisk: medium }
|
|
18
|
+
- { id: browser, kind: browser, required: true, minRisk: high }
|
|
19
|
+
phases:
|
|
20
|
+
- { id: intake, title: Capture observed and expected behavior }
|
|
21
|
+
- { id: clarify, title: Request missing reproduction details }
|
|
22
|
+
- { id: reconnaissance, title: Reproduce before modifying code }
|
|
23
|
+
- { id: impact, title: Trace blast radius }
|
|
24
|
+
- { id: plan, title: Plan the smallest correct fix, requiredArtifacts: [root-cause, regression-test] }
|
|
25
|
+
- { id: approval, title: Human plan approval }
|
|
26
|
+
- { id: implementation, title: Add regression test then fix }
|
|
27
|
+
- { id: verification, title: Run regression and relevant gates, gates: [regression-test, lint, typecheck, unit, build, integration, browser] }
|
|
28
|
+
- { id: repair, title: Bounded repair loop }
|
|
29
|
+
- { id: review, title: Independent fresh-context review }
|
|
30
|
+
- { id: delivery, title: Open the pull request with evidence }
|
|
31
|
+
- { id: retrospective, title: Propose harness improvements, skipped: { reason: Bug fixes rarely need harness changes; raise manually when a pattern recurs } }
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: feature
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Feature protocol
|
|
5
|
+
description: Add a user-facing capability to an existing repository with an approved plan and verified gates.
|
|
6
|
+
engine: ">=0.1.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: medium
|
|
9
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
10
|
+
requiredArtifacts: [intent-brief, impact-map, acceptance-criteria, implementation-plan, dependency-graph, test-plan, approved-plan-record]
|
|
11
|
+
personas: [ordinary-user, unauthorized-user]
|
|
12
|
+
gates:
|
|
13
|
+
- { id: format, kind: format, required: false }
|
|
14
|
+
- { id: lint, kind: lint, required: true }
|
|
15
|
+
- { id: typecheck, kind: typecheck, required: true }
|
|
16
|
+
- { id: unit, kind: unit, required: true }
|
|
17
|
+
- { id: build, kind: build, required: true }
|
|
18
|
+
- { id: integration, kind: integration, required: true, minRisk: medium }
|
|
19
|
+
- { id: browser, kind: browser, required: true, minRisk: high }
|
|
20
|
+
- { id: security-scan, kind: security-scan, required: true, minRisk: high }
|
|
21
|
+
- { id: migration, kind: migration, required: true, minRisk: high }
|
|
22
|
+
phases:
|
|
23
|
+
- { id: intake, title: Classify the request }
|
|
24
|
+
- { id: clarify, title: Clarify intent and constraints }
|
|
25
|
+
- { id: reconnaissance, title: Inspect repository and conventions }
|
|
26
|
+
- { id: impact, title: Map impact and risk }
|
|
27
|
+
- { id: plan, title: Plan and design tests, requiredArtifacts: [implementation-plan, test-plan] }
|
|
28
|
+
- { id: approval, title: Human plan approval, requiredArtifacts: [approved-plan-record] }
|
|
29
|
+
- { id: implementation, title: Implement in an isolated worktree }
|
|
30
|
+
- { id: verification, title: Run required gates, gates: [format, lint, typecheck, unit, build, integration, browser, security-scan, migration] }
|
|
31
|
+
- { id: repair, title: Bounded repair loop }
|
|
32
|
+
- { id: review, title: Independent fresh-context review }
|
|
33
|
+
- { id: delivery, title: Open the pull request with evidence }
|
|
34
|
+
- { id: retrospective, title: Propose harness improvements }
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: idea-to-product
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Idea-to-Product protocol
|
|
5
|
+
description: Discovery and blueprint with cited research and visible assumptions, then approved roadmap issues.
|
|
6
|
+
engine: ">=0.2.0"
|
|
7
|
+
mode: idea-to-product
|
|
8
|
+
defaultRisk: medium
|
|
9
|
+
retry: { maxRepairAttempts: 2, stopOnIdenticalFailure: true }
|
|
10
|
+
requiredArtifacts: [product-blueprint, risk-register, roadmap, adr]
|
|
11
|
+
gates:
|
|
12
|
+
- { id: blueprint-valid, kind: custom, required: true, description: "Blueprint schema, citations and DAG validate" }
|
|
13
|
+
- { id: assumptions-visible, kind: custom, required: true }
|
|
14
|
+
phases:
|
|
15
|
+
- { id: intake, title: Capture the business outcome }
|
|
16
|
+
- { id: clarify, title: Adaptive one-question-at-a-time interview }
|
|
17
|
+
- { id: reconnaissance, title: "Research with cited, dated sources" }
|
|
18
|
+
- { id: impact, title: "Separate facts, assumptions and recommendations" }
|
|
19
|
+
- { id: plan, title: "Personas, journeys, MVP, stack, data and API, roadmap", requiredArtifacts: [product-blueprint, roadmap] }
|
|
20
|
+
- { id: approval, title: Human blueprint approval before bulk issue creation }
|
|
21
|
+
- { id: implementation, title: Create the GitHub hierarchy and first milestone }
|
|
22
|
+
- { id: verification, title: Validate the blueprint and DAG, gates: [blueprint-valid, assumptions-visible] }
|
|
23
|
+
- { id: repair, title: Fix validation errors }
|
|
24
|
+
- { id: review, title: Review assumptions and stack against requirements }
|
|
25
|
+
- { id: delivery, title: Publish roadmap issues }
|
|
26
|
+
- { id: retrospective, title: Record decisions }
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: performance
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Performance protocol
|
|
5
|
+
description: Measure a baseline, change one thing, and report before/after against a stated target.
|
|
6
|
+
engine: ">=0.1.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: medium
|
|
9
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
10
|
+
requiredArtifacts: [baseline, measurement-methodology, profiler-evidence, change-hypothesis, before-after-result, regression-checks]
|
|
11
|
+
gates:
|
|
12
|
+
- { id: baseline-recorded, kind: performance, required: true, description: Baseline with workload and target exists before optimizing }
|
|
13
|
+
- { id: before-after, kind: performance, required: true }
|
|
14
|
+
- { id: load, kind: load, required: false, minRisk: high }
|
|
15
|
+
- { id: lint, kind: lint, required: true }
|
|
16
|
+
- { id: unit, kind: unit, required: true }
|
|
17
|
+
- { id: build, kind: build, required: true }
|
|
18
|
+
phases:
|
|
19
|
+
- { id: intake, title: "Capture workload, target and environment" }
|
|
20
|
+
- { id: clarify, title: Confirm target and acceptable trade-offs }
|
|
21
|
+
- { id: reconnaissance, title: Profile and inspect queries }
|
|
22
|
+
- { id: impact, title: "Separate model, app, database, network and render time" }
|
|
23
|
+
- { id: plan, title: Plan one measured change, requiredArtifacts: [baseline, change-hypothesis] }
|
|
24
|
+
- { id: approval, title: Human plan approval }
|
|
25
|
+
- { id: implementation, title: Apply the change }
|
|
26
|
+
- { id: verification, title: Re-measure and run regression gates, gates: [baseline-recorded, before-after, load, lint, unit, build] }
|
|
27
|
+
- { id: repair, title: Bounded repair loop }
|
|
28
|
+
- { id: review, title: Independent review of methodology }
|
|
29
|
+
- { id: delivery, title: Report trade-offs and whether the target was met }
|
|
30
|
+
- { id: retrospective, title: Propose harness improvements }
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: refactor
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Refactor protocol
|
|
5
|
+
description: Change structure without changing behavior; detect contract, export, schema and config drift.
|
|
6
|
+
engine: ">=0.1.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: medium
|
|
9
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
10
|
+
requiredArtifacts: [behavior-baseline, architecture-target, scope, regression-plan]
|
|
11
|
+
gates:
|
|
12
|
+
- { id: baseline-green, kind: unit, required: true, description: Tests green before the refactor starts }
|
|
13
|
+
- { id: lint, kind: lint, required: true }
|
|
14
|
+
- { id: typecheck, kind: typecheck, required: true }
|
|
15
|
+
- { id: unit, kind: unit, required: true }
|
|
16
|
+
- { id: build, kind: build, required: true }
|
|
17
|
+
- { id: integration, kind: integration, required: true, minRisk: medium }
|
|
18
|
+
- { id: contract-drift, kind: custom, required: true, description: "Public exports, API contracts, schema and config unchanged" }
|
|
19
|
+
phases:
|
|
20
|
+
- { id: intake, title: Capture refactor goal and scope }
|
|
21
|
+
- { id: clarify, title: Confirm behavior must not change }
|
|
22
|
+
- { id: reconnaissance, title: Record behavior baseline }
|
|
23
|
+
- { id: impact, title: Map public surface }
|
|
24
|
+
- { id: plan, title: Plan incremental steps }
|
|
25
|
+
- { id: approval, title: Human plan approval }
|
|
26
|
+
- { id: implementation, title: Refactor in small steps }
|
|
27
|
+
- { id: verification, title: Prove behavior preserved, gates: [baseline-green, lint, typecheck, unit, build, integration, contract-drift] }
|
|
28
|
+
- { id: repair, title: Bounded repair loop }
|
|
29
|
+
- { id: review, title: Independent review }
|
|
30
|
+
- { id: delivery, title: Open the pull request with evidence }
|
|
31
|
+
- { id: retrospective, title: Propose harness improvements }
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: security
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Security protocol
|
|
5
|
+
description: Threat-model, test negative paths, scan dependencies; findings cannot be dismissed by an LLM alone.
|
|
6
|
+
engine: ">=0.1.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: high
|
|
9
|
+
retry: { maxRepairAttempts: 3, stopOnIdenticalFailure: true }
|
|
10
|
+
requiredArtifacts: [threat-model, trust-boundaries, authorization-checks, negative-tests, scan-results, remediation-plan]
|
|
11
|
+
gates:
|
|
12
|
+
- { id: lint, kind: lint, required: true }
|
|
13
|
+
- { id: unit, kind: unit, required: true }
|
|
14
|
+
- { id: build, kind: build, required: true }
|
|
15
|
+
- { id: negative-tests, kind: integration, required: true }
|
|
16
|
+
- { id: security-scan, kind: security-scan, required: true }
|
|
17
|
+
phases:
|
|
18
|
+
- { id: intake, title: Capture the security concern }
|
|
19
|
+
- { id: clarify, title: Confirm authorization and isolated environment }
|
|
20
|
+
- { id: reconnaissance, title: Map trust boundaries }
|
|
21
|
+
- { id: impact, title: Build the threat model }
|
|
22
|
+
- { id: plan, title: Plan remediation and negative tests, requiredArtifacts: [threat-model, remediation-plan] }
|
|
23
|
+
- { id: approval, title: Human plan approval }
|
|
24
|
+
- { id: implementation, title: Remediate }
|
|
25
|
+
- { id: verification, title: Run negative tests and scans, gates: [lint, unit, build, negative-tests, security-scan] }
|
|
26
|
+
- { id: repair, title: Bounded repair loop }
|
|
27
|
+
- { id: review, title: Independent security review }
|
|
28
|
+
- { id: delivery, title: Open the pull request with evidence }
|
|
29
|
+
- { id: retrospective, title: Propose harness improvements }
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: test
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Test protocol
|
|
5
|
+
description: "Full project test on the current commit: static checks, unit and regression suite, integration, browser journeys with personas, security scan, migration, compared with the base branch."
|
|
6
|
+
engine: ">=1.0.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: medium
|
|
9
|
+
retry: { maxRepairAttempts: 0, stopOnIdenticalFailure: true }
|
|
10
|
+
personas: [ordinary-user, impatient-user, unauthorized-user, accessibility]
|
|
11
|
+
gates:
|
|
12
|
+
- { id: format, kind: format, required: false }
|
|
13
|
+
- { id: lint, kind: lint, required: true }
|
|
14
|
+
- { id: typecheck, kind: typecheck, required: true }
|
|
15
|
+
- { id: unit, kind: unit, required: true }
|
|
16
|
+
- { id: build, kind: build, required: true }
|
|
17
|
+
- { id: integration, kind: integration, required: false }
|
|
18
|
+
- { id: browser, kind: browser, required: true }
|
|
19
|
+
- { id: security-scan, kind: security-scan, required: false }
|
|
20
|
+
- { id: migration, kind: migration, required: false }
|
|
21
|
+
phases:
|
|
22
|
+
- { id: verification, title: "Run every applicable check on the current commit and on the base branch", gates: [format, lint, typecheck, unit, build, integration, browser, security-scan, migration] }
|
|
23
|
+
- { id: delivery, title: "Report results, regressions and bugs" }
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: troubleshooting
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Troubleshooting protocol
|
|
5
|
+
description: Read-only evidence first, ranked hypotheses, least destructive experiments, verified recovery.
|
|
6
|
+
engine: ">=0.1.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: medium
|
|
9
|
+
retry: { maxRepairAttempts: 2, stopOnIdenticalFailure: true }
|
|
10
|
+
requiredArtifacts: [timeline, observations, ranked-hypotheses, diagnostic-commands, cause-or-uncertainty, follow-up-checks]
|
|
11
|
+
gates:
|
|
12
|
+
- { id: evidence-preserved, kind: custom, required: true, description: Pre-fix evidence recorded }
|
|
13
|
+
- { id: recovery-verified, kind: custom, required: true }
|
|
14
|
+
phases:
|
|
15
|
+
- { id: intake, title: "Capture symptom, window and environment" }
|
|
16
|
+
- { id: clarify, title: Ask for logs and affected services }
|
|
17
|
+
- { id: reconnaissance, title: Collect read-only evidence }
|
|
18
|
+
- { id: impact, title: "Classify code, environment, credential, provider or flake" }
|
|
19
|
+
- { id: plan, title: Rank hypotheses and choose experiments }
|
|
20
|
+
- { id: approval, title: Approve any mutating remediation }
|
|
21
|
+
- { id: implementation, title: Apply remediation }
|
|
22
|
+
- { id: verification, title: Verify recovery, gates: [evidence-preserved, recovery-verified] }
|
|
23
|
+
- { id: repair, title: Bounded repair loop }
|
|
24
|
+
- { id: review, title: Review conclusion against evidence, skipped: { reason: Evidence ledger is checked by the engine; reviewer is optional for read-only diagnosis } }
|
|
25
|
+
- { id: delivery, title: Report cause or explicit uncertainty }
|
|
26
|
+
- { id: retrospective, title: Propose harness improvements }
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
schemaVersion: 1
|
|
2
|
+
id: verify
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
title: Verify protocol
|
|
5
|
+
description: Run the repository's detected quality gates against the current commit and report evidence.
|
|
6
|
+
engine: ">=0.1.0"
|
|
7
|
+
mode: existing-repo
|
|
8
|
+
defaultRisk: low
|
|
9
|
+
retry: { maxRepairAttempts: 0, stopOnIdenticalFailure: true }
|
|
10
|
+
gates:
|
|
11
|
+
- { id: format, kind: format, required: false }
|
|
12
|
+
- { id: lint, kind: lint, required: true }
|
|
13
|
+
- { id: typecheck, kind: typecheck, required: true }
|
|
14
|
+
- { id: unit, kind: unit, required: true }
|
|
15
|
+
- { id: build, kind: build, required: true }
|
|
16
|
+
phases:
|
|
17
|
+
- { id: verification, title: Run gates against the current commit, gates: [format, lint, typecheck, unit, build] }
|
|
18
|
+
- { id: delivery, title: Report evidence }
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: approve
|
|
3
|
+
description: Record YOUR approval of a ProofLoop plan. Humans only.
|
|
4
|
+
argument-hint: "<run-id>"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
Run `proofloop approve $ARGUMENTS` (no hash) to display the plan and its hash, and show the user the plan in full. If the user already told you to approve this run, run `proofloop approve $ARGUMENTS --plan-hash <hash> --yes` right away; the tool-permission prompt is the one human confirmation, so do not ask again in chat. Otherwise stop after showing the plan and let them decide. Then tell the user to run `proofloop run <run-id>` (in the background) to start execution.
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: audit
|
|
3
|
+
description: When the user says "audit" (optionally with a user count and p95/p99 targets, e.g. "audit for 5000 users, p99 under 500ms"), audit the project for scale and system design - measured latency percentiles under load, static scalability findings, and a checklist-driven design review.
|
|
4
|
+
argument-hint: "[--users 2000] [--p95 300] [--p99 800] [--error-rate 0.01] [--path /api/x]"
|
|
5
|
+
allowed-tools: Bash(proofloop *)
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
Do not ask first; run the audit. Defaults if the user gave no numbers: 2000 users, p95 300 ms, p99 800 ms, errors 1% - say you used defaults.
|
|
9
|
+
|
|
10
|
+
1. Run in the foreground with the Bash timeout at 600000 ms:
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
proofloop audit $ARGUMENTS
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
It sizes the load (users -> concurrent users, rps, in-flight requests, with printed assumptions), scans for scalability smells (unbounded queries, N+1, no timeouts, sync I/O, process-local state, retries without backoff), runs the repository's load test if there is one, and starts the app (`app.start` / `app.url` in `.proofloop/config.json`) to probe each `--path` for p50/p95/p99 and error rate.
|
|
17
|
+
|
|
18
|
+
2. Report the status exactly: `measured-ok`, `violations`, `needs-review` or `not-measured`. **Never say the app "can handle N users".** The probe is one machine; say what it measured against which targets. If nothing was measured (no app start command, no load test), say so and offer to add a k6 script or the app start config through `/proofloop:feature`.
|
|
19
|
+
3. Then do the design review yourself, read-only: run `proofloop audit --checklist`, read the code, and answer each area (capacity, data-access, caching, concurrency, resilience, scalability, failure-modes, observability) with `file:line` evidence, or say "no evidence found". Mark each answer reviewed, not measured. Check the static findings against the code and say which are real.
|
|
20
|
+
4. Offer fixes as a normal change (`/proofloop:feature` or `/proofloop:performance`) so they get a plan with design decisions, an approved plan hash, and a load check. Do not change code during an audit.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: bug
|
|
3
|
+
description: Run the ProofLoop bug protocol: reproduce first, prove the regression test fails before the fix, then fix and verify.
|
|
4
|
+
argument-hint: "[observed vs expected behavior]"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run:
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
proofloop bug "$ARGUMENTS"
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Then show the user the whole plan from the output (at a glance, tasks, acceptance criteria, commands) and the "Gate plan preview", plus any warnings. **Do not approve anything yourself.** Tell them to review and, when satisfied, run `/proofloop:approve <run-id>`. Never describe work as passing unless a gate result in the output says PASS. If the output says BLOCKED, report the reason and evidence path verbatim. If the bug could not be reproduced, ask the user for the missing details instead of proposing a fix.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: cancel
|
|
3
|
+
description: Cancel a ProofLoop run safely; the branch and worktree are preserved.
|
|
4
|
+
argument-hint: "<run-id>"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run `proofloop cancel $ARGUMENTS` and confirm the state.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: diagnose
|
|
3
|
+
description: Diagnose a failing or slow workflow with read-only evidence first and ranked hypotheses.
|
|
4
|
+
argument-hint: "[symptom, logs, environment]"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run:
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
proofloop diagnose "$ARGUMENTS"
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Then show the user the plan summary and the "Gate plan preview" from the output, plus any warnings. **Do not approve anything yourself.** Tell them to review and, when satisfied, run `/proofloop:approve <run-id>`. Never describe work as passing unless a gate result in the output says PASS. If the output says BLOCKED, report the reason and evidence path verbatim. Do not restart, mutate or delete anything without explicit approval.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: feature
|
|
3
|
+
description: Run the ProofLoop feature protocol: discover, plan, wait for approval, implement in an isolated worktree, verify with real gates.
|
|
4
|
+
argument-hint: "[what to build]"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run this and wait for it to finish (it can take several minutes; use a long timeout or run it in the background and poll):
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
proofloop feature "$ARGUMENTS"
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Then show the user the whole plan from the output (at a glance, tasks, acceptance criteria, commands) and the "Gate plan preview", plus any warnings. **Do not approve anything yourself.** Tell them to review and, when satisfied, run `/proofloop:approve <run-id>`. Never describe work as passing unless a gate result in the output says PASS. If the output says BLOCKED, report the reason and evidence path verbatim.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ledger
|
|
3
|
+
description: Export the Proof Ledger for a run (JSON or Markdown), or show the history ProofLoop retrieved before planning.
|
|
4
|
+
argument-hint: "<run-id> [json|markdown]"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run `proofloop ledger export $ARGUMENTS` (default JSON; add `--format markdown` for the readable form). Report the disposition, the criteria that are verified, failed or unverified, and any stale or missing evidence. To see the retrieved history, run `proofloop memory <run-id>`; to inspect past incidents, run `proofloop incident list`. Do not edit or summarize away failed attempts.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: performance
|
|
3
|
+
description: Run the ProofLoop performance protocol: baseline, one change, before/after against a stated target.
|
|
4
|
+
argument-hint: "[slow operation, workload, target]"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run:
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
proofloop performance "$ARGUMENTS"
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Then show the user the plan summary and the "Gate plan preview" from the output, plus any warnings. **Do not approve anything yourself.** Tell them to review and, when satisfied, run `/proofloop:approve <run-id>`. Never describe work as passing unless a gate result in the output says PASS. If the output says BLOCKED, report the reason and evidence path verbatim. Never claim an improvement without recorded before/after numbers and a stated target.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: protocols
|
|
3
|
+
description: List installed ProofLoop protocols and versions.
|
|
4
|
+
argument-hint: ""
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run `proofloop protocols` and show the table, including any diagnostics for invalid project-local protocols.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: resume
|
|
3
|
+
description: Resume an interrupted, paused or blocked ProofLoop run after reconciling Git state.
|
|
4
|
+
argument-hint: "<run-id> [--retry]"
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run `proofloop resume $ARGUMENTS` and report the outcome. Use --retry only after the user confirms the blocker is resolved.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: setup
|
|
3
|
+
description: Check the environment and create a minimal .proofloop config (asks before writing).
|
|
4
|
+
argument-hint: ""
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
allowed-tools: Bash(proofloop *)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Run `proofloop setup` (read-only). Show the self-check and what would be written. Only if the user agrees, run `proofloop setup --yes`. Do not install dependencies or change repository files.
|