repo-harness 0.5.3 → 0.7.0
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/.agents/skills/repo-harness-chatgpt-browser/SKILL.md +106 -0
- package/README.es.md +13 -7
- package/README.fr.md +13 -7
- package/README.ja.md +7 -6
- package/README.md +112 -17
- package/README.zh-CN.md +47 -15
- package/assets/hooks/lib/workflow-state.sh +83 -13
- package/assets/reference-configs/agentic-development-flow.md +7 -0
- package/assets/reference-configs/document-generation.md +1 -0
- package/assets/reference-configs/external-tooling.md +11 -5
- package/assets/reference-configs/handoff-protocol.md +5 -7
- package/assets/reference-configs/harness-overview.md +13 -0
- package/assets/reference-configs/sprint-contracts.md +26 -6
- package/assets/skill-commands/repo-harness-goal/SKILL.md +1 -1
- package/assets/skill-version.json +10 -2
- package/assets/templates/contract.template.md +15 -4
- package/assets/templates/helpers/archive-workflow.sh +2 -2
- package/assets/templates/helpers/capture-plan.sh +2 -2
- package/assets/templates/helpers/check-task-workflow.sh +161 -2
- package/assets/templates/helpers/contract-run.ts +71 -8
- package/assets/templates/helpers/contract-worktree.sh +5 -9
- package/assets/templates/helpers/ensure-task-workflow.sh +28 -6
- package/assets/templates/helpers/harness-trace-grade.sh +150 -0
- package/assets/templates/helpers/new-plan.sh +2 -2
- package/assets/templates/helpers/plan-to-todo.sh +45 -4
- package/assets/templates/helpers/prepare-handoff.sh +51 -4
- package/assets/templates/helpers/sprint-backlog.sh +8 -2
- package/assets/templates/helpers/verify-contract.sh +90 -13
- package/assets/templates/helpers/verify-sprint.sh +496 -14
- package/assets/templates/helpers/workflow-contract.ts +11 -0
- package/assets/templates/plan.template.md +2 -2
- package/assets/templates/review.template.md +13 -1
- package/assets/workflow-contract.v1.json +69 -0
- package/docs/repo-harness-chatgpt-browser-engine.md +184 -0
- package/package.json +13 -3
- package/scripts/archive-workflow.sh +2 -2
- package/scripts/capture-plan.sh +2 -2
- package/scripts/check-ci.sh +38 -1
- package/scripts/check-release-published.sh +51 -0
- package/scripts/check-tarball-install-smoke.sh +58 -0
- package/scripts/check-task-workflow.sh +161 -2
- package/scripts/contract-run.ts +71 -8
- package/scripts/contract-worktree.sh +5 -9
- package/scripts/ensure-task-workflow.sh +28 -6
- package/scripts/harness-trace-grade.sh +150 -0
- package/scripts/lib/project-init-lib.sh +30 -8
- package/scripts/new-plan.sh +2 -2
- package/scripts/plan-to-todo.sh +45 -4
- package/scripts/prepare-handoff.sh +51 -4
- package/scripts/sprint-backlog.sh +8 -2
- package/scripts/verify-contract.sh +90 -13
- package/scripts/verify-sprint.sh +496 -14
- package/scripts/workflow-contract.ts +11 -0
- package/src/cli/chatgpt-browser/engine.ts +182 -0
- package/src/cli/chatgpt-browser/file-policy.ts +158 -0
- package/src/cli/chatgpt-browser/native-provider.ts +378 -0
- package/src/cli/chatgpt-browser/oracle-provider.ts +108 -0
- package/src/cli/chatgpt-browser/prompt-assembler.ts +29 -0
- package/src/cli/chatgpt-browser/session-store.ts +294 -0
- package/src/cli/chatgpt-browser/types.ts +159 -0
- package/src/cli/commands/adopt-plan.ts +186 -0
- package/src/cli/commands/chatgpt.ts +309 -0
- package/src/cli/commands/global-runtime.ts +6 -10
- package/src/cli/commands/init.ts +9 -16
- package/src/cli/commands/install.ts +19 -6
- package/src/cli/commands/mcp.ts +244 -0
- package/src/cli/index.ts +148 -38
- package/src/cli/mcp/audit.ts +32 -0
- package/src/cli/mcp/auth.ts +106 -0
- package/src/cli/mcp/instructions.ts +9 -0
- package/src/cli/mcp/oauth.ts +214 -0
- package/src/cli/mcp/paths.ts +115 -0
- package/src/cli/mcp/policy.ts +127 -0
- package/src/cli/mcp/redaction.ts +53 -0
- package/src/cli/mcp/repo.ts +24 -0
- package/src/cli/mcp/server.ts +87 -0
- package/src/cli/mcp/setup.ts +681 -0
- package/src/cli/mcp/tools.ts +995 -0
- package/src/cli/mcp/transports/http.ts +372 -0
- package/src/cli/mcp/transports/stdio.ts +8 -0
- package/src/cli/mcp/types.ts +34 -0
- package/src/cli/runtime/helper-runner.ts +13 -10
- package/src/cli/tools/codegraph.ts +9 -17
- package/src/core/adoption/gitignore-plan.ts +98 -0
- package/src/core/adoption/helper-wrapper-plan.ts +159 -0
- package/src/core/adoption/manifest-templates.ts +60 -0
- package/src/core/adoption/modes.ts +7 -0
- package/src/core/adoption/operations.ts +126 -0
- package/src/core/adoption/plan.ts +145 -0
- package/src/core/adoption/render.ts +70 -0
- package/src/core/adoption/rollback.ts +62 -0
- package/src/core/adoption/summary.ts +43 -0
- package/src/core/adoption/workflow-contract-asset.ts +12 -0
- package/src/core/adoption/workflow-contract-plan.ts +31 -0
- package/src/effects/fs-transaction.ts +540 -0
- package/src/effects/managed-block.ts +86 -0
- package/src/effects/path-safety.ts +47 -0
- package/src/effects/process-runner.ts +91 -0
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: repo-harness-chatgpt-browser
|
|
3
|
+
description: Use when the user wants Codex to consult their logged-in ChatGPT Web session through repo-harness browser engine for planning, architecture review, PRD critique, or Codex goal generation.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# repo-harness ChatGPT Browser
|
|
7
|
+
|
|
8
|
+
Use this skill when the user asks to consult ChatGPT Web, GPT Pro, browser GPT, or a logged-in ChatGPT account through repo-harness.
|
|
9
|
+
|
|
10
|
+
## Rules
|
|
11
|
+
|
|
12
|
+
1. This uses the user's logged-in ChatGPT Web browser session, not the OpenAI API.
|
|
13
|
+
2. Do not ask for or handle passwords, SSO secrets, 2FA codes, cookies, browser storage, or tokens.
|
|
14
|
+
3. Before a non-dry-run consult, state that it may create or continue a real ChatGPT Web conversation.
|
|
15
|
+
4. Prefer dry-run first when files are involved:
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
repo-harness chatgpt browser-consult --repo . --dry-run --prompt "<prompt>" --file <path>
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
5. For readiness, run:
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
repo-harness chatgpt browser-doctor --repo .
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
6. Use browser consult for planning, review, critique, and goal generation. Do not use it as the executor for code edits.
|
|
28
|
+
7. Save useful results into repo-harness artifacts with repo-relative `--write-output` paths such as:
|
|
29
|
+
|
|
30
|
+
```text
|
|
31
|
+
.ai/harness/handoff/chatgpt-review.md
|
|
32
|
+
.ai/harness/handoff/codex-goal.md
|
|
33
|
+
plans/prds/*.prd.md
|
|
34
|
+
plans/sprints/*.sprint.md
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
8. If login, captcha, workspace picker, or SSO is required, stop and ask the user to complete it in the browser.
|
|
38
|
+
9. Do not enable remote CDP unless the user explicitly asked for remote browser control and the security boundary is documented.
|
|
39
|
+
10. For MCP usage, require the server to be started with:
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
repo-harness mcp serve --repo . --enable-chatgpt-browser
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
11. Do not rely on provider stdout `Artifact:` / `Output:` paths being imported. Browser engine session records save prompt, transcript, output, metadata, and trusted provider IDs; ordinary stdout paths are ignored.
|
|
46
|
+
12. Native provider uses the current ChatGPT Web model selection. Do not pass `--model` or `--thinking` with `--provider native`; use Oracle when model selection is required.
|
|
47
|
+
|
|
48
|
+
## Common Commands
|
|
49
|
+
|
|
50
|
+
Dry-run consult:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
repo-harness chatgpt browser-consult \
|
|
54
|
+
--repo . \
|
|
55
|
+
--dry-run \
|
|
56
|
+
--prompt "Review this sprint and return execution risks." \
|
|
57
|
+
--file plans/sprints/example.sprint.md
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Oracle provider consult:
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
repo-harness chatgpt browser-consult \
|
|
64
|
+
--repo . \
|
|
65
|
+
--provider oracle \
|
|
66
|
+
--prompt "Review this PRD and return risks plus a smallest next step." \
|
|
67
|
+
--file plans/prds/example.prd.md \
|
|
68
|
+
--write-output .ai/harness/handoff/chatgpt-review.md
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Native provider spike:
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
repo-harness chatgpt browser-doctor --repo . --provider native
|
|
75
|
+
repo-harness chatgpt browser-consult \
|
|
76
|
+
--repo . \
|
|
77
|
+
--provider native \
|
|
78
|
+
--browser-channel chrome \
|
|
79
|
+
--keep-browser \
|
|
80
|
+
--prompt "Reply exactly OK"
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Use native provider only when the user is ready for a visible ChatGPT Web run. If login is required, keep the browser open and have the user complete login manually; do not request or handle credentials.
|
|
84
|
+
|
|
85
|
+
Read the result:
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
repo-harness chatgpt browser-list --repo .
|
|
89
|
+
repo-harness chatgpt browser-session --repo . <sessionId>
|
|
90
|
+
repo-harness chatgpt browser-open --repo . <sessionId>
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
Continue from a saved session:
|
|
94
|
+
|
|
95
|
+
```bash
|
|
96
|
+
repo-harness chatgpt browser-followup \
|
|
97
|
+
--repo . \
|
|
98
|
+
--session <sessionId> \
|
|
99
|
+
--prompt "Challenge the previous result and return the smallest next step."
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
Plan cleanup before deleting local session records:
|
|
103
|
+
|
|
104
|
+
```bash
|
|
105
|
+
repo-harness chatgpt browser-cleanup --repo . --status dry_run --limit 20
|
|
106
|
+
```
|
package/README.es.md
CHANGED
|
@@ -56,11 +56,17 @@ En un repositorio adoptado, la superficie se mantiene pequeña:
|
|
|
56
56
|
| `tasks/contracts/`, `tasks/reviews/` y `.ai/harness/checks/` | Scope, verificación y evidencia de review para probar que el trabajo terminó. |
|
|
57
57
|
| `.ai/harness/handoff/` y `tasks/current.md` | Session journal y estado resumible, derivados de workflow artifacts en vez de chat memory. |
|
|
58
58
|
|
|
59
|
-
## Novedades en 0.
|
|
60
|
-
|
|
61
|
-
- **
|
|
62
|
-
|
|
63
|
-
- **
|
|
59
|
+
## Novedades en 0.7.0
|
|
60
|
+
|
|
61
|
+
- **ChatGPT browser engine.** `repo-harness chatgpt browser-*` crea sesiones
|
|
62
|
+
ChatGPT Web repo-locales con archivos revisados por policy, sin usar OpenAI API.
|
|
63
|
+
- **MCP browser tools opt-in.** `repo-harness mcp serve
|
|
64
|
+
--enable-chatgpt-browser` expone consult/read/list/continue/open; por defecto
|
|
65
|
+
estos tools siguen desactivados.
|
|
66
|
+
- **Oracle y native providers.** El engine incluye un Oracle browser wrapper y
|
|
67
|
+
un spike native vía Chrome instalado + CDP local.
|
|
68
|
+
- **Hosted CI y release smoke.** El repo añade un GitHub CI gate y un tarball
|
|
69
|
+
install smoke que arranca los binarios empaquetados de `repo-harness`.
|
|
64
70
|
|
|
65
71
|
## Qué hace el producto
|
|
66
72
|
|
|
@@ -377,8 +383,8 @@ Guards habituales:
|
|
|
377
383
|
|
|
378
384
|
## Release actual
|
|
379
385
|
|
|
380
|
-
- npm package: `repo-harness@0.
|
|
381
|
-
- Generated workflow stamp: `repo-harness@0.
|
|
386
|
+
- npm package: `repo-harness@0.7.0`
|
|
387
|
+
- Generated workflow stamp: `repo-harness@0.7.0+template@0.7.0`
|
|
382
388
|
- GitHub repository: `Ancienttwo/repo-harness`
|
|
383
389
|
- Release history: [`docs/CHANGELOG.md`](docs/CHANGELOG.md)
|
|
384
390
|
|
package/README.fr.md
CHANGED
|
@@ -56,11 +56,17 @@ Dans un dépôt adopté, la surface à comprendre reste volontairement réduite
|
|
|
56
56
|
| `tasks/contracts/`, `tasks/reviews/` et `.ai/harness/checks/` | Scope, vérification et preuves de review pour démontrer que le travail est terminé. |
|
|
57
57
|
| `.ai/harness/handoff/` et `tasks/current.md` | Session journal et état resumable dérivés des workflow artifacts plutôt que de la chat memory. |
|
|
58
58
|
|
|
59
|
-
## Nouveautés de la 0.
|
|
60
|
-
|
|
61
|
-
- **
|
|
62
|
-
|
|
63
|
-
- **
|
|
59
|
+
## Nouveautés de la 0.7.0
|
|
60
|
+
|
|
61
|
+
- **ChatGPT browser engine.** `repo-harness chatgpt browser-*` crée des sessions
|
|
62
|
+
ChatGPT Web repo-locales avec des fichiers contrôlés par policy, sans OpenAI API.
|
|
63
|
+
- **MCP browser tools opt-in.** `repo-harness mcp serve
|
|
64
|
+
--enable-chatgpt-browser` expose consult/read/list/continue/open, désactivés
|
|
65
|
+
par défaut.
|
|
66
|
+
- **Oracle et native providers.** Le moteur inclut un Oracle browser wrapper et
|
|
67
|
+
un spike native via Chrome installé et CDP local.
|
|
68
|
+
- **Hosted CI et release smoke.** Le dépôt ajoute un GitHub CI gate et un
|
|
69
|
+
tarball install smoke qui démarre les binaires packagés `repo-harness`.
|
|
64
70
|
|
|
65
71
|
## Ce que fait le produit
|
|
66
72
|
|
|
@@ -381,8 +387,8 @@ Guards courants :
|
|
|
381
387
|
|
|
382
388
|
## Release actuelle
|
|
383
389
|
|
|
384
|
-
- npm package : `repo-harness@0.
|
|
385
|
-
- Generated workflow stamp : `repo-harness@0.
|
|
390
|
+
- npm package : `repo-harness@0.7.0`
|
|
391
|
+
- Generated workflow stamp : `repo-harness@0.7.0+template@0.7.0`
|
|
386
392
|
- GitHub repository : `Ancienttwo/repo-harness`
|
|
387
393
|
- Release history : [`docs/CHANGELOG.md`](docs/CHANGELOG.md)
|
|
388
394
|
|
package/README.ja.md
CHANGED
|
@@ -47,11 +47,12 @@ Agent に完全な PRD または Sprint を渡せば、あとは review and `nex
|
|
|
47
47
|
| `tasks/contracts/`, `tasks/reviews/`, `.ai/harness/checks/` | 作業完了を証明する scope、verification、review evidence。 |
|
|
48
48
|
| `.ai/harness/handoff/` と `tasks/current.md` | chat memory ではなく workflow artifacts から派生する session journal と resumable status。 |
|
|
49
49
|
|
|
50
|
-
## 0.
|
|
50
|
+
## 0.7.0 の新機能
|
|
51
51
|
|
|
52
|
-
- **
|
|
53
|
-
- **
|
|
54
|
-
- **
|
|
52
|
+
- **ChatGPT browser engine。** `repo-harness chatgpt browser-*` は、OpenAI API を使わず、policy-checked な repo-local ChatGPT Web consult session を作れます。
|
|
53
|
+
- **Opt-in MCP browser tools。** `repo-harness mcp serve --enable-chatgpt-browser` のときだけ consult/read/list/continue/open tools を公開し、デフォルトでは無効です。
|
|
54
|
+
- **Oracle and native providers。** Oracle browser wrapper と、installed Chrome + local CDP を使う native spike を含みます。
|
|
55
|
+
- **Hosted CI and release smoke。** GitHub CI gate と、packaged `repo-harness` binaries を起動する tarball install smoke を追加しました。
|
|
55
56
|
|
|
56
57
|
## repo-harness は何をするか
|
|
57
58
|
|
|
@@ -351,8 +352,8 @@ hook がブロックしたときは、まず terminal の構造化された出
|
|
|
351
352
|
|
|
352
353
|
## 現在の Release
|
|
353
354
|
|
|
354
|
-
- npm package:`repo-harness@0.
|
|
355
|
-
- Generated workflow stamp:`repo-harness@0.
|
|
355
|
+
- npm package:`repo-harness@0.7.0`
|
|
356
|
+
- Generated workflow stamp:`repo-harness@0.7.0+template@0.7.0`
|
|
356
357
|
- GitHub repository:`Ancienttwo/repo-harness`
|
|
357
358
|
- Release history:[`docs/CHANGELOG.md`](docs/CHANGELOG.md)
|
|
358
359
|
|
package/README.md
CHANGED
|
@@ -50,15 +50,43 @@ In an adopted repo, the surface area is intentionally small:
|
|
|
50
50
|
| `tasks/contracts/`, `tasks/reviews/`, and `.ai/harness/checks/` | Scope, verification, and review evidence for proving the work is done. |
|
|
51
51
|
| `.ai/harness/handoff/` and `tasks/current.md` | Session journal and resumable status, derived from workflow artifacts instead of chat memory. |
|
|
52
52
|
|
|
53
|
-
##
|
|
53
|
+
## Human Review Path
|
|
54
54
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
55
|
+
Start with `tasks/reviews/<task>.review.md`. The `## Human Review Card` is the
|
|
56
|
+
one-screen decision surface: verdict, change type, intended vs actual files,
|
|
57
|
+
commands passed, external acceptance, residual risk, reviewer action, and
|
|
58
|
+
rollback. Then inspect the active contract, latest trace in
|
|
59
|
+
`.ai/harness/checks/latest.json`, and the changed files. Accept only when the
|
|
60
|
+
review recommends pass, the card verdict is pass, and external acceptance is
|
|
61
|
+
pass, `not_required`, or an explicit manual override.
|
|
62
|
+
|
|
63
|
+
## Agent Tracking Path
|
|
64
|
+
|
|
65
|
+
Agents read source artifacts before derived summaries:
|
|
66
|
+
|
|
67
|
+
| Agent reads first | Human reviews first |
|
|
68
|
+
| --- | --- |
|
|
69
|
+
| Current user prompt and referenced files | `tasks/reviews/<task>.review.md` Human Review Card |
|
|
70
|
+
| `AGENTS.md` / `CLAUDE.md` | Changed files and diff |
|
|
71
|
+
| Active plan in `.ai/harness/active-plan` | Active contract allowed paths and exit criteria |
|
|
72
|
+
| Active contract in `tasks/contracts/` | `.ai/harness/checks/latest.json` and run trace |
|
|
73
|
+
| Latest handoff in `.ai/harness/handoff/` | Residual risks and rollback |
|
|
74
|
+
|
|
75
|
+
`tasks/current.md` is only an orientation snapshot. If it disagrees with the
|
|
76
|
+
active plan, contract, review, checks, or handoff, the source artifacts win.
|
|
77
|
+
|
|
78
|
+
## What's New in 0.7.0
|
|
79
|
+
|
|
80
|
+
- **ChatGPT browser engine.** `repo-harness chatgpt browser-*` can create
|
|
81
|
+
policy-checked, repo-local ChatGPT Web consult sessions without using the
|
|
82
|
+
OpenAI API.
|
|
83
|
+
- **Opt-in MCP browser tools.** `repo-harness mcp serve
|
|
84
|
+
--enable-chatgpt-browser` exposes consult/read/list/continue/open tools while
|
|
85
|
+
keeping them disabled by default.
|
|
86
|
+
- **Oracle and native providers.** The engine supports an Oracle browser wrapper
|
|
87
|
+
plus a native installed-Chrome CDP spike for logged-in ChatGPT Web runs.
|
|
88
|
+
- **Hosted CI and release smoke.** The repo now ships a GitHub CI gate and a
|
|
89
|
+
tarball install smoke that starts the packaged `repo-harness` binaries.
|
|
62
90
|
|
|
63
91
|
## What repo-harness Does
|
|
64
92
|
|
|
@@ -72,11 +100,71 @@ target repository so Claude, Codex, and humans can agree on:
|
|
|
72
100
|
- which checks and review evidence prove the work is done
|
|
73
101
|
- how hooks should warn, block, trace, and hand off work across sessions
|
|
74
102
|
|
|
75
|
-
It is not an agent gateway, product runtime, database service, or MCP server.
|
|
76
103
|
The product boundary is deliberately boring: inspect a repo, install or refresh
|
|
77
104
|
workflow files, route host events through repo-local hooks, and verify that the
|
|
78
105
|
workflow surfaces stay consistent.
|
|
79
106
|
|
|
107
|
+
As an optional sidecar, `repo-harness mcp` exposes only workflow artifacts to
|
|
108
|
+
MCP clients. ChatGPT can use it as a planner/reviewer to read state and move an
|
|
109
|
+
idea through PRD, checklist Sprint, and Codex goal handoff artifacts; it does
|
|
110
|
+
not get source-code write access, arbitrary shell execution, or a default Codex
|
|
111
|
+
runner. Codex remains the executor. The generated manual setup guide lives at
|
|
112
|
+
`docs/repo-harness-chatgpt-mcp-setup.md`, and the local CLI handoff is
|
|
113
|
+
`repo-harness mcp prepare-goal --prd <prd> --sprint <sprint>`.
|
|
114
|
+
|
|
115
|
+
### MCP Connector Quickstart
|
|
116
|
+
|
|
117
|
+
Use the MCP sidecar when you want ChatGPT to plan against the real repo state
|
|
118
|
+
and Codex to execute the resulting file-backed Sprint.
|
|
119
|
+
|
|
120
|
+
```bash
|
|
121
|
+
repo-harness mcp setup chatgpt --repo .
|
|
122
|
+
repo-harness mcp serve --repo . --transport http --host 127.0.0.1 --port 8765 --profile planner
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
Expose that local server through an HTTPS tunnel and create a ChatGPT Connector
|
|
126
|
+
with the `/mcp` URL. The generated guide is written to:
|
|
127
|
+
|
|
128
|
+
```text
|
|
129
|
+
docs/repo-harness-chatgpt-mcp-setup.md
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
The human workflow is:
|
|
133
|
+
|
|
134
|
+
1. ChatGPT reads repo-harness workflow files through MCP.
|
|
135
|
+
2. ChatGPT writes a PRD with `write_prd_from_idea`.
|
|
136
|
+
3. ChatGPT writes a checklist Sprint with `write_checklist_sprint`.
|
|
137
|
+
4. ChatGPT prepares `.ai/harness/handoff/codex-goal.md` with `prepare_codex_goal_from_sprint`.
|
|
138
|
+
5. Codex runs the host-native `/goal` prompt and stages each completed Sprint phase.
|
|
139
|
+
|
|
140
|
+
Local fallback for the last handoff step:
|
|
141
|
+
|
|
142
|
+
```bash
|
|
143
|
+
repo-harness mcp prepare-goal --repo . --prd plans/prds/<feature>.prd.md --sprint plans/sprints/<feature>.sprint.md
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
The agent-facing Skill is installed at:
|
|
147
|
+
|
|
148
|
+
```text
|
|
149
|
+
.agents/skills/repo-harness-chatgpt-bridge/SKILL.md
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
That Skill tells Codex how to consume ChatGPT-produced PRD/Sprint/Goal artifacts
|
|
153
|
+
without granting ChatGPT source-code writes or shell execution.
|
|
154
|
+
|
|
155
|
+
Dev Mode can opt into local agent execution through MCP. This is off by default.
|
|
156
|
+
When the user enables the `orchestrator` profile with the dev runner setting,
|
|
157
|
+
ChatGPT can call `run_agent_goal`, which reads only
|
|
158
|
+
`.ai/harness/handoff/codex-goal.md` and runs the fixed handoff through an
|
|
159
|
+
allowed local CLI such as `codex exec` or `claude -p`.
|
|
160
|
+
|
|
161
|
+
```bash
|
|
162
|
+
repo-harness mcp serve --repo . --transport http --profile orchestrator --enable-dev-runner --dev-runner-agents codex
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
This setting is for local Developer Mode only. It is timeout-bounded, audited,
|
|
166
|
+
and not arbitrary shell.
|
|
167
|
+
|
|
80
168
|
## How It Works
|
|
81
169
|
|
|
82
170
|
The design has three layers:
|
|
@@ -234,10 +322,10 @@ irm https://raw.githubusercontent.com/Ancienttwo/repo-harness/main/install.ps1 |
|
|
|
234
322
|
```bash
|
|
235
323
|
# Bun
|
|
236
324
|
bun add -g repo-harness
|
|
237
|
-
repo-harness
|
|
325
|
+
repo-harness install
|
|
238
326
|
|
|
239
327
|
# Node/npm, with Bun already on PATH because the CLI runs on Bun
|
|
240
|
-
npx -y repo-harness
|
|
328
|
+
npx -y repo-harness install
|
|
241
329
|
```
|
|
242
330
|
|
|
243
331
|
</details>
|
|
@@ -245,14 +333,15 @@ npx -y repo-harness init
|
|
|
245
333
|
### 2. Bootstrap the host runtime once
|
|
246
334
|
|
|
247
335
|
```bash
|
|
248
|
-
repo-harness
|
|
336
|
+
repo-harness install
|
|
249
337
|
```
|
|
250
338
|
|
|
251
|
-
`
|
|
339
|
+
`install` is the first-run global bootstrap path. It installs the current npm
|
|
252
340
|
package as the global CLI, refreshes repo-harness skill aliases, installs
|
|
253
341
|
user-level hook adapters, configures Waza runtime skills, persists a brain root
|
|
254
342
|
under `~/.repo-harness/config.json`, and configures CodeGraph MCP. It does not
|
|
255
|
-
apply repo-local workflow files to the current directory.
|
|
343
|
+
apply repo-local workflow files to the current directory. `repo-harness init`
|
|
344
|
+
remains a compatibility alias for existing scripts.
|
|
256
345
|
|
|
257
346
|
For an Agent-owned, read-only bootstrap audit, run `npx -y repo-harness setup
|
|
258
347
|
check --json` or add `--check-updates` for version advisories. `setup check` is
|
|
@@ -265,11 +354,17 @@ optional command, and verification surface for the Agent to execute deliberately
|
|
|
265
354
|
|
|
266
355
|
```bash
|
|
267
356
|
# First machine bootstrap after installing the CLI: skills, host adapters, Waza, brain, CodeGraph.
|
|
268
|
-
repo-harness
|
|
357
|
+
repo-harness install
|
|
269
358
|
|
|
270
359
|
# Refresh user-level CLI/runtime pieces after a package update.
|
|
271
360
|
repo-harness update
|
|
272
361
|
|
|
362
|
+
# Remove repo-harness managed host adapters without deleting sibling hooks or third-party tools.
|
|
363
|
+
repo-harness uninstall
|
|
364
|
+
|
|
365
|
+
# Install only the host hook adapters, preserving the older adapter-only surface.
|
|
366
|
+
repo-harness install --target both --location global
|
|
367
|
+
|
|
273
368
|
# Ask for read-only repair guidance without writing files.
|
|
274
369
|
repo-harness update --check
|
|
275
370
|
|
|
@@ -455,8 +550,8 @@ Most common guards:
|
|
|
455
550
|
|
|
456
551
|
## Current Release
|
|
457
552
|
|
|
458
|
-
- npm package: `repo-harness@0.
|
|
459
|
-
- Generated workflow stamp: `repo-harness@0.
|
|
553
|
+
- npm package: `repo-harness@0.7.0`
|
|
554
|
+
- Generated workflow stamp: `repo-harness@0.7.0+template@0.7.0`
|
|
460
555
|
- GitHub repository: `Ancienttwo/repo-harness`
|
|
461
556
|
- Release history: [`docs/CHANGELOG.md`](docs/CHANGELOG.md)
|
|
462
557
|
|
package/README.zh-CN.md
CHANGED
|
@@ -43,14 +43,40 @@ handoff、检查结果和 review evidence 写回项目文件,让下一个 agen
|
|
|
43
43
|
| `tasks/contracts/`、`tasks/reviews/`、`.ai/harness/checks/` | 证明完成所需的 scope、verification 和 review evidence。 |
|
|
44
44
|
| `.ai/harness/handoff/` 和 `tasks/current.md` | session journal 与可恢复状态,从 workflow artifacts 派生,而不是依赖聊天记忆。 |
|
|
45
45
|
|
|
46
|
-
##
|
|
46
|
+
## Human Review Path
|
|
47
47
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
48
|
+
先读 `tasks/reviews/<task>.review.md`。`## Human Review Card` 是一屏决策面:
|
|
49
|
+
verdict、change type、预期/实际改动文件、已通过命令、external acceptance、
|
|
50
|
+
残余风险、reviewer action 和 rollback。然后检查 active contract、
|
|
51
|
+
`.ai/harness/checks/latest.json` 里的 latest trace,以及实际 diff。只有当 review
|
|
52
|
+
recommend pass、card verdict 为 pass,且 external acceptance 为 pass、not_required
|
|
53
|
+
或明确 manual override 时,才进入 closeout。
|
|
54
|
+
|
|
55
|
+
## Agent Tracking Path
|
|
56
|
+
|
|
57
|
+
Agent 先读 source artifacts,再读派生摘要:
|
|
58
|
+
|
|
59
|
+
| Agent reads first | Human reviews first |
|
|
60
|
+
| --- | --- |
|
|
61
|
+
| 当前用户 prompt 和引用文件 | `tasks/reviews/<task>.review.md` 的 Human Review Card |
|
|
62
|
+
| `AGENTS.md` / `CLAUDE.md` | changed files 和 diff |
|
|
63
|
+
| `.ai/harness/active-plan` 指向的 active plan | active contract 的 allowed paths 和 exit criteria |
|
|
64
|
+
| `tasks/contracts/` 下的 active contract | `.ai/harness/checks/latest.json` 和 run trace |
|
|
65
|
+
| `.ai/harness/handoff/` 下的 latest handoff | 残余风险和 rollback |
|
|
66
|
+
|
|
67
|
+
`tasks/current.md` 只是 orientation snapshot。如果它和 active plan、contract、
|
|
68
|
+
review、checks 或 handoff 冲突,以 source artifacts 为准。
|
|
69
|
+
|
|
70
|
+
## 0.7.0 新特性
|
|
71
|
+
|
|
72
|
+
- **ChatGPT browser engine。** `repo-harness chatgpt browser-*` 可以用
|
|
73
|
+
policy-checked 文件输入创建 repo-local ChatGPT Web consult session,不走 OpenAI API。
|
|
74
|
+
- **Opt-in MCP browser tools。** `repo-harness mcp serve
|
|
75
|
+
--enable-chatgpt-browser` 才会暴露 consult/read/list/continue/open 工具,默认关闭。
|
|
76
|
+
- **Oracle 和 native provider。** Browser engine 支持 Oracle browser wrapper,
|
|
77
|
+
也支持基于本机已安装 Chrome CDP 的 logged-in ChatGPT Web spike。
|
|
78
|
+
- **Hosted CI 和 release smoke。** 仓库新增 GitHub CI gate,并用 tarball install
|
|
79
|
+
smoke 验证 packaged `repo-harness` binaries 能启动。
|
|
54
80
|
|
|
55
81
|
## 产品做什么
|
|
56
82
|
|
|
@@ -204,10 +230,10 @@ irm https://raw.githubusercontent.com/Ancienttwo/repo-harness/main/install.ps1 |
|
|
|
204
230
|
```bash
|
|
205
231
|
# Bun
|
|
206
232
|
bun add -g repo-harness
|
|
207
|
-
repo-harness
|
|
233
|
+
repo-harness install
|
|
208
234
|
|
|
209
235
|
# Node/npm;仍要求 Bun 已在 PATH 上,因为 CLI runtime 是 Bun
|
|
210
|
-
npx -y repo-harness
|
|
236
|
+
npx -y repo-harness install
|
|
211
237
|
```
|
|
212
238
|
|
|
213
239
|
</details>
|
|
@@ -215,13 +241,13 @@ npx -y repo-harness init
|
|
|
215
241
|
### 2. 先做一次 host runtime bootstrap
|
|
216
242
|
|
|
217
243
|
```bash
|
|
218
|
-
repo-harness
|
|
244
|
+
repo-harness install
|
|
219
245
|
```
|
|
220
246
|
|
|
221
|
-
`
|
|
247
|
+
`install` 是首次全局引导入口。它把当前 npm 包安装成全局 CLI,刷新 repo-harness
|
|
222
248
|
skill aliases,安装 user-level hook adapters,配置 Waza runtime skills,把 brain
|
|
223
249
|
root 持久化到 `~/.repo-harness/config.json`,并配置 CodeGraph MCP。它不会把当前目录
|
|
224
|
-
默认迁移成 repo-local workflow
|
|
250
|
+
默认迁移成 repo-local workflow。`repo-harness init` 保留为兼容 alias,给已有脚本用。
|
|
225
251
|
|
|
226
252
|
如果要让 Agent 做只读 bootstrap audit,运行 `npx -y repo-harness setup check
|
|
227
253
|
--json`;需要版本提示时加 `--check-updates`。`setup check` 不是 runtime hook:
|
|
@@ -233,11 +259,17 @@ targets、可选 command 和 verification 的 `agent_actions`,由 Agent 再显
|
|
|
233
259
|
|
|
234
260
|
```bash
|
|
235
261
|
# 安装 CLI 后做首次机器级 bootstrap:skills、host adapters、Waza、brain、CodeGraph。
|
|
236
|
-
repo-harness
|
|
262
|
+
repo-harness install
|
|
237
263
|
|
|
238
264
|
# 包更新后刷新 user-level CLI/runtime。
|
|
239
265
|
repo-harness update
|
|
240
266
|
|
|
267
|
+
# 移除 repo-harness 管理的 host adapters,不删除 sibling hooks 或第三方工具。
|
|
268
|
+
repo-harness uninstall
|
|
269
|
+
|
|
270
|
+
# 只安装 host hook adapters,保留旧版 adapter-only surface。
|
|
271
|
+
repo-harness install --target both --location global
|
|
272
|
+
|
|
241
273
|
# 只读检查需要 agent 修复什么,不写文件。
|
|
242
274
|
repo-harness update --check
|
|
243
275
|
|
|
@@ -410,8 +442,8 @@ hook block 工作时,先看 terminal 里的结构化输出。核心字段是
|
|
|
410
442
|
|
|
411
443
|
## 当前 Release
|
|
412
444
|
|
|
413
|
-
- npm package:`repo-harness@0.
|
|
414
|
-
- Generated workflow stamp:`repo-harness@0.
|
|
445
|
+
- npm package:`repo-harness@0.7.0`
|
|
446
|
+
- Generated workflow stamp:`repo-harness@0.7.0+template@0.7.0`
|
|
415
447
|
- GitHub repository:`Ancienttwo/repo-harness`
|
|
416
448
|
- Release history:[`docs/CHANGELOG.md`](docs/CHANGELOG.md)
|
|
417
449
|
|