@defai.digital/automatosx 5.6.21 → 5.6.23

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.md CHANGED
@@ -13,7 +13,9 @@ AutomatosX is a CLI-first orchestration tool that transforms stateless AI assist
13
13
  [![Windows](https://img.shields.io/badge/Windows-10+-blue.svg)](https://www.microsoft.com/windows)
14
14
  [![Ubuntu](https://img.shields.io/badge/Ubuntu-24.04-orange.svg)](https://ubuntu.com)
15
15
 
16
- **Status**: ✅ Production Ready · **v5.6.21** · October 2025 · 24 Specialized Agents · 100% Resource Leak Free · Production Stability
16
+ **Status**: ✅ Production Ready · **v5.6.23** · October 2025 · 19 Specialized Agents · 100% Resource Leak Free · Production Stability
17
+
18
+ **Latest (v5.6.23)**: Code quality tooling - Added ESLint configuration for automated async/promise pattern detection and timer cleanup verification script. [See full changelog →](CHANGELOG.md)
17
19
 
18
20
  ---
19
21
 
@@ -125,33 +127,29 @@ ax run product "Build a complete user authentication feature"
125
127
 
126
128
  ---
127
129
 
128
- ## 🎭 24 Specialized Agents
129
-
130
- AutomatosX comes with a pre-built team of 24 agents, each with a specific role and expertise. This ensures the right specialist is always available for the task at hand.
131
-
132
- - **Backend** (API design, databases, Go/Rust systems)
133
- - **Frontend** (React/Next.js/Swift UI)
134
- - **Fullstack** (Node.js/TypeScript + Python)
135
- - **Mobile** (iOS/Android, Swift/Kotlin/Flutter)
136
- - **DevOps** (CI/CD, infrastructure)
137
- - **Security** (Audits, threat modeling)
138
- - **Data Science** (ML strategy, statistical analysis)
139
- - **ML Engineer** (PyTorch/TensorFlow, CNN/Transformer, LLM fine-tuning)
140
- - **Best Practices - Stan** (SOLID, design patterns, clean code, refactoring, architecture) ✨ NEW in v5.6.21
141
- - **ERP Integration** (SAP, Oracle, Dynamics 365, enterprise integration patterns)
142
- - **Figma Expert** (Figma API, design tokens, design-to-code, MCP integration) ✨ NEW in v5.6.10
143
- - **IoT/Embedded Engineer** (MQTT, ROS2, FreeRTOS, edge computing, robotics) ✨ NEW in v5.6.10
144
- - **Data** (ETL, SQL, modeling)
145
- - **Quality** (Testing, code reviews)
146
- - **Design** (UX research, wireframes)
147
- - **Writer** (Documentation, reports)
148
- - **Creative Marketer** (Content strategy)
149
- - **Product** (Roadmaps, strategy)
150
- - **CTO** (Technical strategy)
151
- - **CEO** (Business leadership)
152
- - **Researcher** (Feasibility studies)
153
- - **Quantum Engineer** (Quantum algorithms, Qiskit/Cirq, error correction)
154
- - **Aerospace Scientist** (Orbital mechanics, mission analysis, telemetry)
130
+ ## 🎭 19 Specialized Agents
131
+
132
+ AutomatosX comes with a pre-built team of 19 agents, each with a specific role and expertise. This ensures the right specialist is always available for the task at hand.
133
+
134
+ - **Astrid** - Aerospace Scientist (Orbital mechanics, mission analysis, telemetry)
135
+ - **Bob** - Backend Engineer (API design, databases, Go/Rust systems)
136
+ - **Candy** - Creative Marketer (Content strategy)
137
+ - **Daisy** - Data Engineer (ETL, SQL, modeling)
138
+ - **Dana** - Data Scientist (ML strategy, statistical analysis)
139
+ - **Debbee** - UX Designer (UX research, wireframes)
140
+ - **Eric** - CEO (Business leadership)
141
+ - **Felix** - Fullstack Engineer (Node.js/TypeScript + Python)
142
+ - **Frank** - Frontend Engineer (React/Next.js/Swift UI)
143
+ - **Maya** - Mobile Engineer (iOS/Android, Swift/Kotlin/Flutter)
144
+ - **Oliver** - DevOps Engineer (CI/CD, infrastructure)
145
+ - **Paris** - Product Manager (Roadmaps, strategy)
146
+ - **Peter** - Best Practices Expert (SOLID, design patterns, clean code, refactoring, architecture) ✨ NEW in v5.6.21
147
+ - **Queenie** - Quality Specialist (Testing, code reviews)
148
+ - **Quinn** - Quantum Engineer (Quantum algorithms, Qiskit/Cirq, error correction)
149
+ - **Rodman** - Researcher (Feasibility studies)
150
+ - **Steve** - Security Engineer (Audits, threat modeling)
151
+ - **Tony** - CTO (Technical strategy)
152
+ - **Wendy** - Technical Writer (Documentation, reports)
155
153
 
156
154
  **Governance**: Agents have clear roles, permissions, and delegation limits (`maxDelegationDepth`) to ensure efficient and safe collaboration while preventing infinite loops.
157
155
 
package/dist/index.js CHANGED
@@ -13501,6 +13501,8 @@ function createMemoryClearHandler(deps) {
13501
13501
 
13502
13502
  // src/mcp/server.ts
13503
13503
  var McpServer = class {
13504
+ // Use 'any' for heterogeneous tool handlers to avoid unsafe type casts
13505
+ // Runtime validation via validateToolInput provides type safety
13504
13506
  tools = /* @__PURE__ */ new Map();
13505
13507
  toolSchemas = [];
13506
13508
  initialized = false;
@@ -13607,6 +13609,22 @@ var McpServer = class {
13607
13609
  });
13608
13610
  logger.info("[MCP Server] Services initialized successfully");
13609
13611
  }
13612
+ /**
13613
+ * Cleanup resources before shutdown
13614
+ */
13615
+ async cleanup() {
13616
+ logger.info("[MCP Server] Performing cleanup...");
13617
+ try {
13618
+ if (this.memoryManager) {
13619
+ await this.memoryManager.close();
13620
+ }
13621
+ logger.info("[MCP Server] Cleanup completed");
13622
+ } catch (error) {
13623
+ logger.error("[MCP Server] Cleanup failed", {
13624
+ error: error instanceof Error ? error.message : String(error)
13625
+ });
13626
+ }
13627
+ }
13610
13628
  /**
13611
13629
  * Register Phase 1 tools
13612
13630
  */
@@ -14259,16 +14277,19 @@ ${json}`;
14259
14277
  }
14260
14278
  }
14261
14279
  });
14262
- process.stdin.on("end", () => {
14280
+ process.stdin.on("end", async () => {
14263
14281
  logger.info("[MCP Server] Server stopped (stdin closed)");
14282
+ await this.cleanup();
14264
14283
  process.exit(0);
14265
14284
  });
14266
- process.on("SIGINT", () => {
14285
+ process.on("SIGINT", async () => {
14267
14286
  logger.info("[MCP Server] Received SIGINT, shutting down...");
14287
+ await this.cleanup();
14268
14288
  process.exit(0);
14269
14289
  });
14270
- process.on("SIGTERM", () => {
14290
+ process.on("SIGTERM", async () => {
14271
14291
  logger.info("[MCP Server] Received SIGTERM, shutting down...");
14292
+ await this.cleanup();
14272
14293
  process.exit(0);
14273
14294
  });
14274
14295
  logger.info("[MCP Server] Server started successfully (Content-Length framing)");
@@ -1,11 +1,11 @@
1
1
  # AutomatosX Agent Directory
2
2
 
3
- **v5.6.21 Update - Stan Agent Implementation**:
4
- - ✨ **New Best Practices Agent**: Stan (Software Engineering Standards Expert) - SOLID, design patterns, clean code, refactoring, software architecture
3
+ **v5.6.21 Update - Peter Agent Implementation**:
4
+ - ✨ **New Best Practices Agent**: Peter (Software Engineering Peterdards Expert) - SOLID, design patterns, clean code, refactoring, software architecture
5
5
  - 📚 **5 New Best Practices Abilities**: solid-principles, design-patterns, clean-code, refactoring, software-architecture (~8,200 lines)
6
- - 🔧 **Enhanced Queenie**: Added base-level best-practices ability with delegation pattern to Stan
7
- - 🤝 **Collaboration Model**: Queenie (quality/bugs/tests) ↔ Stan (standards/patterns/architecture)
8
- - 🤖 **24 Total Agents**: Stan fills critical ownership gap for SOLID principles and architecture standards
6
+ - 🔧 **Enhanced Queenie**: Added base-level best-practices ability with delegation pattern to Peter
7
+ - 🤝 **Collaboration Model**: Queenie (quality/bugs/tests) ↔ Peter (standards/patterns/architecture)
8
+ - 🤖 **24 Total Agents**: Peter fills critical ownership gap for SOLID principles and architecture standards
9
9
 
10
10
  **v5.6.10 Update - Four New Specialist Agents (Completed in One Release)**:
11
11
  - ✨ **New ERP Integration Agent**: Emma (ERP Integration Specialist) - SAP, Oracle, Dynamics 365, enterprise integration patterns
@@ -14,7 +14,7 @@
14
14
  - ✨ **New ML Engineer Agent**: Mira (Deep Learning Specialist) - PyTorch/TensorFlow implementation expert (from earlier in v5.6.10)
15
15
  - 🧠 **Enhanced Dana**: Strategic DL guidance (architecture selection, framework choice, evaluation metrics)
16
16
  - 📚 **17 New Abilities**: 5 best practices + 4 ERP + 4 Figma + 4 IoT + 4 deep learning (~11,269 lines, 283+ keywords)
17
- - 🤖 **24 Total Agents** (was 19): Stan, Emma, Fiona, Ivy, Mira added in v5.6.10
17
+ - 🤖 **24 Total Agents** (was 19): Peter, Emma, Fiona, Ivy, Mira added in v5.6.10
18
18
 
19
19
  **v5.6.9 Update - Agent Team Optimization**:
20
20
  - ✨ **2 New Specialist Agents**: Quinn (Quantum Systems Engineer) & Astrid (Aerospace Mission Scientist)
@@ -50,7 +50,7 @@ AutomatosX uses **team-based provider configuration** with intelligent fallback
50
50
  | Team | Primary Provider | Fallback Chain | Best For |
51
51
  |------|------------------|----------------|----------|
52
52
  | **Engineering** | 🟢 Codex | Codex → Gemini → Claude | Code implementation, testing, DevOps |
53
- | **Core/Quality** | 🟣 Claude | Claude → Gemini → Codex | Code review, QA, security audits |
53
+ | **Core/Quality** | 🟢 Codex | Codex → Gemini → Claude | Code review, QA, security audits |
54
54
  | **Business** | 🟣 Claude | Claude → Codex → Gemini | Strategy, planning, decision-making |
55
55
  | **Design** | 🔵 Gemini | Gemini → Claude → Codex | UX/UI design, technical writing |
56
56
  | **Research** | 🟠 OpenAI | OpenAI → Gemini-CLI → Claude | Research, analysis, feasibility studies |
@@ -196,7 +196,7 @@ Bob (Backend): "Optimize database queries"
196
196
  | Team | Depth 3 | Depth 2 | Depth 1 | Depth 0 |
197
197
  |------|---------|---------|---------|---------|
198
198
  | **Engineering** | Oliver, Dana | - | Felix, Maya, **Bob**, **Frank**, **Quinn**, **Astrid**, **Mira**, **Ivy** ✨ | Steve |
199
- | **Core/Quality** | - | **Queenie** | **Stan** ✨ | - |
199
+ | **Core/Quality** | - | **Queenie** | **Peter** ✨ | - |
200
200
  | **Business** | Tony | - | Paris, Eric | - |
201
201
  | **Design/Content** | - | - | **Fiona** ✨ | Debbee, Wendy |
202
202
  | **Data** | Dana | - | - | Daisy |
@@ -207,7 +207,7 @@ Bob (Backend): "Optimize database queries"
207
207
 
208
208
  - **3 Strategic Coordinators** (Depth 3): Tony, Oliver, Dana
209
209
  - **6 Tactical Coordinators** (Depth 1-2): Queenie (2), Paris, Felix, Maya, Eric, Cynthia
210
- - **9 Tactical Implementers** (Depth 1): Bob, Frank, Quinn (v5.6.9), Astrid (v5.6.9), Mira (v5.6.10), **Stan** ✨ (v5.6.21), Emma (v5.6.10), Fiona (v5.6.11), Ivy (v5.6.11)
210
+ - **9 Tactical Implementers** (Depth 1): Bob, Frank, Quinn (v5.6.9), Astrid (v5.6.9), Mira (v5.6.10), **Peter** ✨ (v5.6.21), Emma (v5.6.10), Fiona (v5.6.11), Ivy (v5.6.11)
211
211
  - **6 Pure Implementers** (Depth 0): Steve, Daisy, Debbee, Wendy, Rodman
212
212
 
213
213
  ---
@@ -414,15 +414,15 @@ Bob (Backend): "Optimize database queries"
414
414
  ### 🎯 Core/Quality Team
415
415
 
416
416
  **Provider Configuration**:
417
- - **Primary**: 🟣 Claude
418
- - **Fallback Chain**: Claude → Gemini → Codex
417
+ - **Primary**: 🟢 Codex (OpenAI)
418
+ - **Fallback Chain**: Codex → Gemini → Claude
419
419
  - **Why**: Optimized for code review, quality assurance, and detailed analysis
420
420
 
421
421
  #### Tactical Coordinator (Depth 2) ⭐ NEW in v5.3.5
422
422
 
423
423
  | Name | Agent | Expertise | Best For | Delegation Capability |
424
424
  |------|-------|-----------|----------|-----------------------|
425
- | **Queenie** | quality | **SHARED code-review** with Stan & **SOLE OWNER** of debugging/testing | Multi-layer QA workflows, test coordination | 2 layers (QA → Implementation → Specialist) |
425
+ | **Queenie** | quality | **SHARED code-review** with Peter & **SOLE OWNER** of debugging/testing | Multi-layer QA workflows, test coordination | 2 layers (QA → Implementation → Specialist) |
426
426
 
427
427
  **Why Depth 2?**: Quality assurance requires coordinating complex workflows where implementers need to delegate to specialists (e.g., Backend implements tests → Security audits security aspects).
428
428
 
@@ -430,9 +430,9 @@ Bob (Backend): "Optimize database queries"
430
430
 
431
431
  | Name | Agent | Expertise | Best For | Delegation Capability |
432
432
  |------|-------|-----------|----------|-----------------------|
433
- | **Stan** | best-practices | **Software engineering standards** - SOLID principles, design patterns (Gang of Four), clean code, refactoring techniques, software architecture (Layered, Microservices, Hexagonal, Event-Driven) ⭐ v5.6.21 | Code reviews, architecture validation, refactoring guidance, pattern recommendations | 1 layer (can consult implementers for code validation) |
433
+ | **Peter** | best-practices | **Software engineering standards** - SOLID principles, design patterns (Gang of Four), clean code, refactoring techniques, software architecture (Layered, Microservices, Hexagonal, Event-Driven) ⭐ v5.6.21 | Code reviews, architecture validation, refactoring guidance, pattern recommendations | 1 layer (can consult implementers for code validation) |
434
434
 
435
- **Stan's Best Practices Expertise (v5.6.21)**:
435
+ **Peter's Best Practices Expertise (v5.6.21)**:
436
436
  - **SOLID Principles**: SRP (Single Responsibility), OCP (Open/Closed), LSP (Liskov Substitution), ISP (Interface Segregation), DIP (Dependency Inversion)
437
437
  - **Design Patterns**: Creational (Singleton, Factory, Builder), Structural (Adapter, Decorator, Facade), Behavioral (Strategy, Observer, Command, Template Method)
438
438
  - **Clean Code**: Meaningful naming, small functions, DRY (Don't Repeat Yourself), YAGNI (You Aren't Gonna Need It), KISS (Keep It Simple)
@@ -545,10 +545,10 @@ Each agent uses a **smart fallback strategy** to ensure maximum reliability:
545
545
  - ✅ Fallback 1: Gemini
546
546
  - ✅ Fallback 2: Claude
547
547
 
548
- **Core/Quality Team** (Queenie, Steve):
549
- - ✅ Primary: Claude
548
+ **Core/Quality Team** (Queenie, Peter):
549
+ - ✅ Primary: Codex (OpenAI)
550
550
  - ✅ Fallback 1: Gemini
551
- - ✅ Fallback 2: Codex (OpenAI)
551
+ - ✅ Fallback 2: Claude
552
552
 
553
553
  **Business Team** (Tony, Eric, Paris):
554
554
  - ✅ Primary: Claude
@@ -4,7 +4,7 @@
4
4
  # v5.2+
5
5
 
6
6
  name: "creative-marketer"
7
- displayName: "Cynthia"
7
+ displayName: "Candy"
8
8
  team: business
9
9
  role: "Creative Marketing Strategist & GenAI Content Specialist"
10
10
  description: "Expert in GenAI prompting, digital marketing, SEO, and video scriptwriting for media generation with Gemini/Imagen/Veo"
@@ -36,7 +36,7 @@ orchestration:
36
36
 
37
37
  # System Prompt
38
38
  systemPrompt: |
39
- You are Cynthia, a Creative Marketing Strategist & GenAI Content Specialist.
39
+ You are Candy, a Creative Marketing Strategist & GenAI Content Specialist.
40
40
 
41
41
  You specialize in creating high-impact marketing campaigns and media content using Google's Gemini ecosystem (Gemini, Imagen, Veo). You bridge the gap between creative storytelling and performance marketing.
42
42
 
@@ -8,18 +8,18 @@ role: QA Engineer
8
8
  description: "Expert in testing strategies, quality assurance, and test automation"
9
9
 
10
10
  # v5.3.3: Team-based configuration with performance optimization
11
- # Team: core (claude primary), but overridden with openai for better performance
11
+ # Team: core (openai/codex primary) - aligned with team-wide change for better code review performance
12
12
  provider: openai
13
13
  fallbackProvider: gemini-cli
14
14
 
15
15
  # Abilities (v5.6.20: Enhanced with best-practices for base-level standards awareness)
16
16
  abilities:
17
- - code-review # SHARED with Stan - Queenie focuses on quality, Stan on standards
17
+ - code-review # SHARED with Peter - Queenie focuses on quality, Peter on standards
18
18
  - debugging # SOLE OWNER - All debugging assistance from quality
19
19
  - testing
20
20
  - troubleshooting
21
21
  - error-analysis
22
- - best-practices # NEW v5.6.20 - Base-level standards awareness, delegate complex standards to Stan
22
+ - best-practices # NEW v5.6.20 - Base-level standards awareness, delegate complex standards to Peter
23
23
  # - regression-matrix # To be created
24
24
 
25
25
  # v5.0.12: Smart ability loading based on task keywords
@@ -70,10 +70,10 @@ systemPrompt: |
70
70
  - Quality is everyone's job, but I'm the last line of defense
71
71
  - A bug found in development is 10x cheaper than in production
72
72
 
73
- You are the SOLE OWNER of debugging, testing, and quality assurance. You SHARE code review with Stan (Best Practices Expert).
73
+ You are the SOLE OWNER of debugging, testing, and quality assurance. You SHARE code review with Peter (Best Practices Expert).
74
74
 
75
- **With Stan**: For complex best practices, SOLID principles, design patterns, or architecture standards issues, delegate to Stan. You focus on quality (bugs, tests, errors), Stan focuses on standards (SOLID, patterns, architecture).
75
+ **With Peter**: For complex best practices, SOLID principles, design patterns, or architecture standards issues, delegate to Peter. You focus on quality (bugs, tests, errors), Peter focuses on standards (SOLID, patterns, architecture).
76
76
 
77
- Execute quality work yourself (maxDelegationDepth: 1). Delegate to Stan for standards expertise, delegate to implementation teams (backend, frontend, security) for fixes.
77
+ Execute quality work yourself (maxDelegationDepth: 1). Delegate to Peter for standards expertise, delegate to implementation teams (backend, frontend, security) for fixes.
78
78
 
79
79
  Communication style: Methodical and detailed with quality-first focus
@@ -1,19 +1,20 @@
1
- # Best Practices Expert - Stan
1
+ # Best Practices Expert - Peter
2
2
  # Best Practices Expert specializing in SOLID principles, design patterns, and clean code
3
3
 
4
4
  name: stan
5
- displayName: Stan
5
+ displayName: Peter
6
6
  team: core
7
7
  role: Best Practices Expert
8
8
  description: "Expert in SOLID principles, design patterns, clean code, refactoring strategies, and software architecture standards"
9
9
 
10
10
  # v5.6.20: Team-based configuration with openai for consistency
11
+ # Team: core (openai/codex primary) - aligned with team-wide change for better code review performance
11
12
  provider: openai
12
13
  fallbackProvider: gemini-cli
13
14
 
14
- # Abilities (v5.6.20: Stan is the authority on best practices and architectural standards)
15
+ # Abilities (v5.6.20: Peter is the authority on best practices and architectural standards)
15
16
  abilities:
16
- - code-review # Shared with Queenie - Stan focuses on standards, Queenie on quality
17
+ - code-review # Shared with Queenie - Peter focuses on standards, Queenie on quality
17
18
  - best-practices # Primary owner of best practices evolution
18
19
  - solid-principles # SOLE OWNER - Single Responsibility, Open/Closed, Liskov, Interface Segregation, Dependency Inversion
19
20
  - design-patterns # SOLE OWNER - Creational, Structural, Behavioral patterns
@@ -87,7 +88,7 @@ orchestration:
87
88
  - mobile
88
89
 
89
90
  systemPrompt: |
90
- You are Stan, a Best Practices Expert and advocate for software craftsmanship.
91
+ You are Peter, a Best Practices Expert and advocate for software craftsmanship.
91
92
 
92
93
  **Personality**: Principled, patient, educational, standards-driven, pragmatic perfectionist
93
94
  **Catchphrase**: "Good code is not written, it's rewritten. SOLID foundations enable lasting architecture."
@@ -6,13 +6,14 @@ displayName: "Core Team"
6
6
  description: "General-purpose assistants and quality assurance"
7
7
 
8
8
  # Provider Configuration
9
+ # v5.6.22: Updated to match documentation and individual agent overrides
9
10
  provider:
10
- primary: claude
11
+ primary: openai # Codex (OpenAI)
11
12
  fallback: gemini
12
13
  fallbackChain:
13
- - claude
14
+ - openai # Codex
14
15
  - gemini
15
- - codex
16
+ - claude
16
17
 
17
18
  # Shared Abilities
18
19
  sharedAbilities:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@defai.digital/automatosx",
3
- "version": "5.6.21",
3
+ "version": "5.6.23",
4
4
  "description": "AI Agent Orchestration Platform",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -40,6 +40,7 @@
40
40
  "release:check": "node tools/check-release.js",
41
41
  "check:size": "bash tools/check-package-size.sh",
42
42
  "tools:check": "bash -c 'echo \"🔍 Checking shell scripts syntax...\"; for f in tools/*.sh; do echo \" Checking $f...\"; bash -n \"$f\" && echo \" ✓ $f OK\" || echo \" ✗ $f FAILED\"; done; echo \"✅ All tools checked\"'",
43
+ "check:timers": "bash tools/check-timer-cleanup.sh",
43
44
  "prepare": "[ -n \"$CI\" ] || husky",
44
45
  "commit": "cz",
45
46
  "release": "standard-version",
@@ -70,6 +71,7 @@
70
71
  },
71
72
  "dependencies": {
72
73
  "@iarna/toml": "^2.2.5",
74
+ "async-mutex": "^0.5.0",
73
75
  "better-sqlite3": "^12.4.1",
74
76
  "boxen": "^8.0.1",
75
77
  "chalk": "^5.6.2",