@agentyx/core 0.1.1 → 0.3.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 (60) hide show
  1. package/README.md +28 -47
  2. package/dist/index.d.mts +396 -155
  3. package/dist/index.d.mts.map +1 -1
  4. package/dist/index.mjs +777 -226
  5. package/dist/index.mjs.map +1 -1
  6. package/package.json +1 -1
  7. package/schema/agentyx.schema.json +11 -7
  8. package/skills/angular-architecture/SKILL.md +29 -0
  9. package/skills/angular-modern/SKILL.md +12 -30
  10. package/skills/angular-signals/SKILL.md +23 -0
  11. package/skills/angular-testing/SKILL.md +24 -0
  12. package/skills/api-design/SKILL.md +29 -0
  13. package/skills/api-documentation/SKILL.md +34 -0
  14. package/skills/aria-patterns/SKILL.md +36 -0
  15. package/skills/auth-patterns/SKILL.md +35 -0
  16. package/skills/brainstorming/SKILL.md +12 -0
  17. package/skills/branching-strategy/SKILL.md +34 -0
  18. package/skills/ci-pipelines/SKILL.md +34 -0
  19. package/skills/code-quality/SKILL.md +28 -0
  20. package/skills/code-review/SKILL.md +23 -0
  21. package/skills/commit-hygiene/SKILL.md +34 -0
  22. package/skills/concise-output/SKILL.md +24 -0
  23. package/skills/containerization/SKILL.md +38 -0
  24. package/skills/context-efficient-development/SKILL.md +24 -0
  25. package/skills/data-modeling/SKILL.md +34 -0
  26. package/skills/decision-records/SKILL.md +34 -0
  27. package/skills/dependency-hygiene/SKILL.md +34 -0
  28. package/skills/dependency-security/SKILL.md +35 -0
  29. package/skills/deployment-safety/SKILL.md +33 -0
  30. package/skills/e2e-testing/SKILL.md +34 -0
  31. package/skills/engineering-principles/SKILL.md +34 -0
  32. package/skills/flaky-tests/SKILL.md +29 -0
  33. package/skills/focused-verification/SKILL.md +22 -0
  34. package/skills/incident-response/SKILL.md +34 -0
  35. package/skills/infrastructure-as-code/SKILL.md +34 -0
  36. package/skills/keyboard-navigation/SKILL.md +34 -0
  37. package/skills/legacy-code/SKILL.md +34 -0
  38. package/skills/metrics-and-tracing/SKILL.md +33 -0
  39. package/skills/parallel-work/SKILL.md +12 -0
  40. package/skills/performance-profiling/SKILL.md +34 -0
  41. package/skills/pull-requests/SKILL.md +34 -0
  42. package/skills/query-performance/SKILL.md +34 -0
  43. package/skills/refactoring-safely/SKILL.md +34 -0
  44. package/skills/requesting-code-review/SKILL.md +13 -0
  45. package/skills/schema-migrations/SKILL.md +34 -0
  46. package/skills/secrets-handling/SKILL.md +34 -0
  47. package/skills/secure-coding/SKILL.md +33 -0
  48. package/skills/semantic-html/SKILL.md +34 -0
  49. package/skills/structured-logging/SKILL.md +34 -0
  50. package/skills/subagent-driven-development/SKILL.md +13 -0
  51. package/skills/targeted-exploration/SKILL.md +24 -0
  52. package/skills/technical-writing/SKILL.md +34 -0
  53. package/skills/test-doubles/SKILL.md +30 -0
  54. package/skills/test-strategy/SKILL.md +35 -0
  55. package/skills/transactions-and-consistency/SKILL.md +34 -0
  56. package/skills/typescript-modeling/SKILL.md +23 -0
  57. package/skills/typescript-modern/SKILL.md +15 -27
  58. package/skills/typescript-strict/SKILL.md +23 -0
  59. package/skills/web-vitals/SKILL.md +34 -0
  60. package/skills/worktree-workflow/SKILL.md +12 -0
package/README.md CHANGED
@@ -1,60 +1,47 @@
1
1
  # @agentyx/core
2
2
 
3
- Domain foundations for [Agentyx](https://github.com/Andersseen/agentyx): the `.agentyx.json` configuration
4
- model, stack definitions, built-in stack/skill/MCP registries, optimization profiles, and
5
- resolution.
3
+ Domain foundations for Agentyx: `.agentyx.json` parsing, pack definitions, built-in Skill/MCP/tool
4
+ registries, project detection, JSON Schema generation, and provider-neutral resolution.
6
5
 
7
- This package has no dependency on Commander or any terminal UI — CLI concerns live in
8
- [`@agentyx/cli`](https://github.com/Andersseen/agentyx/tree/main/packages/cli).
6
+ This package has no dependency on Commander or terminal UI. CLI concerns live in `@agentyx/cli`, and
7
+ provider filesystem writes live in `@agentyx/adapters`.
9
8
 
10
9
  ```ts
11
10
  import {
12
- builtInSkillRegistry,
13
- builtInStacks,
11
+ builtInPacks,
14
12
  loadAgentyxConfig,
15
13
  resolveAgentyxConfig,
16
- resolveStackMcpServerReferences,
17
- resolveStacks,
18
- resolveStackSkills,
14
+ resolvePackSkills,
15
+ resolvePacks,
19
16
  } from "@agentyx/core";
20
17
 
21
- resolveStacks(["angular"]);
22
- // ["core", "typescript", "angular"]
18
+ builtInPacks.map((pack) => pack.name);
19
+ // ["technical", "typescript", "angular", "efficiency", "agentic"]
23
20
 
24
- resolveStackSkills(["angular"]);
25
- // ["planning", "systematic-debugging", "verification", "typescript-modern", "angular-modern"]
21
+ resolvePacks(["technical", "typescript", "angular"]);
22
+ // ["technical", "typescript", "angular"]
26
23
 
27
- resolveStackMcpServerReferences(["angular"]);
28
- // [{ name: "context7", level: "recommended" }]
24
+ resolvePackSkills(["typescript"]);
25
+ // ["typescript-strict", "typescript-modeling", "typescript-modern"]
29
26
 
30
27
  resolveAgentyxConfig(await loadAgentyxConfig(process.cwd()));
31
- // { requestedStacks, resolvedStacks, skills, declaredMcpServers, mcpServers, profile, targets }
28
+ // { requestedPacks, resolvedPacks, skills, declaredMcpServers, mcpServers, declaredTools, tools, enabled, targets }
32
29
  ```
33
30
 
34
- ## Skills
31
+ Packs are composable capability bundles. They can contribute default Skills, default MCP servers, and
32
+ optional MCP/tool capabilities. Optional capabilities are active only when their identifier appears
33
+ in `enable`.
35
34
 
36
- A skill is provider-independent instruction text: `{ name, description, content }` and nothing else.
37
- The built-in skills ship as `SKILL.md` files under `skills/`, with YAML frontmatter for the metadata
38
- and the Markdown body as the content, and are published alongside `dist/`.
39
-
40
- Resolution works on identifiers, and `SkillRegistry.get(name)` is what reads a body:
41
-
42
- ```ts
43
- builtInSkillRegistry.names; // identifiers, no file is read
44
- builtInSkillRegistry.has("planning"); // no file is read
45
- builtInSkillRegistry.get("planning"); // reads, validates and caches SKILL.md
35
+ ```json
36
+ {
37
+ "packs": ["technical", "typescript", "efficiency"],
38
+ "enable": ["rtk"],
39
+ "targets": ["codex"]
40
+ }
46
41
  ```
47
42
 
48
- `createSkillRegistry(sources)` builds an independent registry from `{ name, load }` sources — the
49
- seam an external registry would use later. `parseSkillMarkdown(markdown, origin)` parses one
50
- `SKILL.md`, and `formatSkillMarkdown(skill)` renders one deterministically. That serializer is the
51
- canonical form every provider installs, which is why it lives here: an adapter decides where a skill
52
- goes, never what it says.
53
-
54
- MCP resolution keeps both declared and effective capabilities visible. Profiles are provider-neutral:
55
- `lean` enables essential MCP only, `balanced` enables essential and recommended MCP, and
56
- `autonomous` enables essential, recommended and optional MCP. Skill identifiers are not filtered by
57
- profile.
43
+ Skills ship as `SKILL.md` assets under `skills/`. Resolution returns identifiers only; a Skill body
44
+ is read only when `SkillRegistry.get(name)` is called.
58
45
 
59
46
  The JSON Schema for `.agentyx.json` ships with the package:
60
47
 
@@ -64,14 +51,8 @@ The JSON Schema for `.agentyx.json` ships with the package:
64
51
  }
65
52
  ```
66
53
 
67
- Resolution failures throw domain errors — `UnknownStackError`, `CircularStackDependencyError`,
68
- `UnknownSkillError`, `DuplicateSkillError`, `InvalidSkillError`, `AgentyxConfigNotFoundError`,
69
- `AgentyxConfigParseError`, `AgentyxConfigValidationError` — all extending `AgentyxError` with a stable
70
- `code`.
71
-
72
- Installing skills and effective MCP capabilities into an agent is
73
- [`@agentyx/adapters`](https://github.com/Andersseen/agentyx/tree/main/packages/adapters); core knows
74
- nothing about providers. See the [main README](https://github.com/Andersseen/agentyx#readme) for the
75
- full picture.
54
+ Resolution failures throw domain errors extending `AgentyxError`, including `UnknownPackError`,
55
+ `UnknownEnabledCapabilityError`, `UnknownSkillError`, `UnknownMcpServerError`, and
56
+ `UnknownToolError`.
76
57
 
77
58
  MIT © Andersseen