Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/trust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,16 +59,16 @@ jobs:
# Preserve the former strict SpecSync gate and put its verified binary on
# PATH before Trust invokes the repository lifecycle lane.
- name: Strict SpecSync gate
uses: CorvidLabs/spec-sync@59bbfa766c6cce01ab815ab47db195b0629cc014 # v5.0.1
uses: CorvidLabs/spec-sync@3c2ed4972c8c53ae02ab5dd5775beccd6da3eeb8 # v6.0.0
with:
version: "5.0.1"
version: "6.0.0"
strict: "true"
require-coverage: "100"

# Unified lifecycle, contract, risk, and progressive provenance gate.
- name: CorvidLabs Trust gate
id: trust
uses: CorvidLabs/trust@9d32b5786d2e9e4d39fc581c0091c721ee3d4226 # v1.0.0
uses: CorvidLabs/trust@fcc889f54d8b4892a81af463c5a0250e2be66fc5 # v1.2.0

# Durability: fail if the standing rules block was removed.
- name: Trust block present
Expand Down
28 changes: 24 additions & 4 deletions specs/loader-swift/loader-swift.spec.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
module: loader-swift
version: 1
status: draft
status: active
files:
- loaders/swift/Sources/Agent3MD/Agent3MD.swift
- loaders/swift/Sources/Agent3MDCLI/main.swift
Expand Down Expand Up @@ -36,14 +36,34 @@ manifest, and the tests.
| `fillCommand` | `fillCommand(_ template: String, _ values: [String: String]) -> String`: fill `{name}` placeholders (shell-quoted), leaving unprovided ones visible. |
| `depLinks` | `depLinks(in body: String) -> [Int]`: extract `[[z=N]]` / `[[z=N\|label]]` integer targets. |
| `tokenize` | `tokenize(_ s: String) -> [String]`: lowercased runs of Unicode letters / digits. |
| `init` | `Agent.init(source: String) throws`: parse the source through `ThreeMD.Parser`, pick the identity plane, and index every other plane as a skill by name and z. |
| `get` | `Agent.get(_ name: String) -> Skill?` / `Agent.get(z: Int) -> Skill?`: O(1) fetch of one skill by name or z. |
| `route` | `Agent.route(_ text: String) -> [(skill: Skill, score: Int, hits: [String])]`: rank skills by matched trigger phrases, ties broken by lower z. |
| `resolve` | `Agent.resolve(_ name: String) -> [Skill]`: a skill plus its transitive `[[z=N]]` dependencies, in load order. |
| `command` | `Agent.command(_ name: String, _ values: [String: String]) -> String?` / `Agent.command(z: Int, _ values: [String: String]) -> String?`: the skill's `tool` filled from values, or nil when it has no tool. |

### Structs & Enums
### Exported Types

| Type | Description |
|------|-------------|
| Export | Description |
|--------|-------------|
| `Agent` | A `Sendable` value type: `name`, `model`, `tools`, `identity`, `skills`, with route / get / resolve / command over its skills. |
| `Skill` | A `Sendable` skill: `z`, `name`, `triggers`, `inputs`, `inputSchema`, `tool`, `cost`, `deps`, `body`. |
| `SkillInput` | A `Sendable` typed input: `name`, `type`, `required`. |
| `name` | `SkillInput.name` / `Skill.name` / `Agent.name`: the input's name, the skill's name (`skill-<z>` when the plane has no label), and the agent's name. |
| `type` | `SkillInput.type`: the declared input type (`string`, `number`, `boolean`, `object`, or `array`). |
| `required` | `SkillInput.required`: whether the input must be supplied; a bare input name is required. |
| `z` | `Skill.z`: the skill plane's z index. |
| `triggers` | `Skill.triggers`: the trigger phrases `route` matches a request against. |
| `inputs` | `Skill.inputs`: the input names, derived from `inputSchema` so the two never disagree. |
| `inputSchema` | `Skill.inputSchema`: the typed inputs parsed from the plane's `inputs` attribute. |
| `tool` | `Skill.tool`: the command template, nil unless the plane sets a non-empty `tool`. |
| `cost` | `Skill.cost`: the plane's cost hint, nil when unset. |
| `deps` | `Skill.deps`: the `[[z=N]]` dependency targets found in the body, in body order. |
| `body` | `Skill.body`: the plane's full body text, fetched on demand. |
| `model` | `Agent.model`: the identity plane's model, `"unknown"` when unset. |
| `tools` | `Agent.tools`: the tool names from the identity plane's `tools` metadata. |
| `identity` | `Agent.identity`: the identity plane as a `Skill`, nil when the document has no plane. |
| `skills` | `Agent.skills`: every non-identity plane, in load order. |

### Traits

Expand Down
22 changes: 15 additions & 7 deletions specs/package/package.spec.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
module: package
version: 1
status: draft
status: active
files:
- src/index.ts
- src/index-query.ts
Expand Down Expand Up @@ -30,17 +30,25 @@ keeping per-turn context independent of how many skills the agent has.
| Export | Description |
|--------|-------------|
| `routeQuery` | `routeQuery(agent: Agent, text: string): string[]`: the names of the skills matching `text`, ranked, with everything else about the match dropped. |
| `Agent`, `fillCommand`, `commandPlaceholders` | Re-exported from `./runtime` (the reference loader and its command-template helpers). |
| `validateAgent`, `formatReport` | Re-exported from `./validate` (the agent3md/1 validator). |
| `Agent` | Re-exported from `./runtime` (the reference loader). |
| `fillCommand` | Re-exported from `./runtime` (fill a `{name}` command template from values). |
| `commandPlaceholders` | Re-exported from `./runtime` (the placeholder names a command template references). |
| `validateAgent` | Re-exported from `./validate` (validate a source string against agent3md/1). |
| `formatReport` | Re-exported from `./validate` (render a validation report as text). |
| `parse` | Re-exported from `./threemd` (the canonical 3md parser). |

### Structs & Enums
### Exported Types

| Type | Description |
|------|-------------|
| `Skill`, `SkillInput`, `AgentManifest` | Runtime types, re-exported. |
| `Report`, `Issue`, `IssueLevel` | Validator types, re-exported. |
| `Document`, `Plane` | 3md document types, re-exported. |
| `Skill` | Runtime type, re-exported: one skill plane. |
| `SkillInput` | Runtime type, re-exported: a typed skill input. |
| `AgentManifest` | Runtime type, re-exported: the agent identity plus its skill catalog. |
| `Report` | Validator type, re-exported: the result of `validateAgent`. |
| `Issue` | Validator type, re-exported: one validation finding. |
| `IssueLevel` | Validator type, re-exported: the severity of an `Issue`. |
| `Document` | 3md document type, re-exported. |
| `Plane` | 3md document type, re-exported. |

### Traits

Expand Down
4 changes: 2 additions & 2 deletions specs/runtime/runtime.spec.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
module: runtime
version: 3
status: draft
status: active
files:
- src/runtime.ts

Expand Down Expand Up @@ -29,7 +29,7 @@ whole file into context.
| `fillCommand` | `fillCommand(template, values)`: fill a `{name}` command template from values, shell-quoting them; unprovided placeholders stay visible. |
| `commandPlaceholders` | `commandPlaceholders(template)`: the placeholder names a command template references, de-duplicated. |

### Structs & Enums
### Exported Types

| Type | Description |
|------|-------------|
Expand Down
4 changes: 2 additions & 2 deletions specs/threemd/threemd.spec.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
module: threemd
version: 1
status: draft
status: active
files:
- src/threemd.ts

Expand Down Expand Up @@ -32,7 +32,7 @@ loaders) consumes the `Document` this module produces rather than re-parsing 3md
| `links` | `links(document: Document): CrossPlaneLink[]`: extract every `[[z=N]]` / `[[z=N\|text]]` cross-plane link from the document's plane bodies, in document order. |
| `serialize` | `serialize(document: Document): string`: render a `Document` back into 3md source text. |

### Structs & Enums
### Exported Types

| Type | Description |
|------|-------------|
Expand Down
4 changes: 2 additions & 2 deletions specs/validation/validation.spec.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
module: validation
version: 1
status: draft
status: active
files:
- src/validate.ts

Expand Down Expand Up @@ -31,7 +31,7 @@ that prints a report and exits non-zero when any error is found.
| `validateAgent` | `validateAgent(src: string): Report`: parse and check 3md source against agent3md/1, returning a report of errors and warnings. |
| `formatReport` | `formatReport(file: string, r: Report): string`: render a `Report` as a human-readable, multi-line block with a `PASS` / `FAIL` summary. |

### Structs & Enums
### Exported Types

| Type | Description |
|------|-------------|
Expand Down
Loading