@suss/intent-ir 0.0.2 → 0.1.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/README.md +3 -3
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -6,8 +6,8 @@ The team-authored side of the loop: what the code was *meant* to do, in shapes t
|
|
|
6
6
|
|
|
7
7
|
Two citizens, discriminated by `kind`, both built on `@suss/ir-core` so intent and behaviour describe boundaries the same way:
|
|
8
8
|
|
|
9
|
-
- **System intent** (`kind: boundary`)
|
|
10
|
-
- **Outcome intent** (`kind: prd`)
|
|
9
|
+
- **System intent** (`kind: boundary`): what one boundary should do, as named outcomes. The boundary is REST **or** function-call; each outcome is a `response` (status + body), a `returns` (a function/handler return value), or a `throws` (an error). The function-call form is what lets suss check its own non-HTTP surface.
|
|
10
|
+
- **Outcome intent** (`kind: prd`): human `when` / `expect` scenarios, each with an optional `link` to a system-intent outcome (`<intent-name>.<outcome-id>`). A scenario with no `link` is a valid pending-link state: fully readable, not yet machine-linked.
|
|
11
11
|
|
|
12
12
|
```ts
|
|
13
13
|
import { IntentDocSchema, intentDocToSummary } from "@suss/intent-ir";
|
|
@@ -16,7 +16,7 @@ const doc = IntentDocSchema.parse(/* parsed YAML / JSON */);
|
|
|
16
16
|
const summary = intentDocToSummary(doc); // normalised, checker-ready
|
|
17
17
|
```
|
|
18
18
|
|
|
19
|
-
`schema.ts` is the authoring surface (friendly to write); `summary.ts` is the
|
|
19
|
+
`schema.ts` is the authoring surface (friendly to write); `summary.ts` is the normalized shape the checker consumes (boundaries as `ir-core` `BoundaryBinding`s, bodies as `TypeShape`s, one flat outcome list) plus the transform between them. `source` provenance (`author` / `inferred` / `inferred, curated`) rides along for the inference path.
|
|
20
20
|
|
|
21
21
|
The design is documented in [`docs/internal/proposals/intent-specs.md`](../../docs/internal/proposals/intent-specs.md).
|
|
22
22
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@suss/intent-ir",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Intent IR for suss — the team-authored side of the loop. PRD (outcome) intent and system intent, in shapes that pair against derived behavioral summaries.",
|
|
6
6
|
"keywords": [
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"zod": "^4.0.0"
|
|
48
48
|
},
|
|
49
49
|
"dependencies": {
|
|
50
|
-
"@suss/ir-core": "0.0
|
|
50
|
+
"@suss/ir-core": "0.1.0"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
53
|
"tsup": "*",
|