Skip to content

Commit 51afb12

Browse files
committed
docs: tighten repo docs and validation entrypoints
1 parent 9ebbc93 commit 51afb12

File tree

6 files changed

+97
-58
lines changed

6 files changed

+97
-58
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,9 @@
1010
- Established Commons v1.1.0 as the active in-repo schema surface for new integrations
1111
- Retained v1.0.0 as the last pinned canonical release until v1.1.0 pinning is completed
1212
- Preserved earlier schema versions for compatibility and historical reference
13+
14+
## 1.0.0
15+
16+
- Initial Protocol-Commons release with versioned Commons schemas, shared primitives, and example vectors under `schemas/v1.0.0` and `examples/v1.0.0`
17+
- Introduced the canonical Commons verb set and request/receipt validation model for cross-runtime interoperability
18+
- Established the historical pinned release line that `v1.1.0` now extends as the current in-repo schema family

CONTRIBUTING.md

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# Contributing — Protocol Commons
2+
3+
Protocol-Commons contributions must be small, traceable, and validation-complete.
4+
5+
## Pull Request Spine
6+
7+
Every PR should:
8+
9+
1. Open from a focused branch for one change set
10+
2. Explain the semantic, schema, or documentation impact
11+
3. Include schema/example updates together when contracts change
12+
4. Pass the required validation commands before review
13+
5. Update release notes when the visible contract changes
14+
15+
## Commit Convention
16+
17+
Use a clear imperative subject line. Prefer conventional-style prefixes when they fit, for example:
18+
19+
- `docs: tighten README contract language`
20+
- `feat: add new commons verb schema family`
21+
- `fix: correct receipt validation example`
22+
23+
## Required Checks
24+
25+
Run the canonical validation command before opening a PR:
26+
27+
```bash
28+
npm install
29+
npm run validate
30+
```
31+
32+
Run additional checks when packaging behavior changes:
33+
34+
```bash
35+
npm run test:smoke:import
36+
npm run test:smoke:pack
37+
```
38+
39+
## When Schemas Change
40+
41+
If you change a schema or semantic contract, you must also:
42+
43+
- Add or update matching examples/tests
44+
- Preserve immutability of published version directories unless the change is explicitly historical documentation only
45+
- Review `SCHEMAS.md` and `SPEC.md` for versioning implications
46+
- Update `CHANGELOG.md` when the externally visible contract changes
47+
- Update `RESOLUTION.md`, provenance, or checksum artifacts if the release process requires it
48+
49+
## Versioning Expectations
50+
51+
- Treat published release lines as append-only history
52+
- Use a new version directory for semantic changes
53+
- Keep `v1.1.0` documented as the current in-repo line until a newer line is intentionally introduced
54+
55+
## Review Standard
56+
57+
A contribution is ready for review when a maintainer can understand the intent quickly, reproduce validation locally, and see exact schema/example/doc alignment without extra interpretation.

ONBOARDING.md

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -72,21 +72,16 @@ If a change is not reflected here → **not canonical.**
7272
Protocol-Commons governs TXT keys that resolve schema semantics.
7373
Canonical definitions → `SPEC.md`.
7474

75-
## 4. Contribution Flow
76-
1. Open an Issue describing context + verb(s)
77-
2. Design change per `SCHEMAS.md`
78-
3. Update schemas + examples
79-
4. Validate:
75+
## 4. Working Norms
8076

81-
```
82-
npm install
83-
npm run validate
84-
npm run validate:examples
85-
```
86-
5. Update `RESOLUTION.md`, provenance
87-
6. Submit PR with version class (MAJOR/MINOR/PATCH)
77+
Before changing schemas or examples:
78+
79+
- Read `SCHEMAS.md` for layout and versioning rules
80+
- Read `SPEC.md` for the contract you are changing
81+
- Treat published version folders as immutable unless governance explicitly opens a new release line
82+
- Use `npm run validate` as the default repo-wide verification command
8883

89-
Once approved → tagged + pinned.
84+
If you are preparing a contribution, follow `CONTRIBUTING.md`.
9085

9186
## 5. What “Good” Looks Like
9287

README.md

Lines changed: 26 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,28 @@ If agents cannot agree on what actions mean, interoperability breaks.
5959
6060
---
6161
62+
## Table of Contents
63+
- [Real verbs. Real receipts.](#real-verbs-real-receipts)
64+
- [Quickstart](#quickstart)
65+
- [Commons v1.1.0](#commons-v110)
66+
- [What Commons enables](#what-commons-enables)
67+
- [Why this exists](#why-this-exists)
68+
- [Canonical Verbs](#canonical-verbs)
69+
- [Overview](#overview)
70+
- [Key Principles](#key-principles)
71+
- [This is not…](#this-is-not)
72+
- [CommandLayer Protocol Stack](#commandlayer-protocol-stack)
73+
- [Status](#status)
74+
- [Repository Structure](#repository-structure)
75+
- [Manifest](#manifest)
76+
- [Immutability & Checksums](#immutability--checksums)
77+
- [Validation](#validation)
78+
- [License](#license)
79+
- [Next Layers](#next-layers)
80+
- [References](#references)
81+
82+
---
83+
6284
## Real verbs. Real receipts.
6385
6486
```jsonc
@@ -89,14 +111,13 @@ Every v1.1.0 Commons receipt uses the same evidence-oriented spine:
89111
90112
- `status`
91113
- `timestamp`
92-
- `agent`
93114
- `request_hash`
94-
- `result_hash` *(optional)*
95-
- `result_cid` *(optional)*
96115
- `summary` *(required on success)*
97116
- `signature`
98117
- `error` *(required on error)*
99118
119+
`result_hash` and `result_cid` are optional evidence fields. `agent` is optional and may be included when the actor/provider identity needs to be surfaced.
120+
100121
---
101122
102123
## Quickstart
@@ -194,7 +215,7 @@ The receipt contract is proof-oriented rather than transport-oriented:
194215
"version": "1.1.0",
195216
"status": "ok | error",
196217
"timestamp": "<RFC 3339 date-time>",
197-
"agent": "<stable signer identity>",
218+
"agent": "<optional stable signer identity>",
198219
"request_hash": "sha256:<64 lowercase hex chars>",
199220
"result_hash": "sha256:<64 lowercase hex chars>",
200221
"result_cid": "<optional content identifier>",
@@ -206,28 +227,6 @@ The receipt contract is proof-oriented rather than transport-oriented:
206227
207228
These fields let consumers verify that a signer attested to a specific request hash and, when present, a specific result hash or result CID. Commons does not define transport settlement, execution proofs beyond these fields, or any x402-specific wrapping.
208229
209-
## Table of Contents
210-
- [Real verbs. Real receipts.](#real-verbs-real-receipts)
211-
- [Quickstart](#quickstart)
212-
- [Commons v1.1.0](#commons-v110)
213-
- [What Commons enables](#what-commons-enables)
214-
- [Why this exists](#why-this-exists)
215-
- [Canonical Verbs](#canonical-verbs)
216-
- [Overview](#overview)
217-
- [Key Principles](#key-principles)
218-
- [This is not…](#this-is-not)
219-
- [CommandLayer Protocol Stack](#commandlayer-protocol-stack)
220-
- [Status](#status)
221-
- [Repository Structure](#repository-structure)
222-
- [Manifest](#manifest)
223-
- [Immutability & Checksums](#immutability--checksums)
224-
- [Validation](#validation)
225-
- [License](#license)
226-
- [Next Layers](#next-layers)
227-
- [References](#references)
228-
229-
---
230-
231230
## Why this exists
232231
233232
Fragmented agents create isolated ecosystems and brittle automation.
@@ -384,7 +383,6 @@ Commons gives upper layers a stable meaning layer to build around.
384383
│ ├── <verb>.request.schema.json
385384
│ └── <verb>.receipt.schema.json
386385
└── scripts/
387-
├── ajv-run.mjs
388386
├── validate-all.mjs
389387
└── validate-examples.mjs
390388
```
@@ -418,12 +416,11 @@ Published version directories must not be edited in place.
418416
419417
## Validation
420418
421-
Available commands:
419+
Use `npm run validate` as the canonical repo-wide validation command. For targeted checks, the repo also exposes:
422420
423421
```bash
424422
npm run validate:schemas
425423
npm run validate:examples
426-
npm run validate
427424
```
428425
429426
These commands compile schemas in strict Ajv mode and validate the shipped examples for both `v1.0.0` and `v1.1.0`.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@
4949
"ajv-formats": "^3.0.1"
5050
},
5151
"scripts": {
52-
"validate:schema": "node scripts/ajv-run.mjs",
5352
"validate:schemas": "node scripts/validate-all.mjs",
5453
"validate:examples": "node scripts/validate-examples.mjs",
5554
"validate:all": "npm run validate:schemas && npm run validate:examples",

scripts/ajv-run.mjs

Lines changed: 0 additions & 15 deletions
This file was deleted.

0 commit comments

Comments
 (0)