@ekkos/cli 0.2.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/dist/cache/LocalSessionStore.d.ts +129 -0
- package/dist/cache/LocalSessionStore.js +688 -0
- package/dist/cache/capture.d.ts +26 -0
- package/dist/cache/capture.js +461 -0
- package/dist/cache/index.d.ts +7 -0
- package/dist/cache/index.js +23 -0
- package/dist/cache/types.d.ts +147 -0
- package/dist/cache/types.js +40 -0
- package/dist/commands/init.d.ts +9 -0
- package/dist/commands/init.js +478 -0
- package/dist/commands/run.d.ts +12 -0
- package/dist/commands/run.js +829 -0
- package/dist/commands/setup.d.ts +6 -0
- package/dist/commands/setup.js +658 -0
- package/dist/commands/status.d.ts +1 -0
- package/dist/commands/status.js +109 -0
- package/dist/commands/test.d.ts +1 -0
- package/dist/commands/test.js +157 -0
- package/dist/deploy/agents.d.ts +15 -0
- package/dist/deploy/agents.js +72 -0
- package/dist/deploy/hooks.d.ts +16 -0
- package/dist/deploy/hooks.js +121 -0
- package/dist/deploy/index.d.ts +7 -0
- package/dist/deploy/index.js +24 -0
- package/dist/deploy/instructions.d.ts +12 -0
- package/dist/deploy/instructions.js +36 -0
- package/dist/deploy/mcp.d.ts +19 -0
- package/dist/deploy/mcp.js +109 -0
- package/dist/deploy/plugins.d.ts +19 -0
- package/dist/deploy/plugins.js +62 -0
- package/dist/deploy/settings.d.ts +8 -0
- package/dist/deploy/settings.js +84 -0
- package/dist/deploy/skills.d.ts +19 -0
- package/dist/deploy/skills.js +60 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +71 -0
- package/dist/restore/RestoreOrchestrator.d.ts +48 -0
- package/dist/restore/RestoreOrchestrator.js +481 -0
- package/dist/restore/index.d.ts +4 -0
- package/dist/restore/index.js +20 -0
- package/dist/utils/platform.d.ts +29 -0
- package/dist/utils/platform.js +65 -0
- package/dist/utils/session-words.json +119 -0
- package/dist/utils/state.d.ts +57 -0
- package/dist/utils/state.js +186 -0
- package/dist/utils/templates.d.ts +24 -0
- package/dist/utils/templates.js +118 -0
- package/package.json +48 -0
- package/templates/CLAUDE.md +287 -0
- package/templates/README.md +378 -0
- package/templates/agents/README.md +182 -0
- package/templates/agents/code-reviewer.md +166 -0
- package/templates/agents/debug-detective.md +169 -0
- package/templates/agents/ekkOS_Vercel.md +99 -0
- package/templates/agents/extension-manager.md +229 -0
- package/templates/agents/git-companion.md +185 -0
- package/templates/agents/github-test-agent.md +321 -0
- package/templates/agents/railway-manager.md +179 -0
- package/templates/claude-plugins/PHASE2_COMPLETION.md +346 -0
- package/templates/claude-plugins/PLUGIN_PROPOSALS.md +1776 -0
- package/templates/claude-plugins/README.md +587 -0
- package/templates/claude-plugins/agents/code-reviewer.json +14 -0
- package/templates/claude-plugins/agents/debug-detective.json +15 -0
- package/templates/claude-plugins/agents/git-companion.json +14 -0
- package/templates/claude-plugins/blog-manager/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins/blog-manager/commands/blog.md +691 -0
- package/templates/claude-plugins/golden-loop-monitor/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins/golden-loop-monitor/commands/loop-status.md +434 -0
- package/templates/claude-plugins/learning-tracker/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins/learning-tracker/commands/my-patterns.md +282 -0
- package/templates/claude-plugins/memory-lens/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins/memory-lens/commands/memory-search.md +181 -0
- package/templates/claude-plugins/pattern-coach/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins/pattern-coach/commands/forge.md +365 -0
- package/templates/claude-plugins/project-schema-validator/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins/project-schema-validator/commands/validate-schema.md +582 -0
- package/templates/claude-plugins-admin/AGENT_TEAM_PROPOSALS.md +819 -0
- package/templates/claude-plugins-admin/README.md +446 -0
- package/templates/claude-plugins-admin/autonomous-admin-agent/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/autonomous-admin-agent/commands/agent.md +595 -0
- package/templates/claude-plugins-admin/backend-agent/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/backend-agent/commands/backend.md +798 -0
- package/templates/claude-plugins-admin/deploy-guardian/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/deploy-guardian/commands/deploy.md +554 -0
- package/templates/claude-plugins-admin/frontend-agent/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/frontend-agent/commands/frontend.md +881 -0
- package/templates/claude-plugins-admin/mcp-server-manager/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/mcp-server-manager/commands/mcp.md +85 -0
- package/templates/claude-plugins-admin/memory-system-monitor/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/memory-system-monitor/commands/memory-health.md +569 -0
- package/templates/claude-plugins-admin/qa-agent/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/qa-agent/commands/qa.md +863 -0
- package/templates/claude-plugins-admin/tech-lead-agent/.claude-plugin/plugin.json +8 -0
- package/templates/claude-plugins-admin/tech-lead-agent/commands/lead.md +732 -0
- package/templates/commands/continue.md +47 -0
- package/templates/cursor-hooks/after-agent-response.sh +117 -0
- package/templates/cursor-hooks/before-submit-prompt.sh +419 -0
- package/templates/cursor-hooks/hooks.json +20 -0
- package/templates/cursor-hooks/lib/contract.sh +320 -0
- package/templates/cursor-hooks/stop.sh +75 -0
- package/templates/cursor-rules/ekkos-memory.md +187 -0
- package/templates/hooks/assistant-response.sh +96 -0
- package/templates/hooks/hooks.json +28 -0
- package/templates/hooks/lib/contract.sh +320 -0
- package/templates/hooks/lib/state.sh +158 -0
- package/templates/hooks/session-start.ps1 +41 -0
- package/templates/hooks/session-start.sh +318 -0
- package/templates/hooks/stop.ps1 +16 -0
- package/templates/hooks/stop.sh +989 -0
- package/templates/hooks/user-prompt-submit.ps1 +174 -0
- package/templates/hooks/user-prompt-submit.sh +587 -0
- package/templates/hooks-node/lib/state.js +187 -0
- package/templates/hooks-node/stop.js +416 -0
- package/templates/hooks-node/user-prompt-submit.js +337 -0
- package/templates/plan-template.md +306 -0
- package/templates/rules/00-hooks-contract.mdc +89 -0
- package/templates/rules/30-ekkos-core.mdc +188 -0
- package/templates/rules/31-ekkos-messages.mdc +78 -0
- package/templates/skills/continue/SKILL.md +169 -0
- package/templates/skills/ekkOS_Deep_Recall/Skill.md +282 -0
- package/templates/skills/ekkOS_Learn/Skill.md +265 -0
- package/templates/skills/ekkOS_Memory_First/Skill.md +206 -0
- package/templates/skills/ekkOS_Plan_Assist/Skill.md +302 -0
- package/templates/skills/ekkOS_Preferences/Skill.md +247 -0
- package/templates/skills/ekkOS_Reflect/Skill.md +257 -0
- package/templates/skills/ekkOS_Safety/Skill.md +265 -0
- package/templates/skills/ekkOS_Schema/Skill.md +251 -0
- package/templates/skills/ekkOS_Summary/Skill.md +257 -0
- package/templates/skills/ekkOS_Vault/Skill.md +287 -0
- package/templates/skills/permissions/Skill.md +322 -0
- package/templates/spec-template.md +159 -0
- package/templates/windsurf-hooks/before-submit-prompt.sh +238 -0
- package/templates/windsurf-hooks/hooks.json +10 -0
- package/templates/windsurf-hooks/lib/contract.sh +320 -0
- package/templates/windsurf-rules/ekkos-memory.md +129 -0
|
@@ -0,0 +1,322 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: permissions
|
|
3
|
+
description: Manage ekkOS tool permissions. View, grant, or revoke permissions for proactive tool execution. Use when user types "/permissions" or wants to configure what ekkOS can do automatically.
|
|
4
|
+
allowed-tools:
|
|
5
|
+
- Bash
|
|
6
|
+
- Read
|
|
7
|
+
- Write
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# /permissions - Manage ekkOS Tool Permissions
|
|
11
|
+
|
|
12
|
+
Control what ekkOS tools can run proactively without asking for approval.
|
|
13
|
+
|
|
14
|
+
## Usage
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
/permissions # Show current permissions
|
|
18
|
+
/permissions list # Show all permissions
|
|
19
|
+
/permissions grant <scope> # Grant a permission
|
|
20
|
+
/permissions revoke <scope> # Revoke a permission
|
|
21
|
+
/permissions reset # Reset to defaults
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## Permission Scopes
|
|
25
|
+
|
|
26
|
+
### 🔍 ekkOS_Search (Low Risk)
|
|
27
|
+
```bash
|
|
28
|
+
/permissions grant search:auto_before_answer
|
|
29
|
+
→ Automatically search memory before answering technical questions
|
|
30
|
+
|
|
31
|
+
/permissions grant search:auto_on_debug
|
|
32
|
+
→ Automatically search for similar issues when debugging
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
### 🔨 ekkOS_Forge (Medium Risk)
|
|
36
|
+
```bash
|
|
37
|
+
/permissions grant forge:auto_on_fix
|
|
38
|
+
→ Automatically create patterns when you fix bugs
|
|
39
|
+
|
|
40
|
+
/permissions grant forge:auto_on_solution
|
|
41
|
+
→ Create patterns for any non-trivial solution you provide
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### 📋 ekkOS_Directive (Medium Risk)
|
|
45
|
+
```bash
|
|
46
|
+
/permissions grant directive:auto_capture_preferences
|
|
47
|
+
→ Automatically save user preferences as directives
|
|
48
|
+
|
|
49
|
+
/permissions grant directive:auto_capture_corrections
|
|
50
|
+
→ Save corrections as directives without asking
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### 📊 ekkOS_Track (Low Risk)
|
|
54
|
+
```bash
|
|
55
|
+
/permissions grant track:auto_track_usage
|
|
56
|
+
→ Automatically track when patterns are applied
|
|
57
|
+
|
|
58
|
+
/permissions grant track:auto_track_outcomes
|
|
59
|
+
→ Track success/failure of pattern applications
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### ⚠️ ekkOS_Conflict (Low Risk)
|
|
63
|
+
```bash
|
|
64
|
+
/permissions grant conflict:auto_check_destructive
|
|
65
|
+
→ Automatically check for conflicts before dangerous operations
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### 🧠 ekkOS_Recall (Low Risk)
|
|
69
|
+
```bash
|
|
70
|
+
/permissions grant recall:auto_load_context
|
|
71
|
+
→ Automatically load relevant past context for tasks
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## Risk Levels
|
|
75
|
+
|
|
76
|
+
| Level | Operations | Examples |
|
|
77
|
+
|-------|------------|----------|
|
|
78
|
+
| **Low** | Read-only, no side effects | Search, Recall, Conflict checks |
|
|
79
|
+
| **Medium** | Write operations, reversible | Forge patterns, Create directives |
|
|
80
|
+
| **High** | Destructive, irreversible | (None currently - all high-risk requires explicit approval) |
|
|
81
|
+
|
|
82
|
+
## Implementation
|
|
83
|
+
|
|
84
|
+
When user runs `/permissions`:
|
|
85
|
+
|
|
86
|
+
### Step 1: Parse Command
|
|
87
|
+
|
|
88
|
+
```bash
|
|
89
|
+
#!/bin/bash
|
|
90
|
+
ARGS="${ARGUMENTS:-list}"
|
|
91
|
+
API_KEY=$(jq -r '.apiKey // .hookApiKey' ~/.ekkos/config.json)
|
|
92
|
+
BASE_URL="https://api.ekkos.dev"
|
|
93
|
+
|
|
94
|
+
case "$ARGS" in
|
|
95
|
+
""|list)
|
|
96
|
+
# Show current permissions
|
|
97
|
+
curl -s "$BASE_URL/api/v1/permissions" \
|
|
98
|
+
-H "Authorization: Bearer $API_KEY" | jq .
|
|
99
|
+
;;
|
|
100
|
+
|
|
101
|
+
grant*)
|
|
102
|
+
# Extract scope from "grant scope:name"
|
|
103
|
+
SCOPE=$(echo "$ARGS" | sed 's/grant //')
|
|
104
|
+
curl -s "$BASE_URL/api/v1/permissions/grant" \
|
|
105
|
+
-H "Authorization: Bearer $API_KEY" \
|
|
106
|
+
-H "Content-Type: application/json" \
|
|
107
|
+
-d "{\"scope\": \"$SCOPE\"}" | jq .
|
|
108
|
+
;;
|
|
109
|
+
|
|
110
|
+
revoke*)
|
|
111
|
+
# Extract scope from "revoke scope:name"
|
|
112
|
+
SCOPE=$(echo "$ARGS" | sed 's/revoke //')
|
|
113
|
+
curl -s "$BASE_URL/api/v1/permissions/revoke" \
|
|
114
|
+
-H "Authorization: Bearer $API_KEY" \
|
|
115
|
+
-H "Content-Type: application/json" \
|
|
116
|
+
-d "{\"scope\": \"$SCOPE\"}" | jq .
|
|
117
|
+
;;
|
|
118
|
+
|
|
119
|
+
reset)
|
|
120
|
+
# Reset to recommended defaults
|
|
121
|
+
curl -s "$BASE_URL/api/v1/permissions/reset" \
|
|
122
|
+
-H "Authorization: Bearer $API_KEY" \
|
|
123
|
+
-X POST | jq .
|
|
124
|
+
;;
|
|
125
|
+
|
|
126
|
+
*)
|
|
127
|
+
echo "Unknown command: $ARGS"
|
|
128
|
+
echo "Usage: /permissions [list|grant|revoke|reset]"
|
|
129
|
+
exit 1
|
|
130
|
+
;;
|
|
131
|
+
esac
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
### Step 2: Display Results
|
|
135
|
+
|
|
136
|
+
Format the response for readability:
|
|
137
|
+
|
|
138
|
+
```
|
|
139
|
+
✓ ekkOS Tool Permissions
|
|
140
|
+
|
|
141
|
+
## Active Permissions (5)
|
|
142
|
+
|
|
143
|
+
🔍 ekkOS_Search
|
|
144
|
+
✓ auto_before_answer [low risk] Used: 247 times
|
|
145
|
+
✓ auto_on_debug [low risk] Used: 18 times
|
|
146
|
+
|
|
147
|
+
🔨 ekkOS_Forge
|
|
148
|
+
✓ auto_on_fix [medium risk] Used: 42 times
|
|
149
|
+
|
|
150
|
+
📋 ekkOS_Directive
|
|
151
|
+
✓ auto_capture_preferences [medium risk] Used: 9 times
|
|
152
|
+
|
|
153
|
+
## Revoked Permissions (1)
|
|
154
|
+
|
|
155
|
+
🔨 ekkOS_Forge
|
|
156
|
+
✗ auto_on_solution [medium risk] Revoked 3 days ago
|
|
157
|
+
|
|
158
|
+
## Available Permissions
|
|
159
|
+
|
|
160
|
+
You can grant these additional permissions:
|
|
161
|
+
|
|
162
|
+
/permissions grant track:auto_track_usage
|
|
163
|
+
/permissions grant recall:auto_load_context
|
|
164
|
+
/permissions grant conflict:auto_check_destructive
|
|
165
|
+
|
|
166
|
+
Run "/permissions grant <scope>" to enable.
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
### Step 3: Recommend Defaults
|
|
170
|
+
|
|
171
|
+
If user has NO permissions set, show recommended starter set:
|
|
172
|
+
|
|
173
|
+
```
|
|
174
|
+
🚀 Recommended Starter Permissions
|
|
175
|
+
|
|
176
|
+
These are safe, read-only operations that make ekkOS smarter:
|
|
177
|
+
|
|
178
|
+
/permissions grant search:auto_before_answer ← Search memory first
|
|
179
|
+
/permissions grant track:auto_track_usage ← Track what works
|
|
180
|
+
/permissions grant conflict:auto_check_destructive ← Safety checks
|
|
181
|
+
|
|
182
|
+
Would you like to grant all three? (y/n)
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
## Permission Enforcement
|
|
186
|
+
|
|
187
|
+
The MCP gateway checks permissions before executing tools:
|
|
188
|
+
|
|
189
|
+
```typescript
|
|
190
|
+
// Before executing a tool
|
|
191
|
+
const hasPermission = await checkPermission(
|
|
192
|
+
userId,
|
|
193
|
+
toolName,
|
|
194
|
+
context.permission_scope
|
|
195
|
+
);
|
|
196
|
+
|
|
197
|
+
if (!hasPermission) {
|
|
198
|
+
// Ask user for approval
|
|
199
|
+
return {
|
|
200
|
+
success: false,
|
|
201
|
+
error: 'Permission required',
|
|
202
|
+
request_permission: {
|
|
203
|
+
tool: toolName,
|
|
204
|
+
scope: context.permission_scope,
|
|
205
|
+
description: 'What this allows...',
|
|
206
|
+
risk_level: 'low'
|
|
207
|
+
}
|
|
208
|
+
};
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
// Execute tool with permission
|
|
212
|
+
await executeTool(toolName, args);
|
|
213
|
+
await trackPermissionUsage(userId, toolName, scope);
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
## Examples
|
|
217
|
+
|
|
218
|
+
### Example 1: First Time User
|
|
219
|
+
|
|
220
|
+
```
|
|
221
|
+
User: /permissions
|
|
222
|
+
|
|
223
|
+
Output:
|
|
224
|
+
✓ ekkOS Tool Permissions
|
|
225
|
+
|
|
226
|
+
You haven't granted any permissions yet.
|
|
227
|
+
|
|
228
|
+
🚀 Recommended Starter Set (read-only, safe):
|
|
229
|
+
|
|
230
|
+
/permissions grant search:auto_before_answer
|
|
231
|
+
/permissions grant track:auto_track_usage
|
|
232
|
+
/permissions grant conflict:auto_check_destructive
|
|
233
|
+
|
|
234
|
+
Or grant all at once:
|
|
235
|
+
|
|
236
|
+
/permissions reset ← Sets recommended defaults
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
### Example 2: Grant Permission
|
|
240
|
+
|
|
241
|
+
```
|
|
242
|
+
User: /permissions grant forge:auto_on_fix
|
|
243
|
+
|
|
244
|
+
Output:
|
|
245
|
+
✓ Permission Granted
|
|
246
|
+
|
|
247
|
+
🔨 ekkOS_Forge: auto_on_fix [medium risk]
|
|
248
|
+
|
|
249
|
+
This allows:
|
|
250
|
+
- Automatically create memory patterns when you fix bugs
|
|
251
|
+
- Patterns are saved without asking for approval
|
|
252
|
+
- You can review patterns later with /patterns list
|
|
253
|
+
|
|
254
|
+
To revoke: /permissions revoke forge:auto_on_fix
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
### Example 3: View Active
|
|
258
|
+
|
|
259
|
+
```
|
|
260
|
+
User: /permissions list
|
|
261
|
+
|
|
262
|
+
Output:
|
|
263
|
+
✓ ekkOS Tool Permissions (6 active)
|
|
264
|
+
|
|
265
|
+
🔍 ekkOS_Search
|
|
266
|
+
✓ auto_before_answer Used 342 times Last: 2 min ago
|
|
267
|
+
✓ auto_on_debug Used 29 times Last: 1 hour ago
|
|
268
|
+
|
|
269
|
+
🔨 ekkOS_Forge
|
|
270
|
+
✓ auto_on_fix Used 67 times Last: 5 min ago
|
|
271
|
+
|
|
272
|
+
📋 ekkOS_Directive
|
|
273
|
+
✓ auto_capture_preferences Used 14 times Last: 1 day ago
|
|
274
|
+
|
|
275
|
+
📊 ekkOS_Track
|
|
276
|
+
✓ auto_track_usage Used 534 times Last: 1 min ago
|
|
277
|
+
✓ auto_track_outcomes Used 67 times Last: 10 min ago
|
|
278
|
+
|
|
279
|
+
Total proactive actions: 1,053
|
|
280
|
+
```
|
|
281
|
+
|
|
282
|
+
### Example 4: Revoke Permission
|
|
283
|
+
|
|
284
|
+
```
|
|
285
|
+
User: /permissions revoke forge:auto_on_fix
|
|
286
|
+
|
|
287
|
+
Output:
|
|
288
|
+
✓ Permission Revoked
|
|
289
|
+
|
|
290
|
+
🔨 ekkOS_Forge: auto_on_fix
|
|
291
|
+
|
|
292
|
+
This permission is now disabled. I will ask before creating patterns.
|
|
293
|
+
|
|
294
|
+
To re-enable: /permissions grant forge:auto_on_fix
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
## Integration with Skills
|
|
298
|
+
|
|
299
|
+
When a skill wants to use a tool proactively:
|
|
300
|
+
|
|
301
|
+
```markdown
|
|
302
|
+
# In ekkOS_Learn skill
|
|
303
|
+
|
|
304
|
+
Before calling ekkOS_Forge, check if permission is granted:
|
|
305
|
+
|
|
306
|
+
1. Try proactive execution (relies on MCP gateway permission check)
|
|
307
|
+
2. If rejected → explain what permission is needed
|
|
308
|
+
3. Offer to grant permission: "/permissions grant forge:auto_on_solution"
|
|
309
|
+
```
|
|
310
|
+
|
|
311
|
+
## Success Metrics
|
|
312
|
+
|
|
313
|
+
Permissions are working well when:
|
|
314
|
+
- ✅ Users grant permissions for operations they trust
|
|
315
|
+
- ✅ ekkOS operates autonomously within granted boundaries
|
|
316
|
+
- ✅ Users rarely see "permission required" prompts for granted scopes
|
|
317
|
+
- ✅ Permission usage stats show which features are most valuable
|
|
318
|
+
- ✅ Users feel in control of what ekkOS can do automatically
|
|
319
|
+
|
|
320
|
+
---
|
|
321
|
+
|
|
322
|
+
**Mantra**: Explicit permissions enable proactive intelligence. Users control the autonomy level.
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
# Feature Specification: [Feature Name]
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
**Brief description of the feature and its purpose in the Echo ecosystem.**
|
|
5
|
+
|
|
6
|
+
## User Stories
|
|
7
|
+
|
|
8
|
+
### Primary User Story
|
|
9
|
+
**As a [user type], I want [functionality] so that [benefit/value].**
|
|
10
|
+
|
|
11
|
+
### Additional User Stories
|
|
12
|
+
- **As a [user type], I want [functionality] so that [benefit/value].**
|
|
13
|
+
- **As a [user type], I want [functionality] so that [benefit/value].**
|
|
14
|
+
|
|
15
|
+
## Functional Requirements
|
|
16
|
+
|
|
17
|
+
### Core Functionality
|
|
18
|
+
1. **Requirement 1**: Description of what the system must do
|
|
19
|
+
2. **Requirement 2**: Description of what the system must do
|
|
20
|
+
3. **Requirement 3**: Description of what the system must do
|
|
21
|
+
|
|
22
|
+
### AI Integration Requirements
|
|
23
|
+
1. **AI Provider**: Which AI provider(s) will be used
|
|
24
|
+
2. **Processing Pipeline**: How content flows through AI systems
|
|
25
|
+
3. **Fallback Strategy**: What happens when AI fails
|
|
26
|
+
4. **Cost Considerations**: Expected API usage and costs
|
|
27
|
+
|
|
28
|
+
### Data Requirements
|
|
29
|
+
1. **Input Data**: What data is required
|
|
30
|
+
2. **Output Data**: What data is produced
|
|
31
|
+
3. **Storage Requirements**: How data is persisted
|
|
32
|
+
4. **Privacy Considerations**: Data handling and protection
|
|
33
|
+
|
|
34
|
+
## Technical Requirements
|
|
35
|
+
|
|
36
|
+
### API Design
|
|
37
|
+
- **Endpoints**: List of required API endpoints
|
|
38
|
+
- **Request/Response**: Data structures and validation
|
|
39
|
+
- **Authentication**: Security requirements
|
|
40
|
+
- **Rate Limiting**: Performance considerations
|
|
41
|
+
|
|
42
|
+
### Database Schema
|
|
43
|
+
- **Tables**: New or modified database tables
|
|
44
|
+
- **Indexes**: Performance optimization requirements
|
|
45
|
+
- **Migrations**: Database change requirements
|
|
46
|
+
|
|
47
|
+
### Frontend Components
|
|
48
|
+
- **UI Components**: New or modified React components
|
|
49
|
+
- **State Management**: Data flow and state handling
|
|
50
|
+
- **User Experience**: Interaction patterns and flows
|
|
51
|
+
|
|
52
|
+
## Non-Functional Requirements
|
|
53
|
+
|
|
54
|
+
### Performance
|
|
55
|
+
- **Response Time**: Expected API response times
|
|
56
|
+
- **Throughput**: Expected request volume
|
|
57
|
+
- **Scalability**: Growth and scaling considerations
|
|
58
|
+
|
|
59
|
+
### Reliability
|
|
60
|
+
- **Uptime**: Availability requirements
|
|
61
|
+
- **Error Handling**: Error scenarios and recovery
|
|
62
|
+
- **Monitoring**: Observability and alerting
|
|
63
|
+
|
|
64
|
+
### Security
|
|
65
|
+
- **Authentication**: User verification requirements
|
|
66
|
+
- **Authorization**: Access control requirements
|
|
67
|
+
- **Data Protection**: Privacy and security measures
|
|
68
|
+
|
|
69
|
+
## Acceptance Criteria
|
|
70
|
+
|
|
71
|
+
### Functional Acceptance
|
|
72
|
+
- [ ] **Criterion 1**: Specific, testable requirement
|
|
73
|
+
- [ ] **Criterion 2**: Specific, testable requirement
|
|
74
|
+
- [ ] **Criterion 3**: Specific, testable requirement
|
|
75
|
+
|
|
76
|
+
### Technical Acceptance
|
|
77
|
+
- [ ] **Criterion 1**: Performance or technical requirement
|
|
78
|
+
- [ ] **Criterion 2**: Performance or technical requirement
|
|
79
|
+
- [ ] **Criterion 3**: Performance or technical requirement
|
|
80
|
+
|
|
81
|
+
### AI Acceptance
|
|
82
|
+
- [ ] **Criterion 1**: AI accuracy or quality requirement
|
|
83
|
+
- [ ] **Criterion 2**: AI performance requirement
|
|
84
|
+
- [ ] **Criterion 3**: AI reliability requirement
|
|
85
|
+
|
|
86
|
+
## Dependencies
|
|
87
|
+
|
|
88
|
+
### Internal Dependencies
|
|
89
|
+
- **Feature A**: Required for this feature to work
|
|
90
|
+
- **Feature B**: Required for this feature to work
|
|
91
|
+
|
|
92
|
+
### External Dependencies
|
|
93
|
+
- **API Service**: External service requirements
|
|
94
|
+
- **AI Provider**: AI service requirements
|
|
95
|
+
- **Third-party Library**: Library requirements
|
|
96
|
+
|
|
97
|
+
## Risks and Mitigations
|
|
98
|
+
|
|
99
|
+
### Technical Risks
|
|
100
|
+
- **Risk 1**: Description and mitigation strategy
|
|
101
|
+
- **Risk 2**: Description and mitigation strategy
|
|
102
|
+
|
|
103
|
+
### AI Risks
|
|
104
|
+
- **Risk 1**: AI accuracy or availability risk
|
|
105
|
+
- **Risk 2**: AI cost or performance risk
|
|
106
|
+
|
|
107
|
+
### Business Risks
|
|
108
|
+
- **Risk 1**: User adoption or satisfaction risk
|
|
109
|
+
- **Risk 2**: Competitive or market risk
|
|
110
|
+
|
|
111
|
+
## Implementation Plan
|
|
112
|
+
|
|
113
|
+
### Phase 1: Foundation
|
|
114
|
+
- [ ] **Task 1**: Description and estimated effort
|
|
115
|
+
- [ ] **Task 2**: Description and estimated effort
|
|
116
|
+
|
|
117
|
+
### Phase 2: Core Implementation
|
|
118
|
+
- [ ] **Task 1**: Description and estimated effort
|
|
119
|
+
- [ ] **Task 2**: Description and estimated effort
|
|
120
|
+
|
|
121
|
+
### Phase 3: Integration and Testing
|
|
122
|
+
- [ ] **Task 1**: Description and estimated effort
|
|
123
|
+
- [ ] **Task 2**: Description and estimated effort
|
|
124
|
+
|
|
125
|
+
## Success Metrics
|
|
126
|
+
|
|
127
|
+
### User Metrics
|
|
128
|
+
- **Metric 1**: How success will be measured
|
|
129
|
+
- **Metric 2**: How success will be measured
|
|
130
|
+
|
|
131
|
+
### Technical Metrics
|
|
132
|
+
- **Metric 1**: Performance or reliability metric
|
|
133
|
+
- **Metric 2**: Performance or reliability metric
|
|
134
|
+
|
|
135
|
+
### AI Metrics
|
|
136
|
+
- **Metric 1**: AI accuracy or quality metric
|
|
137
|
+
- **Metric 2**: AI cost or efficiency metric
|
|
138
|
+
|
|
139
|
+
## Review and Acceptance Checklist
|
|
140
|
+
|
|
141
|
+
### Specification Review
|
|
142
|
+
- [ ] **Requirement Completeness**: All requirements clearly defined
|
|
143
|
+
- [ ] **Technical Feasibility**: Implementation approach validated
|
|
144
|
+
- [ ] **AI Integration**: AI capabilities and limitations understood
|
|
145
|
+
- [ ] **User Experience**: UX flow and interactions defined
|
|
146
|
+
|
|
147
|
+
### Technical Review
|
|
148
|
+
- [ ] **Architecture Alignment**: Fits with existing system architecture
|
|
149
|
+
- [ ] **Performance Impact**: Performance implications understood
|
|
150
|
+
- [ ] **Security Review**: Security implications addressed
|
|
151
|
+
- [ ] **Scalability**: Growth and scaling considerations addressed
|
|
152
|
+
|
|
153
|
+
### Business Review
|
|
154
|
+
- [ ] **User Value**: Clear value proposition for users
|
|
155
|
+
- [ ] **Resource Requirements**: Development effort and costs estimated
|
|
156
|
+
- [ ] **Timeline**: Realistic implementation timeline
|
|
157
|
+
- [ ] **Success Criteria**: Clear definition of success
|
|
158
|
+
|
|
159
|
+
|