aiwf 0.3.18 → 0.3.19
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/README.ko.md +84 -0
- package/README.md +87 -0
- package/ai-tools/README.md +105 -0
- package/ai-tools/augment/README.md +371 -0
- package/ai-tools/augment/config.json +30 -0
- package/ai-tools/augment/template/.augment/aiwf-integration.md +387 -0
- package/ai-tools/augment/template/.augment/augment.yaml +347 -0
- package/ai-tools/augment/template/augment.config.json +64 -0
- package/ai-tools/claude-code/README.md +151 -0
- package/ai-tools/claude-code/config.json +28 -0
- package/ai-tools/claude-code/template/CLAUDE.md +91 -0
- package/ai-tools/cursor/README.md +314 -0
- package/ai-tools/cursor/config.json +29 -0
- package/ai-tools/cursor/template/.cursorrules +362 -0
- package/ai-tools/github-copilot/README.md +195 -0
- package/ai-tools/github-copilot/config.json +24 -0
- package/ai-tools/github-copilot/template/.github/copilot-instructions.md +202 -0
- package/ai-tools/windsurf/README.md +355 -0
- package/ai-tools/windsurf/config.json +29 -0
- package/ai-tools/windsurf/template/.windsurf/aiwf-rules.md +260 -0
- package/ai-tools/windsurf/template/.windsurf/windsurf.config.js +312 -0
- package/ai-tools/windsurf/template/windsurf.config.json +63 -0
- package/docs/CODE_CLEANUP_GUIDE.ko.md +415 -0
- package/docs/CODE_CLEANUP_GUIDE.md +415 -0
- package/docs/VALIDATOR_API.ko.md +324 -0
- package/docs/VALIDATOR_API.md +324 -0
- package/package.json +3 -2
- package/src/cli/index.js +338 -0
- package/src/lib/backup-manager.js +4 -3
- package/src/lib/installer.js +126 -3
- package/src/lib/validator.js +78 -313
- package/src/utils/messages.js +16 -2
- package/src/utils/paths.js +1 -20
|
@@ -0,0 +1,312 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Windsurf AI Configuration for AIWF Projects
|
|
3
|
+
*
|
|
4
|
+
* This configuration enables Windsurf to understand and work with
|
|
5
|
+
* the AI Workflow Framework (AIWF) structure and conventions.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
module.exports = {
|
|
9
|
+
// Project context
|
|
10
|
+
projectType: 'aiwf',
|
|
11
|
+
frameworkVersion: '1.0.0',
|
|
12
|
+
|
|
13
|
+
// AIWF structure recognition
|
|
14
|
+
projectStructure: {
|
|
15
|
+
root: '.aiwf',
|
|
16
|
+
features: '.aiwf/06_FEATURE_LEDGERS',
|
|
17
|
+
sprints: '.aiwf/03_SPRINTS',
|
|
18
|
+
personas: '.aiwf/personas',
|
|
19
|
+
templates: '.aiwf/99_TEMPLATES'
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
// Code generation patterns
|
|
23
|
+
patterns: {
|
|
24
|
+
// Feature-based patterns
|
|
25
|
+
feature: {
|
|
26
|
+
template: 'aiwf-feature',
|
|
27
|
+
metadata: ['featureId', 'taskId', 'sprintId', 'persona'],
|
|
28
|
+
validation: 'always',
|
|
29
|
+
documentation: 'required'
|
|
30
|
+
},
|
|
31
|
+
|
|
32
|
+
// Service patterns
|
|
33
|
+
service: {
|
|
34
|
+
template: 'aiwf-service',
|
|
35
|
+
includes: ['feature-validation', 'error-handling', 'logging'],
|
|
36
|
+
baseClass: 'AiwfService'
|
|
37
|
+
},
|
|
38
|
+
|
|
39
|
+
// Component patterns
|
|
40
|
+
component: {
|
|
41
|
+
template: 'aiwf-component',
|
|
42
|
+
style: 'functional',
|
|
43
|
+
hooks: ['useFeature', 'useTask', 'usePersona']
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
|
|
47
|
+
// Context providers
|
|
48
|
+
contextProviders: [
|
|
49
|
+
{
|
|
50
|
+
name: 'featureLedger',
|
|
51
|
+
path: '.aiwf/06_FEATURE_LEDGERS',
|
|
52
|
+
parser: 'markdown',
|
|
53
|
+
cache: true
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
name: 'currentSprint',
|
|
57
|
+
path: '.aiwf/03_SPRINTS',
|
|
58
|
+
parser: 'aiwf-sprint',
|
|
59
|
+
watch: true
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
name: 'activePersona',
|
|
63
|
+
path: '.aiwf/current_persona.json',
|
|
64
|
+
parser: 'json',
|
|
65
|
+
watch: true
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
|
|
69
|
+
// Code suggestions behavior
|
|
70
|
+
suggestions: {
|
|
71
|
+
// Prioritize AIWF patterns
|
|
72
|
+
priorityPatterns: [
|
|
73
|
+
'feature-reference',
|
|
74
|
+
'task-implementation',
|
|
75
|
+
'sprint-alignment',
|
|
76
|
+
'persona-specific'
|
|
77
|
+
],
|
|
78
|
+
|
|
79
|
+
// Auto-include metadata
|
|
80
|
+
autoInclude: {
|
|
81
|
+
featureId: true,
|
|
82
|
+
taskId: true,
|
|
83
|
+
persona: true,
|
|
84
|
+
timestamp: false
|
|
85
|
+
},
|
|
86
|
+
|
|
87
|
+
// Validation rules
|
|
88
|
+
validation: {
|
|
89
|
+
requireFeatureId: true,
|
|
90
|
+
checkFeatureStatus: true,
|
|
91
|
+
validateTaskAlignment: true
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
|
|
95
|
+
// Persona-specific configurations
|
|
96
|
+
personas: {
|
|
97
|
+
architect: {
|
|
98
|
+
focus: ['design-patterns', 'architecture', 'scalability'],
|
|
99
|
+
suggestions: ['interfaces', 'abstractions', 'patterns'],
|
|
100
|
+
documentation: 'extensive'
|
|
101
|
+
},
|
|
102
|
+
security: {
|
|
103
|
+
focus: ['validation', 'sanitization', 'authentication'],
|
|
104
|
+
suggestions: ['security-checks', 'audit-logging', 'encryption'],
|
|
105
|
+
warnings: 'aggressive'
|
|
106
|
+
},
|
|
107
|
+
frontend: {
|
|
108
|
+
focus: ['ui-components', 'user-experience', 'performance'],
|
|
109
|
+
suggestions: ['react-patterns', 'optimization', 'accessibility'],
|
|
110
|
+
style: 'modern'
|
|
111
|
+
},
|
|
112
|
+
backend: {
|
|
113
|
+
focus: ['api-design', 'data-flow', 'scalability'],
|
|
114
|
+
suggestions: ['rest-patterns', 'database-optimization', 'caching'],
|
|
115
|
+
testing: 'comprehensive'
|
|
116
|
+
},
|
|
117
|
+
data_analyst: {
|
|
118
|
+
focus: ['data-processing', 'visualization', 'insights'],
|
|
119
|
+
suggestions: ['pandas-patterns', 'chart-types', 'statistics'],
|
|
120
|
+
documentation: 'detailed'
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
|
|
124
|
+
// Integration with AIWF commands
|
|
125
|
+
commands: {
|
|
126
|
+
// Feature operations
|
|
127
|
+
'Create Feature': {
|
|
128
|
+
command: 'aiwf ledger create',
|
|
129
|
+
shortcut: 'ctrl+shift+f',
|
|
130
|
+
context: 'always'
|
|
131
|
+
},
|
|
132
|
+
'Update Task': {
|
|
133
|
+
command: 'aiwf task update',
|
|
134
|
+
shortcut: 'ctrl+shift+t',
|
|
135
|
+
context: 'in-task'
|
|
136
|
+
},
|
|
137
|
+
'Switch Persona': {
|
|
138
|
+
command: 'aiwf persona use',
|
|
139
|
+
shortcut: 'ctrl+shift+p',
|
|
140
|
+
context: 'always'
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
|
|
144
|
+
// Code templates
|
|
145
|
+
templates: {
|
|
146
|
+
// Feature implementation template
|
|
147
|
+
'aiwf-feature': `/**
|
|
148
|
+
* @feature {{featureId}} - {{featureName}}
|
|
149
|
+
* @task {{taskId}} - {{taskName}}
|
|
150
|
+
* @sprint {{sprintId}}
|
|
151
|
+
* @persona {{activePersona}}
|
|
152
|
+
*/
|
|
153
|
+
|
|
154
|
+
import { FeatureLedger, TaskManager } from '@aiwf/core';
|
|
155
|
+
|
|
156
|
+
export class {{className}} {
|
|
157
|
+
constructor(
|
|
158
|
+
private ledger: FeatureLedger,
|
|
159
|
+
private taskManager: TaskManager
|
|
160
|
+
) {
|
|
161
|
+
this.validateFeature();
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
private async validateFeature() {
|
|
165
|
+
const feature = await this.ledger.getFeature('{{featureId}}');
|
|
166
|
+
if (feature.status !== 'active') {
|
|
167
|
+
throw new Error(\`Feature {{featureId}} is not active\`);
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
// Implementation here
|
|
172
|
+
}`,
|
|
173
|
+
|
|
174
|
+
// Service template
|
|
175
|
+
'aiwf-service': `/**
|
|
176
|
+
* {{serviceName}} Service
|
|
177
|
+
* @feature {{featureId}}
|
|
178
|
+
* @layer service
|
|
179
|
+
*/
|
|
180
|
+
|
|
181
|
+
import { BaseService } from '@aiwf/core';
|
|
182
|
+
import { Logger } from '@aiwf/logging';
|
|
183
|
+
|
|
184
|
+
export class {{serviceName}}Service extends BaseService {
|
|
185
|
+
private logger: Logger;
|
|
186
|
+
|
|
187
|
+
constructor() {
|
|
188
|
+
super('{{featureId}}');
|
|
189
|
+
this.logger = new Logger('{{serviceName}}Service');
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
// Service methods
|
|
193
|
+
}`,
|
|
194
|
+
|
|
195
|
+
// Test template
|
|
196
|
+
'aiwf-test': `/**
|
|
197
|
+
* Tests for {{featureName}}
|
|
198
|
+
* @feature {{featureId}}
|
|
199
|
+
* @task {{taskId}}
|
|
200
|
+
*/
|
|
201
|
+
|
|
202
|
+
import { describe, it, expect, beforeEach } from '@jest/globals';
|
|
203
|
+
import { {{className}} } from './{{fileName}}';
|
|
204
|
+
|
|
205
|
+
describe('Feature {{featureId}}: {{featureName}}', () => {
|
|
206
|
+
describe('Task {{taskId}}: {{taskName}}', () => {
|
|
207
|
+
let instance: {{className}};
|
|
208
|
+
|
|
209
|
+
beforeEach(() => {
|
|
210
|
+
instance = new {{className}}();
|
|
211
|
+
});
|
|
212
|
+
|
|
213
|
+
describe('Acceptance Criteria', () => {
|
|
214
|
+
it('should meet criteria 1', async () => {
|
|
215
|
+
// Test implementation
|
|
216
|
+
});
|
|
217
|
+
});
|
|
218
|
+
});
|
|
219
|
+
});`
|
|
220
|
+
},
|
|
221
|
+
|
|
222
|
+
// Import organization
|
|
223
|
+
importOrganization: {
|
|
224
|
+
order: [
|
|
225
|
+
'external',
|
|
226
|
+
'@aiwf/core',
|
|
227
|
+
'@aiwf/*',
|
|
228
|
+
'project',
|
|
229
|
+
'feature',
|
|
230
|
+
'relative'
|
|
231
|
+
],
|
|
232
|
+
grouping: true,
|
|
233
|
+
sorting: 'alphabetical'
|
|
234
|
+
},
|
|
235
|
+
|
|
236
|
+
// Error handling patterns
|
|
237
|
+
errorHandling: {
|
|
238
|
+
style: 'contextual',
|
|
239
|
+
includeFeatureContext: true,
|
|
240
|
+
standardErrors: {
|
|
241
|
+
'FeatureNotActive': 'Feature {{featureId}} is not active',
|
|
242
|
+
'TaskNotFound': 'Task {{taskId}} not found in sprint {{sprintId}}',
|
|
243
|
+
'PersonaMismatch': 'Current persona {{current}} does not match required {{required}}'
|
|
244
|
+
}
|
|
245
|
+
},
|
|
246
|
+
|
|
247
|
+
// Documentation generation
|
|
248
|
+
documentation: {
|
|
249
|
+
style: 'jsdoc',
|
|
250
|
+
required: ['feature', 'task', 'params', 'returns'],
|
|
251
|
+
autoGenerate: {
|
|
252
|
+
feature: true,
|
|
253
|
+
task: true,
|
|
254
|
+
sprint: true,
|
|
255
|
+
persona: true
|
|
256
|
+
}
|
|
257
|
+
},
|
|
258
|
+
|
|
259
|
+
// Performance optimization
|
|
260
|
+
performance: {
|
|
261
|
+
enableProfiling: true,
|
|
262
|
+
featureMetrics: true,
|
|
263
|
+
suggestions: {
|
|
264
|
+
memoization: true,
|
|
265
|
+
lazyLoading: true,
|
|
266
|
+
codeSpitting: true
|
|
267
|
+
}
|
|
268
|
+
},
|
|
269
|
+
|
|
270
|
+
// Security patterns
|
|
271
|
+
security: {
|
|
272
|
+
enableChecks: true,
|
|
273
|
+
patterns: {
|
|
274
|
+
inputValidation: 'always',
|
|
275
|
+
outputSanitization: 'always',
|
|
276
|
+
authentication: 'feature-based',
|
|
277
|
+
authorization: 'role-based'
|
|
278
|
+
}
|
|
279
|
+
},
|
|
280
|
+
|
|
281
|
+
// Git integration
|
|
282
|
+
git: {
|
|
283
|
+
commitFormat: '{{type}}({{featureId}}): {{message}}',
|
|
284
|
+
branchFormat: 'feature/{{featureId}}-{{name}}',
|
|
285
|
+
prTemplate: `## Feature: {{featureId}}
|
|
286
|
+
## Task: {{taskId}}
|
|
287
|
+
## Sprint: {{sprintId}}
|
|
288
|
+
|
|
289
|
+
### Changes
|
|
290
|
+
-
|
|
291
|
+
|
|
292
|
+
### Testing
|
|
293
|
+
- [ ] Unit tests pass
|
|
294
|
+
- [ ] Integration tests pass
|
|
295
|
+
- [ ] Acceptance criteria met
|
|
296
|
+
|
|
297
|
+
### Documentation
|
|
298
|
+
- [ ] Code documented
|
|
299
|
+
- [ ] Feature ledger updated
|
|
300
|
+
- [ ] Sprint log updated`
|
|
301
|
+
},
|
|
302
|
+
|
|
303
|
+
// Project-specific overrides
|
|
304
|
+
projectRules: {
|
|
305
|
+
// Add your project-specific rules here
|
|
306
|
+
},
|
|
307
|
+
|
|
308
|
+
// Disabled features
|
|
309
|
+
disabled: [
|
|
310
|
+
// Add any features to disable
|
|
311
|
+
]
|
|
312
|
+
};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"windsurf": {
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"aiwf_integration": {
|
|
5
|
+
"enabled": true,
|
|
6
|
+
"feature_ledger": {
|
|
7
|
+
"path": ".aiwf/feature-ledger/",
|
|
8
|
+
"auto_reference": true,
|
|
9
|
+
"validation": true
|
|
10
|
+
},
|
|
11
|
+
"personas": {
|
|
12
|
+
"path": ".aiwf/personas/",
|
|
13
|
+
"default": "developer",
|
|
14
|
+
"auto_switch": true
|
|
15
|
+
},
|
|
16
|
+
"sprints": {
|
|
17
|
+
"path": ".aiwf/03_SPRINTS/",
|
|
18
|
+
"track_progress": true,
|
|
19
|
+
"task_integration": true
|
|
20
|
+
},
|
|
21
|
+
"context": {
|
|
22
|
+
"compression_threshold": 1000,
|
|
23
|
+
"auto_compress": true,
|
|
24
|
+
"cache_compressed": true
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"cascade_settings": {
|
|
28
|
+
"aiwf_aware": true,
|
|
29
|
+
"feature_suggestions": true,
|
|
30
|
+
"task_context": true,
|
|
31
|
+
"persona_based_flow": true
|
|
32
|
+
},
|
|
33
|
+
"workspace": {
|
|
34
|
+
"feature_first": true,
|
|
35
|
+
"sprint_aligned": true,
|
|
36
|
+
"documentation_sync": true
|
|
37
|
+
},
|
|
38
|
+
"ai_settings": {
|
|
39
|
+
"model_preferences": {
|
|
40
|
+
"fast_tasks": "cascade-small",
|
|
41
|
+
"complex_tasks": "cascade-large",
|
|
42
|
+
"architecture": "cascade-architect"
|
|
43
|
+
},
|
|
44
|
+
"context_management": {
|
|
45
|
+
"max_tokens": 100000,
|
|
46
|
+
"compression_enabled": true,
|
|
47
|
+
"feature_context_priority": true
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"shortcuts": {
|
|
51
|
+
"check_feature": "cmd+shift+f",
|
|
52
|
+
"update_task": "cmd+shift+t",
|
|
53
|
+
"switch_persona": "cmd+shift+p",
|
|
54
|
+
"compress_context": "cmd+shift+c"
|
|
55
|
+
},
|
|
56
|
+
"automation": {
|
|
57
|
+
"auto_update_task_status": true,
|
|
58
|
+
"auto_reference_features": true,
|
|
59
|
+
"auto_compress_large_files": true,
|
|
60
|
+
"auto_sync_documentation": true
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|