@plainconceptsplatform/agent-harness 3.5.0 → 3.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/LICENSE +21 -21
- package/README.md +471 -454
- package/cli/commands/join.js +259 -259
- package/cli/commands/migrate.js +310 -310
- package/cli/commands/shared.js +27 -27
- package/cli/commands/single.js +79 -79
- package/cli/commands/update.js +121 -121
- package/cli/commands/wizard.js +134 -134
- package/cli/fragments/archive/az.md +97 -97
- package/cli/fragments/archive/gh.md +96 -96
- package/cli/fragments/archive/gl.md +96 -96
- package/cli/fragments/archive/none.md +75 -75
- package/cli/fragments/guardrails/codegraph.md +5 -5
- package/cli/fragments/guardrails/humanizer.md +4 -4
- package/cli/fragments/guardrails/memory.md +4 -4
- package/cli/fragments/guardrails/rtk.md +3 -3
- package/cli/fragments/guardrails/simple-english.md +4 -4
- package/cli/fragments/ops-backlog/az.md +28 -28
- package/cli/fragments/ops-backlog/gh.md +28 -28
- package/cli/fragments/ops-backlog/jira.md +28 -28
- package/cli/fragments/ops-review/az.md +62 -62
- package/cli/fragments/ops-review/gh.md +51 -51
- package/cli/fragments/ops-review/gl.md +55 -55
- package/cli/fragments/ops-ship/az.md +81 -81
- package/cli/fragments/ops-ship/gh.md +67 -67
- package/cli/fragments/ops-ship/gl.md +84 -84
- package/cli/index.js +116 -116
- package/cli/presets/agents-content.json +34 -34
- package/cli/presets/browser.json +10 -10
- package/cli/presets/clean.json +21 -21
- package/cli/presets/models.json +68 -68
- package/cli/presets/optimization.json +32 -32
- package/cli/presets/platforms.json +76 -76
- package/cli/presets/source.json +23 -23
- package/cli/steps/browser/index.js +48 -48
- package/cli/steps/clean/index.js +120 -120
- package/cli/steps/copy/agents.js +120 -120
- package/cli/steps/copy/commands.js +79 -79
- package/cli/steps/copy/fullstack-engineer.js +89 -89
- package/cli/steps/copy/index.js +88 -88
- package/cli/steps/copy/opencode-json.js +324 -324
- package/cli/steps/copy/skills.js +316 -316
- package/cli/steps/metadata/index.js +115 -115
- package/cli/steps/models/format.js +88 -88
- package/cli/steps/models/index.js +64 -64
- package/cli/steps/models/write.js +38 -38
- package/cli/steps/openspec/index.js +136 -136
- package/cli/steps/optimization/codegraph.js +141 -141
- package/cli/steps/optimization/detect.js +66 -66
- package/cli/steps/optimization/humanizer.js +17 -17
- package/cli/steps/optimization/index.js +158 -158
- package/cli/steps/optimization/memory.js +91 -91
- package/cli/steps/optimization/patch-guardrails.js +111 -111
- package/cli/steps/optimization/simple-english.js +17 -17
- package/cli/steps/optimization/skills-lock.js +30 -30
- package/cli/steps/platform/index.js +109 -109
- package/cli/steps/source/index.js +123 -123
- package/cli/utils/agent-color.js +111 -111
- package/cli/utils/copy.js +134 -134
- package/cli/utils/exec-spinner.js +47 -47
- package/cli/utils/exec.js +134 -134
- package/cli/utils/legacy-check.js +30 -30
- package/cli/utils/models-cache.js +58 -58
- package/cli/utils/models-pricing.js +42 -42
- package/cli/utils/paths.js +81 -81
- package/cli/utils/process.js +3 -3
- package/cli/utils/terminal.js +6 -6
- package/cli/utils/update-manifest.js +75 -75
- package/harness/.opencode/_gitignore +10 -10
- package/harness/.opencode/commands/init.md +5 -5
- package/harness/.opencode/commands/make-architecture.md +5 -5
- package/harness/.opencode/commands/make-design.md +5 -5
- package/harness/.opencode/commands/make-engineer.md +5 -5
- package/harness/.opencode/commands/make-guardrails.md +5 -5
- package/harness/.opencode/commands/make-user-model.md +5 -5
- package/harness/.opencode/commands/ops-backlog.md +10 -10
- package/harness/.opencode/commands/ops-review.md +10 -10
- package/harness/.opencode/commands/ops-ship.md +9 -9
- package/harness/.opencode/commands/plan-apply.md +9 -9
- package/harness/.opencode/commands/plan-archive.md +7 -7
- package/harness/.opencode/commands/plan-explore.md +11 -11
- package/harness/.opencode/commands/plan-goal.md +5 -5
- package/harness/.opencode/commands/plan-propose.md +11 -11
- package/harness/.opencode/commands/plan-quick.md +7 -7
- package/harness/.opencode/commands/plan-story.md +11 -11
- package/harness/.opencode/commands/repo-audit.md +7 -7
- package/harness/.opencode/commands/repo-help.md +5 -5
- package/harness/.opencode/commands/repo-initialize.md +5 -5
- package/harness/.opencode/commands/repo-onboard.md +5 -5
- package/harness/.opencode/commands/repo-verify.md +5 -5
- package/harness/.opencode/package.json +5 -5
- package/harness/.opencode/plugins/pc-commit-coauthor.js +41 -0
- package/harness/.opencode/plugins/pc-subagent-monitor.js +184 -184
- package/harness/.opencode/plugins/pc-subagent-tiers.js +367 -367
- package/harness/.opencode/plugins/pc-system-reminders.js +404 -386
- package/harness/.opencode/scripts/check-diff.mjs +279 -252
- package/harness/.opencode/scripts/code-rules.mjs +288 -288
- package/harness/.opencode/scripts/platform-manifest.mjs +112 -0
- package/harness/AGENTS.md +49 -49
- package/harness/ARCHITECTURE.md +13 -13
- package/harness/DESIGN.md +13 -13
- package/harness/opencode.jsonc +36 -36
- package/harness/openspec/config.yaml +20 -20
- package/harness/skills-lock.json +17 -17
- package/package.json +14 -12
- package/skills/README.md +18 -18
- package/skills/agent-harness-cli/SKILL.md +86 -86
- package/skills/browser-automation/SKILL.md +72 -72
- package/skills/pc-guardrails-generic/SKILL.md +53 -53
- package/skills/pc-guardrails-project/SKILL.md +8 -8
- package/skills/pc-make-architecture/SKILL.md +33 -32
- package/skills/pc-make-architecture/structure-template.md +64 -64
- package/skills/pc-make-design/SKILL.md +45 -45
- package/skills/pc-make-engineer/SKILL.md +59 -59
- package/skills/pc-make-engineer/signal-mapping.md +53 -53
- package/skills/pc-make-engineer/template.md +36 -36
- package/skills/pc-make-guardrails/SKILL.md +44 -44
- package/skills/pc-make-guardrails/category-reference.md +112 -112
- package/skills/pc-make-merge-risk-assess/SKILL.md +70 -70
- package/skills/pc-make-merge-risk-assess/category-reference.md +114 -114
- package/skills/pc-make-user-model/SKILL.md +56 -56
- package/skills/pc-ops-ship/SKILL.md +22 -22
- package/skills/pc-plan-apply/SKILL.md +88 -88
- package/skills/pc-plan-apply/simple-mode.md +21 -21
- package/skills/pc-plan-archive/SKILL.md +66 -66
- package/skills/pc-plan-explore/SKILL.md +21 -21
- package/skills/pc-plan-goal/SKILL.md +91 -91
- package/skills/pc-plan-goal/branching.md +39 -39
- package/skills/pc-plan-goal/failure-policy.md +30 -30
- package/skills/pc-plan-goal/output-mode.md +10 -10
- package/skills/pc-plan-goal/output.md +71 -71
- package/skills/pc-plan-propose/SKILL.md +125 -125
- package/skills/pc-plan-propose/task-annotation.md +39 -39
- package/skills/pc-plan-quick/SKILL.md +46 -46
- package/skills/pc-plan-story/SKILL.md +93 -93
- package/skills/pc-repo-audit/SKILL.md +44 -44
- package/skills/pc-repo-help/SKILL.md +87 -87
- package/skills/pc-repo-initialize/SKILL.md +119 -119
- package/skills/pc-repo-onboard/SKILL.md +32 -32
- package/skills/pc-repo-verify/SKILL.md +150 -150
- package/skills/pc-userstory-az/SKILL.md +71 -71
- package/skills/pc-userstory-browser/SKILL.md +64 -64
- package/skills/pc-userstory-gh/SKILL.md +63 -63
- package/skills/pc-userstory-jira/SKILL.md +74 -74
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import fs from 'node:fs'
|
|
2
|
+
import path from 'node:path'
|
|
3
|
+
|
|
4
|
+
export const ANSWERS_FILE = '.copier-answers.yml'
|
|
5
|
+
export const MANIFEST_FILE = '.platform/manifest'
|
|
6
|
+
export const EXCEPTIONS_FILE = '.platform/exceptions.yml'
|
|
7
|
+
|
|
8
|
+
const escapeRegExp = text => text.replace(/[.*+?^${}()|[\]\\/]/g, '\\$&')
|
|
9
|
+
|
|
10
|
+
export function globToRegExp(glob) {
|
|
11
|
+
const directory = glob.endsWith('/')
|
|
12
|
+
const body = glob.replace(/\/$/, '')
|
|
13
|
+
const anchored = body.includes('/')
|
|
14
|
+
const pattern = body.replace(/^\//, '')
|
|
15
|
+
let source = ''
|
|
16
|
+
for (let i = 0; i < pattern.length; i++) {
|
|
17
|
+
const c = pattern[i]
|
|
18
|
+
if (c === '*' && pattern[i + 1] === '*' && (i === 0 || pattern[i - 1] === '/')) {
|
|
19
|
+
if (i + 2 === pattern.length) {
|
|
20
|
+
source += '.*'
|
|
21
|
+
i += 1
|
|
22
|
+
continue
|
|
23
|
+
}
|
|
24
|
+
if (pattern[i + 2] === '/') {
|
|
25
|
+
source += '(?:.*/)?'
|
|
26
|
+
i += 2
|
|
27
|
+
continue
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
if (c === '*') {
|
|
31
|
+
source += '[^/]*'
|
|
32
|
+
while (pattern[i + 1] === '*') i++
|
|
33
|
+
} else if (c === '?') source += '[^/]'
|
|
34
|
+
else if (c === '[' && pattern.indexOf(']', i + 2) !== -1) {
|
|
35
|
+
const end = pattern.indexOf(']', i + 2)
|
|
36
|
+
source += `[${pattern.slice(i + 1, end).replace(/^!/, '^')}]`
|
|
37
|
+
i = end
|
|
38
|
+
} else if (c === '\\' && i + 1 < pattern.length) source += escapeRegExp(pattern[++i])
|
|
39
|
+
else source += escapeRegExp(c)
|
|
40
|
+
}
|
|
41
|
+
return new RegExp(`^${anchored ? '' : '(?:.*/)?'}${source}${directory ? '/.*' : '(?:/.*)?'}$`)
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export function parseManifest(text) {
|
|
45
|
+
return text
|
|
46
|
+
.split(/\r?\n/)
|
|
47
|
+
.map(line => line.replace(/(?<!\\)\s+$/, ''))
|
|
48
|
+
.filter(line => line && !line.startsWith('#'))
|
|
49
|
+
.map(line => {
|
|
50
|
+
const negated = line.startsWith('!')
|
|
51
|
+
return { negated, regex: globToRegExp(negated ? line.slice(1) : line) }
|
|
52
|
+
})
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function matchesRules(rules, file) {
|
|
56
|
+
let matched = false
|
|
57
|
+
for (const rule of rules) if (rule.regex.test(file)) matched = !rule.negated
|
|
58
|
+
return matched
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
const scalar = raw => {
|
|
62
|
+
const value = raw.trim()
|
|
63
|
+
const quoted = value.match(/^(["'])(.*)\1$/)
|
|
64
|
+
return quoted ? quoted[2] : value.replace(/\s+#.*$/, '')
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export function parseExceptions(text) {
|
|
68
|
+
const exceptions = []
|
|
69
|
+
let current
|
|
70
|
+
for (const line of text.split(/\r?\n/)) {
|
|
71
|
+
if (!line.trim() || line.trim().startsWith('#') || /^exceptions:/.test(line)) continue
|
|
72
|
+
const item = line.match(/^\s*-\s+(.*)$/)
|
|
73
|
+
if (item) exceptions.push((current = {}))
|
|
74
|
+
const pair = (item ? item[1] : line).match(/^\s*([A-Za-z_]+):\s*(.*)$/)
|
|
75
|
+
if (pair && current) current[pair[1]] = scalar(pair[2])
|
|
76
|
+
}
|
|
77
|
+
return exceptions
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export function commitOf(answers) {
|
|
81
|
+
const match = answers?.match(/^_commit:\s*(.+)$/m)
|
|
82
|
+
return match ? scalar(match[1]) : null
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
const localDate = (now = new Date()) =>
|
|
86
|
+
`${now.getFullYear()}-${String(now.getMonth() + 1).padStart(2, '0')}-${String(now.getDate()).padStart(2, '0')}`
|
|
87
|
+
|
|
88
|
+
function readText(file) {
|
|
89
|
+
try {
|
|
90
|
+
return fs.readFileSync(file, 'utf8')
|
|
91
|
+
} catch {
|
|
92
|
+
return null
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
// A repository opts in by carrying both files; without them every caller behaves exactly as before.
|
|
97
|
+
export function loadPlatform(root) {
|
|
98
|
+
if (!fs.existsSync(path.join(root, ANSWERS_FILE))) return null
|
|
99
|
+
const manifest = readText(path.join(root, MANIFEST_FILE))
|
|
100
|
+
if (manifest == null) return null
|
|
101
|
+
return {
|
|
102
|
+
rules: parseManifest(manifest),
|
|
103
|
+
exceptions: parseExceptions(readText(path.join(root, EXCEPTIONS_FILE)) ?? ''),
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
export function isPlatformOwned(platform, file, today = localDate()) {
|
|
108
|
+
const relative = file.replace(/\\/g, '/').replace(/^\.\//, '')
|
|
109
|
+
if (!matchesRules(platform.rules, relative)) return false
|
|
110
|
+
return !platform.exceptions.some(e =>
|
|
111
|
+
typeof e.path === 'string' && /^\d{4}-\d{2}-\d{2}$/.test(e.expires ?? '') && e.expires >= today && globToRegExp(e.path).test(relative))
|
|
112
|
+
}
|
package/harness/AGENTS.md
CHANGED
|
@@ -1,49 +1,49 @@
|
|
|
1
|
-
# AGENTS.md
|
|
2
|
-
|
|
3
|
-
<!-- PC-NOT-INITIALIZED -->
|
|
4
|
-
|
|
5
|
-
# Agent operating guide
|
|
6
|
-
|
|
7
|
-
The operating contract for AI agents in this repository. Agent-agnostic: OpenCode, Claude Code, Codex, Gemini and others.
|
|
8
|
-
|
|
9
|
-
## Session context
|
|
10
|
-
|
|
11
|
-
Before a non-trivial change, read `AGENTS.md` for workflow rules, `ARCHITECTURE.md` for boundaries and component interactions, `DESIGN.md` for UI and design-system work, and the active OpenSpec change or the specification covering the area you are changing.
|
|
12
|
-
|
|
13
|
-
Command aliases: OpenSpec skills may reference `/opsx-propose`, `/opsx-apply`, `/opsx-archive`, or `/opsx-explore`. Always substitute them with the `pc-plan-propose`, `pc-plan-apply`, `pc-plan-archive`, and `pc-plan-explore` skills respectively. User-facing command names are `/plan-propose`, `/plan-apply`, `/plan-archive`, and `/plan-explore`. Never mention the `opsx-` names to the user.
|
|
14
|
-
|
|
15
|
-
## Workflow ownership
|
|
16
|
-
|
|
17
|
-
<!-- PC-PLATFORM-WORKFLOW-START -->
|
|
18
|
-
<!-- PC-PLATFORM-WORKFLOW-END -->
|
|
19
|
-
|
|
20
|
-
## Planning and execution
|
|
21
|
-
|
|
22
|
-
- Never combine an unrelated refactor with the work you were asked to do. It arrives under a message that does not mention it, and the reviewer approves both.
|
|
23
|
-
- Never introduce a new convention where the repository already has one, and never guess when requirements, architecture or a security constraint are unclear. Ask.
|
|
24
|
-
|
|
25
|
-
## Engineer selection
|
|
26
|
-
|
|
27
|
-
Inspect `.opencode/agents/*.md` before spawning. Prefer the most specialized custom engineer. `build` and `plan` are the only primaries and are never spawned; `fullstack-engineer` is the body they share and the fallback worker, so prefer a specialist over it. If no specialist matches, tell the user to create one with `/make-engineer`. Spawn only engineers present in that directory.
|
|
28
|
-
|
|
29
|
-
The `pc-plan-apply` skill is authoritative for subagent waves, dependency ordering, retries, and concurrency. A spawn past `agents.maxConcurrent` is denied (`pc-subagent-monitor`); a denied spawn is not a failed task, so re-issue it in the next wave.
|
|
30
|
-
|
|
31
|
-
## Tool and repository safety
|
|
32
|
-
|
|
33
|
-
- Never expose or commit secrets, credentials, tokens, or production data.
|
|
34
|
-
- Never overwrite a generated file, or uncommitted changes you did not make. The tree may be shared with a person and another agent.
|
|
35
|
-
- Never bypass a check, weaken a test, or silence a lint rule to reach a green result. A green run that was arranged is worse than a red one, because nobody looks again.
|
|
36
|
-
- Commit, push, open a pull request, change dependencies, or touch deployment configuration only with the user's explicit approval and the repository's stated process.
|
|
37
|
-
|
|
38
|
-
## Verification and completion
|
|
39
|
-
|
|
40
|
-
- Never call a bug fixed without a test that would have caught it, where one is practical.
|
|
41
|
-
- Never leave a specification, `ARCHITECTURE.md` or `DESIGN.md` asserting something this change made false.
|
|
42
|
-
- Never end on a blocker without naming it and the decision it needs. An unattended run that stops quietly looks like one that finished.
|
|
43
|
-
|
|
44
|
-
## Skills
|
|
45
|
-
|
|
46
|
-
Skills live in `.agents/skills/`. Always installed: `@pc-guardrails-generic`, `@pc-guardrails-project`, and `@browser-automation`. An entry under `## Abilities` is not a passive reference: call the `skill` tool once per `@skill-name`, guardrails first. Editing, shell and spawning stay blocked until you have (`pc-system-reminders`), and a loaded skill can require further loads.
|
|
47
|
-
|
|
48
|
-
<!-- PC-PLATFORM-SKILLS-GUIDE-START -->
|
|
49
|
-
<!-- PC-PLATFORM-SKILLS-GUIDE-END -->
|
|
1
|
+
# AGENTS.md
|
|
2
|
+
|
|
3
|
+
<!-- PC-NOT-INITIALIZED -->
|
|
4
|
+
|
|
5
|
+
# Agent operating guide
|
|
6
|
+
|
|
7
|
+
The operating contract for AI agents in this repository. Agent-agnostic: OpenCode, Claude Code, Codex, Gemini and others.
|
|
8
|
+
|
|
9
|
+
## Session context
|
|
10
|
+
|
|
11
|
+
Before a non-trivial change, read `AGENTS.md` for workflow rules, `ARCHITECTURE.md` for boundaries and component interactions, `DESIGN.md` for UI and design-system work, and the active OpenSpec change or the specification covering the area you are changing.
|
|
12
|
+
|
|
13
|
+
Command aliases: OpenSpec skills may reference `/opsx-propose`, `/opsx-apply`, `/opsx-archive`, or `/opsx-explore`. Always substitute them with the `pc-plan-propose`, `pc-plan-apply`, `pc-plan-archive`, and `pc-plan-explore` skills respectively. User-facing command names are `/plan-propose`, `/plan-apply`, `/plan-archive`, and `/plan-explore`. Never mention the `opsx-` names to the user.
|
|
14
|
+
|
|
15
|
+
## Workflow ownership
|
|
16
|
+
|
|
17
|
+
<!-- PC-PLATFORM-WORKFLOW-START -->
|
|
18
|
+
<!-- PC-PLATFORM-WORKFLOW-END -->
|
|
19
|
+
|
|
20
|
+
## Planning and execution
|
|
21
|
+
|
|
22
|
+
- Never combine an unrelated refactor with the work you were asked to do. It arrives under a message that does not mention it, and the reviewer approves both.
|
|
23
|
+
- Never introduce a new convention where the repository already has one, and never guess when requirements, architecture or a security constraint are unclear. Ask.
|
|
24
|
+
|
|
25
|
+
## Engineer selection
|
|
26
|
+
|
|
27
|
+
Inspect `.opencode/agents/*.md` before spawning. Prefer the most specialized custom engineer. `build` and `plan` are the only primaries and are never spawned; `fullstack-engineer` is the body they share and the fallback worker, so prefer a specialist over it. If no specialist matches, tell the user to create one with `/make-engineer`. Spawn only engineers present in that directory.
|
|
28
|
+
|
|
29
|
+
The `pc-plan-apply` skill is authoritative for subagent waves, dependency ordering, retries, and concurrency. A spawn past `agents.maxConcurrent` is denied (`pc-subagent-monitor`); a denied spawn is not a failed task, so re-issue it in the next wave.
|
|
30
|
+
|
|
31
|
+
## Tool and repository safety
|
|
32
|
+
|
|
33
|
+
- Never expose or commit secrets, credentials, tokens, or production data.
|
|
34
|
+
- Never overwrite a generated file, or uncommitted changes you did not make. The tree may be shared with a person and another agent.
|
|
35
|
+
- Never bypass a check, weaken a test, or silence a lint rule to reach a green result. A green run that was arranged is worse than a red one, because nobody looks again.
|
|
36
|
+
- Commit, push, open a pull request, change dependencies, or touch deployment configuration only with the user's explicit approval and the repository's stated process.
|
|
37
|
+
|
|
38
|
+
## Verification and completion
|
|
39
|
+
|
|
40
|
+
- Never call a bug fixed without a test that would have caught it, where one is practical.
|
|
41
|
+
- Never leave a specification, `ARCHITECTURE.md` or `DESIGN.md` asserting something this change made false.
|
|
42
|
+
- Never end on a blocker without naming it and the decision it needs. An unattended run that stops quietly looks like one that finished.
|
|
43
|
+
|
|
44
|
+
## Skills
|
|
45
|
+
|
|
46
|
+
Skills live in `.agents/skills/`. Always installed: `@pc-guardrails-generic`, `@pc-guardrails-project`, and `@browser-automation`. An entry under `## Abilities` is not a passive reference: call the `skill` tool once per `@skill-name`, guardrails first. Editing, shell and spawning stay blocked until you have (`pc-system-reminders`), and a loaded skill can require further loads.
|
|
47
|
+
|
|
48
|
+
<!-- PC-PLATFORM-SKILLS-GUIDE-START -->
|
|
49
|
+
<!-- PC-PLATFORM-SKILLS-GUIDE-END -->
|
package/harness/ARCHITECTURE.md
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
> NOT GENERATED YET
|
|
2
|
-
>
|
|
3
|
-
> This file has not been populated yet. It is intentionally empty.
|
|
4
|
-
>
|
|
5
|
-
> **If this is a greenfield project** (no codebase exists yet): skip this for now. Come back and run `/make-architecture` once you have meaningful code, structure, or infrastructure in place.
|
|
6
|
-
>
|
|
7
|
-
> **If this is a brownfield project** (existing codebase): run this command now to generate the architecture documentation:
|
|
8
|
-
>
|
|
9
|
-
> ```
|
|
10
|
-
> /make-architecture
|
|
11
|
-
> ```
|
|
12
|
-
>
|
|
13
|
-
> This command analyzes your folder structure, config files, routes, data models, integrations, and build setup, then writes a complete ARCHITECTURE.md covering components, data flow, tech stack, deployment, and more. It is safe to rerun any time the architecture changes significantly.
|
|
1
|
+
> NOT GENERATED YET
|
|
2
|
+
>
|
|
3
|
+
> This file has not been populated yet. It is intentionally empty.
|
|
4
|
+
>
|
|
5
|
+
> **If this is a greenfield project** (no codebase exists yet): skip this for now. Come back and run `/make-architecture` once you have meaningful code, structure, or infrastructure in place.
|
|
6
|
+
>
|
|
7
|
+
> **If this is a brownfield project** (existing codebase): run this command now to generate the architecture documentation:
|
|
8
|
+
>
|
|
9
|
+
> ```
|
|
10
|
+
> /make-architecture
|
|
11
|
+
> ```
|
|
12
|
+
>
|
|
13
|
+
> This command analyzes your folder structure, config files, routes, data models, integrations, and build setup, then writes a complete ARCHITECTURE.md covering components, data flow, tech stack, deployment, and more. It is safe to rerun any time the architecture changes significantly.
|
package/harness/DESIGN.md
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
> NOT GENERATED YET
|
|
2
|
-
>
|
|
3
|
-
> This file has not been populated yet. It is intentionally empty.
|
|
4
|
-
>
|
|
5
|
-
> **If this is a greenfield project** (no UI exists yet): skip this for now. Come back and run `/make-design` once you have a design system, UI components, or styles in place.
|
|
6
|
-
>
|
|
7
|
-
> **If this is a brownfield project** (existing UI/styles): run this command now to generate the design documentation:
|
|
8
|
-
>
|
|
9
|
-
> ```
|
|
10
|
-
> /make-design
|
|
11
|
-
> ```
|
|
12
|
-
>
|
|
13
|
-
> This command analyzes your CSS, Tailwind config, component files, and design tokens, then writes a complete DESIGN.md with structured YAML tokens and written design intent. It is safe to rerun any time your design system changes.
|
|
1
|
+
> NOT GENERATED YET
|
|
2
|
+
>
|
|
3
|
+
> This file has not been populated yet. It is intentionally empty.
|
|
4
|
+
>
|
|
5
|
+
> **If this is a greenfield project** (no UI exists yet): skip this for now. Come back and run `/make-design` once you have a design system, UI components, or styles in place.
|
|
6
|
+
>
|
|
7
|
+
> **If this is a brownfield project** (existing UI/styles): run this command now to generate the design documentation:
|
|
8
|
+
>
|
|
9
|
+
> ```
|
|
10
|
+
> /make-design
|
|
11
|
+
> ```
|
|
12
|
+
>
|
|
13
|
+
> This command analyzes your CSS, Tailwind config, component files, and design tokens, then writes a complete DESIGN.md with structured YAML tokens and written design intent. It is safe to rerun any time your design system changes.
|
package/harness/opencode.jsonc
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://opencode.ai/config.json",
|
|
3
|
-
"mcp": {
|
|
4
|
-
"servers": {
|
|
5
|
-
"agent-browser": {
|
|
6
|
-
"type": "local",
|
|
7
|
-
"command": ["agent-browser", "mcp", "--tools", "core"],
|
|
8
|
-
"disabled": false
|
|
9
|
-
}
|
|
10
|
-
},
|
|
11
|
-
"timeout": {
|
|
12
|
-
"catalog": 300000,
|
|
13
|
-
"execution": 300000
|
|
14
|
-
}
|
|
15
|
-
},
|
|
16
|
-
"compaction": {
|
|
17
|
-
"auto": true,
|
|
18
|
-
"buffer": 10000
|
|
19
|
-
},
|
|
20
|
-
"permissions": [
|
|
21
|
-
{ "action": "question", "resource": "*", "effect": "allow" },
|
|
22
|
-
{ "action": "skill", "resource": "*", "effect": "allow" }
|
|
23
|
-
],
|
|
24
|
-
"skills": [".agents/skills"],
|
|
25
|
-
"default_agent": "plan",
|
|
26
|
-
"agents": {
|
|
27
|
-
"build": { "mode": "primary" },
|
|
28
|
-
"plan": {
|
|
29
|
-
"mode": "primary",
|
|
30
|
-
"permissions": [
|
|
31
|
-
{ "action": "edit", "resource": "*", "effect": "deny" },
|
|
32
|
-
{ "action": "subagent", "resource": "*", "effect": "deny" }
|
|
33
|
-
]
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://opencode.ai/config.json",
|
|
3
|
+
"mcp": {
|
|
4
|
+
"servers": {
|
|
5
|
+
"agent-browser": {
|
|
6
|
+
"type": "local",
|
|
7
|
+
"command": ["agent-browser", "mcp", "--tools", "core"],
|
|
8
|
+
"disabled": false
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
"timeout": {
|
|
12
|
+
"catalog": 300000,
|
|
13
|
+
"execution": 300000
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"compaction": {
|
|
17
|
+
"auto": true,
|
|
18
|
+
"buffer": 10000
|
|
19
|
+
},
|
|
20
|
+
"permissions": [
|
|
21
|
+
{ "action": "question", "resource": "*", "effect": "allow" },
|
|
22
|
+
{ "action": "skill", "resource": "*", "effect": "allow" }
|
|
23
|
+
],
|
|
24
|
+
"skills": [".agents/skills"],
|
|
25
|
+
"default_agent": "plan",
|
|
26
|
+
"agents": {
|
|
27
|
+
"build": { "mode": "primary" },
|
|
28
|
+
"plan": {
|
|
29
|
+
"mode": "primary",
|
|
30
|
+
"permissions": [
|
|
31
|
+
{ "action": "edit", "resource": "*", "effect": "deny" },
|
|
32
|
+
{ "action": "subagent", "resource": "*", "effect": "deny" }
|
|
33
|
+
]
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
schema: spec-driven
|
|
2
|
-
|
|
3
|
-
# Project context (optional)
|
|
4
|
-
# This is shown to AI when creating artifacts.
|
|
5
|
-
# Add your tech stack, conventions, style guides, domain knowledge, etc.
|
|
6
|
-
# Example:
|
|
7
|
-
# context: |
|
|
8
|
-
# Tech stack: TypeScript, React, Node.js
|
|
9
|
-
# We use conventional commits
|
|
10
|
-
# Domain: e-commerce platform
|
|
11
|
-
|
|
12
|
-
# Per-artifact rules (optional)
|
|
13
|
-
# Add custom rules for specific artifacts.
|
|
14
|
-
# Example:
|
|
15
|
-
# rules:
|
|
16
|
-
# proposal:
|
|
17
|
-
# - Keep proposals under 500 words
|
|
18
|
-
# - Always include a "Non-goals" section
|
|
19
|
-
# tasks:
|
|
20
|
-
# - Break tasks into chunks of max 2 hours
|
|
1
|
+
schema: spec-driven
|
|
2
|
+
|
|
3
|
+
# Project context (optional)
|
|
4
|
+
# This is shown to AI when creating artifacts.
|
|
5
|
+
# Add your tech stack, conventions, style guides, domain knowledge, etc.
|
|
6
|
+
# Example:
|
|
7
|
+
# context: |
|
|
8
|
+
# Tech stack: TypeScript, React, Node.js
|
|
9
|
+
# We use conventional commits
|
|
10
|
+
# Domain: e-commerce platform
|
|
11
|
+
|
|
12
|
+
# Per-artifact rules (optional)
|
|
13
|
+
# Add custom rules for specific artifacts.
|
|
14
|
+
# Example:
|
|
15
|
+
# rules:
|
|
16
|
+
# proposal:
|
|
17
|
+
# - Keep proposals under 500 words
|
|
18
|
+
# - Always include a "Non-goals" section
|
|
19
|
+
# tasks:
|
|
20
|
+
# - Break tasks into chunks of max 2 hours
|
package/harness/skills-lock.json
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 1,
|
|
3
|
-
"skills": {
|
|
4
|
-
"find-skills": {
|
|
5
|
-
"source": "vercel-labs/skills",
|
|
6
|
-
"sourceType": "github",
|
|
7
|
-
"skillPath": "skills/find-skills/SKILL.md",
|
|
8
|
-
"computedHash": "781bd6d3f9b19f8c9af6b53d8d0e4876d0183841b565db34ca7092ffa412d111"
|
|
9
|
-
},
|
|
10
|
-
"user-story": {
|
|
11
|
-
"source": "deanpeters/product-manager-skills",
|
|
12
|
-
"sourceType": "github",
|
|
13
|
-
"skillPath": "skills/user-story/SKILL.md",
|
|
14
|
-
"computedHash": "user-story-placeholder"
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"version": 1,
|
|
3
|
+
"skills": {
|
|
4
|
+
"find-skills": {
|
|
5
|
+
"source": "vercel-labs/skills",
|
|
6
|
+
"sourceType": "github",
|
|
7
|
+
"skillPath": "skills/find-skills/SKILL.md",
|
|
8
|
+
"computedHash": "781bd6d3f9b19f8c9af6b53d8d0e4876d0183841b565db34ca7092ffa412d111"
|
|
9
|
+
},
|
|
10
|
+
"user-story": {
|
|
11
|
+
"source": "deanpeters/product-manager-skills",
|
|
12
|
+
"sourceType": "github",
|
|
13
|
+
"skillPath": "skills/user-story/SKILL.md",
|
|
14
|
+
"computedHash": "user-story-placeholder"
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plainconceptsplatform/agent-harness",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.7.0",
|
|
4
4
|
"description": "Installs the Plain Concepts Platform Harness into any codebase, and keeps it up to date. Wires OpenCode, OpenSpec, codegraph, and agentmemory into a multi-agent workflow that runs on native parallel subagents.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"opencode",
|
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
"engines": {
|
|
43
43
|
"node": ">=18"
|
|
44
44
|
},
|
|
45
|
+
"packageManager": "pnpm@11.10.0",
|
|
45
46
|
"dependencies": {
|
|
46
47
|
"@inquirer/prompts": "^7.0.0",
|
|
47
48
|
"chalk": "^5.0.0",
|
|
@@ -50,16 +51,6 @@
|
|
|
50
51
|
"jsonc-parser": "^3.3.1",
|
|
51
52
|
"ora": "^8.0.0"
|
|
52
53
|
},
|
|
53
|
-
"devDependencies": {
|
|
54
|
-
"@eslint/js": "^9.0.0",
|
|
55
|
-
"eslint": "^9.0.0",
|
|
56
|
-
"globals": "^15.0.0",
|
|
57
|
-
"markdownlint-cli2": "0.23.2",
|
|
58
|
-
"vitest": "^4.1.5"
|
|
59
|
-
},
|
|
60
|
-
"vitest": {
|
|
61
|
-
"environment": "node"
|
|
62
|
-
},
|
|
63
54
|
"scripts": {
|
|
64
55
|
"lint": "eslint .",
|
|
65
56
|
"lint:fix": "eslint . --fix",
|
|
@@ -67,7 +58,18 @@
|
|
|
67
58
|
"lint:md:fix": "markdownlint-cli2 --fix \"**/*.md\"",
|
|
68
59
|
"test": "vitest run",
|
|
69
60
|
"test:watch": "vitest",
|
|
61
|
+
"prepublishOnly": "npm run lint && npm run lint:md && npm run test",
|
|
70
62
|
"release:dry": "pnpm publish --dry-run --no-git-checks --access public",
|
|
71
63
|
"release": "pnpm publish --no-git-checks --access public"
|
|
64
|
+
},
|
|
65
|
+
"devDependencies": {
|
|
66
|
+
"@eslint/js": "^9.0.0",
|
|
67
|
+
"eslint": "^9.0.0",
|
|
68
|
+
"globals": "^15.0.0",
|
|
69
|
+
"markdownlint-cli2": "0.23.2",
|
|
70
|
+
"vitest": "^4.1.5"
|
|
71
|
+
},
|
|
72
|
+
"vitest": {
|
|
73
|
+
"environment": "node"
|
|
72
74
|
}
|
|
73
|
-
}
|
|
75
|
+
}
|
package/skills/README.md
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
# skills/
|
|
2
|
-
|
|
3
|
-
Two kinds of skills live here, both discoverable by `npx skills`:
|
|
4
|
-
|
|
5
|
-
| Kind | Directories | Purpose |
|
|
6
|
-
| --- | --- | --- |
|
|
7
|
-
| Installable `pc-*` + `browser-automation` | `pc-*`, `browser-automation` | What the CLI copies into a target project under `.agents/skills/` during onboarding. Plain Concepts' own skills. |
|
|
8
|
-
| CLI-self | `agent-harness-cli` | Skills for agents working on THIS CLI repo (driving `npx @plainconceptsplatform/agent-harness`). Never copied into target projects. |
|
|
9
|
-
|
|
10
|
-
Discoverability: any `SKILL.md` in a subdirectory here is auto-discovered by OpenCode, Claude Code, and `npx skills` (which scans `./skills/` as a recognized project-skill location).
|
|
11
|
-
|
|
12
|
-
## Using one
|
|
13
|
-
|
|
14
|
-
Point your agent at the directory, or copy a skill into wherever your tool discovers skills:
|
|
15
|
-
|
|
16
|
-
```bash
|
|
17
|
-
cp -r skills/agent-harness-cli ~/.claude/skills/
|
|
18
|
-
```
|
|
1
|
+
# skills/
|
|
2
|
+
|
|
3
|
+
Two kinds of skills live here, both discoverable by `npx skills`:
|
|
4
|
+
|
|
5
|
+
| Kind | Directories | Purpose |
|
|
6
|
+
| --- | --- | --- |
|
|
7
|
+
| Installable `pc-*` + `browser-automation` | `pc-*`, `browser-automation` | What the CLI copies into a target project under `.agents/skills/` during onboarding. Plain Concepts' own skills. |
|
|
8
|
+
| CLI-self | `agent-harness-cli` | Skills for agents working on THIS CLI repo (driving `npx @plainconceptsplatform/agent-harness`). Never copied into target projects. |
|
|
9
|
+
|
|
10
|
+
Discoverability: any `SKILL.md` in a subdirectory here is auto-discovered by OpenCode, Claude Code, and `npx skills` (which scans `./skills/` as a recognized project-skill location).
|
|
11
|
+
|
|
12
|
+
## Using one
|
|
13
|
+
|
|
14
|
+
Point your agent at the directory, or copy a skill into wherever your tool discovers skills:
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
cp -r skills/agent-harness-cli ~/.claude/skills/
|
|
18
|
+
```
|