ckodex-stx-spec — Skills Transparency Exchange v1
A symmetric protocol for publishing and querying the runtime state
of a CKODEX skill pool: which skills are loaded, at what tier, with
what evidence chain, under what policy.
STX is the wire format that connects two CKODEX specs:
ckodex-skill-spec-v1.1 — what a skill statically declares (manifest, ontology, runtime hints)
ckodex-skill-lifecycle-rfc001 — how a harness moves skills through the six-tier FSM at runtime
STX itself defines:
- A typed graph domain model (
stx-domain.v1.schema.json)
- An event stream contract for publish-side state changes (
stx-event.v1.schema.json)
- A query/response contract for read access (
stx-query-response.v1.schema.json)
- Three normative transports: REST (OpenAPI 3.1), gRPC (proto3), GraphQL (SDL)
- A capability handshake for transport, privacy mode, and rate-limit negotiation
When this skill triggers
- "design a transparency API for skill state"
- "expose skill lifecycle state to a client"
- "audit what skills a harness has loaded right now"
- "publish skill tier transitions as events"
- "STX", "Skills Transparency Exchange", "skill graph API"
- "GraphQL / gRPC / OpenAPI for skill state"
When this skill does NOT trigger
- Authoring a single skill manifest → use
ckodex-skill-spec-v1.1
- Implementing the FSM kernel inside a harness → use
ckodex-skill-lifecycle-rfc001
- Generic AI observability / OpenTelemetry → STX is skill-specific, not a replacement for OTel
What it ships
ckodex-stx-spec/
├── SKILL.md, README.md, SPEC.md, CHANGELOG.md, MANIFEST.json
├── schemas/
│ ├── stx-domain.v1.schema.json graph types (Harness, Session, SkillState, TierTransition, EvidenceBundle, AttestationChain, PolicyGate, CapabilityDescriptor)
│ ├── stx-event.v1.schema.json publisher event stream
│ ├── stx-query-response.v1.schema.json consumer query envelope
│ └── stx-context-v1.jsonld JSON-LD @context for the domain
├── protocols/
│ ├── openapi.yaml OpenAPI 3.1 (REST)
│ ├── stx.proto gRPC proto3
│ └── schema.graphql GraphQL SDL
├── reference/
│ ├── __init__.py
│ ├── publisher.py harness-side stub
│ └── consumer.py client-side stub
├── conformance/
│ ├── vectors.json 10 canonical vectors (P1..P5, C1..C5)
│ └── run.py kernel-runnable runner
├── examples/
│ ├── handshake-request.json
│ ├── handshake-response.json
│ ├── event-tier-promotion.json
│ ├── event-evidence-emit.json
│ ├── query-skill-pool.json
│ └── query-skill-pool-response.json
├── diagrams/
│ ├── domain-graph.{html, mmd, render-manifest.json} T1 ckodex-native
│ └── publish-subscribe.{html, mmd, render-manifest.json} T4 swimlane
└── scripts/
└── validate.sh bundle self-test (8 sections)
Symmetric protocol (key idea)
STX has two roles that share one domain model:
- Publisher (harness-side) exposes
GET /stx/v1/harness, GET /stx/v1/sessions/{id}, and emits an event stream STREAM /stx/v1/events. It MUST publish capability descriptor, current skill pool state, every tier transition, and every evidence bundle.
- Consumer (client-side) queries the same domain through any of three transports and receives identical typed responses across all of them.
Both roles use the same stx-domain.v1.schema.json types. A conformant implementation passes the publisher vectors (P1..P5) AND the consumer vectors (C1..C5) when acting in the respective role.
Default privacy mode
STX defaults to audit-private. Other modes (debug-local, public-anchor, regulated-export) are negotiated per session via the capability handshake. The default is enforced by the defaultPrivacyMode constant in stx-domain.v1.schema.json.
Verification
bash scripts/validate.sh
# expect: STATUS: 0F / 0W — PASS
The bundle self-test covers: file presence, JSON parse, JSON Schema validity, OpenAPI/proto/GraphQL syntactic validity, conformance vectors P1..P5 + C1..C5, MANIFEST.json sha256 ledger.
References
references/SPEC.md — full narrative specification
references/publisher.md — publisher chapter (what a harness MUST expose)
references/consumer.md — consumer chapter (query patterns + GraphQL)
references/transports.md — how the three transports relate to one shared domain
1---2name: ckodex-stx-spec3description: Skills Transparency Exchange v1 — symmetric publisher/consumer protocol for exposing and querying CKODEX skill-lifecycle runtime state. Use when designing, implementing, or auditing how a harness publishes skill pool state (tier, score, evidence) or how a client queries it. Covers JSON-LD domain model, JSON Schema 2020-12 contracts, OpenAPI 3.1 REST, gRPC proto3, and GraphQL SDL — all three transports normative.4license: Apache-2.05---67# ckodex-stx-spec — Skills Transparency Exchange v189> A symmetric protocol for publishing and querying the runtime state10> of a CKODEX skill pool: which skills are loaded, at what tier, with11> what evidence chain, under what policy.1213STX is the wire format that connects two CKODEX specs:1415- **`ckodex-skill-spec-v1.1`** — what a skill statically declares (manifest, ontology, runtime hints)16- **`ckodex-skill-lifecycle-rfc001`** — how a harness moves skills through the six-tier FSM at runtime1718STX itself defines:19201. A typed graph domain model (`stx-domain.v1.schema.json`)212. An event stream contract for publish-side state changes (`stx-event.v1.schema.json`)223. A query/response contract for read access (`stx-query-response.v1.schema.json`)234. Three normative transports: REST (OpenAPI 3.1), gRPC (proto3), GraphQL (SDL)245. A capability handshake for transport, privacy mode, and rate-limit negotiation2526## When this skill triggers2728- "design a transparency API for skill state"29- "expose skill lifecycle state to a client"30- "audit what skills a harness has loaded right now"31- "publish skill tier transitions as events"32- "STX", "Skills Transparency Exchange", "skill graph API"33- "GraphQL / gRPC / OpenAPI for skill state"3435## When this skill does NOT trigger3637- Authoring a single skill manifest → use `ckodex-skill-spec-v1.1`38- Implementing the FSM kernel inside a harness → use `ckodex-skill-lifecycle-rfc001`39- Generic AI observability / OpenTelemetry → STX is skill-specific, not a replacement for OTel4041## What it ships4243```44ckodex-stx-spec/45├── SKILL.md, README.md, SPEC.md, CHANGELOG.md, MANIFEST.json46├── schemas/47│ ├── stx-domain.v1.schema.json graph types (Harness, Session, SkillState, TierTransition, EvidenceBundle, AttestationChain, PolicyGate, CapabilityDescriptor)48│ ├── stx-event.v1.schema.json publisher event stream49│ ├── stx-query-response.v1.schema.json consumer query envelope50│ └── stx-context-v1.jsonld JSON-LD @context for the domain51├── protocols/52│ ├── openapi.yaml OpenAPI 3.1 (REST)53│ ├── stx.proto gRPC proto354│ └── schema.graphql GraphQL SDL55├── reference/56│ ├── __init__.py57│ ├── publisher.py harness-side stub58│ └── consumer.py client-side stub59├── conformance/60│ ├── vectors.json 10 canonical vectors (P1..P5, C1..C5)61│ └── run.py kernel-runnable runner62├── examples/63│ ├── handshake-request.json64│ ├── handshake-response.json65│ ├── event-tier-promotion.json66│ ├── event-evidence-emit.json67│ ├── query-skill-pool.json68│ └── query-skill-pool-response.json69├── diagrams/70│ ├── domain-graph.{html, mmd, render-manifest.json} T1 ckodex-native71│ └── publish-subscribe.{html, mmd, render-manifest.json} T4 swimlane72└── scripts/73 └── validate.sh bundle self-test (8 sections)74```7576## Symmetric protocol (key idea)7778STX has two roles that share one domain model:7980- **Publisher** (harness-side) exposes `GET /stx/v1/harness`, `GET /stx/v1/sessions/{id}`, and emits an event stream `STREAM /stx/v1/events`. It MUST publish capability descriptor, current skill pool state, every tier transition, and every evidence bundle.81- **Consumer** (client-side) queries the same domain through any of three transports and receives identical typed responses across all of them.8283Both roles use the same `stx-domain.v1.schema.json` types. A conformant implementation passes the publisher vectors (P1..P5) AND the consumer vectors (C1..C5) when acting in the respective role.8485## Default privacy mode8687STX defaults to `audit-private`. Other modes (`debug-local`, `public-anchor`, `regulated-export`) are negotiated per session via the capability handshake. The default is enforced by the `defaultPrivacyMode` constant in `stx-domain.v1.schema.json`.8889## Verification9091```bash92bash scripts/validate.sh93# expect: STATUS: 0F / 0W — PASS94```9596The bundle self-test covers: file presence, JSON parse, JSON Schema validity, OpenAPI/proto/GraphQL syntactic validity, conformance vectors P1..P5 + C1..C5, MANIFEST.json sha256 ledger.9798## References99100- `references/SPEC.md` — full narrative specification101- `references/publisher.md` — publisher chapter (what a harness MUST expose)102- `references/consumer.md` — consumer chapter (query patterns + GraphQL)103- `references/transports.md` — how the three transports relate to one shared domain