specialist-agent 2.8.1 → 2.10.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.
@@ -4,129 +4,124 @@ AI agents for any framework — Vue 3, React, Next.js, SvelteKit, Angular, Astro
4
4
 
5
5
  ## Quick Install
6
6
 
7
- ### Option 1: CLI (Recommended)
7
+ ### Option 1: CLI + OpenCode Config
8
8
 
9
9
  ```bash
10
10
  cd /path/to/your-project
11
11
  npx specialist-agent init
12
12
  ```
13
13
 
14
- The wizard will:
14
+ Then copy the OpenCode config to your project root:
15
15
 
16
- 1. Auto-detect your framework from `package.json`
17
- 2. Let you choose Full or Lite mode
18
- 3. Install agents and skills to `.claude/`
19
-
20
- ### Option 2: Manual Installation
21
-
22
- 1. **Clone the repository:**
16
+ ```bash
17
+ cp node_modules/specialist-agent/.opencode/opencode.json ./opencode.json
18
+ ```
23
19
 
24
- ```bash
25
- git clone https://github.com/HerbertJulio/specialist-agent.git
26
- ```
20
+ Or manually add `opencode.json` (see template in this directory).
27
21
 
28
- 2. **Copy your framework pack:**
22
+ ### Option 2: Native OpenCode Agents
29
23
 
30
- ```bash
31
- # For React projects
32
- cp -r specialist-agent/packs/react/* your-project/.claude/
24
+ OpenCode reads agents from `.opencode/agents/`. Install directly:
33
25
 
34
- # For Vue projects
35
- cp -r specialist-agent/packs/vue/* your-project/.claude/
26
+ ```bash
27
+ git clone https://github.com/HerbertJulio/specialist-agent.git /tmp/sa
36
28
 
37
- # For Next.js projects
38
- cp -r specialist-agent/packs/nextjs/* your-project/.claude/
29
+ # Copy agents to OpenCode directory
30
+ mkdir -p .opencode/agents
31
+ cp /tmp/sa/agents/*.md .opencode/agents/
39
32
 
40
- # For SvelteKit projects
41
- cp -r specialist-agent/packs/svelte/* your-project/.claude/
33
+ # Copy framework-specific agents (pick your framework)
34
+ cp /tmp/sa/packs/react/agents/*.md .opencode/agents/
35
+ # Options: react, vue, nextjs, svelte, angular, astro, nuxt
42
36
 
43
- # For Angular projects
44
- cp -r specialist-agent/packs/angular/* your-project/.claude/
37
+ # Copy opencode.json and CLAUDE.md
38
+ cp /tmp/sa/.opencode/opencode.json ./opencode.json
39
+ cp /tmp/sa/packs/{your-framework}/CLAUDE.md ./CLAUDE.md
45
40
 
46
- # For Astro projects
47
- cp -r specialist-agent/packs/astro/* your-project/.claude/
41
+ rm -rf /tmp/sa
42
+ ```
48
43
 
49
- # For Nuxt projects
50
- cp -r specialist-agent/packs/nuxt/* your-project/.claude/
51
- ```
44
+ ### Option 3: opencode.json Only
52
45
 
53
- 3. **Copy CLAUDE.md to your project root:**
46
+ If you already have agents in `.claude/agents/` from the CLI, just add the `opencode.json` to your project root. OpenCode will pick up the agent definitions from the config.
54
47
 
55
- ```bash
56
- cp specialist-agent/packs/{your-framework}/CLAUDE.md your-project/CLAUDE.md
57
- ```
48
+ ## Key Difference: Directory
58
49
 
59
- 4. **Copy framework-agnostic agents (optional):**
50
+ | Platform | Agent directory | Config |
51
+ |----------|----------------|--------|
52
+ | Claude Code | `.claude/agents/` | `.claude/settings.json` |
53
+ | OpenCode | `.opencode/agents/` | `opencode.json` |
60
54
 
61
- ```bash
62
- cp -r specialist-agent/agents/* your-project/.claude/agents/
63
- ```
55
+ The markdown agent files are compatible across both platforms. Copy them to the directory your platform expects.
64
56
 
65
- ## Usage in OpenCode
57
+ ## Usage
66
58
 
67
- Once installed, use agents by mentioning them:
59
+ Reference agents with `@`:
68
60
 
69
61
  ```
70
62
  @builder create an orders module with CRUD for /v2/orders
71
63
  @reviewer review the authentication module
72
64
  @tdd implement the payment service with tests first
73
- @planner plan the user dashboard feature
65
+ @planner plan the checkout flow
66
+ @doctor the login page returns 500, investigate
74
67
  ```
75
68
 
76
69
  ## Available Agents
77
70
 
78
- ### Framework-Agnostic
71
+ ### Core
79
72
 
80
- - `@starter` - Create new projects from scratch
81
- - `@explorer` - Explore unfamiliar codebases
82
- - `@planner` - Adaptive task planning
83
- - `@executor` - Cost-aware task execution with autonomous mode
84
- - `@tdd` - Test-Driven Development enforcer
85
- - `@debugger` - Systematic 4-phase debugging
86
- - `@finance` - Payment and billing systems
87
- - `@cloud` - Cloud architecture and IaC
88
- - `@security` - Authentication and security
89
- - `@designer` - UI/UX and design systems
90
- - `@data` - Database and caching
91
- - `@devops` - Docker, K8s, CI/CD
92
- - `@tester` - Test strategies and coverage
73
+ | Agent | Use For |
74
+ |-------|---------|
75
+ | `@builder` | Create modules, components, services |
76
+ | `@reviewer` | Code review (spec + quality + architecture) |
77
+ | `@doctor` | Bug investigation |
78
+ | `@planner` | Feature planning |
79
+ | `@executor` | Execute plans with checkpoints |
80
+ | `@tdd` | Test-driven development |
93
81
 
94
- ### Pack-Specific
82
+ ### Specialist
95
83
 
96
- - `@builder` - Create modules, components, services
97
- - `@reviewer` - Unified 3-in-1 code review
98
- - `@doctor` - Bug investigation
99
- - `@migrator` - Legacy code migration
84
+ | Agent | Use For |
85
+ |-------|---------|
86
+ | `@api` | REST/GraphQL API design |
87
+ | `@perf` | Performance optimization |
88
+ | `@security` | Auth, OWASP audits |
89
+ | `@finance` | Payments, billing |
90
+ | `@cloud` | Cloud architecture, IaC |
91
+ | `@data` | Database design |
92
+ | `@devops` | Docker, K8s, CI/CD |
93
+ | `@architect` | System architecture migration |
94
+ | `@designer` | Design systems, accessibility |
100
95
 
101
- ## Skills
96
+ ### Support
102
97
 
103
- Quick shortcuts for common tasks:
98
+ | Agent | Use For |
99
+ |-------|---------|
100
+ | `@scout` | Quick project analysis |
101
+ | `@explorer` | Deep codebase exploration |
102
+ | `@debugger` | Systematic debugging |
103
+ | `@pair` | Pair programming |
104
104
 
105
- ```
106
- /brainstorm [idea] - Socratic brainstorming before planning
107
- /plan [feature] - Create adaptive implementation plan
108
- /tdd [module] - TDD workflow: RED → GREEN → REFACTOR
109
- /debug [error] - Systematic debugging
110
- /audit [path] - Multi-domain code audit
111
- /onboard - Codebase onboarding
112
- /checkpoint [name] - Create git checkpoint
113
- /estimate [feature] - Estimate token cost
114
- /dev-create-module [name] - Scaffold complete module
115
- ```
105
+ ## Troubleshooting
106
+
107
+ **Agents not recognized?**
108
+
109
+ 1. Verify `.opencode/agents/` has `.md` files, OR `opencode.json` has agent definitions
110
+ 2. Reference agents with `@name` (e.g., `@builder`)
116
111
 
117
- ## Mode Selection
112
+ **Using both Claude Code and OpenCode?**
118
113
 
119
- | Mode | Model | Cost | Best For |
120
- |------|-------|------|----------|
121
- | Full | Sonnet/Opus | Higher | Complex features, architecture |
122
- | Lite | Haiku | Lower | Simple tasks, quick fixes |
114
+ Run `npx specialist-agent init` for `.claude/` agents, then copy them:
115
+
116
+ ```bash
117
+ cp .claude/agents/*.md .opencode/agents/
118
+ ```
123
119
 
124
120
  ## Support
125
121
 
126
122
  - Documentation: <https://specialistagent.com.br/>
127
123
  - Issues: https://github.com/HerbertJulio/specialist-agent/issues
128
- - Discussions: https://github.com/HerbertJulio/specialist-agent/discussions
129
124
 
130
125
  ## License
131
126
 
132
- MIT - Use freely.
127
+ MIT
@@ -0,0 +1,141 @@
1
+ {
2
+ "$schema": "https://opencode.ai/config.json",
3
+ "instructions": "Read CLAUDE.md for project conventions. Always use specialist agents (@builder, @reviewer, @planner, etc.) instead of generic prompts.",
4
+ "agent": {
5
+ "builder": {
6
+ "description": "Build modules, components, and services with tests",
7
+ "mode": "primary",
8
+ "tools": { "write": true, "edit": true, "bash": true }
9
+ },
10
+ "reviewer": {
11
+ "description": "Unified 3-in-1 code review (spec, quality, architecture)",
12
+ "mode": "primary",
13
+ "tools": { "write": false, "edit": false, "bash": true }
14
+ },
15
+ "doctor": {
16
+ "description": "Investigate bugs with systematic 4-phase diagnosis",
17
+ "mode": "primary",
18
+ "tools": { "write": false, "edit": false, "bash": true }
19
+ },
20
+ "planner": {
21
+ "description": "Create adaptive implementation plans by complexity",
22
+ "mode": "primary",
23
+ "tools": { "write": true, "edit": false, "bash": false }
24
+ },
25
+ "executor": {
26
+ "description": "Execute plans with checkpoints and cost tracking",
27
+ "mode": "primary",
28
+ "tools": { "write": true, "edit": true, "bash": true }
29
+ },
30
+ "tdd": {
31
+ "description": "Test-driven development (RED > GREEN > REFACTOR)",
32
+ "mode": "primary",
33
+ "tools": { "write": true, "edit": true, "bash": true }
34
+ },
35
+ "debugger": {
36
+ "description": "Systematic 4-phase debugging with evidence",
37
+ "mode": "primary",
38
+ "tools": { "write": false, "edit": true, "bash": true }
39
+ },
40
+ "pair": {
41
+ "description": "Real-time pair programming assistance",
42
+ "mode": "primary",
43
+ "tools": { "write": true, "edit": true, "bash": true }
44
+ },
45
+ "analyst": {
46
+ "description": "Convert requirements into technical specifications",
47
+ "mode": "primary",
48
+ "tools": { "write": true, "edit": false, "bash": false }
49
+ },
50
+ "api": {
51
+ "description": "Design REST/GraphQL APIs with OpenAPI specs",
52
+ "mode": "primary",
53
+ "tools": { "write": true, "edit": true, "bash": true }
54
+ },
55
+ "perf": {
56
+ "description": "Performance optimization with measurable improvements",
57
+ "mode": "primary",
58
+ "tools": { "write": true, "edit": true, "bash": true }
59
+ },
60
+ "security": {
61
+ "description": "Auth and OWASP vulnerability audits",
62
+ "mode": "primary",
63
+ "tools": { "write": true, "edit": true, "bash": true }
64
+ },
65
+ "finance": {
66
+ "description": "Payment, billing, and subscription systems",
67
+ "mode": "primary",
68
+ "tools": { "write": true, "edit": true, "bash": true }
69
+ },
70
+ "cloud": {
71
+ "description": "Cloud architecture and Infrastructure as Code",
72
+ "mode": "primary",
73
+ "tools": { "write": true, "edit": true, "bash": true }
74
+ },
75
+ "data": {
76
+ "description": "Database schemas, migrations, and caching",
77
+ "mode": "primary",
78
+ "tools": { "write": true, "edit": true, "bash": true }
79
+ },
80
+ "devops": {
81
+ "description": "Docker, Kubernetes, and CI/CD pipelines",
82
+ "mode": "primary",
83
+ "tools": { "write": true, "edit": true, "bash": true }
84
+ },
85
+ "i18n": {
86
+ "description": "Internationalization and translations",
87
+ "mode": "primary",
88
+ "tools": { "write": true, "edit": true, "bash": false }
89
+ },
90
+ "docs": {
91
+ "description": "Generate documentation from code",
92
+ "mode": "primary",
93
+ "tools": { "write": true, "edit": true, "bash": false }
94
+ },
95
+ "refactor": {
96
+ "description": "Code refactoring for clarity and maintainability",
97
+ "mode": "primary",
98
+ "tools": { "write": true, "edit": true, "bash": true }
99
+ },
100
+ "deps": {
101
+ "description": "Dependency management and security updates",
102
+ "mode": "primary",
103
+ "tools": { "write": true, "edit": true, "bash": true }
104
+ },
105
+ "legal": {
106
+ "description": "GDPR, LGPD, CCPA compliance",
107
+ "mode": "primary",
108
+ "tools": { "write": true, "edit": true, "bash": false }
109
+ },
110
+ "designer": {
111
+ "description": "Design systems with accessibility",
112
+ "mode": "primary",
113
+ "tools": { "write": true, "edit": true, "bash": false }
114
+ },
115
+ "tester": {
116
+ "description": "Test strategies and coverage improvement",
117
+ "mode": "primary",
118
+ "tools": { "write": true, "edit": true, "bash": true }
119
+ },
120
+ "scout": {
121
+ "description": "Quick project analysis",
122
+ "mode": "primary",
123
+ "tools": { "write": false, "edit": false, "bash": true }
124
+ },
125
+ "explorer": {
126
+ "description": "Deep codebase exploration",
127
+ "mode": "primary",
128
+ "tools": { "write": false, "edit": false, "bash": true }
129
+ },
130
+ "architect": {
131
+ "description": "Full system architecture migration (hexagonal, DDD, CQRS)",
132
+ "mode": "primary",
133
+ "tools": { "write": true, "edit": true, "bash": true }
134
+ },
135
+ "ripple": {
136
+ "description": "Cascading impact analysis of changes",
137
+ "mode": "primary",
138
+ "tools": { "write": false, "edit": false, "bash": true }
139
+ }
140
+ }
141
+ }
@@ -49,20 +49,29 @@ Read `docs/ARCHITECTURE.md` if it exists, then scan the project for architecture
49
49
 
50
50
  ### Workflow
51
51
  1. Scan project structure: directory depth, module boundaries, dependency direction
52
- 2. Detect current architecture pattern:
53
-
54
- | Pattern | Indicators |
55
- |---------|-----------|
56
- | **Monolith** | Single deployment unit, shared database, deep coupling between modules |
57
- | **Layered (MVC)** | `controllers/`, `models/`, `views/` directories, horizontal slicing |
58
- | **Feature-based Modular** | `modules/[feature]/` directories, vertical slicing |
59
- | **Hexagonal (Ports & Adapters)** | `ports/`, `adapters/`, `domain/` directories, dependency inversion |
60
- | **Clean Architecture** | `entities/`, `use-cases/`, `interfaces/`, `frameworks/` layers |
61
- | **DDD** | `aggregates/`, `value-objects/`, `domain-events/`, bounded contexts |
62
- | **Microservices** | Multiple `package.json`, separate deployments, API gateways |
63
- | **Event-Driven** | Message brokers, event handlers, eventual consistency patterns |
64
- | **Modular Monolith** | Module boundaries enforced but single deployment |
65
- | **Serverless** | Function handlers, event triggers, stateless execution units |
52
+ 2. Detect current architecture pattern using these heuristics:
53
+
54
+ | Pattern | Detection Heuristics |
55
+ |---------|---------------------|
56
+ | **Flat / Component-Driven** | Single `src/components/` with many files, no modules/ or features/ |
57
+ | **Layered (MVC/MVVM)** | `controllers/`, `models/`, `views/`, `routes/`, `repositories/` dirs |
58
+ | **Feature-based Modular** | `modules/[feature]/` or `features/[feature]/` with barrel exports (index.ts) |
59
+ | **Feature-Sliced Design** | 3+ of: `app/`, `pages/`, `widgets/`, `features/`, `entities/`, `shared/` |
60
+ | **Atomic Design** | `atoms/`, `molecules/`, `organisms/`, `templates/` directories |
61
+ | **Screaming Architecture** | Top-level dirs are business domains (not technical: users/, orders/, payments/) |
62
+ | **Clean Architecture** | `domain/`, `use-cases/` or `application/`, `infrastructure/`, `presentation/` |
63
+ | **Hexagonal (Ports & Adapters)** | `ports/` (in/out), `adapters/` (in/out), `domain/` or `core/` |
64
+ | **DDD** | `aggregates/`, `value-objects/`, `domain-events/`, `bounded-contexts/` |
65
+ | **CQRS** | `commands/`, `queries/`, `command-handlers/`, `query-handlers/`, `read-models/` |
66
+ | **Event-Driven** | `events/`, `handlers/`, `subscribers/`, `publishers/`, `sagas/` |
67
+ | **Microservices** | Multiple `package.json`/`Dockerfile` in subdirs, API gateway config |
68
+ | **Modular Monolith** | Single pkg.json, `modules/` with domain/application/infrastructure layers |
69
+ | **Serverless** | `serverless.yml`, `sam-template.yaml`, function handlers |
70
+ | **Unstructured** | No clear pattern, files loosely organized |
71
+
72
+ **Monorepo Detection:** Also check for `turbo.json` (Turborepo), `nx.json` (Nx), `lerna.json` (Lerna), `pnpm-workspace.yaml` (pnpm), or `package.json` with `workspaces` field.
73
+
74
+ **Next.js Router:** Check for `app/layout.tsx` (App Router) vs `pages/_app.tsx` (Pages Router).
66
75
 
67
76
  3. Analyze dependency health:
68
77
  - Map import directions (are dependencies flowing inward or outward?)