@ai-outfitter/outfitter 1.12.0 → 1.14.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.
- package/dist/cli/commands/DumpCommand.d.ts +1 -0
- package/dist/cli/commands/DumpCommand.js +25 -5
- package/dist/cli/commands/DumpCommand.js.map +1 -1
- package/dist/cli/commands/ListCommand.d.ts +9 -0
- package/dist/cli/commands/ListCommand.js +33 -11
- package/dist/cli/commands/ListCommand.js.map +1 -1
- package/dist/cli/commands/ValidateCommand.js +2 -2
- package/dist/cli/commands/ValidateCommand.js.map +1 -1
- package/dist/dump/WorkflowDump.d.ts +4 -0
- package/dist/dump/WorkflowDump.js +148 -0
- package/dist/dump/WorkflowDump.js.map +1 -0
- package/dist/resolver/Resolver.js +2 -0
- package/dist/resolver/Resolver.js.map +1 -1
- package/dist/resolver/ResolverValidation.d.ts +2 -0
- package/dist/resolver/ResolverValidation.js +181 -2
- package/dist/resolver/ResolverValidation.js.map +1 -1
- package/dist/resolver/Resource.d.ts +1 -1
- package/dist/resolver/Resource.js +1 -1
- package/dist/resolver/Resource.js.map +1 -1
- package/dist/resolver/WorkflowDefinition.d.ts +56 -0
- package/dist/resolver/WorkflowDefinition.js +23 -0
- package/dist/resolver/WorkflowDefinition.js.map +1 -0
- package/dist/schemas/settings.schema.json +6 -0
- package/dist/schemas/workflow.schema.json +81 -0
- package/dist/settings/Settings.d.ts +2 -0
- package/dist/settings/Settings.js +1 -0
- package/dist/settings/Settings.js.map +1 -1
- package/dist/settings/SettingsLoader.js +1 -0
- package/dist/settings/SettingsLoader.js.map +1 -1
- package/dist/settings/SettingsMerger.js +6 -0
- package/dist/settings/SettingsMerger.js.map +1 -1
- package/dist/setup/DefaultCatalog.js +1 -1
- package/dist/setup/DefaultCatalog.js.map +1 -1
- package/dist/validation/SchemaValidator.d.ts +1 -1
- package/dist/validation/SchemaValidator.js +2 -0
- package/dist/validation/SchemaValidator.js.map +1 -1
- package/docs/documentation/catalogs.md +9 -1
- package/docs/documentation/cli.md +13 -8
- package/docs/documentation/dump-and-bake.md +2 -0
- package/docs/documentation/settings.md +8 -2
- package/package.json +1 -1
- package/src/schemas/settings.schema.json +6 -0
- package/src/schemas/workflow.schema.json +81 -0
|
@@ -5,11 +5,13 @@ const readSchema = (schemaFileName) => JSON.parse(readFileSync(new URL(`../schem
|
|
|
5
5
|
const settingsSchema = readSchema('settings.schema.json');
|
|
6
6
|
const agentSchema = readSchema('agent.schema.json');
|
|
7
7
|
const systemExtensionHookSchema = readSchema('system-extension-hook.schema.json');
|
|
8
|
+
const workflowSchema = readSchema('workflow.schema.json');
|
|
8
9
|
const ajv = new Ajv2020({ allErrors: true });
|
|
9
10
|
const validators = {
|
|
10
11
|
settings: ajv.compile(settingsSchema),
|
|
11
12
|
agent: ajv.compile(agentSchema),
|
|
12
13
|
'system-extension-hook': ajv.compile(systemExtensionHookSchema),
|
|
14
|
+
workflow: ajv.compile(workflowSchema),
|
|
13
15
|
};
|
|
14
16
|
export const createValidationResult = (issues) => ({
|
|
15
17
|
valid: issues.length === 0,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SchemaValidator.js","sourceRoot":"","sources":["../../src/validation/SchemaValidator.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAC/E,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAGvC,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAc3C,MAAM,UAAU,GAAG,CAAC,cAAsB,EAAW,EAAE,CACrD,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,IAAI,GAAG,CAAC,cAAc,cAAc,EAAE,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC;AAE7F,MAAM,cAAc,GAAG,UAAU,CAAC,sBAAsB,CAAC,CAAC;AAC1D,MAAM,WAAW,GAAG,UAAU,CAAC,mBAAmB,CAAC,CAAC;AACpD,MAAM,yBA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UAAsB,EAAE,QAAiB,EAAoB,EAAE;IAC5F,MAAM,QAAQ,GAAG,UAAU,CAAC,UAAU,CAAC,CAAC;IAExC,IAAI,QAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC;QACvB,OAAO,sBAAsB,CAAC,EAAE,CAAC,CAAC;IACpC,CAAC;IAED,OAAO,sBAAsB,CAAE,QAAQ,CAAC,MAAiC,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC,CAAC;AACjG,CAAC,CAAC;AAEF,MAAM,cAAc,GAAG,CAAC,KAAkB,EAAmB,EAAE,CAAC,CAAC;IAC/D,IAAI,EAAE,KAAK,CAAC,YAAY,KAAK,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,YAAY;IAC1D,OAAO,EAAE,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC;CAC/B,CAAC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Catalogs
|
|
2
2
|
|
|
3
|
-
A catalog is a git repository that publishes a `.agents` payload — agents, skills, tasks, knowledge, commands — so a person, team, or organization can share it. You can bootstrap a machine or project from one, or add one as an ongoing source that Outfitter keeps synchronized.
|
|
3
|
+
A catalog is a git repository that publishes a `.agents` payload — agents, skills, workflows, tasks, knowledge, commands — so a person, team, or organization can share it. You can bootstrap a machine or project from one, or add one as an ongoing source that Outfitter keeps synchronized.
|
|
4
4
|
|
|
5
5
|
```bash
|
|
6
6
|
outfitter setup https://github.com/ncrmro/.agents
|
|
@@ -33,6 +33,8 @@ ncrmro/.agents/ # repository root
|
|
|
33
33
|
tasks/
|
|
34
34
|
weekly-kpis/task.md
|
|
35
35
|
knowledge/
|
|
36
|
+
workflows/
|
|
37
|
+
engineer/workflow.yaml
|
|
36
38
|
settings.yml # Outfitter settings (optional; see settings.md)
|
|
37
39
|
settings.local.yml # gitignored machine-local overrides
|
|
38
40
|
```
|
|
@@ -83,6 +85,12 @@ Remote entries additionally accept:
|
|
|
83
85
|
|
|
84
86
|
Resources from all sources resolve by slug behind local layers, following [layer precedence](./concepts.md#layer-precedence). Agent-local skills keep their owning-agent namespace through cache and source merging. Outfitter reports shadowed IDs so consumers can see which source supplies a selected resource.
|
|
85
87
|
|
|
88
|
+
### Workflows are configuration, not an execution engine
|
|
89
|
+
|
|
90
|
+
Each `workflows/<slug>/workflow.yaml` is a typed graph that names its human, agent, tool, and system actors. Agent actors reference ordinary catalog profiles. Node-level skill, prompt, and MCP assertions must already belong to the selected agent's composed closure. Nested workflow references resolve by slug and may not form cycles.
|
|
91
|
+
|
|
92
|
+
`outfitter validate --strict` validates the graph and the complete composed dependency closure. `outfitter dump --workflow <slug>` produces a reviewable `.agents` bundle for distribution. Outfitter never schedules or executes the graph.
|
|
93
|
+
|
|
86
94
|
### Catalog dependencies (transitive sources)
|
|
87
95
|
|
|
88
96
|
A catalog can depend on other catalogs by declaring `sources` in its own settings file
|
|
@@ -71,13 +71,15 @@ resolution tells you to run `outfitter sync`.
|
|
|
71
71
|
|
|
72
72
|
List resolvable resources across all layers, with the winning source for each slug and any shadowed IDs.
|
|
73
73
|
|
|
74
|
-
| Argument | Description
|
|
75
|
-
| -------- |
|
|
76
|
-
| `[kind]` | Optional filter: `agents`, `skills`, `knowledge`, `commands`. |
|
|
74
|
+
| Argument | Description |
|
|
75
|
+
| -------- | -------------------------------------------------------------------------- |
|
|
76
|
+
| `[kind]` | Optional filter: `agents`, `skills`, `knowledge`, `commands`, `workflows`. |
|
|
77
|
+
|
|
78
|
+
`--json` emits an object containing `ok`, `resources`, and `diagnostics`; diagnostics remain available when strict mode fails.
|
|
77
79
|
|
|
78
80
|
## `outfitter validate`
|
|
79
81
|
|
|
80
|
-
Validate the effective resource set: protocol layout, frontmatter, unresolved slugs in agent loadouts, broken or escaping skill references, and settings schema.
|
|
82
|
+
Validate the effective resource set: protocol layout, frontmatter, unresolved slugs in agent loadouts, broken or escaping skill references, workflow graphs and composed closures, and settings schema.
|
|
81
83
|
|
|
82
84
|
| Option | Description |
|
|
83
85
|
| ---------- | ---------------------------------------- |
|
|
@@ -88,10 +90,13 @@ Validate the effective resource set: protocol layout, frontmatter, unresolved sl
|
|
|
88
90
|
|
|
89
91
|
Write the composed resource tree as a self-contained `.agents/` directory for review, vendoring, or air-gapped use. Identical sources, refs, and selections produce byte-identical output; dumps never contain credentials, sessions, caches, or other mutable runtime state.
|
|
90
92
|
|
|
91
|
-
| Option
|
|
92
|
-
|
|
|
93
|
-
| `--agent <id>`
|
|
94
|
-
| `--
|
|
93
|
+
| Option | Description |
|
|
94
|
+
| ----------------- | ------------------------------------------------------------------------------ |
|
|
95
|
+
| `--agent <id>` | Restrict the dump to one agent's transitive closure. |
|
|
96
|
+
| `--workflow <id>` | Export one workflow, its nested workflows, and every referenced agent closure. |
|
|
97
|
+
| `--out <dir>` | Destination directory (default `./.agents`). |
|
|
98
|
+
|
|
99
|
+
Workflow dumps are non-executable configuration bundles. They contain the canonical workflow YAML, composed agent resources, and a hash/provenance manifest. A workflow dump refuses an existing destination instead of replacing user files.
|
|
95
100
|
|
|
96
101
|
> **Tasks and `outfitter task bake`** — baking a task and its inputs into an immutable execution artifact — are the subject of a separate upcoming RFC and are not part of this command surface yet. See [Tasks](./tasks.md).
|
|
97
102
|
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
```bash
|
|
10
10
|
outfitter dump --out ./review
|
|
11
11
|
outfitter dump --agent engineer --out ./engineer # one agent's transitive closure only
|
|
12
|
+
outfitter dump --workflow engineer --out ./workflow # graph + nested graphs + agent closures
|
|
12
13
|
```
|
|
13
14
|
|
|
14
15
|
Use dumps to:
|
|
@@ -24,6 +25,7 @@ Use dumps to:
|
|
|
24
25
|
- **Safe** — a dump may include reviewable source provenance, but never credentials, auth state, sessions, transcripts, caches, backups, mutable harness state, or symlinks escaping the tree.
|
|
25
26
|
- **Protocol-shaped** — the output is a valid `.agents` payload usable by any protocol consumer, not just Outfitter. Any Outfitter-specific provenance metadata is namespaced, JSON-based, and removable without losing the underlying resources.
|
|
26
27
|
- **Harness-discoverable** — selected agent-local skills are flattened into top-level `skills/<id>/` in the closure output, with their packaged references, scripts, and assets intact.
|
|
28
|
+
- **Workflow-auditable** — workflow exports preserve canonical YAML and record every nested workflow, agent composition, file hash, and winning source in `.outfitter/workflow-composition.json`.
|
|
27
29
|
|
|
28
30
|
## Bake
|
|
29
31
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Outfitter settings configure how resources are resolved and launched. They live inside the `.agents` tree so a tree carries everything it needs, and they are the only Outfitter-specific files in it — deleting them leaves a pure protocol payload.
|
|
4
4
|
|
|
5
|
-
Settings do not carry resource selections. An agent's loadout — its skills, subagents, model, and so on — lives on the [agent](./agents.md)
|
|
5
|
+
Settings do not carry an agent's resource selections. An agent's loadout — its skills, subagents, model, and so on — lives on the [agent](./agents.md). Settings separately record which workflow roots are explicitly enabled.
|
|
6
6
|
|
|
7
7
|
## Scopes
|
|
8
8
|
|
|
@@ -34,6 +34,11 @@ sources:
|
|
|
34
34
|
ref: v1.2.0
|
|
35
35
|
- path: ../shared-agents # local directory, read live from disk
|
|
36
36
|
|
|
37
|
+
# Workflow roots this project explicitly enables from the effective resource set.
|
|
38
|
+
workflows:
|
|
39
|
+
- software-factory
|
|
40
|
+
- adversarial-review
|
|
41
|
+
|
|
37
42
|
# Organization-distributed settings, layered below local settings.
|
|
38
43
|
remote_settings:
|
|
39
44
|
- github: my-org/.outfitter
|
|
@@ -52,6 +57,7 @@ telemetry:
|
|
|
52
57
|
- `default_agent` / `default_harness` — which agent plain `outfitter` runs, and the harness it launches in.
|
|
53
58
|
- `isolation` — whether a run stands on the harness configuration already on this machine. `inherit`, the default, layers the composition over it, so a Claude run keeps your workspace trust, permissions, credentials, plugins, and MCP servers. `isolated` launches from the composition alone, which is what a reproducible CI or container run wants; `--isolated` selects it for one run. Only Claude has an inherit path today. This key is honored **only** from your own `~/.agents` settings: a checked-in project or a remote catalog must not decide how much of your machine a profile it ships can see.
|
|
54
59
|
- `sources` — ordered list of remote or local `.agents` payloads. Remote entries (`github:` / `uri:`) accept `ref:` pinning and an optional `path:` to the payload inside the repository; see [Catalogs](./catalogs.md) for conventions and trust guidance.
|
|
60
|
+
- `workflows` — unique workflow root slugs enabled by this file. The effective set is the ordered, deduplicated union from every loaded remote, user, user-local, project, and project-local settings file. Missing and empty lists enable no roots. Source catalogs contribute definitions, but their settings are not loaded. `outfitter list workflows` shows enabled roots only; `outfitter validate` fails when an enabled root is not resolvable or its reachable workflow, agent, and resource closure is invalid; and `outfitter dump --workflow <slug>` requires the root itself to be enabled. Nested workflow dependencies are enabled implicitly for an enabled root's closure, but cannot be dumped directly unless separately listed. Normal resource precedence applies, so a project workflow definition overrides the same slug from the user or a catalog.
|
|
55
61
|
- `remote_settings` — shared settings a repository distributes; cached locally and merged below your project and user settings, so anything you set locally wins.
|
|
56
62
|
- `cache_directory` — the repository cache root used consistently by sync, remote settings, remote
|
|
57
63
|
source resolution, and default-catalog setup. It defaults to `~/.agents/cache`; repositories live
|
|
@@ -72,4 +78,4 @@ Higher wins:
|
|
|
72
78
|
5. Cached remote settings (in configured order)
|
|
73
79
|
6. Built-in defaults
|
|
74
80
|
|
|
75
|
-
Scalar settings override
|
|
81
|
+
Scalar settings override. `sources` follows last-wins ordering per scope so a higher-precedence file replaces the complete lower-precedence list. `workflows` is additive: loaded settings contribute an ordered-set union, and repeated slugs across files collapse to their first occurrence.
|
package/package.json
CHANGED
|
@@ -77,6 +77,12 @@
|
|
|
77
77
|
"additionalProperties": false
|
|
78
78
|
}
|
|
79
79
|
},
|
|
80
|
+
"workflows": {
|
|
81
|
+
"type": "array",
|
|
82
|
+
"description": "Workflow root slugs explicitly enabled by this settings scope.",
|
|
83
|
+
"items": { "type": "string", "minLength": 1 },
|
|
84
|
+
"uniqueItems": true
|
|
85
|
+
},
|
|
80
86
|
"remote_settings": {
|
|
81
87
|
"type": "array",
|
|
82
88
|
"items": {
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://ai-outfitter.com/schemas/workflow.schema.json",
|
|
4
|
+
"title": "AI Outfitter workflow",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": true,
|
|
7
|
+
"required": ["version", "id", "title", "description", "actors", "nodes"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"version": { "const": 1 },
|
|
10
|
+
"id": { "type": "string", "pattern": "^[a-z0-9]+(?:[._-][a-z0-9]+)*$" },
|
|
11
|
+
"title": { "type": "string", "minLength": 1 },
|
|
12
|
+
"description": { "type": "string", "minLength": 1 },
|
|
13
|
+
"status": { "type": "string" },
|
|
14
|
+
"actors": {
|
|
15
|
+
"type": "object",
|
|
16
|
+
"additionalProperties": {
|
|
17
|
+
"type": "object",
|
|
18
|
+
"additionalProperties": true,
|
|
19
|
+
"required": ["kind"],
|
|
20
|
+
"properties": {
|
|
21
|
+
"kind": { "enum": ["human", "agent", "tool", "system"] },
|
|
22
|
+
"profile": { "type": "string" },
|
|
23
|
+
"skills": { "type": "array", "items": { "type": "string" }, "uniqueItems": true }
|
|
24
|
+
},
|
|
25
|
+
"allOf": [
|
|
26
|
+
{
|
|
27
|
+
"if": { "properties": { "kind": { "const": "agent" } }, "required": ["kind"] },
|
|
28
|
+
"then": { "required": ["profile"] }
|
|
29
|
+
}
|
|
30
|
+
]
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"environments": { "type": "object" },
|
|
34
|
+
"integrations": {
|
|
35
|
+
"type": "object",
|
|
36
|
+
"additionalProperties": {
|
|
37
|
+
"type": "object",
|
|
38
|
+
"additionalProperties": true,
|
|
39
|
+
"properties": {
|
|
40
|
+
"kind": { "type": "string" },
|
|
41
|
+
"server": { "type": "string" },
|
|
42
|
+
"tools": { "type": "array", "items": { "type": "string" }, "uniqueItems": true },
|
|
43
|
+
"repository": { "type": "string" },
|
|
44
|
+
"ref": { "type": "string" },
|
|
45
|
+
"path": { "type": "string" },
|
|
46
|
+
"sha256": { "type": "string" }
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"checks": { "type": "object" },
|
|
51
|
+
"triggers": { "type": "array", "items": { "type": "object" } },
|
|
52
|
+
"feedback": { "type": "array", "items": { "type": "object", "required": ["from", "to"] } },
|
|
53
|
+
"nodes": {
|
|
54
|
+
"type": "array",
|
|
55
|
+
"minItems": 1,
|
|
56
|
+
"items": {
|
|
57
|
+
"type": "object",
|
|
58
|
+
"additionalProperties": true,
|
|
59
|
+
"required": ["id", "description"],
|
|
60
|
+
"properties": {
|
|
61
|
+
"id": { "type": "string", "pattern": "^[a-z0-9]+(?:[._-][a-z0-9]+)*$" },
|
|
62
|
+
"description": { "type": "string", "minLength": 1 },
|
|
63
|
+
"action": { "type": "string" },
|
|
64
|
+
"workflow": { "type": "string" },
|
|
65
|
+
"actor": { "type": "string" },
|
|
66
|
+
"environment": { "type": "string" },
|
|
67
|
+
"needs": { "type": "array", "items": { "type": "string" }, "uniqueItems": true },
|
|
68
|
+
"skill": { "type": "string" },
|
|
69
|
+
"skills": { "type": "array", "items": { "type": "string" }, "uniqueItems": true },
|
|
70
|
+
"prompt_fragment": { "type": "string" },
|
|
71
|
+
"prompt_fragments": { "type": "array", "items": { "type": "string" }, "uniqueItems": true },
|
|
72
|
+
"uses": { "type": "array", "items": { "type": "string" }, "uniqueItems": true }
|
|
73
|
+
},
|
|
74
|
+
"oneOf": [
|
|
75
|
+
{ "required": ["action"], "not": { "required": ["workflow"] } },
|
|
76
|
+
{ "required": ["workflow"], "not": { "required": ["action"] } }
|
|
77
|
+
]
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|