agents-opencode
Advanced tools
@@ -77,6 +77,10 @@ --- | ||
| 1. Read `AGENTS.md` for project context and recent activity | ||
| 2. Review any prior content creation patterns and topics covered | ||
| 2. Read `state/session-state.json` for active goals/risks (if present) | ||
| 3. Read `handoff/latest.md` for continuation context (if present) | ||
| 4. Review any prior content creation patterns and topics covered | ||
| **At task completion:** | ||
| Update `AGENTS.md` with timestamped entry (latest first): | ||
| 1. Update `state/session-state.json` with content decisions, risks, and next actions (if state file is in use). | ||
| 2. Generate or refresh handoff packet using project tooling when content workflow phase changed. | ||
| 3. Then update `AGENTS.md` with timestamped entry (latest first): | ||
@@ -83,0 +87,0 @@ ```markdown |
@@ -136,6 +136,10 @@ --- | ||
| 1. Read `AGENTS.md` for project context and recent activity | ||
| 2. Review any established patterns and conventions from prior sessions | ||
| 2. Read `state/session-state.json` for active goals/risks (if present) | ||
| 3. Read `handoff/latest.md` for continuation context (if present) | ||
| 4. Review any established patterns and conventions from prior sessions | ||
| **At task completion:** | ||
| Update `AGENTS.md` with timestamped entry (latest first): | ||
| 1. Update `state/session-state.json` with implementation decisions, open risks, and next actions. | ||
| 2. Generate or refresh handoff packet using project tooling when implementation phase meaningfully changed. | ||
| 3. Then update `AGENTS.md` with timestamped entry (latest first): | ||
@@ -142,0 +146,0 @@ ```markdown |
| --- | ||
| description: Engineering Manager advisor for leadership decisions, team dynamics, and technical strategy | ||
| mode: primary | ||
| temperature: 0.3 | ||
| temperature: 0.25 | ||
| steps: 30 | ||
@@ -135,5 +135,11 @@ permission: | ||
| **At session start:** Read `AGENTS.md` for project context and review existing EM-related documents. | ||
| **At session start:** | ||
| 1. Read `AGENTS.md` for project context and review existing EM-related documents. | ||
| 2. Read `state/session-state.json` for active goals/risks (if present). | ||
| 3. Read `handoff/latest.md` for continuation context (if present). | ||
| **At task completion:** Update `AGENTS.md` with timestamped entry (latest first, 3-5 bullets max): | ||
| **At task completion:** | ||
| 1. Update `state/session-state.json` with key recommendations, risks, and next actions. | ||
| 2. Generate or refresh handoff packet using project tooling when advisory state changed. | ||
| 3. Then update `AGENTS.md` with timestamped entry (latest first, 3-5 bullets max): | ||
@@ -140,0 +146,0 @@ ```markdown |
@@ -221,2 +221,22 @@ --- | ||
| ## Progress Tracking for Long-Running Work | ||
| For complex or multi-phase tasks, include and maintain a status table in updates. | ||
| Use this format: | ||
| ```markdown | ||
| ## Workstream Status | ||
| | ID | Initiative | Impact / Effort | Status | Notes | | ||
| |---|---|---|---|---| | ||
| | S1 | [Initiative] | [High/Medium/Low] / [High/Medium/Low] | [✅ Done / 🔄 In Progress / ⏳ Planned / ⛔ Blocked] | [Short note] | | ||
| ``` | ||
| Update cadence: | ||
| - Include the table at plan start for long-running/complex tasks. | ||
| - Update status after each completed phase or loop cycle. | ||
| - Keep exactly one active item as `🔄 In Progress` where possible. | ||
| - Reflect blockers immediately with `⛔ Blocked` and mitigation options. | ||
| ## Safety & Validation | ||
@@ -242,6 +262,10 @@ - Verify each phase completes successfully | ||
| 1. Read `AGENTS.md` for project context and recent activity | ||
| 2. Apply successful orchestration patterns from previous sessions | ||
| 2. Read `state/session-state.json` for working memory (if present) | ||
| 3. Read `handoff/latest.md` for continuation context (if present) | ||
| 4. Apply successful orchestration patterns from previous sessions | ||
| **At task completion:** | ||
| Update `AGENTS.md` with timestamped entry (latest first): | ||
| 1. Refresh `state/session-state.json` with current phase, risks, decisions, and next actions. | ||
| 2. Generate or refresh handoff packet using project tooling when phase state changed. | ||
| 3. Then update `AGENTS.md` with timestamped entry (latest first): | ||
@@ -248,0 +272,0 @@ ```markdown |
@@ -181,6 +181,10 @@ --- | ||
| 1. Read `AGENTS.md` for project context and recent activity | ||
| 2. Review prior planning decisions and patterns | ||
| 2. Read `state/session-state.json` for active goals/risks (if present) | ||
| 3. Read `handoff/latest.md` for continuation context (if present) | ||
| 4. Review prior planning decisions and patterns | ||
| **At task completion:** | ||
| Update `AGENTS.md` with timestamped entry (latest first): | ||
| 1. Refresh `state/session-state.json` with planning decisions, risks, and recommended next actions. | ||
| 2. Generate or refresh handoff packet using project tooling when plan state changed. | ||
| 3. Then update `AGENTS.md` with timestamped entry (latest first): | ||
@@ -187,0 +191,0 @@ ```markdown |
+64
-0
@@ -23,2 +23,6 @@ #!/usr/bin/env node | ||
| const AGENT_DIR_LEGACY = 'agent'; | ||
| const PROJECT_TEMPLATE_FILES = [ | ||
| path.join('state', 'session-state.json'), | ||
| path.join('handoff', '.gitkeep'), | ||
| ]; | ||
@@ -426,2 +430,40 @@ function resolveAgentDirectory(opencodeDir) { | ||
| function installProjectTemplateFiles(sourceDir, scope, paths, backupSession) { | ||
| if (scope !== 'project') { | ||
| return { installedCount: 0, skippedCount: 0 }; | ||
| } | ||
| let installedCount = 0; | ||
| let skippedCount = 0; | ||
| for (const relativePath of PROJECT_TEMPLATE_FILES) { | ||
| const src = path.join(sourceDir, relativePath); | ||
| if (!fs.existsSync(src)) { | ||
| warning(`Project template source is missing: ${relativePath}`); | ||
| continue; | ||
| } | ||
| const dest = path.join(paths.rootDir, relativePath); | ||
| ensureDir(path.dirname(dest)); | ||
| if (fs.existsSync(dest)) { | ||
| skippedCount += 1; | ||
| continue; | ||
| } | ||
| try { | ||
| if (backupSession) { | ||
| backupSession.backupFile(dest, relativePath); | ||
| } | ||
| } catch { | ||
| // backup not required for first-write path | ||
| } | ||
| fs.copyFileSync(src, dest); | ||
| installedCount += 1; | ||
| } | ||
| return { installedCount, skippedCount }; | ||
| } | ||
| function mergeInstallerConfig(targetConfigPath, sourceConfig, onBeforeWrite) { | ||
@@ -755,2 +797,3 @@ const patch = { | ||
| const { | ||
| sourceDir, | ||
| sourceConfig, | ||
@@ -783,2 +826,12 @@ sourceOpencodeDir, | ||
| const templateResult = installProjectTemplateFiles(sourceDir, scope, paths, backupSession); | ||
| if (scope === 'project') { | ||
| if (templateResult.installedCount > 0) { | ||
| success(`✓ Installed ${templateResult.installedCount} project template file(s)`); | ||
| } | ||
| if (templateResult.skippedCount > 0) { | ||
| info(`Skipped ${templateResult.skippedCount} existing project template file(s)`); | ||
| } | ||
| } | ||
| if (languages) { | ||
@@ -815,2 +868,10 @@ filterLanguages(paths.opencodeDir, languages); | ||
| const managedFiles = buildManagedFilesFromSource(scope, sourceManagedFiles, paths); | ||
| if (scope === 'project') { | ||
| for (const templateRelativePath of PROJECT_TEMPLATE_FILES) { | ||
| const absoluteTemplatePath = path.join(paths.rootDir, templateRelativePath); | ||
| if (fs.existsSync(absoluteTemplatePath)) { | ||
| managedFiles.push(templateRelativePath); | ||
| } | ||
| } | ||
| } | ||
| const manifest = { | ||
@@ -1328,2 +1389,3 @@ schemaVersion: 1, | ||
| const ok = installScope({ | ||
| sourceDir, | ||
| sourceConfig, | ||
@@ -1366,2 +1428,3 @@ sourceOpencodeDir, | ||
| const ok = installScope({ | ||
| sourceDir, | ||
| sourceConfig, | ||
@@ -1381,2 +1444,3 @@ sourceOpencodeDir, | ||
| const ok = installScope({ | ||
| sourceDir, | ||
| sourceConfig, | ||
@@ -1383,0 +1447,0 @@ sourceOpencodeDir, |
+10
-1
| { | ||
| "name": "agents-opencode", | ||
| "version": "1.4.2", | ||
| "version": "1.5.0", | ||
| "description": "OpenCode Agents: Intelligent AI assistants for software development. Features 8 specialized agents, 14 coding standards, automated code review, documentation generation, and cross-platform installation. Supports .NET, Python, TypeScript, Flutter, Go, Java, Node.js, React, Ruby, and Rust with plan-first execution and context-aware assistance.", | ||
@@ -23,4 +23,13 @@ "files": [ | ||
| "validate:agents": "node scripts/validate-agents.js", | ||
| "validate:commands": "node scripts/validate-command-matrices.js", | ||
| "eval:agents": "node evals/harness/run-evals.js", | ||
| "eval:agents:json": "node evals/harness/run-evals.js --json --out evals/reports/latest.json", | ||
| "eval:agents:trend": "node scripts/compare-eval-trend.js --current evals/reports/latest.json --baseline evals/fixtures/eval-trend-baseline.json --out evals/reports/trend-summary.md", | ||
| "validate:installer": "node scripts/test-installer.js", | ||
| "validate:docs": "node scripts/validate-docs.js", | ||
| "validate:docs:external": "node scripts/validate-docs.js --external", | ||
| "validate:docs:external:allowlist": "node scripts/validate-docs.js --external --allowlist", | ||
| "validate:changelog": "node scripts/validate-changelog-labels.js", | ||
| "validate:session": "node scripts/validate-session-state.js", | ||
| "handoff:generate": "node scripts/generate-handoff.js --state state/session-state.json --out handoff/latest.md", | ||
| "validate:context": "node scripts/check-context-size.js", | ||
@@ -27,0 +36,0 @@ "validate:all": "npm run doctor" |
+15
-0
@@ -170,5 +170,20 @@ # OpenCode Agents | ||
| ## Agent Evals | ||
| - `npm run eval:agents` runs deterministic contract checks for agent and command metadata. | ||
| - `npm run eval:agents:json` writes machine-readable output to `evals/reports/latest.json`. | ||
| - These checks are integrated into doctor and CI validation summary gating. | ||
| ## Validation | ||
| - Run `npm run doctor` for the complete local validation suite. | ||
| - For full check mapping (local commands ↔ CI gates), see **[Compatibility](./docs/compatibility.md)**. | ||
| ## Docs | ||
| - **[Getting Started](./docs/getting-started.md)** | ||
| - **[Approval Gates](./docs/approval-gates.md)** | ||
| - **[Compatibility](./docs/compatibility.md)** | ||
| - **[Deprecation & Migration Policy](./docs/deprecation-migration.md)** | ||
| - **[State Management](./docs/state-management.md)** | ||
| - **[Full Documentation](https://shahboura.github.io/agents-opencode/)** |
251143
2.4%1248
4.61%189
8.62%