elsabro 2.2.0 → 3.7.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.
Files changed (88) hide show
  1. package/README.md +668 -20
  2. package/agents/elsabro-orchestrator.md +113 -0
  3. package/bin/install.js +0 -0
  4. package/commands/elsabro/execute.md +223 -46
  5. package/commands/elsabro/start.md +34 -0
  6. package/commands/elsabro/verify-work.md +29 -0
  7. package/flows/development-flow.json +452 -0
  8. package/flows/quick-flow.json +118 -0
  9. package/hooks/confirm-destructive.sh +145 -0
  10. package/hooks/hooks-config.json +81 -0
  11. package/hooks/lint-check.sh +238 -0
  12. package/hooks/post-edit-test.sh +189 -0
  13. package/package.json +5 -3
  14. package/references/SYSTEM_INDEX.md +379 -5
  15. package/references/agent-marketplace.md +2274 -0
  16. package/references/agent-protocol.md +1126 -0
  17. package/references/ai-code-suggestions.md +2413 -0
  18. package/references/checkpointing.md +595 -0
  19. package/references/collaboration-patterns.md +851 -0
  20. package/references/collaborative-sessions.md +1081 -0
  21. package/references/configuration-management.md +1810 -0
  22. package/references/cost-tracking.md +1095 -0
  23. package/references/enterprise-sso.md +2001 -0
  24. package/references/error-contracts-tests.md +1171 -0
  25. package/references/error-contracts-v2.md +968 -0
  26. package/references/error-contracts.md +3102 -0
  27. package/references/event-driven.md +1031 -0
  28. package/references/flow-orchestration.md +940 -0
  29. package/references/flow-visualization.md +1557 -0
  30. package/references/ide-integrations.md +3513 -0
  31. package/references/interrupt-system.md +681 -0
  32. package/references/kubernetes-deployment.md +3099 -0
  33. package/references/memory-system.md +683 -0
  34. package/references/mobile-companion.md +3236 -0
  35. package/references/multi-llm-providers.md +2494 -0
  36. package/references/multi-project-memory.md +1182 -0
  37. package/references/observability.md +793 -0
  38. package/references/output-schemas.md +858 -0
  39. package/references/parallel-worktrees.md +293 -0
  40. package/references/performance-profiler.md +955 -0
  41. package/references/plugin-system.md +1526 -0
  42. package/references/prompt-management.md +292 -0
  43. package/references/sandbox-execution.md +303 -0
  44. package/references/security-system.md +1253 -0
  45. package/references/streaming.md +696 -0
  46. package/references/testing-framework.md +1151 -0
  47. package/references/time-travel.md +802 -0
  48. package/references/tool-registry.md +886 -0
  49. package/references/voice-commands.md +3296 -0
  50. package/scripts/setup-parallel-worktrees.sh +319 -0
  51. package/skills/memory-update.md +207 -0
  52. package/skills/review.md +331 -0
  53. package/skills/techdebt.md +289 -0
  54. package/skills/tutor.md +219 -0
  55. package/templates/.planning/notes/.gitkeep +0 -0
  56. package/templates/CLAUDE.md.template +48 -0
  57. package/templates/agent-marketplace-config.json +220 -0
  58. package/templates/agent-protocol-config.json +136 -0
  59. package/templates/ai-suggestions-config.json +100 -0
  60. package/templates/checkpoint-state.json +61 -0
  61. package/templates/collaboration-config.json +157 -0
  62. package/templates/collaborative-sessions-config.json +153 -0
  63. package/templates/configuration-config.json +245 -0
  64. package/templates/cost-tracking-config.json +148 -0
  65. package/templates/enterprise-sso-config.json +438 -0
  66. package/templates/error-handling-config.json +79 -2
  67. package/templates/events-config.json +148 -0
  68. package/templates/flow-visualization-config.json +196 -0
  69. package/templates/ide-integrations-config.json +442 -0
  70. package/templates/kubernetes-config.json +764 -0
  71. package/templates/memory-state.json +84 -0
  72. package/templates/mistakes.md.template +52 -0
  73. package/templates/mobile-companion-config.json +600 -0
  74. package/templates/multi-llm-config.json +544 -0
  75. package/templates/multi-project-memory-config.json +145 -0
  76. package/templates/observability-config.json +109 -0
  77. package/templates/patterns.md.template +114 -0
  78. package/templates/performance-profiler-config.json +125 -0
  79. package/templates/plugin-config.json +170 -0
  80. package/templates/prompt-management-config.json +86 -0
  81. package/templates/sandbox-config.json +185 -0
  82. package/templates/schemas-config.json +65 -0
  83. package/templates/security-config.json +120 -0
  84. package/templates/streaming-config.json +72 -0
  85. package/templates/testing-config.json +81 -0
  86. package/templates/timetravel-config.json +62 -0
  87. package/templates/tool-registry-config.json +109 -0
  88. package/templates/voice-commands-config.json +658 -0
@@ -0,0 +1,109 @@
1
+ {
2
+ "observability": {
3
+ "enabled": true,
4
+ "serviceName": "elsabro",
5
+ "environment": "development",
6
+ "version": "3.0.0",
7
+
8
+ "tracing": {
9
+ "enabled": true,
10
+ "samplingRate": 1.0,
11
+ "propagation": "w3c",
12
+ "exporters": ["console"],
13
+ "spanProcessors": {
14
+ "batch": {
15
+ "maxQueueSize": 2048,
16
+ "maxExportBatchSize": 512,
17
+ "scheduledDelayMillis": 5000
18
+ }
19
+ }
20
+ },
21
+
22
+ "metrics": {
23
+ "enabled": true,
24
+ "collectionInterval": 60000,
25
+ "exporters": ["console"],
26
+ "predefinedMetrics": {
27
+ "agents": true,
28
+ "flows": true,
29
+ "checkpoints": true,
30
+ "interrupts": true,
31
+ "memory": true
32
+ },
33
+ "histogramBuckets": {
34
+ "duration": [1, 5, 10, 30, 60, 120, 300],
35
+ "tokens": [100, 500, 1000, 5000, 10000, 50000]
36
+ }
37
+ },
38
+
39
+ "logging": {
40
+ "enabled": true,
41
+ "level": "INFO",
42
+ "structured": true,
43
+ "includeTraceContext": true,
44
+ "exporters": ["console"],
45
+ "format": {
46
+ "timestamp": true,
47
+ "level": true,
48
+ "message": true,
49
+ "context": true
50
+ }
51
+ },
52
+
53
+ "events": {
54
+ "enabled": true,
55
+ "types": [
56
+ "agent.started",
57
+ "agent.completed",
58
+ "agent.failed",
59
+ "flow.started",
60
+ "flow.completed",
61
+ "checkpoint.saved",
62
+ "checkpoint.restored",
63
+ "interrupt.triggered",
64
+ "interrupt.resolved",
65
+ "memory.learned",
66
+ "error.occurred"
67
+ ]
68
+ },
69
+
70
+ "exporters": {
71
+ "console": {
72
+ "enabled": true,
73
+ "colorize": true,
74
+ "prettyPrint": true
75
+ },
76
+ "file": {
77
+ "enabled": false,
78
+ "path": ".planning/telemetry/",
79
+ "format": "jsonl",
80
+ "rotation": {
81
+ "enabled": true,
82
+ "maxSize": "10MB",
83
+ "maxFiles": 5
84
+ }
85
+ },
86
+ "jaeger": {
87
+ "enabled": false,
88
+ "endpoint": "http://localhost:14268/api/traces",
89
+ "serviceName": "elsabro"
90
+ },
91
+ "langtrace": {
92
+ "enabled": false,
93
+ "apiKey": "",
94
+ "projectId": ""
95
+ },
96
+ "otlp": {
97
+ "enabled": false,
98
+ "endpoint": "http://localhost:4318",
99
+ "protocol": "http/protobuf"
100
+ }
101
+ },
102
+
103
+ "dashboard": {
104
+ "refreshInterval": 5000,
105
+ "showActiveOnly": false,
106
+ "historyLimit": 100
107
+ }
108
+ }
109
+ }
@@ -0,0 +1,114 @@
1
+ # Patrones Preferidos
2
+
3
+ > Este archivo contiene patrones de codigo que el proyecto prefiere.
4
+ > Claude usa estos patrones como referencia al escribir codigo nuevo.
5
+
6
+ ## Componentes React
7
+
8
+ ```tsx
9
+ // Estructura preferida de componente
10
+ interface Props {
11
+ // Props tipadas
12
+ }
13
+
14
+ export function ComponentName({ prop1, prop2 }: Props) {
15
+ // Hooks primero
16
+ const [state, setState] = useState<Type>(initial);
17
+
18
+ // Efectos despues
19
+ useEffect(() => {
20
+ // ...
21
+ }, [deps]);
22
+
23
+ // Handlers
24
+ const handleClick = () => {
25
+ // ...
26
+ };
27
+
28
+ // Early returns para casos edge
29
+ if (!data) return <Loading />;
30
+
31
+ // Render principal
32
+ return (
33
+ <div>
34
+ {/* ... */}
35
+ </div>
36
+ );
37
+ }
38
+ ```
39
+
40
+ ## Custom Hooks
41
+
42
+ ```tsx
43
+ // Estructura preferida de hook
44
+ export function useCustomHook(param: Type) {
45
+ const [state, setState] = useState<Type>(initial);
46
+
47
+ useEffect(() => {
48
+ // Efecto
49
+ return () => {
50
+ // Cleanup
51
+ };
52
+ }, [param]);
53
+
54
+ return { state, actions };
55
+ }
56
+ ```
57
+
58
+ ## API Calls
59
+
60
+ ```tsx
61
+ // Patron preferido para fetch
62
+ async function fetchData<T>(url: string): Promise<T> {
63
+ const response = await fetch(url);
64
+
65
+ if (!response.ok) {
66
+ throw new Error(`HTTP ${response.status}: ${response.statusText}`);
67
+ }
68
+
69
+ return response.json();
70
+ }
71
+ ```
72
+
73
+ ## Error Handling
74
+
75
+ ```tsx
76
+ // Patron preferido para errores
77
+ try {
78
+ const result = await riskyOperation();
79
+ return { success: true, data: result };
80
+ } catch (error) {
81
+ console.error('[Context]:', error);
82
+ return { success: false, error: error.message };
83
+ }
84
+ ```
85
+
86
+ ## Testing
87
+
88
+ ```tsx
89
+ // Estructura preferida de test
90
+ describe('ComponentName', () => {
91
+ it('should render correctly', () => {
92
+ render(<ComponentName />);
93
+ expect(screen.getByRole('button')).toBeInTheDocument();
94
+ });
95
+
96
+ it('should handle user interaction', async () => {
97
+ const user = userEvent.setup();
98
+ render(<ComponentName />);
99
+
100
+ await user.click(screen.getByRole('button'));
101
+
102
+ expect(/* resultado */).toBe(/* esperado */);
103
+ });
104
+ });
105
+ ```
106
+
107
+ ---
108
+
109
+ ## Como Agregar Patrones
110
+
111
+ Cuando quieras que Claude use un patron especifico, di:
112
+ - "Siempre usa este patron para..."
113
+ - "Prefiero que los componentes se vean asi..."
114
+ - "Guarda este patron en tu memoria"
@@ -0,0 +1,125 @@
1
+ {
2
+ "performanceProfiler": {
3
+ "enabled": true,
4
+ "version": "1.0.0",
5
+
6
+ "profiler": {
7
+ "defaultMode": "sampling",
8
+ "samplingInterval": 100,
9
+ "maxSamples": 10000,
10
+ "captureStacks": true,
11
+ "stackDepth": 20,
12
+ "autoStart": false,
13
+ "targets": [
14
+ { "type": "agent", "pattern": "*" },
15
+ { "type": "flow", "pattern": "*" },
16
+ { "type": "tool", "pattern": "*" }
17
+ ]
18
+ },
19
+
20
+ "tracing": {
21
+ "enabled": true,
22
+ "traceAgents": true,
23
+ "traceFlows": true,
24
+ "traceTools": true,
25
+ "traceLLMCalls": true,
26
+ "minDuration": 100,
27
+ "captureMetadata": true
28
+ },
29
+
30
+ "bottleneckDetection": {
31
+ "enabled": true,
32
+ "realtime": true,
33
+ "thresholds": {
34
+ "latencyP95": 30000,
35
+ "latencyP99": 60000,
36
+ "throughputMin": 0.1,
37
+ "memoryPressure": 0.8,
38
+ "errorRate": 0.05
39
+ },
40
+ "autoAnalyze": true,
41
+ "analyzeInterval": 60000
42
+ },
43
+
44
+ "memory": {
45
+ "trackHeap": true,
46
+ "trackGC": true,
47
+ "leakDetection": true,
48
+ "leakThreshold": 0.1,
49
+ "snapshotOnLeak": false
50
+ },
51
+
52
+ "latency": {
53
+ "trackPercentiles": [50, 75, 90, 95, 99],
54
+ "histogramBuckets": [100, 500, 1000, 5000, 10000, 30000, 60000],
55
+ "sloTargets": {
56
+ "agent": { "p95": 30000, "p99": 60000 },
57
+ "tool": { "p95": 5000, "p99": 10000 },
58
+ "flow": { "p95": 120000, "p99": 300000 }
59
+ }
60
+ },
61
+
62
+ "dashboard": {
63
+ "enabled": true,
64
+ "refreshInterval": 1000,
65
+ "showHotspots": true,
66
+ "showBottlenecks": true,
67
+ "showRecommendations": true,
68
+ "showResourceUsage": true,
69
+ "maxHotspots": 10,
70
+ "maxBottlenecks": 5,
71
+ "maxRecommendations": 5
72
+ },
73
+
74
+ "export": {
75
+ "formats": ["json", "flamegraph", "chrome-trace"],
76
+ "autoExport": false,
77
+ "exportPath": ".elsabro/profiles",
78
+ "retention": {
79
+ "enabled": true,
80
+ "maxProfiles": 50,
81
+ "maxAge": 604800000
82
+ }
83
+ },
84
+
85
+ "alerts": {
86
+ "enabled": true,
87
+ "channels": ["console"],
88
+ "rules": [
89
+ {
90
+ "name": "high-latency",
91
+ "condition": "p95 > 60000",
92
+ "severity": "high",
93
+ "cooldown": 300000
94
+ },
95
+ {
96
+ "name": "memory-leak",
97
+ "condition": "heapTrend > 0.1",
98
+ "severity": "critical",
99
+ "cooldown": 600000
100
+ },
101
+ {
102
+ "name": "low-throughput",
103
+ "condition": "throughput < 0.05",
104
+ "severity": "medium",
105
+ "cooldown": 180000
106
+ }
107
+ ]
108
+ },
109
+
110
+ "benchmarking": {
111
+ "enabled": true,
112
+ "defaultIterations": 5,
113
+ "warmupIterations": 1,
114
+ "cooldownMs": 1000,
115
+ "compareBaseline": true,
116
+ "baselinePath": ".elsabro/baselines"
117
+ },
118
+
119
+ "integration": {
120
+ "observability": true,
121
+ "costTracking": true,
122
+ "flowEngine": true
123
+ }
124
+ }
125
+ }
@@ -0,0 +1,170 @@
1
+ {
2
+ "plugins": {
3
+ "enabled": true,
4
+ "version": "1.0.0",
5
+
6
+ "discovery": {
7
+ "sources": [
8
+ {
9
+ "type": "directory",
10
+ "path": ".elsabro/plugins",
11
+ "enabled": true
12
+ },
13
+ {
14
+ "type": "directory",
15
+ "path": "~/.elsabro/global-plugins",
16
+ "enabled": true
17
+ },
18
+ {
19
+ "type": "npm",
20
+ "scope": "@elsabro",
21
+ "enabled": false
22
+ }
23
+ ],
24
+ "autoDiscover": true,
25
+ "scanInterval": 60000
26
+ },
27
+
28
+ "loading": {
29
+ "validateManifest": true,
30
+ "checkDependencies": true,
31
+ "timeout": 30000,
32
+ "parallel": false
33
+ },
34
+
35
+ "activation": {
36
+ "autoActivate": true,
37
+ "activateOnStartup": true,
38
+ "lazyActivation": true,
39
+ "activationTimeout": 10000
40
+ },
41
+
42
+ "hotReload": {
43
+ "enabled": true,
44
+ "watchPatterns": ["**/*.js", "**/*.ts", "**/*.json"],
45
+ "ignorePatterns": ["**/node_modules/**", "**/.git/**"],
46
+ "debounce": 1000
47
+ },
48
+
49
+ "sandbox": {
50
+ "enabled": true,
51
+ "timeout": 30000,
52
+ "resourceLimits": {
53
+ "memory": 134217728,
54
+ "cpu": 0.5
55
+ },
56
+ "allowedBuiltins": ["path", "url", "util", "events", "crypto"],
57
+ "blockedBuiltins": ["child_process", "cluster", "dgram", "dns", "net", "tls", "vm", "worker_threads"]
58
+ },
59
+
60
+ "permissions": {
61
+ "promptUser": true,
62
+ "rememberChoice": true,
63
+ "defaultDeny": true,
64
+ "trustedPublishers": [],
65
+ "definitions": {
66
+ "filesystem:read": {
67
+ "name": "Read Files",
68
+ "description": "Read files from the filesystem",
69
+ "risk": "low"
70
+ },
71
+ "filesystem:write": {
72
+ "name": "Write Files",
73
+ "description": "Create or modify files on the filesystem",
74
+ "risk": "medium"
75
+ },
76
+ "network": {
77
+ "name": "Network Access",
78
+ "description": "Make HTTP/HTTPS requests to external services",
79
+ "risk": "medium"
80
+ },
81
+ "shell": {
82
+ "name": "Execute Commands",
83
+ "description": "Run shell commands and scripts",
84
+ "risk": "high"
85
+ },
86
+ "env": {
87
+ "name": "Environment Variables",
88
+ "description": "Access environment variables",
89
+ "risk": "low"
90
+ },
91
+ "secrets": {
92
+ "name": "Secrets Access",
93
+ "description": "Access the secrets vault",
94
+ "risk": "high"
95
+ },
96
+ "config:read": {
97
+ "name": "Read Configuration",
98
+ "description": "Read ELSABRO configuration",
99
+ "risk": "low"
100
+ },
101
+ "config:write": {
102
+ "name": "Write Configuration",
103
+ "description": "Modify ELSABRO configuration",
104
+ "risk": "medium"
105
+ }
106
+ }
107
+ },
108
+
109
+ "storage": {
110
+ "path": ".elsabro/plugin-data",
111
+ "maxSizePerPlugin": 52428800,
112
+ "backupEnabled": true,
113
+ "encryptSensitive": true
114
+ },
115
+
116
+ "registry": {
117
+ "deduplicateContributions": true,
118
+ "allowOverrides": false,
119
+ "namespaceContributions": true
120
+ },
121
+
122
+ "hooks": {
123
+ "enabled": true,
124
+ "timeout": 5000,
125
+ "continueOnError": true,
126
+ "builtinPoints": [
127
+ "agent:beforeRun",
128
+ "agent:afterRun",
129
+ "tool:beforeExecute",
130
+ "tool:afterExecute",
131
+ "llm:beforeCall",
132
+ "llm:afterCall",
133
+ "config:change",
134
+ "plugin:activate",
135
+ "plugin:deactivate",
136
+ "session:start",
137
+ "session:end",
138
+ "error:occurred"
139
+ ]
140
+ },
141
+
142
+ "marketplace": {
143
+ "enabled": false,
144
+ "url": "https://plugins.elsabro.dev",
145
+ "checkUpdates": true,
146
+ "updateCheckInterval": 86400000,
147
+ "autoUpdate": false
148
+ },
149
+
150
+ "telemetry": {
151
+ "enabled": false,
152
+ "collectUsage": false,
153
+ "collectErrors": true,
154
+ "anonymize": true
155
+ },
156
+
157
+ "logging": {
158
+ "enabled": true,
159
+ "level": "info",
160
+ "perPlugin": true,
161
+ "logPath": ".elsabro/logs/plugins"
162
+ },
163
+
164
+ "defaults": {
165
+ "disabled": [],
166
+ "alwaysEnabled": [],
167
+ "preInstalled": []
168
+ }
169
+ }
170
+ }
@@ -0,0 +1,86 @@
1
+ {
2
+ "promptManagement": {
3
+ "enabled": true,
4
+ "version": "1.0.0",
5
+
6
+ "registry": {
7
+ "loadBuiltins": true,
8
+ "customPath": ".elsabro/prompts",
9
+ "watchForChanges": true,
10
+ "cacheEnabled": true,
11
+ "cacheTTL": 300000
12
+ },
13
+
14
+ "engine": {
15
+ "strictMode": false,
16
+ "escapeHtml": false,
17
+ "maxTemplateSize": 100000,
18
+ "maxNestingDepth": 10,
19
+ "customHelpers": {}
20
+ },
21
+
22
+ "variables": {
23
+ "validation": {
24
+ "enabled": true,
25
+ "strict": false
26
+ },
27
+ "defaults": {
28
+ "language": "typescript",
29
+ "framework": null
30
+ }
31
+ },
32
+
33
+ "versioning": {
34
+ "strategy": "semver",
35
+ "autoIncrement": false,
36
+ "keepVersions": 10
37
+ },
38
+
39
+ "experiments": {
40
+ "enabled": true,
41
+ "minSampleSize": 30,
42
+ "maxConcurrent": 5,
43
+ "defaultTrafficSplit": "equal",
44
+ "defaultMetrics": ["success_rate", "quality_score", "completion_time"],
45
+ "autoAnalyze": true,
46
+ "confidenceThreshold": 0.95,
47
+ "persistence": {
48
+ "enabled": true,
49
+ "path": ".elsabro/experiments"
50
+ }
51
+ },
52
+
53
+ "builtinTemplates": {
54
+ "explore": { "enabled": true, "category": "exploration" },
55
+ "implement": { "enabled": true, "category": "implementation" },
56
+ "review": { "enabled": true, "category": "review" },
57
+ "plan": { "enabled": true, "category": "planning" },
58
+ "debug": { "enabled": true, "category": "debugging" },
59
+ "test": { "enabled": true, "category": "testing" }
60
+ },
61
+
62
+ "categories": [
63
+ "exploration",
64
+ "implementation",
65
+ "review",
66
+ "planning",
67
+ "debugging",
68
+ "testing",
69
+ "documentation",
70
+ "analysis",
71
+ "custom"
72
+ ],
73
+
74
+ "export": {
75
+ "formats": ["json", "yaml"],
76
+ "includeMetadata": true,
77
+ "includeExperiments": false
78
+ },
79
+
80
+ "logging": {
81
+ "enabled": true,
82
+ "logRenders": false,
83
+ "logExperiments": true
84
+ }
85
+ }
86
+ }