@renseiai/agentfactory 0.8.17 → 0.8.18

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 (40) hide show
  1. package/dist/src/merge-queue/adapters/github-native.d.ts +8 -0
  2. package/dist/src/merge-queue/adapters/github-native.d.ts.map +1 -1
  3. package/dist/src/merge-queue/adapters/github-native.js +37 -7
  4. package/dist/src/merge-queue/adapters/github-native.test.js +71 -42
  5. package/dist/src/orchestrator/activity-emitter.d.ts +7 -0
  6. package/dist/src/orchestrator/activity-emitter.d.ts.map +1 -1
  7. package/dist/src/orchestrator/activity-emitter.js +19 -1
  8. package/dist/src/orchestrator/api-activity-emitter.d.ts +6 -0
  9. package/dist/src/orchestrator/api-activity-emitter.d.ts.map +1 -1
  10. package/dist/src/orchestrator/api-activity-emitter.js +35 -0
  11. package/dist/src/orchestrator/index.d.ts +2 -0
  12. package/dist/src/orchestrator/index.d.ts.map +1 -1
  13. package/dist/src/orchestrator/index.js +1 -0
  14. package/dist/src/orchestrator/issue-tracker-client.d.ts +2 -1
  15. package/dist/src/orchestrator/issue-tracker-client.d.ts.map +1 -1
  16. package/dist/src/orchestrator/orchestrator.d.ts.map +1 -1
  17. package/dist/src/orchestrator/orchestrator.js +42 -0
  18. package/dist/src/orchestrator/security-scan-event.d.ts +57 -0
  19. package/dist/src/orchestrator/security-scan-event.d.ts.map +1 -0
  20. package/dist/src/orchestrator/security-scan-event.js +192 -0
  21. package/dist/src/orchestrator/security-scan-event.test.d.ts +2 -0
  22. package/dist/src/orchestrator/security-scan-event.test.d.ts.map +1 -0
  23. package/dist/src/orchestrator/security-scan-event.test.js +219 -0
  24. package/dist/src/orchestrator/state-recovery.d.ts.map +1 -1
  25. package/dist/src/orchestrator/state-recovery.js +1 -0
  26. package/dist/src/orchestrator/work-types.d.ts +1 -1
  27. package/dist/src/orchestrator/work-types.d.ts.map +1 -1
  28. package/dist/src/providers/types.d.ts +1 -0
  29. package/dist/src/providers/types.d.ts.map +1 -1
  30. package/dist/src/templates/registry.test.js +3 -2
  31. package/dist/src/templates/types.d.ts +2 -0
  32. package/dist/src/templates/types.d.ts.map +1 -1
  33. package/dist/src/templates/types.js +1 -0
  34. package/dist/src/tools/index.d.ts +2 -0
  35. package/dist/src/tools/index.d.ts.map +1 -1
  36. package/dist/src/tools/index.js +1 -0
  37. package/dist/src/tools/tool-category.d.ts +16 -0
  38. package/dist/src/tools/tool-category.d.ts.map +1 -0
  39. package/dist/src/tools/tool-category.js +58 -0
  40. package/package.json +2 -2
@@ -0,0 +1,58 @@
1
+ /**
2
+ * Tool category classification based on tool name pattern matching.
3
+ *
4
+ * Classifies tools into functional categories for dashboard and analytics use.
5
+ */
6
+ const CATEGORY_PATTERNS = [
7
+ {
8
+ category: 'security',
9
+ patterns: /security|vuln|scan|sast|dast|sbom|cve|audit(?!.*\bno-audit\b)/i,
10
+ },
11
+ {
12
+ category: 'testing',
13
+ patterns: /test|jest|vitest|playwright|cypress|coverage|assert/i,
14
+ },
15
+ {
16
+ category: 'deploy',
17
+ patterns: /deploy|release|publish|docker|k8s|terraform|infra/i,
18
+ },
19
+ {
20
+ category: 'build',
21
+ patterns: /build|compile|bundle|webpack|vite|esbuild|tsc/i,
22
+ },
23
+ {
24
+ category: 'research',
25
+ patterns: /search|fetch|browse|read|grep|glob|explore/i,
26
+ },
27
+ ];
28
+ /**
29
+ * Extract the tool-specific portion from an MCP-qualified tool name.
30
+ *
31
+ * MCP tool names follow the pattern `mcp__{pluginName}__{toolName}`.
32
+ * Returns the portion after the last `__` separator, or the original
33
+ * name if it's not MCP-qualified.
34
+ */
35
+ function extractToolName(toolName) {
36
+ const lastSep = toolName.lastIndexOf('__');
37
+ if (lastSep !== -1 && lastSep < toolName.length - 2) {
38
+ return toolName.substring(lastSep + 2);
39
+ }
40
+ return toolName;
41
+ }
42
+ /**
43
+ * Classify a tool into a functional category based on its name.
44
+ *
45
+ * Handles both simple tool names (e.g. `Read`, `Bash`) and
46
+ * MCP-qualified names (e.g. `mcp__af-linear__af_linear_create_issue`).
47
+ *
48
+ * Returns `'general'` for tools that don't match any specific category.
49
+ */
50
+ export function classifyTool(toolName) {
51
+ const name = extractToolName(toolName);
52
+ for (const { category, patterns } of CATEGORY_PATTERNS) {
53
+ if (patterns.test(name)) {
54
+ return category;
55
+ }
56
+ }
57
+ return 'general';
58
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@renseiai/agentfactory",
3
- "version": "0.8.17",
3
+ "version": "0.8.18",
4
4
  "type": "module",
5
5
  "description": "Multi-agent fleet management for coding agents — orchestrator, providers, crash recovery",
6
6
  "author": "Rensei AI (https://rensei.ai)",
@@ -56,7 +56,7 @@
56
56
  "@types/node": "^22.5.4",
57
57
  "typescript": "^5.7.3",
58
58
  "vitest": "^3.2.3",
59
- "@renseiai/create-agentfactory-app": "0.8.17"
59
+ "@renseiai/create-agentfactory-app": "0.8.18"
60
60
  },
61
61
  "scripts": {
62
62
  "build": "tsc",