extra pt2
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
if status is-interactive
|
||||
# Commands to run in interactive sessions can go here
|
||||
# Commands to run in interactive sessions can go here
|
||||
end
|
||||
|
||||
fish_config theme choose "Catppuccin Mocha" --color-theme=dark
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"LuaSnip": { "branch": "master", "commit": "dae4f5aaa3574bd0c2b9dd20fb9542a02c10471c" },
|
||||
"catppuccin": { "branch": "main", "commit": "c4d475e4b5684747cde9b3f849186af7837d4397" },
|
||||
"catppuccin": { "branch": "main", "commit": "12c004cde3f36cb1d57242f1e6aac46b09a0e5b4" },
|
||||
"cmp-buffer": { "branch": "main", "commit": "b74fab3656eea9de20a9b8116afa3cfc4ec09657" },
|
||||
"cmp-nvim-lsp": { "branch": "main", "commit": "cbc7b02bb99fae35cb42f514762b89b5126651ef" },
|
||||
"cmp-path": { "branch": "main", "commit": "c642487086dbd9a93160e1679a1327be111cbc25" },
|
||||
@@ -15,9 +15,9 @@
|
||||
"mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" },
|
||||
"none-ls.nvim": { "branch": "main", "commit": "f61f46ded0ca9edce7a09b674f8e162d10921426" },
|
||||
"nvim-cmp": { "branch": "main", "commit": "da88697d7f45d16852c6b2769dc52387d1ddc45f" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "ead0f5f342d8d323441e7d4b88f0fc436a81ad5f" },
|
||||
"nvim-treesitter": { "branch": "main", "commit": "544320a9cf5d6bf539ec1cc54d393064015670c4" },
|
||||
"opencode.nvim": { "branch": "main", "commit": "7cae6b64cb2fe41bb515d9eec6e0da2494656706" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "2163c54bb6cfec53e3e555665ada945b8c8331b9" },
|
||||
"nvim-treesitter": { "branch": "main", "commit": "5cb05e1b0fa3c469958a2b26f36b3fe930af221c" },
|
||||
"opencode.nvim": { "branch": "main", "commit": "1088ee70dd997d785a1757d351c07407f0abfc9f" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
|
||||
"telescope-fzf-native.nvim": { "branch": "main", "commit": "6fea601bd2b694c6f2ae08a6c6fab14930c60e2c" },
|
||||
"telescope.nvim": { "branch": "master", "commit": "3333a52ff548ba0a68af6d8da1e54f9cd96e9179" }
|
||||
|
||||
36
.config/opencode/.memory/knowledge/conventions.md
Normal file
36
.config/opencode/.memory/knowledge/conventions.md
Normal file
@@ -0,0 +1,36 @@
|
||||
# Conventions
|
||||
|
||||
## File Organization
|
||||
|
||||
```
|
||||
~/.config/opencode/
|
||||
├── opencode.jsonc # Main config (default agent, plugins, permissions)
|
||||
├── AGENTS.md # Cross-tool instructions (single source of truth)
|
||||
├── CLAUDE.md -> AGENTS.md # Symlink for Claude
|
||||
├── .cursorrules -> AGENTS.md # Symlink for Cursor
|
||||
├── agents/ # Agent definitions
|
||||
│ ├── lead.md
|
||||
│ ├── coder.md
|
||||
│ ├── reviewer.md
|
||||
│ └── ...
|
||||
├── skills/ # Reusable skill modules
|
||||
│ └── doc-coverage/
|
||||
└── .memory/ # Persistent memory
|
||||
```
|
||||
|
||||
## Naming Conventions
|
||||
|
||||
- Agent files: `{role}.md` (e.g., `coder.md`, `reviewer.md`)
|
||||
- Plan files: `{feature}.md` (e.g., `memory-restructure.md`)
|
||||
- Research files: `{topic}.md` (e.g., `micode-memory-system.md`)
|
||||
- Gate files: `{feature}.md` (e.g., `auth-flow.md`)
|
||||
|
||||
## Memory Structure
|
||||
|
||||
See [Memory Structure](../manifest.yaml) for the canonical structure.
|
||||
|
||||
## Cross-Tool Instructions
|
||||
|
||||
- `AGENTS.md` is the single source of truth
|
||||
- All other instruction files are symlinks to it
|
||||
- Never edit symlinked files directly
|
||||
35
.config/opencode/.memory/knowledge/domain/concepts.md
Normal file
35
.config/opencode/.memory/knowledge/domain/concepts.md
Normal file
@@ -0,0 +1,35 @@
|
||||
# Domain Concepts
|
||||
|
||||
## Agent Roles
|
||||
|
||||
| Role | Responsibility |
|
||||
|------|----------------|
|
||||
| Lead | Primary orchestrator — decomposes work, delegates, synthesizes |
|
||||
| Coder | Implementation-focused coding |
|
||||
| Reviewer | Code quality, correctness, security review |
|
||||
| Tester | Functional and adversarial testing |
|
||||
| Explorer | Fast codebase mapping and discovery |
|
||||
| Researcher | Deep technical investigation |
|
||||
| Librarian | Documentation coverage and accuracy |
|
||||
| Critic | Pre-implementation gate and blocker resolution |
|
||||
| SME | Domain-specific consultation |
|
||||
| Designer | UI/UX interaction and visual guidance |
|
||||
|
||||
## Memory Categories
|
||||
|
||||
| Category | Purpose | Location |
|
||||
|----------|---------|----------|
|
||||
| Knowledge | Persistent project understanding | `.memory/knowledge/` |
|
||||
| Decisions | Architecture Decision Records | `.memory/decisions.md` |
|
||||
| Plans | Active implementation plans | `.memory/plans/` |
|
||||
| Research | Technical investigations | `.memory/research/` |
|
||||
| Gates | Quality gate records | `.memory/gates/` |
|
||||
| Sessions | Session continuity | `.memory/sessions/` |
|
||||
|
||||
## Quality Pipeline Flow
|
||||
|
||||
Standard flow: `explorer/researcher → coder → reviewer → tester → librarian`
|
||||
|
||||
Exceptions:
|
||||
- Tier 3: skips tester
|
||||
- Tier 1: adds security reviewer and adversarial tester
|
||||
@@ -1,4 +1,4 @@
|
||||
## Project Overview
|
||||
# Project Overview
|
||||
|
||||
This is the OpenCode agentic configuration for a multi-agent coding workflow. It defines agent roles, permissions, quality pipelines, and project memory conventions used across all projects that load this config.
|
||||
|
||||
@@ -10,7 +10,7 @@ This is the OpenCode agentic configuration for a multi-agent coding workflow. It
|
||||
|
||||
## Agent Architecture
|
||||
|
||||
10 agents with distinct roles, models, and permission profiles. See [Agent Roster in AGENTS.md](../AGENTS.md#agent-roster) for the full table.
|
||||
10 agents with distinct roles, models, and permission profiles. See [Agent Roster in AGENTS.md](../../AGENTS.md#agent-roster) for the full table.
|
||||
|
||||
### Permission Model
|
||||
|
||||
@@ -18,7 +18,7 @@ This is the OpenCode agentic configuration for a multi-agent coding workflow. It
|
||||
- **Memory-only edit access:** `reviewer`, `tester`, `explorer`, `researcher`, `critic`, `sme`, `designer` — these agents have `permission.edit: allow` but are instructed to keep code/source edits read-only. Their edit permission exists solely to support `.memory/*` writes for recording duties (verdicts, discoveries, research, guidance, design decisions).
|
||||
- **No edit access:** none (all agents can write `.memory/*`).
|
||||
|
||||
See [Decision: Agent Memory Write Access](decisions.md#agent-memory-write-access) for rationale and guardrails.
|
||||
See [Decision: Agent Memory Write Access](../decisions.md#agent-memory-write-access) for rationale and guardrails.
|
||||
|
||||
### Memory Write Guardrails
|
||||
|
||||
@@ -37,10 +37,4 @@ Tiered pipeline (Tier 1/2/3) defined in `agents/lead.md`. Standard flow: `explor
|
||||
- `skills/doc-coverage/SKILL.md` section `### 3. Instruction File` validates one canonical instruction file (`AGENTS.md`) plus symlink correctness for `CLAUDE.md`, `.cursorrules`, and `.github/copilot-instructions.md`, rather than treating all four as independently edited files.
|
||||
- The checklist explicitly flags duplication of `.memory/` tracking content (plans/research) inside instruction files as an anti-pattern.
|
||||
|
||||
See [Cross-Tool Instruction Files](../AGENTS.md#cross-tool-instruction-files) and [Doc coverage checklist section 3](../skills/doc-coverage/SKILL.md#3-instruction-file).
|
||||
|
||||
## MCP Servers
|
||||
|
||||
- **Context7:** Remote documentation lookup (`https://mcp.context7.com/mcp`)
|
||||
- **GitHub Grep:** Remote code search across public repos (`https://mcp.grep.app`)
|
||||
- **Playwright:** Local headless Chromium for UI testing
|
||||
See [Cross-Tool Instruction Files](../../AGENTS.md#cross-tool-instruction-files) and [Doc coverage checklist section 3](../skills/doc-coverage/SKILL.md#3-instruction-file).
|
||||
@@ -0,0 +1,21 @@
|
||||
# Error Handling Patterns
|
||||
|
||||
## Agent-Level Error Handling
|
||||
|
||||
Agents follow the retry circuit breaker pattern defined in `agents/lead.md`:
|
||||
|
||||
- After 3 coder rejections on the same task: revisit design, simplify, or consult SME
|
||||
- After 5 total failures: escalate to user (Tier-3 escalation)
|
||||
|
||||
## Memory Write Errors
|
||||
|
||||
Agents with memory-only edit access should:
|
||||
1. Write to `.memory/*` files for their recording duties
|
||||
2. If write fails, report to lead for escalation
|
||||
3. Never attempt to modify non-memory files as a workaround
|
||||
|
||||
## Quality Gate Failures
|
||||
|
||||
- Reviewer `CHANGES-REQUESTED` is a hard block — do not advance to tester
|
||||
- Reviewer `REJECTED` requires redesign — do not retry same approach
|
||||
- Tester `PARTIAL` is not a pass — either fix blocker or escalate to user
|
||||
27
.config/opencode/.memory/knowledge/patterns/logging.md
Normal file
27
.config/opencode/.memory/knowledge/patterns/logging.md
Normal file
@@ -0,0 +1,27 @@
|
||||
# Logging Patterns
|
||||
|
||||
## Agent Output Standards
|
||||
|
||||
Subagents must return actionable results, not status recaps:
|
||||
|
||||
| Agent | Expected Output |
|
||||
|-------|-----------------|
|
||||
| Explorer | File maps, edit points, dependency chains |
|
||||
| Researcher | Specific findings, code patterns, API details |
|
||||
| Tester | Test results with pass/fail counts and specific failures |
|
||||
| Reviewer | Structured verdict with findings and resolution status |
|
||||
|
||||
## Recording Discipline
|
||||
|
||||
Memory files preserve *knowledge*, not *activity logs*:
|
||||
|
||||
- ✅ Record: outcomes, decisions, discoveries, patterns
|
||||
- ❌ Don't record: phase transitions, status changes, ceremony checkpoints
|
||||
|
||||
## Verdict Tracking
|
||||
|
||||
All reviewer/tester findings must be tracked to resolution:
|
||||
|
||||
- Status flow: `OPEN → ASSIGNED → RESOLVED | WONTFIX`
|
||||
- Findings must not be silently dropped
|
||||
- Include unresolved findings in coder re-dispatch
|
||||
25
.config/opencode/.memory/knowledge/patterns/testing.md
Normal file
25
.config/opencode/.memory/knowledge/patterns/testing.md
Normal file
@@ -0,0 +1,25 @@
|
||||
# Testing Patterns
|
||||
|
||||
## Verification Tiers
|
||||
|
||||
| Tier | Scope | Pipeline |
|
||||
|------|-------|----------|
|
||||
| Tier 1 | New features, security-sensitive, multi-file refactors | coder → reviewer:correctness → reviewer:security → tester:standard → tester:adversarial |
|
||||
| Tier 2 | Moderate changes, UI updates, bug fixes | coder → reviewer:correctness → tester:standard |
|
||||
| Tier 3 | Single-file fixes, config tweaks, copy changes | coder → reviewer:correctness |
|
||||
|
||||
## Functional Verification Requirements
|
||||
|
||||
Static analysis is NOT verification. Every feature must be functionally verified:
|
||||
|
||||
- **API endpoints**: Real HTTP requests with response verification
|
||||
- **Frontend**: Browser-based or test-suite verification
|
||||
- **Full-stack**: End-to-end UI → API → DB → response cycle
|
||||
- **Bug fixes**: Reproduce bug, verify it no longer occurs
|
||||
|
||||
## What Does NOT Count as Verification
|
||||
|
||||
- ❌ Type checks (`tsc`, `bun run check`)
|
||||
- ❌ Linting (`eslint`, `ruff`)
|
||||
- ❌ Build succeeding
|
||||
- ❌ Reading code and concluding "this looks correct"
|
||||
22
.config/opencode/.memory/knowledge/tech-stack.md
Normal file
22
.config/opencode/.memory/knowledge/tech-stack.md
Normal file
@@ -0,0 +1,22 @@
|
||||
# Tech Stack
|
||||
|
||||
## Core Technologies
|
||||
|
||||
| Component | Technology | Notes |
|
||||
|-----------|------------|-------|
|
||||
| Runtime | OpenCode CLI | Agentic coding tool |
|
||||
| Config format | JSONC | `opencode.jsonc` with comments |
|
||||
| Agent definitions | Markdown + YAML frontmatter | `agents/*.md` |
|
||||
| Memory system | Markdown + YAML | `.memory/` directory |
|
||||
|
||||
## MCP Servers
|
||||
|
||||
| Server | Purpose | Endpoint |
|
||||
|--------|---------|----------|
|
||||
| Context7 | Remote documentation lookup | `https://mcp.context7.com/mcp` |
|
||||
| GitHub Grep | Remote code search across public repos | `https://mcp.grep.app` |
|
||||
| Playwright | Local headless Chromium for UI testing | Local |
|
||||
|
||||
## Model Assignments
|
||||
|
||||
See [Agent Roster](../../AGENTS.md#agent-roster) for model assignments per agent role.
|
||||
55
.config/opencode/.memory/manifest.yaml
Normal file
55
.config/opencode/.memory/manifest.yaml
Normal file
@@ -0,0 +1,55 @@
|
||||
name: opencode-config
|
||||
version: 1
|
||||
categories:
|
||||
# System
|
||||
- path: system.md
|
||||
description: One-paragraph project overview and elevator pitch
|
||||
group: system
|
||||
|
||||
# Knowledge
|
||||
- path: knowledge/overview.md
|
||||
description: Project architecture, agent roles, and quality pipeline
|
||||
group: knowledge
|
||||
- path: knowledge/tech-stack.md
|
||||
description: Technologies, versions, dependencies, and MCP servers
|
||||
group: knowledge
|
||||
- path: knowledge/conventions.md
|
||||
description: Coding style, naming patterns, and file organization
|
||||
group: knowledge
|
||||
- path: knowledge/patterns/error-handling.md
|
||||
description: Error handling and recovery patterns
|
||||
group: knowledge
|
||||
- path: knowledge/patterns/testing.md
|
||||
description: Testing strategies and patterns
|
||||
group: knowledge
|
||||
- path: knowledge/patterns/logging.md
|
||||
description: Logging practices and conventions
|
||||
group: knowledge
|
||||
- path: knowledge/domain/concepts.md
|
||||
description: Domain-specific terminology and workflows
|
||||
group: knowledge
|
||||
|
||||
# Decisions
|
||||
- path: decisions.md
|
||||
description: Architecture Decision Records (ADRs)
|
||||
group: decisions
|
||||
|
||||
# Gates
|
||||
- path: gates/
|
||||
description: Quality gate records (review and test outcomes per feature)
|
||||
group: gates
|
||||
|
||||
# Plans
|
||||
- path: plans/agent-memory-write-access.md
|
||||
description: Plan for enabling memory write access for recording agents
|
||||
group: plans
|
||||
|
||||
# Research
|
||||
- path: research/
|
||||
description: Research findings and technical investigations
|
||||
group: research
|
||||
|
||||
# Sessions
|
||||
- path: sessions/continuity.md
|
||||
description: Rolling session continuity notes
|
||||
group: sessions
|
||||
34
.config/opencode/.memory/sessions/continuity.md
Normal file
34
.config/opencode/.memory/sessions/continuity.md
Normal file
@@ -0,0 +1,34 @@
|
||||
# Session Continuity
|
||||
|
||||
Rolling notes for maintaining context across sessions.
|
||||
|
||||
## Current Focus
|
||||
|
||||
<!-- Update this section at session start/end -->
|
||||
|
||||
-
|
||||
|
||||
## Recent Changes
|
||||
|
||||
<!-- Record significant changes with dates -->
|
||||
|
||||
| Date | Change |
|
||||
|------|--------|
|
||||
| 2026-03-09 | Restructured `.memory/` to nested structure with manifest.yaml index |
|
||||
|
||||
## Open Items
|
||||
|
||||
<!-- Items to address in future sessions -->
|
||||
|
||||
-
|
||||
|
||||
## Decisions Pending
|
||||
|
||||
<!-- Decisions that need user input or further investigation -->
|
||||
|
||||
-
|
||||
|
||||
## Notes
|
||||
|
||||
<!-- Free-form notes for next session -->
|
||||
|
||||
1
.config/opencode/.memory/system.md
Normal file
1
.config/opencode/.memory/system.md
Normal file
@@ -0,0 +1 @@
|
||||
OpenCode agentic configuration for multi-agent coding workflows. Defines 10 agent roles with distinct models and permissions, tiered quality pipelines (reviewer → tester), and a persistent memory system for knowledge, decisions, and plans. Used as a global template across all projects. Config lives in `~/.config/opencode/` with agent definitions in `agents/*.md` and cross-tool instructions in `AGENTS.md`.
|
||||
@@ -36,12 +36,44 @@ Maintain `AGENTS.md` as the single source of truth:
|
||||
- **Verify symlinks exist**: `CLAUDE.md`, `.cursorrules`, `.github/copilot-instructions.md` should all point to `AGENTS.md`
|
||||
- **Do NOT duplicate `.memory/` contents** — instruction file is for "how to work here", not "what we're doing"
|
||||
|
||||
### 3. Memory File Maintenance
|
||||
### 3. Memory Structure Maintenance
|
||||
|
||||
- Review `.memory/` files for accuracy, staleness, and completeness.
|
||||
- Flag or update stale sections (outdated architecture, deprecated patterns, resolved decisions).
|
||||
Ensure `.memory/` conforms to the standard structure:
|
||||
|
||||
```text
|
||||
.memory/
|
||||
├── manifest.yaml # Index: all files with descriptions + groups
|
||||
├── system.md # One-paragraph project overview
|
||||
├── knowledge/ # Nested knowledge domains
|
||||
│ ├── overview.md
|
||||
│ ├── tech-stack.md
|
||||
│ ├── conventions.md
|
||||
│ ├── patterns/
|
||||
│ └── domain/
|
||||
├── decisions.md # ADRs only
|
||||
├── plans/ # One file per feature
|
||||
├── research/ # Research findings
|
||||
├── gates/ # Quality gate records
|
||||
└── sessions/ # Session continuity
|
||||
└── continuity.md
|
||||
```
|
||||
|
||||
**Manifest maintenance:**
|
||||
- When new `.memory/` files are created, update `manifest.yaml` with path, description, and group
|
||||
- Descriptions should be one line explaining what the file contains
|
||||
- Groups: `knowledge`, `decisions`, `plans`, `research`, `gates`, `sessions`
|
||||
|
||||
**Structure compliance:**
|
||||
- Ensure `knowledge/` uses nested structure for domains and patterns
|
||||
- Quality gate records go in `gates/<feature>.md`, not plan files
|
||||
- Session continuity goes in `sessions/continuity.md`
|
||||
- ADRs go in `decisions.md`, not scattered
|
||||
|
||||
**Content maintenance:**
|
||||
- Review `.memory/` files for accuracy, staleness, and completeness
|
||||
- Flag or update stale sections (outdated architecture, deprecated patterns, resolved decisions)
|
||||
- Ensure cross-references between `.memory/` files are valid
|
||||
- Keep hierarchy shallow (max 2 heading levels preferred).
|
||||
- Keep hierarchy shallow (max 2 heading levels preferred)
|
||||
|
||||
## Operating Rules
|
||||
|
||||
|
||||
9
.local/bin/clipboard-menu
Executable file
9
.local/bin/clipboard-menu
Executable file
@@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
# Clipboard menu using cliphist and rofi
|
||||
|
||||
selection=$(cliphist list | rofi -dmenu -p "Clipboard")
|
||||
|
||||
# Only copy if something was actually selected
|
||||
if [ -n "$selection" ]; then
|
||||
echo "$selection" | cliphist decode | wl-copy
|
||||
fi
|
||||
Reference in New Issue
Block a user