@manhd_d/ai-harness 0.12.0 → 0.14.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/CHANGELOG.md +35 -0
- package/README.md +28 -37
- package/adapters/ai-python/adapter.yaml +1 -1
- package/adapters/ai-python/rules.md +3 -0
- package/adapters/ai-python/skills/harness-ai-python-rag-access/SKILL.md +1 -0
- package/adapters/ai-python/skills/harness-ai-python-tool-safety/SKILL.md +1 -0
- package/adapters/astro/adapter.yaml +3 -5
- package/adapters/astro/checks/verification.yaml +6 -6
- package/adapters/astro/evals/cases.json +5 -5
- package/adapters/astro/rules/architecture.md +2 -8
- package/adapters/astro/rules/deployment.md +2 -8
- package/adapters/astro/rules.md +5 -14
- package/adapters/astro/skills/harness-astro-islands/SKILL.md +3 -2
- package/adapters/astro/skills/harness-astro-performance/SKILL.md +1 -0
- package/adapters/astro/skills/harness-astro-project-architecture/SKILL.md +9 -19
- package/adapters/astro/skills/harness-astro-seo/SKILL.md +1 -0
- package/adapters/java-spring/adapter.yaml +2 -4
- package/adapters/java-spring/rules/database.md +2 -2
- package/adapters/java-spring/rules/performance.md +2 -2
- package/adapters/java-spring/rules.md +4 -1
- package/adapters/java-spring/skills/harness-java-spring-spring-api/SKILL.md +1 -0
- package/adapters/kubernetes/adapter.yaml +1 -1
- package/adapters/kubernetes/rules.md +3 -0
- package/adapters/kubernetes/skills/harness-kubernetes-helm-release/SKILL.md +1 -0
- package/adapters/kubernetes/skills/harness-kubernetes-rollout-safety/SKILL.md +1 -0
- package/adapters/kubernetes/skills/harness-kubernetes-workload-review/SKILL.md +1 -0
- package/adapters/react-native/adapter.yaml +1 -1
- package/adapters/react-native/rules.md +3 -0
- package/adapters/react-native/skills/harness-react-native-behavior-testing/SKILL.md +1 -0
- package/adapters/react-native/skills/harness-react-native-device-permissions/SKILL.md +1 -0
- package/adapters/react-native/skills/harness-react-native-offline-sync/SKILL.md +1 -0
- package/adapters/react-native/skills/harness-react-native-screen-delivery/SKILL.md +1 -0
- package/adapters/react-nextjs/adapter.yaml +1 -1
- package/adapters/react-nextjs/rules.md +3 -0
- package/adapters/react-nextjs/skills/harness-react-nextjs-accessible-ui/SKILL.md +1 -0
- package/adapters/react-nextjs/skills/harness-react-nextjs-behavior-testing/SKILL.md +1 -0
- package/adapters/react-nextjs/skills/harness-react-nextjs-feature-delivery/SKILL.md +1 -0
- package/adapters/react-nextjs/skills/harness-react-nextjs-server-boundaries/SKILL.md +1 -0
- package/bin/aih.js +1 -1
- package/capabilities/analysis/capability.json +48 -0
- package/capabilities/analysis/checks/verification.json +16 -0
- package/capabilities/analysis/evals/cases.json +15 -0
- package/capabilities/architecture/agents/architecture-reviewer.md +5 -0
- package/capabilities/architecture/agents/solution-architect.md +5 -0
- package/capabilities/architecture/capability.json +1 -1
- package/capabilities/delivery/agents/project-manager.md +10 -11
- package/capabilities/delivery/capability.json +8 -2
- package/capabilities/delivery/templates/delivery-plan.md +2 -23
- package/capabilities/discovery/capability.json +37 -0
- package/capabilities/discovery/checks/verification.json +16 -0
- package/capabilities/discovery/evals/cases.json +15 -0
- package/capabilities/product/agents/business-analyst.md +5 -0
- package/capabilities/product/agents/product-manager.md +5 -0
- package/capabilities/product/agents/product-owner.md +5 -0
- package/capabilities/product/agents/project-manager.md +9 -14
- package/capabilities/product/agents/requirements-reviewer.md +5 -0
- package/capabilities/product/capability.json +8 -2
- package/capabilities/product/common/document-contract.md +10 -0
- package/capabilities/product/evals/cases.json +11 -0
- package/capabilities/product/skills/harness-product-acceptance-criteria/SKILL.md +4 -7
- package/capabilities/product/skills/harness-product-backlog-prioritization/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-brd-generation/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-business-analysis/SKILL.md +7 -10
- package/capabilities/product/skills/harness-product-document-review/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-idea-discovery/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-knowledge-analysis/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-mvp-definition/SKILL.md +1 -2
- package/capabilities/product/skills/harness-product-prd-generation/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-product-outcomes/SKILL.md +1 -2
- package/capabilities/product/skills/harness-product-product-research/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-srs-generation/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-techspec/SKILL.md +1 -1
- package/capabilities/product/skills/harness-product-traceability/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-use-case-generation/SKILL.md +2 -6
- package/capabilities/product/skills/harness-product-user-stories/SKILL.md +2 -6
- package/capabilities/product/templates/delivery-plan.md +3 -17
- package/cli/adapters.js +9 -5
- package/cli/agents.js +45 -9
- package/cli/capabilities.js +39 -8
- package/cli/checkpoint.js +57 -0
- package/cli/claude.js +40 -0
- package/cli/comparison.js +46 -0
- package/cli/composition.js +1 -0
- package/cli/files.js +2 -1
- package/cli/harness.js +78 -20
- package/cli/main.js +51 -15
- package/cli/maven.js +28 -0
- package/cli/portable-config.js +121 -0
- package/cli/start-config.js +15 -0
- package/cli/start.js +138 -0
- package/cli/verification-report.js +1 -1
- package/config/agents.claude-code.json +100 -0
- package/config/agents.default.json +25 -5
- package/core/agents/documentation.md +5 -0
- package/core/agents/implementer.md +5 -0
- package/core/agents/orchestrator.md +5 -0
- package/core/agents/planner.md +5 -0
- package/core/agents/project-manager.md +20 -0
- package/core/agents/reviewer.md +5 -0
- package/core/agents/security-reviewer.md +5 -0
- package/core/agents/test-engineer.md +5 -0
- package/core/checks/verification.json +12 -0
- package/core/evals/cases.json +44 -0
- package/core/policies/permissions.md +3 -1
- package/core/workflows/agent-routing.md +27 -26
- package/core/workflows/continuous-development.md +3 -0
- package/core/workflows/project-setup.md +18 -0
- package/core/workflows/spec-to-code.md +1 -1
- package/docs/README.md +6 -1
- package/docs/agent-configuration.md +9 -5
- package/docs/agent-first.md +66 -0
- package/docs/agent-handoffs.md +4 -0
- package/docs/architecture.md +14 -0
- package/docs/cli.md +21 -0
- package/docs/configuration-backup.md +122 -0
- package/docs/continuous-development.md +4 -0
- package/docs/examples/astro-micro-tools.md +1 -1
- package/docs/examples/checkpoint.json +20 -0
- package/docs/examples/spring-boot-api.md +2 -4
- package/docs/getting-started.md +9 -6
- package/docs/i18n/README.es.md +35 -0
- package/docs/i18n/README.vi.md +21 -43
- package/docs/i18n/README.zh-CN.md +35 -0
- package/docs/project-configuration.md +9 -1
- package/docs/skill-matrix.md +7 -7
- package/docs/start.md +38 -0
- package/docs/tool-setup/README.md +69 -67
- package/docs/tool-setup/claude-code.md +41 -49
- package/docs/tool-setup/codex.md +31 -43
- package/docs/tool-setup/copilot.md +35 -38
- package/docs/tool-setup/cursor.md +25 -40
- package/docs/tool-setup/gemini-cli.md +31 -35
- package/docs/tool-setup/kiro.md +55 -0
- package/docs/versioning.md +24 -0
- package/evals/real-task-comparison.md +4 -0
- package/harness.yaml +4 -2
- package/package.json +3 -2
- package/scripts/compare-tasks.js +15 -0
- package/templates/AGENTS.md +20 -28
- package/templates/delivery-plan.md +25 -0
- package/adapters/astro/skills/harness-astro-cloudflare/SKILL.md +0 -27
- package/adapters/astro/skills/harness-astro-microfrontend/SKILL.md +0 -27
- package/adapters/java-spring/skills/harness-java-spring-database-migration/SKILL.md +0 -23
- package/adapters/java-spring/skills/harness-java-spring-kafka-outbox/SKILL.md +0 -23
|
@@ -27,7 +27,7 @@ with a field-level error; it is not reset automatically. Keep credentials in hos
|
|
|
27
27
|
## Contract and precedence
|
|
28
28
|
Schema version 1 uses provider, defaultModel, defaultReasoning, models, agents and execution, with
|
|
29
29
|
optional hosts. Role IDs are namespace:role: core:planner, product:project-manager and
|
|
30
|
-
delivery:project-manager
|
|
30
|
+
delivery:project-manager retain distinct configuration IDs but alias the canonical core:project-manager responsibility. Defaults cover all current roles; only installed selected
|
|
31
31
|
roles are active. Unknown/custom role IDs can be declared but are not asserted to have a host contract.
|
|
32
32
|
Future unmapped installed roles inherit project defaults and are listed by setup.
|
|
33
33
|
|
|
@@ -41,10 +41,10 @@ explicit role mappings. enabled:false disables a dedicated route, not required r
|
|
|
41
41
|
```json
|
|
42
42
|
{
|
|
43
43
|
"schema_version": 1,
|
|
44
|
-
"provider": "
|
|
45
|
-
"defaultModel": "
|
|
44
|
+
"provider": "host",
|
|
45
|
+
"defaultModel": "host-default",
|
|
46
46
|
"defaultReasoning": "medium",
|
|
47
|
-
"models": { "economy": "
|
|
47
|
+
"models": { "economy": "host-default", "balanced": "host-default", "premium": "host-default" },
|
|
48
48
|
"agents": {
|
|
49
49
|
"core:orchestrator": { "model": "@balanced", "reasoning": "high" },
|
|
50
50
|
"core:implementer": { "model": "@balanced", "reasoning": "medium" },
|
|
@@ -56,7 +56,7 @@ explicit role mappings. enabled:false disables a dedicated route, not required r
|
|
|
56
56
|
```
|
|
57
57
|
This is a partial example; omitted registered roles inherit defaults. The shipped default covers Core,
|
|
58
58
|
Product, Architecture and Delivery roles. Orchestrator/Planner/Architect/Reviewer/Security Reviewer
|
|
59
|
-
use
|
|
59
|
+
use declared high/medium reasoning preferences; new seeds retain host-selected models and documentation uses low reasoning. Explicit provider/model examples below illustrate configuration and are not defaults.
|
|
60
60
|
Economy is Luna low with single-agent/one concurrent session; it is a preference, not a cost guarantee.
|
|
61
61
|
|
|
62
62
|
Reasoning levels structurally accepted: none, minimal, low, medium, high, xhigh, max, ultra. Actual
|
|
@@ -97,3 +97,7 @@ controls vary by client. No role JSON automatically creates a native subagent or
|
|
|
97
97
|
one lead plus at most one independent helper when supported. Keep inputs scoped, load skill metadata
|
|
98
98
|
before one needed body and checkpoint unresolved work. Actual usage/quotas come from the host; no fake
|
|
99
99
|
budget meter is inferred from model tiers, maxRounds or concurrency. See [Agent handoffs](agent-handoffs.md).
|
|
100
|
+
|
|
101
|
+
## Agent-first defaults and declarations (unreleased)
|
|
102
|
+
|
|
103
|
+
New seeds use host/host-default so the actual host model remains selected; old agents.json is preserved. Claude host init offers native aliases only when absent. aih agents resolves canonical role IDs and required/optional skill preferences. Optional execution.autonomy and execution.budget are validated declarations, not execution permission or quota enforcement. Checkpoint real usage or unknown; never infer cost or auto-escalate. See [Agent-first guide](agent-first.md).
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Agent-first delivery and migration from 0.12.0
|
|
2
|
+
|
|
3
|
+
Unreleased additions require a reviewed source bundle until published. Distribution stays release-PR owned.
|
|
4
|
+
|
|
5
|
+
## Responsibility and scope
|
|
6
|
+
Core Orchestrator selects only needed BA, PO/Product Manager, SA, PM, Developer and QA/Reviewer perspectives. Single host performs them sequentially; independent workers require actual host delegation. Inspect scope, approved requirements/ADRs and existing conventions first. Open architecture/technology choices go to SA with alternatives/trade-offs and actual owner decision. Reuse accepted choices without asking again. Adapters implement accepted designs; they do not choose infrastructure.
|
|
7
|
+
|
|
8
|
+
Core-only works on unsupported stacks. Registered detection is metadata, not a supported-stack restriction or runtime readiness guarantee. All remaining adapter skills take approved SA decisions as input. The Java outbox/migration and Astro Cloudflare/microfrontend recipes are retired; old IDs return migration guidance after update. Existing old snapshots still contain their old locked skills until reviewed update. Edited managed retired files block the whole update rather than being deleted silently.
|
|
9
|
+
|
|
10
|
+
## Selective capabilities and compatibility
|
|
11
|
+
Analysis exposes 11 canonical Product skills for requirements/domain/AC/traceability/TechSpec. Discovery exposes 5 for idea/research/MVP/PRD/outcomes. product remains the 16-skill compatibility bundle. Select either or both without duplicate skill IDs. Canonical Product assets are vendored to retain shared references and old template paths; this controls exposed context, not npm download size. There are no new npm packages.
|
|
12
|
+
|
|
13
|
+
```sh
|
|
14
|
+
aih init --capabilities analysis,architecture,delivery
|
|
15
|
+
aih agents
|
|
16
|
+
aih skills
|
|
17
|
+
aih new-doc srs --capability analysis
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
For existing consumers edit project.json capabilities on a branch and use update --dry-run/update/check. Product new-doc routes stay usable when the selected profile declares that template. Profile-specific routes default to docs/<profile>; existing artifact outputs take precedence. No existing document is moved.
|
|
21
|
+
|
|
22
|
+
core:project-manager is canonical. product:project-manager and delivery:project-manager remain configured role aliases with their model overrides; canonical_id identifies the same responsibility. Delivery-plan aliases resolve to one locked template but preserve old output routes and old user docs.
|
|
23
|
+
|
|
24
|
+
## Models, autonomy and budgets
|
|
25
|
+
New seeds keep the host-selected model (provider host, model host-default). Existing agents.json bytes are preserved. init --host claude-code seeds Anthropic native aliases sonnet/haiku/opus only when absent; aliases do not verify account access. Explicit mappings/premium choice still require actual host support. Optional execution.autonomy declares assisted/autopilot, actions and repositories; autopilot needs explicit nonempty action/repository scope. Optional budget declares maxTokens or maxCost/currency. These settings neither grant user authorization nor enforce permissions/quota. Defaults remain assisted by absence; this repository's no-auto-merge rule applies to its own development.
|
|
26
|
+
|
|
27
|
+
Example optional declaration:
|
|
28
|
+
```json
|
|
29
|
+
{"mode":"autopilot","actions":["read","edit","test","commit","create-pr"],"repositories":["team/project"]}
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
This is execution.autonomy, not a complete agents.json replacement. Merge/release/deploy/source-write need explicit action scope and actual user authorization plus host/repository rules. Do not manufacture quota or auto-switch to paid models.
|
|
33
|
+
|
|
34
|
+
## Brownfield and Claude
|
|
35
|
+
```sh
|
|
36
|
+
aih init --detect --host claude-code --link-claude --claude-skills
|
|
37
|
+
aih doctor
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
Default init/update preserves CLAUDE.md. --link-claude appends only a managed @AGENTS.md import, preserving BOM/line endings/user text; existing active imports are left alone. The managed block is drift-checked and subsequent updates preserve it. --claude-skills installs locked wrappers directing the host to full canonical .agents skills; custom native skills/settings survive and collisions abort before writes. Verify actual loading with Claude /context and invoke a wrapper in an authorized session. CLI tests do not prove live skill loading.
|
|
41
|
+
|
|
42
|
+
Doctor examines root CLAUDE.md/CLAUDE.local.md and .claude/CLAUDE.md, excluding imports mentioned inside code/comments. It warns about possible instruction shadowing, not a proven host failure. Claude version, ancestor/global files, plugins and settings remain unverified. Official documentation: https://code.claude.com/docs/en/memory and https://code.claude.com/docs/en/skills .
|
|
43
|
+
|
|
44
|
+
Maven detection follows declared module paths at most two levels, 64 POMs, 1 MiB per file and 4 MiB total. Evidence identifies each POM; missing/deeper modules produce warnings. Unsafe paths/symlinks, XML entities/CDATA and interpolation fail rather than being resolved. This is a bounded metadata reader, not general XML/profile/interpolation resolution. Other monorepos need host discovery.
|
|
45
|
+
|
|
46
|
+
Team-owned .agents/.claude skills outside Harness names are preserved and excluded from the Harness catalog/check. check validates locked files, not user skill semantics. The host can load those skills normally. Unowned collisions at a Harness destination fail; no global scanning or adoption occurs.
|
|
47
|
+
|
|
48
|
+
## Meaningful-step checkpoint and recovery
|
|
49
|
+
Use existing OpenSpec design/tasks/decisions/evidence as authoritative work records. Save a compact machine checkpoint after meaningful steps and before external side effects; do not copy chat history or secrets. See the [checkpoint fixture](examples/checkpoint.json).
|
|
50
|
+
|
|
51
|
+
```sh
|
|
52
|
+
aih checkpoint change-id --report handoff.json
|
|
53
|
+
aih resume change-id
|
|
54
|
+
aih checkpoint change-id --report next-handoff.json --expected <prior-checkpoint-sha256>
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
Checkpoint requires an existing change and intact installation. Baseline/evidence paths are project-relative, local regular files with SHA-256 and 1 MiB limits. Completed tasks/operations need evidence; receipts are producer-declared. Replacements require the observed previous digest and preserve previous bytes in checkpoint-history. This is trusted-workspace compare-before-write, not a cross-host database transaction.
|
|
58
|
+
|
|
59
|
+
Resume is read-only: flag stale baseline and unknown/prepared side effects; check actual source/remote state before retry. Do not recreate PRs/publications whose outcome is unknown. External source revisions are declarations and need host reconciliation. Omit usage or use null when unknown; measured cost needs source/currency. Evidence drift blocks recovery until reconciled. Interrupted work before a checkpoint may still need reconstruction.
|
|
60
|
+
|
|
61
|
+
## Verification, evaluation and rollback
|
|
62
|
+
Use existing adaptive verification/report/TechSpec contracts and source-write policy. UAT and operational feedback update the existing backlog/proposal, not accepted scope automatically. BA domain work includes glossary/data dictionary/state/decision tables when relevant. Required runtime/source publication checks stay BLOCKED/NOT_RUN when inaccessible.
|
|
63
|
+
|
|
64
|
+
Local tests and real tarball smoke validate contracts, preservation, drift, alias routes and recovery; live agents remain unscored until authorized host/model/budget. For 18-run manually entered comparison use [real-task protocol](../evals/real-task-comparison.md) and scripts/compare-tasks.js; missing observations remain null.
|
|
65
|
+
|
|
66
|
+
Review update --dry-run/update/check, snapshot Git diff and changed catalog. No custom configs, source documents, native settings or work records are automatically migrated. Re-export eval reports because bundle/dataset hashes change. Revert the consumer snapshot commit to roll back. Suggested next release is minor with retained old module/role/template routes and explicit retired-skill migration; consumers depending on retired recipes must review this behavioral change before upgrading.
|
package/docs/agent-handoffs.md
CHANGED
|
@@ -104,3 +104,7 @@ scoped context, round checkpoint and actual checks; do not claim JSON enforced t
|
|
|
104
104
|
## Resume and lifecycle
|
|
105
105
|
|
|
106
106
|
Use [Continuous development](continuous-development.md). Store baseline/tested revisions, decisions, blockers, remaining work and next action in the existing OpenSpec tasks handoff. Re-read actual sources on resume and invalidate affected stale evidence. Keep implementation complete, merged and released distinct; supplied feedback remains proposed scope until accepted.
|
|
107
|
+
|
|
108
|
+
## Agent-first routing and PM aliases
|
|
109
|
+
|
|
110
|
+
[Canonical Project Manager](../core/agents/project-manager.md) owns delivery. Product/Delivery PM IDs are compatibility aliases; route by canonical_id, not separate workers. Analysis/Discovery agents use canonical Product contracts above. Preferred skills are explicit; optional perspectives need not be installed. See [Agent-first migration](agent-first.md).
|
package/docs/architecture.md
CHANGED
|
@@ -152,3 +152,17 @@ See [Adaptive verification and TechSpec](adaptive-verification.md) for read-only
|
|
|
152
152
|
## Continuous development
|
|
153
153
|
|
|
154
154
|
The [continuous-development workflow](continuous-development.md) composes existing Core and optional Product/Architecture/Delivery contracts. Baseline/impact and handoff sections extend existing OpenSpec Markdown templates; no schema, runtime, state store or CLI command is added. Hosts reconcile revisions and perform authorized section edits; structural readiness cannot enforce semantic freshness.
|
|
155
|
+
|
|
156
|
+
## Agent-first changes (unreleased)
|
|
157
|
+
|
|
158
|
+
Optional capability profiles declare asset_owner for a canonical owner; loading validates subset membership, and installation vendors canonical assets while exposing selected skills once. Optional agent/template aliases retain old IDs/routes. Root CLAUDE managed import and native skill wrappers are opt-in locked payloads; external native settings remain project-owned. Checkpoint commands store declarations/history and compute local drift without a runtime/state server. See [Agent-first migration](agent-first.md).
|
|
159
|
+
|
|
160
|
+
## Guided intake and portable configuration
|
|
161
|
+
|
|
162
|
+
start uses terminal prompts or a non-TTY plan with saved user-owned start.json; canonical source/output
|
|
163
|
+
declarations remain artifacts.json. backup exports an allowlisted, bounded UTF-8 config archive only.
|
|
164
|
+
restore validates schema/digests/configs/paths, previews conflicts, requires explicit replacement and
|
|
165
|
+
saves a before-backup through the same installation guard/rollback machinery. Transfer copies only
|
|
166
|
+
project/agent preferences and removes repository autonomy. No credentials, machine paths, locked
|
|
167
|
+
payload, custom skills or checkpoint/document contents are exported. Full repo recovery remains Git
|
|
168
|
+
and external-source backup. See [Configuration backup](configuration-backup.md).
|
package/docs/cli.md
CHANGED
|
@@ -159,3 +159,24 @@ local fallback. Configured output contracts require reviewed artifact-impact.jso
|
|
|
159
159
|
review stage requires declared completion/evidence. No remote calls, source writes or approval claims.
|
|
160
160
|
|
|
161
161
|
See [Adaptive verification and TechSpec](adaptive-verification.md) for read-only discovery, evidence reports and selective technical documentation.
|
|
162
|
+
|
|
163
|
+
## Agent-first additions (unreleased)
|
|
164
|
+
|
|
165
|
+
aih agents shows canonical IDs, skill preferences and model declarations. init --host claude-code seeds a native preset only when agents.json is absent. init/update --link-claude and --claude-skills opt in to managed import/wrappers; native settings remain user-owned. checkpoint <id> --report saves project-owned recovery state; --expected supplies prior digest for replacement. resume <id> is read-only. See [Agent-first guide](agent-first.md). No command launches agents, probes providers, merges or measures quota.
|
|
166
|
+
|
|
167
|
+
## Start, backup và restore (bản nâng cấp này)
|
|
168
|
+
|
|
169
|
+
| Lệnh | Hành vi |
|
|
170
|
+
| --- | --- |
|
|
171
|
+
| `aih start` | Terminal: intake ngắn; không TTY: read-only plan; trả host_prompt |
|
|
172
|
+
| `aih start --goal docs --task "Implement requirements" --input docs/requirements --output docs/specs` | Lưu task và seed nguồn/output còn thiếu |
|
|
173
|
+
| `aih backup [--output backups/config.json]` | Export 8 file cấu hình dùng chung; không ghi đè archive |
|
|
174
|
+
| `aih restore --from config.json --dry-run` | Kiểm tra schema/digest và xem file/conflict trước ghi |
|
|
175
|
+
| `aih restore --from config.json [--replace]` | Phục hồi cùng dự án, tự backup trước thay file khác nội dung |
|
|
176
|
+
| `aih restore --from config.json --transfer` | Chuyển module/model; bỏ repo autonomy và nguồn/task/domain/command cũ |
|
|
177
|
+
|
|
178
|
+
Tất cả nhận --target. Đường dẫn --from/--output tính từ project root. --host dùng với start;
|
|
179
|
+
--change chỉ cho start --goal resume. Các flags sai command bị từ chối. Lệnh --dry-run thuộc restore
|
|
180
|
+
không đổi target hoặc chờ stdin. Fresh repo restore trước init; installed repo update/check sau khi
|
|
181
|
+
selection đổi. Đọc [Start](start.md) và [Configuration backup](configuration-backup.md) cho giới hạn,
|
|
182
|
+
phục hồi checkpoint và rollback. Các lệnh không truy cập remote, chạy model, cấp quyền hay auto-merge.
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
# Lưu cấu hình, backup và chuyển dự án
|
|
2
|
+
|
|
3
|
+
Các lệnh dưới đây dùng `aih` khi đã cài global. Nếu dùng npx, thay `aih` bằng
|
|
4
|
+
`npx --yes @manhd_d/ai-harness`. Những lệnh start/backup/restore thuộc bản nâng cấp này;
|
|
5
|
+
chỉ dùng với bản đã phát hành có các lệnh đó, hoặc checkout/package đã review.
|
|
6
|
+
|
|
7
|
+
## Thông tin của bạn nằm ở đâu?
|
|
8
|
+
|
|
9
|
+
Ở **repo dự án áp dụng Harness**, phần cấu hình dùng chung nằm trong `.harness/`:
|
|
10
|
+
|
|
11
|
+
| File | Thông tin người dùng | Khi update |
|
|
12
|
+
| --- | --- | --- |
|
|
13
|
+
| `.harness/project.json` | Adapter/capability đã chọn | Giữ nguyên |
|
|
14
|
+
| `.harness/agents.json` | Agent → provider/model/reasoning, execution preferences | Giữ nguyên |
|
|
15
|
+
| `.harness/start.json` | Mục tiêu, task, ID change cần tiếp tục | Giữ nguyên |
|
|
16
|
+
| `.harness/artifacts.json` | Đường dẫn/link input, nơi ghi output, owner, revision, write policy | Giữ nguyên |
|
|
17
|
+
| `.harness/integrations.json` | Tên kết nối của host và phạm vi khai báo | Giữ nguyên |
|
|
18
|
+
| `.harness/environment.json` | Tool/lệnh test và tham chiếu biến môi trường | Giữ nguyên |
|
|
19
|
+
| `.harness/local.md` | Nghiệp vụ, convention và quyết định đã chốt | Giữ nguyên |
|
|
20
|
+
| `openspec/config.yaml` | Cấu hình OpenSpec của dự án | Giữ nguyên |
|
|
21
|
+
| `.harness/machine.json` | Đường dẫn chỉ dùng trên máy này | Giữ nguyên, Git ignore; không vào backup cấu hình |
|
|
22
|
+
| `openspec/changes/<id>/` | Spec, tiến độ, checkpoint/history và evidence | Giữ nguyên; backup cùng repo |
|
|
23
|
+
|
|
24
|
+
**Input/output thực tế nằm ở nơi `artifacts.json` chỉ định**, ví dụ `docs/requirements/`,
|
|
25
|
+
`docs/specs/`, Confluence hoặc Figma. Cấu hình lưu liên kết; không sao chép nội dung nguồn bên ngoài.
|
|
26
|
+
Các skill riêng và native config của AI tool cũng cần giữ cùng cơ chế backup phù hợp của bạn.
|
|
27
|
+
|
|
28
|
+
`.harness/core/`, `adapters/`, `capabilities/`, `templates/`, `integrations/` và `lock.json`
|
|
29
|
+
là snapshot do Harness quản lý. Không sửa các file này để tùy biến. Giữ toàn bộ repo trong Git
|
|
30
|
+
để rollback snapshot chính xác; bản backup cấu hình chỉ chứa các file được liệt kê bên dưới.
|
|
31
|
+
Không lưu API key/token/password trong cấu hình; host/secret manager quản lý chúng riêng.
|
|
32
|
+
|
|
33
|
+
## Backup trước update hoặc cài lại
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
aih backup
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
CLI trả đường dẫn `.harness/backups/config-<timestamp>-<id>.json`. **Copy file này ra nơi riêng
|
|
40
|
+
ngoài repo/máy**, ví dụ ổ backup hoặc kho riêng của bạn; file ở máy hiện tại chưa bảo vệ khỏi mất máy.
|
|
41
|
+
Muốn tên dễ nhớ:
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
aih backup --output backups/harness-config.json
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Đường dẫn CLI tính từ project root; không dùng đường dẫn tuyệt đối. CLI từ chối ghi đè backup đã có.
|
|
48
|
+
Archive JSON giữ nguyên bytes UTF-8 của 8 file dùng chung ở bảng (nếu hiện có), kèm schema version,
|
|
49
|
+
CLI version và SHA-256 từng file. Digest phát hiện sửa nhầm, không xác thực nguồn backup.
|
|
50
|
+
Review file trước khi chia sẻ; bản backup là plain text và không tự dò/xóa mọi secret bạn có thể đã ghi nhầm.
|
|
51
|
+
Folder mặc định `.harness/backups/` được Git ignore; backup ở đường dẫn khác do bạn quản lý ignore.
|
|
52
|
+
|
|
53
|
+
**Không có trong archive:** machine.json, biến môi trường/credentials, host login/native settings,
|
|
54
|
+
snapshot/lock, custom skills, code, nội dung docs/UI bên ngoài, OpenSpec changes/checkpoints/history/evidence.
|
|
55
|
+
Muốn phục hồi toàn bộ công việc, backup **repo + các nguồn/tài khoản ngoài repo** bằng cơ chế của bạn.
|
|
56
|
+
|
|
57
|
+
Update thông thường bảo toàn file dùng chung; không cần restore mỗi lần:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
aih backup
|
|
61
|
+
aih update --dry-run
|
|
62
|
+
aih update
|
|
63
|
+
aih check
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Trước đó hãy nâng CLI global lên phiên bản đã review nếu cần. CLI không tải bản mới khi chạy update.
|
|
67
|
+
|
|
68
|
+
## Phục hồi cùng dự án
|
|
69
|
+
|
|
70
|
+
Copy archive vào project root thành `harness-config.json`, rồi xem trước:
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
aih restore --from harness-config.json --dry-run
|
|
74
|
+
aih restore --from harness-config.json
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
File giống hệt được giữ nguyên, file thiếu được tạo. File khác nội dung **không bị ghi đè** nếu chưa
|
|
78
|
+
chọn `--replace`. Nếu muốn khôi phục bản cũ thay cho cấu hình hiện tại:
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
aih restore --from harness-config.json --dry-run --replace
|
|
82
|
+
aih restore --from harness-config.json --replace
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
Trước thay file, CLI tự tạo archive cấu hình hiện tại trong `.harness/backups/`; kết quả trả đường dẫn.
|
|
86
|
+
Không xóa file người dùng không có trong archive. Validation/schema/digest/path/conflict được kiểm tra
|
|
87
|
+
trước ghi; lỗi ghi thông thường rollback. Gián đoạn tiến trình/mất điện không phải transaction nhiều
|
|
88
|
+
file an toàn tuyệt đối: kiểm tra trạng thái và phục hồi từ backup/Git trước khi tiếp tục.
|
|
89
|
+
|
|
90
|
+
Với repo chưa có snapshot, **restore trước `init`** để bộ cài dùng đúng module và model đã lưu:
|
|
91
|
+
|
|
92
|
+
```bash
|
|
93
|
+
aih restore --from harness-config.json
|
|
94
|
+
aih init
|
|
95
|
+
aih check
|
|
96
|
+
aih doctor
|
|
97
|
+
aih start
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
Với repo đã cài, dùng `update --dry-run`, `update`, `check` sau restore nếu selection đổi.
|
|
101
|
+
Restore không sửa snapshot hỏng; phục hồi snapshot qua Git hoặc cài bundle đã review vào repo sạch.
|
|
102
|
+
Nếu goal đã lưu là resume, phục hồi OpenSpec changes/evidence trước khi chạy start/resume.
|
|
103
|
+
Schema archive/config chưa được hỗ trợ bị từ chối; không tự đổi schema hay hạ phiên bản. OpenSpec
|
|
104
|
+
config được giữ dạng text; correctness thuộc upstream OpenSpec validator.
|
|
105
|
+
|
|
106
|
+
## Mang sang dự án khác
|
|
107
|
+
|
|
108
|
+
Copy archive vào repo mới, dùng chế độ transfer:
|
|
109
|
+
|
|
110
|
+
```bash
|
|
111
|
+
aih restore --from harness-config.json --transfer --dry-run
|
|
112
|
+
aih restore --from harness-config.json --transfer
|
|
113
|
+
aih init
|
|
114
|
+
aih start
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
Transfer mang **project.json + agents.json**: adapter/capability và model/reasoning/execution preferences.
|
|
118
|
+
Khai báo autonomy gắn repo cũ bị loại bỏ. Task, domain facts, nguồn input/output, connection aliases,
|
|
119
|
+
commands, OpenSpec config và state không được chuyển. `start` giúp khai báo lại theo dự án mới.
|
|
120
|
+
Nếu repo mới đã có cấu hình khác, review conflict và chỉ dùng --replace khi muốn thay chúng.
|
|
121
|
+
Model đã khai báo vẫn cần host hỗ trợ; restore không đăng nhập, cấp quyền hoặc gọi API/provider.
|
|
122
|
+
Muốn dùng lại nguồn tài liệu cũ, khai báo rõ nguồn/revision/quyền truy cập tại dự án mới sau review.
|
|
@@ -86,3 +86,7 @@ records. `aih eval --scope all` exports scenarios; it does not run a model. Prod
|
|
|
86
86
|
its optional document templates/TechSpec skill. Existing docs/configs/changes are preserved on update;
|
|
87
87
|
add missing baseline/handoff sections selectively, do not regenerate old changes. Revert the consumer
|
|
88
88
|
installation commit to roll back; re-export evaluations after bundle hashes change.
|
|
89
|
+
|
|
90
|
+
## Agent-first checkpoint additions (unreleased)
|
|
91
|
+
|
|
92
|
+
Use aih agents for canonical responsibilities and preferred skills; load only needed perspectives. For a machine-readable meaningful-step handoff use aih checkpoint <id> --report file.json and aih resume <id>. Keep design/tasks/decisions and evidence authoritative; checkpoint references them instead of copying chat. Reconcile baseline drift and unknown side effects before retry; quota/usage remains unknown without actual host data. See [Agent-first guide](agent-first.md).
|
|
@@ -114,7 +114,7 @@ aih eval --scope all # dataset/review template, không gọi model
|
|
|
114
114
|
aih check
|
|
115
115
|
```
|
|
116
116
|
|
|
117
|
-
Dùng Core review/TDD và `harness-astro-performance` để ghi bằng chứng build/browser thực chạy,
|
|
117
|
+
Dùng Core review/TDD và `harness-astro-performance` để ghi bằng chứng build/browser thực chạy, và SA/approved ADR khi có yêu cầu deployment độc lập. Hoàn tất spec → code → tests → human PR review. Harness không deploy/merge tự động.
|
|
118
118
|
|
|
119
119
|
## Tài liệu chính thức
|
|
120
120
|
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schema_version": 1,
|
|
3
|
+
"change_id": "change-id",
|
|
4
|
+
"phase": "implementation",
|
|
5
|
+
"summary": "Draft handoff; replace with actual evidence",
|
|
6
|
+
"timestamp": "2026-10-13T10:00:00Z",
|
|
7
|
+
"baseline": [],
|
|
8
|
+
"completed": [],
|
|
9
|
+
"pending": [
|
|
10
|
+
{
|
|
11
|
+
"id": "task-1",
|
|
12
|
+
"summary": "Continue scoped work"
|
|
13
|
+
}
|
|
14
|
+
],
|
|
15
|
+
"in_progress": null,
|
|
16
|
+
"blockers": [],
|
|
17
|
+
"next_action": "Inspect actual baseline and populate references",
|
|
18
|
+
"external_sources": [],
|
|
19
|
+
"operations": []
|
|
20
|
+
}
|
|
@@ -56,13 +56,11 @@ Lệnh `new-change` **chỉ tạo draft**, không validate/approve spec. Gate: r
|
|
|
56
56
|
~~~bash
|
|
57
57
|
aih skill harness-java-spring-spring-api
|
|
58
58
|
aih skill harness-tdd
|
|
59
|
-
aih skill harness-
|
|
60
|
-
aih skill harness-java-spring-kafka-outbox
|
|
59
|
+
aih skill harness-review
|
|
61
60
|
~~~
|
|
62
61
|
|
|
63
62
|
- `spring-api`: controller/service/repository theo pattern hiện có, tenant-scope server-side, DTO và HTTP contract.
|
|
64
|
-
-
|
|
65
|
-
- `kafka-outbox`: chỉ dùng **khi có event publication**; transactional write, duplicate consumer delivery, retry/dead-letter.
|
|
63
|
+
- Schema, messaging và deployment choices theo approved SA/ADR và tooling thực tế. Khi chưa có quyết định quan trọng, SA đưa alternatives/trade-offs và hỏi owner trước implementation; không dùng recipe từ adapter.
|
|
66
64
|
- `harness-tdd`: negative auth test, missing resource, validation, successful request, regression. Không tạo implementation Kafka/DB nếu requirement không cần.
|
|
67
65
|
|
|
68
66
|
Lệnh verify ứng dụng **tùy repo** — dưới đây chỉ là ví dụ nếu có Maven wrapper:
|
package/docs/getting-started.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Bắt đầu với AI Harness
|
|
2
2
|
|
|
3
|
-
**Cài vào project → mở AI
|
|
3
|
+
**Cài vào project → start → mở AI làm việc → review kết quả.** Cần Node.js **22+** và một thư mục project. Với dự án mới, tạo thư mục/repository trước; Harness không tạo ứng dụng hay chạy model.
|
|
4
4
|
|
|
5
5
|
## 1. Cài vào project
|
|
6
6
|
|
|
@@ -31,9 +31,10 @@ npx --yes @manhd_d/ai-harness init --adapters java-spring --capabilities product
|
|
|
31
31
|
Thêm `--capabilities uiux` khi cần UI/UX; `monetization` cho website có quảng cáo. [Danh mục đầy đủ](cli.md).
|
|
32
32
|
Với project đã cài, đổi lựa chọn trong `.harness/project.json` rồi dùng `update`.
|
|
33
33
|
|
|
34
|
-
## 2.
|
|
34
|
+
## 2. Start và mở AI làm việc
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
Chạy `npx --yes @manhd_d/ai-harness start`: trả lời mục tiêu/input/output còn thiếu, rồi gửi
|
|
37
|
+
`host_prompt` từ kết quả vào AI tool đang mở project. [Luồng start](start.md). Nếu đã biết task, có thể gửi thẳng:
|
|
37
38
|
|
|
38
39
|
> Đọc AGENTS.md và .harness/local.md. Khảo sát code, tài liệu và lệnh test hiện có;
|
|
39
40
|
> ghi context còn thiếu vào .harness/local.md, chỉ hỏi phần chưa rõ.
|
|
@@ -41,7 +42,8 @@ Mở thư mục project trong công cụ AI, rồi gửi:
|
|
|
41
42
|
|
|
42
43
|
Bạn có thể giao ý tưởng, tài liệu BA hoặc task code. Không cần gọi từng agent/skill.
|
|
43
44
|
Với web/mobile, giao màn hình hoặc tính năng theo common/API/state/navigation hiện có; [skills đã có](frontend-mobile.md).
|
|
44
|
-
|
|
45
|
+
Xem [setup theo AI tool](tool-setup/README.md) cho Codex, Claude Code, Cursor, Copilot, Gemini CLI và Kiro:
|
|
46
|
+
phân biệt cài tool, cài Harness và kiểm tra instructions đã được đọc.
|
|
45
47
|
Lệnh `setup` chỉ xuất gợi ý thiết lập, không phải bước bắt buộc để bắt đầu.
|
|
46
48
|
|
|
47
49
|
Review diff và test, rồi commit `AGENTS.md`, `.harness/`, `.agents/skills/` cùng code.
|
|
@@ -64,7 +66,8 @@ Task nhỏ không cần bộ tài liệu đầy đủ. Không cần cài OpenSpe
|
|
|
64
66
|
|
|
65
67
|
`check` kiểm tra file Harness; `verify` xuất checklist. Code cần **test của project** và review thực tế.
|
|
66
68
|
|
|
67
|
-
Trước cập nhật, tạo branch và commit trạng thái hiện tại.
|
|
69
|
+
Trước cập nhật, tạo branch và commit trạng thái hiện tại. Chạy `npx --yes @manhd_d/ai-harness backup`
|
|
70
|
+
và copy JSON được trả về ra nơi riêng ngoài repo. [Lưu ở đâu, cài lại và chuyển dự án](configuration-backup.md). Xem trước, áp dụng rồi kiểm tra:
|
|
68
71
|
|
|
69
72
|
```bash
|
|
70
73
|
npx --yes @manhd_d/ai-harness@latest update --dry-run
|
|
@@ -80,6 +83,6 @@ Dùng thường xuyên có thể cài global: `npm install -g @manhd_d/ai-harnes
|
|
|
80
83
|
## Docs/UI destinations
|
|
81
84
|
For idea-driven or existing-doc work, ask the AI to reuse or clarify input/output destinations,
|
|
82
85
|
canonical owners and source-write scope. Record them in project-owned artifacts.json/integrations.json;
|
|
83
|
-
`
|
|
86
|
+
`npx --yes @manhd_d/ai-harness artifacts` shows declarations. See [Artifact contract](artifact-contract.md).
|
|
84
87
|
|
|
85
88
|
For successive features, bugfixes or a resumed session, give the host a normal request. It follows [Continuous development](continuous-development.md), rechecks the baseline and maintains only affected docs.
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# AI Harness
|
|
2
|
+
|
|
3
|
+
[English](../../README.md) · [Tiếng Việt](README.vi.md) · [简体中文](README.zh-CN.md) · **Español**
|
|
4
|
+
|
|
5
|
+
Agent workflows reutilizables para desarrollar software: **Requirements → Design → Code → Test → Review.**
|
|
6
|
+
|
|
7
|
+
Entrega una idea, docs existentes o un change request a tu AI coding tool. Harness ayuda a inspeccionar el proyecto, aclarar decisiones, implementar el scope aceptado y mantener los spec/docs afectados. Carga solo los roles y skills necesarios.
|
|
8
|
+
|
|
9
|
+
Los Core workflows sirven para cualquier proyecto. El stack support es opcional y no elige infrastructure ni architecture.
|
|
10
|
+
|
|
11
|
+
Requiere Node.js 22+. Ejecuta en el directorio del proyecto:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npx --yes @manhd_d/ai-harness init
|
|
15
|
+
npx --yes @manhd_d/ai-harness start
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Ejecuta `start` para comenzar con tus entradas y envía `host_prompt` a tu herramienta de IA. [Configuración, copia de seguridad y transferencia](../configuration-backup.md).
|
|
19
|
+
|
|
20
|
+
`npx` no instala el command global `aih`. Comprueba con `npx --yes @manhd_d/ai-harness check` y abre el mismo proyecto en tu AI tool. [Setup común](../tool-setup/README.md).
|
|
21
|
+
|
|
22
|
+
> Read AGENTS.md. Inspect this project and its approved decisions. Implement [task], run appropriate checks and maintain affected docs.
|
|
23
|
+
|
|
24
|
+
El host ejecuta tests y controla tools, delegation y permissions. MCP/connector/API pueden aportar input con acceso autorizado. init --detect identifica stacks compatibles; check comprueba la integrity de Harness.
|
|
25
|
+
|
|
26
|
+
| AI tool | Setup |
|
|
27
|
+
| --- | --- |
|
|
28
|
+
| **Codex** | [Guía](../tool-setup/codex.md) |
|
|
29
|
+
| **Claude Code** | [Guía](../tool-setup/claude-code.md) |
|
|
30
|
+
| **Cursor** | [Guía](../tool-setup/cursor.md) |
|
|
31
|
+
| **GitHub Copilot** | [Guía](../tool-setup/copilot.md) |
|
|
32
|
+
| **Gemini CLI** | [Guía](../tool-setup/gemini-cli.md) |
|
|
33
|
+
| **Kiro** | [Guía](../tool-setup/kiro.md) |
|
|
34
|
+
|
|
35
|
+
[Docs y ejemplos](../README.md) · [Getting started](../getting-started.md) · [Input/output](../artifact-contract.md) · [Agent configuration](../agent-configuration.md) · [Continuous development](../continuous-development.md) · [MIT](../../LICENSE)
|
package/docs/i18n/README.vi.md
CHANGED
|
@@ -1,57 +1,35 @@
|
|
|
1
1
|
# AI Harness
|
|
2
2
|
|
|
3
|
-
[English](../../README.md) · **Tiếng Việt**
|
|
3
|
+
[English](../../README.md) · **Tiếng Việt** · [简体中文](README.zh-CN.md) · [Español](README.es.md)
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Agent workflows tái sử dụng cho phát triển phần mềm: **Requirements → Design → Code → Test → Review.**
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Đưa ý tưởng, docs có sẵn hoặc change request cho AI coding tool. Harness giúp AI đọc project, làm rõ quyết định, triển khai scope đã chấp nhận và maintain spec/docs liên quan. Chỉ dùng roles và skills cần cho task.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
Core workflows dùng được với mọi project. Stack support là tùy chọn; không tự chọn infrastructure hay architecture.
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
| --- | --- |
|
|
13
|
-
| **BA / PO — Business analysis & product** | Từ ý tưởng hoặc docs có sẵn đến BRD, PRD, SRS, user stories và acceptance criteria. |
|
|
14
|
-
| **SA — Solution architecture** | Architecture, non-functional requirements, technical decisions và change-impact analysis. |
|
|
15
|
-
| **PM — Delivery planning** | Delivery phases, dependencies, risks và scope changes. |
|
|
16
|
-
| **Dev / QA — Implementation & testing** | Feature implementation, debugging, tests và code review theo project conventions. |
|
|
17
|
-
| **UI/UX & DevOps** | UI design, CI/CD, deployment và operations guidance khi cần. |
|
|
18
|
-
|
|
19
|
-
Hỗ trợ Spring Boot, React/Next.js, React Native/Expo, Python AI/RAG, Astro và Kubernetes.
|
|
20
|
-
Chỉ chọn phần cần dùng; task nhỏ không cần đủ bộ docs hay spec. [Chọn stack & module](../../docs/getting-started.md).
|
|
21
|
-
|
|
22
|
-
## Chạy ở đâu?
|
|
23
|
-
|
|
24
|
-
| Công cụ AI | Cách sử dụng | Hướng dẫn |
|
|
25
|
-
| --- | --- | --- |
|
|
26
|
-
| **Codex** | CLI hoặc extension trong IDE | [Cài đặt & thiết lập](../../docs/tool-setup/codex.md) |
|
|
27
|
-
| **Claude Code** | Chạy `claude` trong terminal của project | [Cài đặt & thiết lập](../../docs/tool-setup/claude-code.md) |
|
|
28
|
-
| **Cursor** | Mở project, giao việc trong Agent | [Cài đặt & thiết lập](../../docs/tool-setup/cursor.md) |
|
|
29
|
-
| **GitHub Copilot** | Agent trong IDE hoặc Copilot CLI | [Cài đặt & thiết lập](../../docs/tool-setup/copilot.md) |
|
|
30
|
-
| **Gemini CLI** | Chạy `gemini` trong terminal của project | [Cài đặt & thiết lập](../../docs/tool-setup/gemini-cli.md) |
|
|
31
|
-
|
|
32
|
-
Harness cài hướng dẫn; công cụ AI thực hiện công việc. Cách nạp hướng dẫn tùy công cụ, theo link trên.
|
|
33
|
-
|
|
34
|
-
## Quick start
|
|
35
|
-
|
|
36
|
-
Cần **Node.js 22+** và một công cụ AI ở bảng trên. Chạy trong thư mục project:
|
|
11
|
+
Cần Node.js 22+. Chạy trong project:
|
|
37
12
|
|
|
38
13
|
```bash
|
|
39
|
-
npx --yes @manhd_d/ai-harness init
|
|
14
|
+
npx --yes @manhd_d/ai-harness init
|
|
15
|
+
npx --yes @manhd_d/ai-harness start
|
|
40
16
|
```
|
|
41
17
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
> Đọc AGENTS.md, khảo sát project và ghi context cần thiết vào .harness/local.md.
|
|
45
|
-
> Thực hiện yêu cầu: [mô tả công việc]. Chạy test phù hợp và báo cáo kết quả.
|
|
18
|
+
Chạy `start` để được hướng dẫn theo input hiện có, rồi gửi `host_prompt` cho AI. [Cấu hình, backup và chuyển dự án](../configuration-backup.md).
|
|
46
19
|
|
|
47
|
-
|
|
48
|
-
Nếu `--detect` chưa nhận diện được stack, [chọn module thủ công](../../docs/getting-started.md).
|
|
49
|
-
`aih check` chỉ kiểm tra file Harness; tính năng đúng hay chưa cần test của project và review.
|
|
20
|
+
`npx` không cài global command `aih`. Kiểm tra bằng `npx --yes @manhd_d/ai-harness check`, rồi mở cùng project trong AI tool. [Setup chung](../tool-setup/README.md).
|
|
50
21
|
|
|
51
|
-
|
|
22
|
+
> Read AGENTS.md. Inspect this project and its approved decisions. Implement [task], run appropriate checks and maintain affected docs.
|
|
52
23
|
|
|
53
|
-
|
|
24
|
+
Host chạy tests và quản lý tools, delegation, permissions. MCP/connector/API có thể cung cấp input khi host có quyền truy cập. init --detect nhận diện stack hỗ trợ; check kiểm tra integrity của Harness.
|
|
54
25
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
[
|
|
26
|
+
| AI tool | Setup |
|
|
27
|
+
| --- | --- |
|
|
28
|
+
| **Codex** | [Hướng dẫn](../tool-setup/codex.md) |
|
|
29
|
+
| **Claude Code** | [Hướng dẫn](../tool-setup/claude-code.md) |
|
|
30
|
+
| **Cursor** | [Hướng dẫn](../tool-setup/cursor.md) |
|
|
31
|
+
| **GitHub Copilot** | [Hướng dẫn](../tool-setup/copilot.md) |
|
|
32
|
+
| **Gemini CLI** | [Hướng dẫn](../tool-setup/gemini-cli.md) |
|
|
33
|
+
| **Kiro** | [Hướng dẫn](../tool-setup/kiro.md) |
|
|
34
|
+
|
|
35
|
+
[Docs & examples](../README.md) · [Getting started](../getting-started.md) · [Input/output](../artifact-contract.md) · [Agent configuration](../agent-configuration.md) · [Continuous development](../continuous-development.md) · [MIT](../../LICENSE)
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# AI Harness
|
|
2
|
+
|
|
3
|
+
[English](../../README.md) · [Tiếng Việt](README.vi.md) · **简体中文** · [Español](README.es.md)
|
|
4
|
+
|
|
5
|
+
可复用的软件开发 Agent workflows: **Requirements → Design → Code → Test → Review.**
|
|
6
|
+
|
|
7
|
+
把想法、已有 docs 或 change request 交给 AI coding tool。Harness 帮助 AI 检查项目、澄清待定决策、实现已确认的 scope,并维护相关 spec/docs。只加载任务需要的 roles 和 skills。
|
|
8
|
+
|
|
9
|
+
Core workflows 可用于任何项目。Stack support 是可选的,不会自动选择 infrastructure 或 architecture。
|
|
10
|
+
|
|
11
|
+
需要 Node.js 22+。在项目目录运行:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npx --yes @manhd_d/ai-harness init
|
|
15
|
+
npx --yes @manhd_d/ai-harness start
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
运行 `start` 获取引导,然后将 `host_prompt` 发送给 AI 工具。[配置备份与项目迁移](../configuration-backup.md)。
|
|
19
|
+
|
|
20
|
+
`npx` 不会安装全局 `aih` command。使用 `npx --yes @manhd_d/ai-harness check` 检查,然后在 AI tool 中打开同一项目。[通用 Setup](../tool-setup/README.md)。
|
|
21
|
+
|
|
22
|
+
> Read AGENTS.md. Inspect this project and its approved decisions. Implement [task], run appropriate checks and maintain affected docs.
|
|
23
|
+
|
|
24
|
+
Host 执行 tests,并控制 tools、delegation 和 permissions。MCP/connector/API 可在 host 获得访问权限后提供 input。init --detect 用于支持的 stack;check 检查 Harness integrity。
|
|
25
|
+
|
|
26
|
+
| AI tool | Setup |
|
|
27
|
+
| --- | --- |
|
|
28
|
+
| **Codex** | [使用指南](../tool-setup/codex.md) |
|
|
29
|
+
| **Claude Code** | [使用指南](../tool-setup/claude-code.md) |
|
|
30
|
+
| **Cursor** | [使用指南](../tool-setup/cursor.md) |
|
|
31
|
+
| **GitHub Copilot** | [使用指南](../tool-setup/copilot.md) |
|
|
32
|
+
| **Gemini CLI** | [使用指南](../tool-setup/gemini-cli.md) |
|
|
33
|
+
| **Kiro** | [使用指南](../tool-setup/kiro.md) |
|
|
34
|
+
|
|
35
|
+
[Docs 与示例](../README.md) · [Getting started](../getting-started.md) · [Input/output](../artifact-contract.md) · [Agent configuration](../agent-configuration.md) · [Continuous development](../continuous-development.md) · [MIT](../../LICENSE)
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
| File | Nội dung | Git |
|
|
4
4
|
| --- | --- | --- |
|
|
5
|
+
| `.harness/start.json` | Mục tiêu/task và ID checkpoint nếu tiếp tục | Commit |
|
|
5
6
|
| `.harness/project.json` | Adapter/capability | Commit |
|
|
6
7
|
| `.harness/agents.json` | Provider/model/reasoning theo role, execution preferences và host mappings | Commit |
|
|
7
8
|
| `.harness/artifacts.json` | Input/output/storage, canonical ownership và source-write policy | Commit |
|
|
@@ -10,7 +11,7 @@
|
|
|
10
11
|
| `.harness/environment.json` | Công cụ, lệnh, file cần có | Commit |
|
|
11
12
|
| `.harness/machine.json` | Đường dẫn riêng của máy, tùy chọn | Ignore |
|
|
12
13
|
|
|
13
|
-
Init/update tạo environment rỗng nếu chưa có và thêm `/machine.json` vào cuối
|
|
14
|
+
Init/update tạo environment rỗng nếu chưa có và thêm `/backups/` và `/machine.json` vào cuối
|
|
14
15
|
`.harness/.gitignore`. File đã được Git track vẫn được track: ignore không xóa khỏi index/history.
|
|
15
16
|
CLI không tạo file machine và không đọc nội dung Maven settings. Không ghi mật khẩu/token vào các
|
|
16
17
|
file Harness; credentials thuộc cơ chế quản lý riêng của công cụ.
|
|
@@ -91,3 +92,10 @@ local.md đã trả lời. Setup không phải wizard nhập liệu và không t
|
|
|
91
92
|
Xem [Artifact contract](artifact-contract.md). `aih artifacts` báo khai báo; `aih setup` gợi ý hỏi
|
|
92
93
|
nơi lưu docs/UI nếu chưa biết. Các file này project-owned và được bảo toàn khi update; chúng không
|
|
93
94
|
kết nối MCP, cấp quyền hay chạy tool. Credentials và native host config nằm ngoài Git.
|
|
95
|
+
|
|
96
|
+
## Backup và dùng lại
|
|
97
|
+
|
|
98
|
+
Chạy `aih start` để lưu intake. File được bảo toàn khi update. Chạy `aih backup`, copy archive ngoài
|
|
99
|
+
repo; `aih restore --from <file> --dry-run` xem trước phục hồi. Dùng --transfer ở repo mới để chỉ
|
|
100
|
+
chuyển module/model, tránh nguồn/tiến độ cũ. [Hướng dẫn đầy đủ](configuration-backup.md) mô tả các
|
|
101
|
+
file được lưu, những gì không có trong backup, conflict/backup-before-replace và cách cài lại.
|