@markdown-ai/cli 1.0.0-rc.2
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/HOW-TO-USE.md +386 -0
- package/README.md +18 -0
- package/dist/cli.js +11297 -0
- package/dist/conformance/README.md +36 -0
- package/dist/conformance/invalid/11-name-uppercase.mda +8 -0
- package/dist/conformance/invalid/12-description-over-1024.mda +8 -0
- package/dist/conformance/invalid/13-skill-output-mda-extended-toplevel.md +10 -0
- package/dist/conformance/invalid/14-signature-without-integrity.mda +14 -0
- package/dist/conformance/invalid/15-version-range-compound.mda +13 -0
- package/dist/conformance/invalid/16-agents-md-allowed-tools-toplevel.md +8 -0
- package/dist/conformance/invalid/17-mcp-server-md-missing-name.md +7 -0
- package/dist/conformance/invalid/18-integrity-bad-digest-length.mda +11 -0
- package/dist/conformance/invalid/19-signature-digest-mismatch.mda +17 -0
- package/dist/conformance/invalid/24-unterminated-frontmatter.mda +7 -0
- package/dist/conformance/invalid/25-invalid-utf8.mda +8 -0
- package/dist/conformance/invalid/26-skill-md-body-only.md +3 -0
- package/dist/conformance/invalid/28-trust-policy-issuer-only.json +12 -0
- package/dist/conformance/invalid/29-sigstore-signature-without-rekor.mda +15 -0
- package/dist/conformance/invalid/30-did-web-signature-with-rekor.mda +17 -0
- package/dist/conformance/invalid/31-payload-type-jcs-suffix.mda +18 -0
- package/dist/conformance/invalid/32-trust-policy-sigstore-without-rekor.json +10 -0
- package/dist/conformance/invalid/33-trust-policy-sigstore-empty-rekor.json +11 -0
- package/dist/conformance/invalid/34-trust-policy-sigstore-rekor-disabled.json +14 -0
- package/dist/conformance/invalid/37-trusted-runtime-missing-integrity.mda +11 -0
- package/dist/conformance/invalid/38-trusted-runtime-missing-signature.mda +14 -0
- package/dist/conformance/invalid/39-trusted-runtime-duplicate-did-web-signature.mda +25 -0
- package/dist/conformance/invalid/40-trusted-runtime-untrusted-did-web-signer.mda +20 -0
- package/dist/conformance/invalid/41-trust-policy-did-web-with-rekor.json +12 -0
- package/dist/conformance/invalid/44-trusted-runtime-untrusted-sigstore-subject.mda +23 -0
- package/dist/conformance/invalid/45-runtime-policy-version-2.json +9 -0
- package/dist/conformance/manifest.yaml +376 -0
- package/dist/conformance/valid/01-frontmatter-minimal.mda +8 -0
- package/dist/conformance/valid/03-relationships-with-mirror.mda +20 -0
- package/dist/conformance/valid/04-depends-on-and-requires.mda +21 -0
- package/dist/conformance/valid/05-integrity-sha256.mda +14 -0
- package/dist/conformance/valid/06-sigstore-signed.mda +22 -0
- package/dist/conformance/valid/07-did-web-signed.mda +20 -0
- package/dist/conformance/valid/08-agents-md-frontmatter-free.md +9 -0
- package/dist/conformance/valid/09-agents-md-with-frontmatter.md +12 -0
- package/dist/conformance/valid/20-bom-prefixed.mda +8 -0
- package/dist/conformance/valid/21-crlf-line-endings.mda +8 -0
- package/dist/conformance/valid/22-body-with-horizontal-rule.mda +16 -0
- package/dist/conformance/valid/23-empty-body.mda +4 -0
- package/dist/conformance/valid/27-trust-policy-github-actions.json +13 -0
- package/dist/conformance/valid/35-trust-policy-did-web.json +9 -0
- package/dist/conformance/valid/36-trust-policy-did-web-two-signatures.json +14 -0
- package/dist/conformance/valid/42-trust-policy-human-sigstore.json +13 -0
- package/dist/conformance/valid/43-trusted-runtime-sigstore-signed.mda +23 -0
- package/dist/schemas/_defs/depends-on.schema.json +18 -0
- package/dist/schemas/_defs/description.schema.json +9 -0
- package/dist/schemas/_defs/integrity.schema.json +34 -0
- package/dist/schemas/_defs/iso8601.schema.json +8 -0
- package/dist/schemas/_defs/mda-extended.schema.json +43 -0
- package/dist/schemas/_defs/mda-keys.schema.json +34 -0
- package/dist/schemas/_defs/metadata-namespaces.schema.json +48 -0
- package/dist/schemas/_defs/name.schema.json +10 -0
- package/dist/schemas/_defs/requires.schema.json +13 -0
- package/dist/schemas/_defs/signature.schema.json +72 -0
- package/dist/schemas/_defs/version-range.schema.json +8 -0
- package/dist/schemas/frontmatter-agents-md.schema.json +24 -0
- package/dist/schemas/frontmatter-mcp-server-md.schema.json +25 -0
- package/dist/schemas/frontmatter-skill-md.schema.json +26 -0
- package/dist/schemas/frontmatter-source.schema.json +37 -0
- package/dist/schemas/mda-trust-policy.schema.json +113 -0
- package/dist/schemas/relationship-footnote.schema.json +45 -0
- package/package.json +42 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/integrity.schema.json",
|
|
4
|
+
"title": "MDA integrity field",
|
|
5
|
+
"description": "Cryptographic content hash that anchors the artifact for tamper detection. See spec §08.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["algorithm", "digest"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"algorithm": {
|
|
10
|
+
"type": "string",
|
|
11
|
+
"enum": ["sha256", "sha384", "sha512"]
|
|
12
|
+
},
|
|
13
|
+
"digest": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "Self-describing digest in <algorithm>:<lowercase-hex> form. The prefix MUST match the algorithm field; the hex length MUST match the algorithm.",
|
|
16
|
+
"pattern": "^(sha256|sha384|sha512):[0-9a-f]+$"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"additionalProperties": false,
|
|
20
|
+
"allOf": [
|
|
21
|
+
{
|
|
22
|
+
"if": { "properties": { "algorithm": { "const": "sha256" } } },
|
|
23
|
+
"then": { "properties": { "digest": { "pattern": "^sha256:[0-9a-f]{64}$" } } }
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
"if": { "properties": { "algorithm": { "const": "sha384" } } },
|
|
27
|
+
"then": { "properties": { "digest": { "pattern": "^sha384:[0-9a-f]{96}$" } } }
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"if": { "properties": { "algorithm": { "const": "sha512" } } },
|
|
31
|
+
"then": { "properties": { "digest": { "pattern": "^sha512:[0-9a-f]{128}$" } } }
|
|
32
|
+
}
|
|
33
|
+
]
|
|
34
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/iso8601.schema.json",
|
|
4
|
+
"title": "ISO 8601 date-time",
|
|
5
|
+
"type": "string",
|
|
6
|
+
"format": "date-time",
|
|
7
|
+
"description": "RFC 3339 / ISO 8601 timestamp with timezone, e.g. 2026-01-15T09:00:00Z."
|
|
8
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/mda-extended.schema.json",
|
|
4
|
+
"title": "MDA-extended frontmatter fields",
|
|
5
|
+
"description": "Reusable shape for MDA-extended fields. In .mda sources these MAY appear at the top level. In compiled outputs they MUST be nested under metadata.mda.* (with the same shape).",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"properties": {
|
|
8
|
+
"doc-id": {
|
|
9
|
+
"type": "string",
|
|
10
|
+
"description": "Unique document identifier; UUID format recommended.",
|
|
11
|
+
"pattern": "^[a-zA-Z0-9_-]{8,}$"
|
|
12
|
+
},
|
|
13
|
+
"title": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "Free-text human-readable title. Distinct from `name` (which is a machine ID)."
|
|
16
|
+
},
|
|
17
|
+
"version": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"description": "SemVer 2.0.0 string. MUST be quoted (no number coercion). MUST NOT include build metadata in v1.0.",
|
|
20
|
+
"pattern": "^\\d+\\.\\d+\\.\\d+(-[0-9A-Za-z.-]+)?$"
|
|
21
|
+
},
|
|
22
|
+
"requires": { "$ref": "requires.schema.json" },
|
|
23
|
+
"depends-on": {
|
|
24
|
+
"type": "array",
|
|
25
|
+
"items": { "$ref": "depends-on.schema.json" }
|
|
26
|
+
},
|
|
27
|
+
"author": { "type": "string" },
|
|
28
|
+
"tags": {
|
|
29
|
+
"type": "array",
|
|
30
|
+
"items": { "type": "string" }
|
|
31
|
+
},
|
|
32
|
+
"created-date": { "$ref": "iso8601.schema.json" },
|
|
33
|
+
"updated-date": { "$ref": "iso8601.schema.json" },
|
|
34
|
+
"relationships": {
|
|
35
|
+
"type": "array",
|
|
36
|
+
"items": {
|
|
37
|
+
"$ref": "../relationship-footnote.schema.json"
|
|
38
|
+
},
|
|
39
|
+
"description": "Mirror of footnote relationship payloads. REQUIRED in compiled output when the source had relationship footnotes."
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"additionalProperties": false
|
|
43
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/mda-keys.schema.json",
|
|
4
|
+
"title": "MDA did:web public-keys document",
|
|
5
|
+
"description": "Schema for the JSON document hosted at https://<domain>/.well-known/mda-keys.json used by the did:web signature verification path. See spec §09-5.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["keys"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"keys": {
|
|
10
|
+
"type": "array",
|
|
11
|
+
"minItems": 1,
|
|
12
|
+
"items": {
|
|
13
|
+
"type": "object",
|
|
14
|
+
"required": ["key-id", "algorithm", "public-key"],
|
|
15
|
+
"properties": {
|
|
16
|
+
"key-id": { "type": "string", "minLength": 1 },
|
|
17
|
+
"algorithm": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"enum": ["ed25519", "ecdsa-p256", "rsa-pss-sha256"]
|
|
20
|
+
},
|
|
21
|
+
"public-key": {
|
|
22
|
+
"type": "string",
|
|
23
|
+
"description": "PEM-encoded public key, or base64 raw bytes for ed25519.",
|
|
24
|
+
"minLength": 1
|
|
25
|
+
},
|
|
26
|
+
"not-before": { "type": "string", "format": "date-time" },
|
|
27
|
+
"not-after": { "type": "string", "format": "date-time" }
|
|
28
|
+
},
|
|
29
|
+
"additionalProperties": false
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"additionalProperties": false
|
|
34
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/metadata-namespaces.schema.json",
|
|
4
|
+
"title": "metadata vendor namespaces",
|
|
5
|
+
"description": "Reserved keys under top-level `metadata`. The full registry lives in REGISTRY.md (governed by spec §04).",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"properties": {
|
|
8
|
+
"mda": { "$ref": "mda-extended.schema.json" },
|
|
9
|
+
"claude-code": {
|
|
10
|
+
"type": "object",
|
|
11
|
+
"description": "Anthropic Claude Code namespace.",
|
|
12
|
+
"additionalProperties": true
|
|
13
|
+
},
|
|
14
|
+
"codex": {
|
|
15
|
+
"type": "object",
|
|
16
|
+
"description": "OpenAI Codex namespace.",
|
|
17
|
+
"additionalProperties": true
|
|
18
|
+
},
|
|
19
|
+
"hermes": {
|
|
20
|
+
"type": "object",
|
|
21
|
+
"description": "Nous Research Hermes Agent namespace.",
|
|
22
|
+
"additionalProperties": true
|
|
23
|
+
},
|
|
24
|
+
"opencode": {
|
|
25
|
+
"type": "object",
|
|
26
|
+
"description": "OpenCode namespace.",
|
|
27
|
+
"additionalProperties": true
|
|
28
|
+
},
|
|
29
|
+
"openclaw": {
|
|
30
|
+
"type": "object",
|
|
31
|
+
"description": "OpenClaw namespace.",
|
|
32
|
+
"additionalProperties": true
|
|
33
|
+
},
|
|
34
|
+
"skills-sh": {
|
|
35
|
+
"type": "object",
|
|
36
|
+
"description": "skills.sh / Skills Directory registry namespace.",
|
|
37
|
+
"additionalProperties": true
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"patternProperties": {
|
|
41
|
+
"^[a-z0-9]+(-[a-z0-9]+)*$": {
|
|
42
|
+
"type": "object",
|
|
43
|
+
"description": "Any other vendor namespace; key MUST be a kebab-case identifier and SHOULD be registered in REGISTRY.md.",
|
|
44
|
+
"additionalProperties": true
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
"additionalProperties": false
|
|
48
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/name.schema.json",
|
|
4
|
+
"title": "MDA name identifier",
|
|
5
|
+
"description": "Kebab-case machine identifier shared by `name`, vendor namespace keys, and similar. Used by reference from other schemas.",
|
|
6
|
+
"type": "string",
|
|
7
|
+
"minLength": 1,
|
|
8
|
+
"maxLength": 64,
|
|
9
|
+
"pattern": "^[a-z0-9]+(-[a-z0-9]+)*$"
|
|
10
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/requires.schema.json",
|
|
4
|
+
"title": "MDA requires (capabilities)",
|
|
5
|
+
"description": "Open key-value capability declarations. Standard keys are documented in spec §10 and listed in REGISTRY.md. Unknown keys are permitted and SHOULD be ignored by consumers that do not recognize them.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"propertyNames": {
|
|
8
|
+
"pattern": "^[a-z0-9]+(-[a-z0-9]+)*$",
|
|
9
|
+
"minLength": 1,
|
|
10
|
+
"maxLength": 64
|
|
11
|
+
},
|
|
12
|
+
"additionalProperties": true
|
|
13
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/signature.schema.json",
|
|
4
|
+
"title": "MDA signature entry",
|
|
5
|
+
"description": "One entry in the top-level signatures[] array. Binds a publisher identity to integrity.digest via DSSE PAE. See spec §09.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["signer", "key-id", "payload-digest", "algorithm", "signature"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"signer": {
|
|
10
|
+
"type": "string",
|
|
11
|
+
"description": "<method>:<identity>. method MUST be one of sigstore-oidc, did-web.",
|
|
12
|
+
"pattern": "^(sigstore-oidc|did-web):.+$"
|
|
13
|
+
},
|
|
14
|
+
"key-id": {
|
|
15
|
+
"type": "string",
|
|
16
|
+
"description": "Method-specific handle: Fulcio cert SHA-256 (sigstore) or key fingerprint (did:web).",
|
|
17
|
+
"minLength": 1
|
|
18
|
+
},
|
|
19
|
+
"payload-digest": {
|
|
20
|
+
"type": "string",
|
|
21
|
+
"description": "MUST equal integrity.digest byte-for-byte. Self-describing <algorithm>:<lowercase-hex> form; hex length MUST match the algorithm.",
|
|
22
|
+
"pattern": "^(sha256:[0-9a-f]{64}|sha384:[0-9a-f]{96}|sha512:[0-9a-f]{128})$"
|
|
23
|
+
},
|
|
24
|
+
"algorithm": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"enum": ["ed25519", "ecdsa-p256", "rsa-pss-sha256"]
|
|
27
|
+
},
|
|
28
|
+
"signature": {
|
|
29
|
+
"type": "string",
|
|
30
|
+
"description": "Base64 (RFC 4648 §4) of the raw signature bytes over the DSSE PAE envelope.",
|
|
31
|
+
"minLength": 1
|
|
32
|
+
},
|
|
33
|
+
"rekor-log-id": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"description": "Rekor transparency log identifier; required when signer starts with sigstore-oidc:."
|
|
36
|
+
},
|
|
37
|
+
"rekor-log-index": {
|
|
38
|
+
"type": "integer",
|
|
39
|
+
"minimum": 0,
|
|
40
|
+
"description": "Rekor entry index; required when signer starts with sigstore-oidc:."
|
|
41
|
+
},
|
|
42
|
+
"payload-type": {
|
|
43
|
+
"type": "string",
|
|
44
|
+
"description": "DSSE payload-type declaring the semantic type of the canonicalized payload bytes. Default (when absent): application/vnd.mda.integrity+json. Vendor-defined types follow RFC 6838 vendor tree: application/vnd.<vendor>.<doc-type>+json (the +jcs+ structured-suffix form is non-IANA and not used). The JCS canonicalization contract for each payload-type is defined in spec prose, not in the media-type identifier itself. See §09-3.1 and REGISTRY.md.",
|
|
45
|
+
"pattern": "^application/vnd\\.[a-z0-9][a-z0-9.\\-]*\\+json$"
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"additionalProperties": false,
|
|
49
|
+
"allOf": [
|
|
50
|
+
{
|
|
51
|
+
"if": {
|
|
52
|
+
"properties": { "signer": { "pattern": "^sigstore-oidc:" } }
|
|
53
|
+
},
|
|
54
|
+
"then": {
|
|
55
|
+
"required": ["rekor-log-id", "rekor-log-index"]
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"if": {
|
|
60
|
+
"properties": { "signer": { "pattern": "^did-web:" } }
|
|
61
|
+
},
|
|
62
|
+
"then": {
|
|
63
|
+
"not": {
|
|
64
|
+
"anyOf": [
|
|
65
|
+
{ "required": ["rekor-log-id"] },
|
|
66
|
+
{ "required": ["rekor-log-index"] }
|
|
67
|
+
]
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
]
|
|
72
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/_defs/version-range.schema.json",
|
|
4
|
+
"title": "MDA version-range",
|
|
5
|
+
"description": "Restricted SemVer range admitted by MDA v1.0. Either an exact SemVer 2.0.0 string or a caret range. See spec §03-3.2.",
|
|
6
|
+
"type": "string",
|
|
7
|
+
"pattern": "^\\^?\\d+\\.\\d+\\.\\d+(-[0-9A-Za-z.-]+)?$"
|
|
8
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/frontmatter-agents-md.schema.json",
|
|
4
|
+
"title": "AGENTS.md output frontmatter (strict, optional)",
|
|
5
|
+
"description": "Strict schema for the optional YAML frontmatter of an AGENTS.md file. Frontmatter is OPTIONAL in AGENTS.md (per AAIF upstream); when present, MDA-extended fields MUST appear under metadata.mda.* and per-vendor fields under metadata.<vendor>.*. allowed-tools is NOT permitted at the top level.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"properties": {
|
|
8
|
+
"name": { "$ref": "_defs/name.schema.json" },
|
|
9
|
+
"description": { "$ref": "_defs/description.schema.json" },
|
|
10
|
+
"license": { "type": "string" },
|
|
11
|
+
"compatibility": { "type": "string", "maxLength": 500 },
|
|
12
|
+
"metadata": { "$ref": "_defs/metadata-namespaces.schema.json" },
|
|
13
|
+
"integrity": { "$ref": "_defs/integrity.schema.json" },
|
|
14
|
+
"signatures": {
|
|
15
|
+
"type": "array",
|
|
16
|
+
"minItems": 1,
|
|
17
|
+
"items": { "$ref": "_defs/signature.schema.json" }
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"dependentRequired": {
|
|
21
|
+
"signatures": ["integrity"]
|
|
22
|
+
},
|
|
23
|
+
"unevaluatedProperties": false
|
|
24
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/frontmatter-mcp-server-md.schema.json",
|
|
4
|
+
"title": "MCP-SERVER.md output frontmatter (strict)",
|
|
5
|
+
"description": "Strict schema for the YAML frontmatter of a compiled MCP-SERVER.md file. Two-file artifact: requires a sibling mcp-server.json. MDA-extended fields MUST appear under metadata.mda.*; per-vendor fields under metadata.<vendor>.*. allowed-tools is NOT permitted at the top level.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["name", "description"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"name": { "$ref": "_defs/name.schema.json" },
|
|
10
|
+
"description": { "$ref": "_defs/description.schema.json" },
|
|
11
|
+
"license": { "type": "string" },
|
|
12
|
+
"compatibility": { "type": "string", "maxLength": 500 },
|
|
13
|
+
"metadata": { "$ref": "_defs/metadata-namespaces.schema.json" },
|
|
14
|
+
"integrity": { "$ref": "_defs/integrity.schema.json" },
|
|
15
|
+
"signatures": {
|
|
16
|
+
"type": "array",
|
|
17
|
+
"minItems": 1,
|
|
18
|
+
"items": { "$ref": "_defs/signature.schema.json" }
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
"dependentRequired": {
|
|
22
|
+
"signatures": ["integrity"]
|
|
23
|
+
},
|
|
24
|
+
"unevaluatedProperties": false
|
|
25
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/frontmatter-skill-md.schema.json",
|
|
4
|
+
"title": "SKILL.md output frontmatter (strict)",
|
|
5
|
+
"description": "Strict schema for the YAML frontmatter of a compiled SKILL.md file. Conforms to agentskills.io v1. MDA-extended fields MUST appear under metadata.mda.*; per-vendor fields MUST appear under metadata.<vendor>.*. unevaluatedProperties:false enforces the no-stray-fields rule.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["name", "description"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"name": { "$ref": "_defs/name.schema.json" },
|
|
10
|
+
"description": { "$ref": "_defs/description.schema.json" },
|
|
11
|
+
"license": { "type": "string" },
|
|
12
|
+
"compatibility": { "type": "string", "maxLength": 500 },
|
|
13
|
+
"allowed-tools": { "type": "string" },
|
|
14
|
+
"metadata": { "$ref": "_defs/metadata-namespaces.schema.json" },
|
|
15
|
+
"integrity": { "$ref": "_defs/integrity.schema.json" },
|
|
16
|
+
"signatures": {
|
|
17
|
+
"type": "array",
|
|
18
|
+
"minItems": 1,
|
|
19
|
+
"items": { "$ref": "_defs/signature.schema.json" }
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"dependentRequired": {
|
|
23
|
+
"signatures": ["integrity"]
|
|
24
|
+
},
|
|
25
|
+
"unevaluatedProperties": false
|
|
26
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/frontmatter-source.schema.json",
|
|
4
|
+
"title": "MDA source frontmatter",
|
|
5
|
+
"description": "Permissive schema for .mda source files. MDA-extended fields MAY appear at the top level. Open-standard fields are also accepted at the top level. Use frontmatter-skill-md / frontmatter-agents-md / frontmatter-mcp-server-md for compiled outputs.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"properties": {
|
|
8
|
+
"name": { "$ref": "_defs/name.schema.json" },
|
|
9
|
+
"description": { "$ref": "_defs/description.schema.json" },
|
|
10
|
+
"license": { "type": "string" },
|
|
11
|
+
"compatibility": { "type": "string", "maxLength": 500 },
|
|
12
|
+
"allowed-tools": { "type": "string" },
|
|
13
|
+
"metadata": { "$ref": "_defs/metadata-namespaces.schema.json" },
|
|
14
|
+
|
|
15
|
+
"integrity": { "$ref": "_defs/integrity.schema.json" },
|
|
16
|
+
"signatures": {
|
|
17
|
+
"type": "array",
|
|
18
|
+
"minItems": 1,
|
|
19
|
+
"items": { "$ref": "_defs/signature.schema.json" }
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
"doc-id": { "$ref": "_defs/mda-extended.schema.json#/properties/doc-id" },
|
|
23
|
+
"title": { "$ref": "_defs/mda-extended.schema.json#/properties/title" },
|
|
24
|
+
"version": { "$ref": "_defs/mda-extended.schema.json#/properties/version" },
|
|
25
|
+
"requires": { "$ref": "_defs/requires.schema.json" },
|
|
26
|
+
"depends-on": { "$ref": "_defs/mda-extended.schema.json#/properties/depends-on" },
|
|
27
|
+
"author": { "$ref": "_defs/mda-extended.schema.json#/properties/author" },
|
|
28
|
+
"tags": { "$ref": "_defs/mda-extended.schema.json#/properties/tags" },
|
|
29
|
+
"created-date": { "$ref": "_defs/iso8601.schema.json" },
|
|
30
|
+
"updated-date": { "$ref": "_defs/iso8601.schema.json" },
|
|
31
|
+
"relationships": { "$ref": "_defs/mda-extended.schema.json#/properties/relationships" }
|
|
32
|
+
},
|
|
33
|
+
"dependentRequired": {
|
|
34
|
+
"signatures": ["integrity"]
|
|
35
|
+
},
|
|
36
|
+
"additionalProperties": false
|
|
37
|
+
}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/mda-trust-policy.schema.json",
|
|
4
|
+
"title": "MDA trust policy",
|
|
5
|
+
"description": "Trust policy for the MDA trusted-runtime verification profile.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["version", "trustedSigners"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"version": {
|
|
10
|
+
"type": "integer",
|
|
11
|
+
"const": 1
|
|
12
|
+
},
|
|
13
|
+
"minSignatures": {
|
|
14
|
+
"type": "integer",
|
|
15
|
+
"minimum": 1
|
|
16
|
+
},
|
|
17
|
+
"trustedSigners": {
|
|
18
|
+
"type": "array",
|
|
19
|
+
"minItems": 1,
|
|
20
|
+
"uniqueItems": true,
|
|
21
|
+
"items": {
|
|
22
|
+
"oneOf": [
|
|
23
|
+
{
|
|
24
|
+
"type": "object",
|
|
25
|
+
"required": ["type", "issuer", "subject"],
|
|
26
|
+
"properties": {
|
|
27
|
+
"type": { "const": "sigstore-oidc" },
|
|
28
|
+
"issuer": {
|
|
29
|
+
"type": "string",
|
|
30
|
+
"format": "uri",
|
|
31
|
+
"minLength": 1
|
|
32
|
+
},
|
|
33
|
+
"subject": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"minLength": 1
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
"additionalProperties": false
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"type": "object",
|
|
42
|
+
"required": ["type", "domain"],
|
|
43
|
+
"properties": {
|
|
44
|
+
"type": { "const": "did-web" },
|
|
45
|
+
"domain": {
|
|
46
|
+
"type": "string",
|
|
47
|
+
"pattern": "^[A-Za-z0-9](?:[A-Za-z0-9.-]{0,251}[A-Za-z0-9])?$"
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"additionalProperties": false
|
|
51
|
+
}
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"rekor": {
|
|
56
|
+
"type": "object",
|
|
57
|
+
"required": ["url"],
|
|
58
|
+
"properties": {
|
|
59
|
+
"url": {
|
|
60
|
+
"type": "string",
|
|
61
|
+
"format": "uri"
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"additionalProperties": false
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
"allOf": [
|
|
68
|
+
{
|
|
69
|
+
"if": {
|
|
70
|
+
"properties": {
|
|
71
|
+
"trustedSigners": {
|
|
72
|
+
"contains": {
|
|
73
|
+
"type": "object",
|
|
74
|
+
"properties": {
|
|
75
|
+
"type": { "const": "sigstore-oidc" }
|
|
76
|
+
},
|
|
77
|
+
"required": ["type"]
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
"required": ["trustedSigners"]
|
|
82
|
+
},
|
|
83
|
+
"then": {
|
|
84
|
+
"required": ["rekor"],
|
|
85
|
+
"properties": {
|
|
86
|
+
"rekor": { "required": ["url"] }
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"if": {
|
|
92
|
+
"properties": {
|
|
93
|
+
"trustedSigners": {
|
|
94
|
+
"not": {
|
|
95
|
+
"contains": {
|
|
96
|
+
"type": "object",
|
|
97
|
+
"properties": {
|
|
98
|
+
"type": { "const": "sigstore-oidc" }
|
|
99
|
+
},
|
|
100
|
+
"required": ["type"]
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"required": ["trustedSigners"]
|
|
106
|
+
},
|
|
107
|
+
"then": {
|
|
108
|
+
"not": { "required": ["rekor"] }
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
],
|
|
112
|
+
"additionalProperties": false
|
|
113
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://mda.sno.dev/spec/v1.0/schemas/relationship-footnote.schema.json",
|
|
4
|
+
"title": "MDA relationship payload",
|
|
5
|
+
"description": "Schema for the JSON payload of an MDA relationship footnote (`[^id]: { ... }`) and for entries in the `metadata.mda.relationships` mirror in compiled outputs.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["rel-type", "doc-id"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"rel-type": {
|
|
10
|
+
"type": "string",
|
|
11
|
+
"enum": ["parent", "child", "related", "cites", "supports", "contradicts", "extends"],
|
|
12
|
+
"description": "The kind of relationship to the target document."
|
|
13
|
+
},
|
|
14
|
+
"doc-id": {
|
|
15
|
+
"type": "string",
|
|
16
|
+
"description": "Target document's `doc-id`. UUID format recommended.",
|
|
17
|
+
"minLength": 1
|
|
18
|
+
},
|
|
19
|
+
"rel-desc": {
|
|
20
|
+
"type": "string",
|
|
21
|
+
"description": "Human-readable description of the relationship."
|
|
22
|
+
},
|
|
23
|
+
"rel-strength": {
|
|
24
|
+
"type": "number",
|
|
25
|
+
"minimum": 0,
|
|
26
|
+
"maximum": 1,
|
|
27
|
+
"description": "Optional confidence/relevance score [0,1]."
|
|
28
|
+
},
|
|
29
|
+
"bi-directional": {
|
|
30
|
+
"type": "boolean",
|
|
31
|
+
"default": false,
|
|
32
|
+
"description": "Whether the relationship implies a link back from the target."
|
|
33
|
+
},
|
|
34
|
+
"context": {
|
|
35
|
+
"type": "object",
|
|
36
|
+
"description": "Optional details about where/how this link applies.",
|
|
37
|
+
"properties": {
|
|
38
|
+
"section": { "type": "string" },
|
|
39
|
+
"relevance": { "type": "string" }
|
|
40
|
+
},
|
|
41
|
+
"additionalProperties": true
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"additionalProperties": false
|
|
45
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@markdown-ai/cli",
|
|
3
|
+
"version": "1.0.0-rc.2",
|
|
4
|
+
"description": "Reference CLI for Markdown AI / MDA artifacts.",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "git+https://github.com/sno-ai/mda.git",
|
|
9
|
+
"directory": "apps/cli"
|
|
10
|
+
},
|
|
11
|
+
"homepage": "https://github.com/sno-ai/mda/tree/main/apps/cli",
|
|
12
|
+
"bugs": {
|
|
13
|
+
"url": "https://github.com/sno-ai/mda/issues"
|
|
14
|
+
},
|
|
15
|
+
"type": "module",
|
|
16
|
+
"bin": {
|
|
17
|
+
"mda": "dist/cli.js"
|
|
18
|
+
},
|
|
19
|
+
"files": [
|
|
20
|
+
"dist",
|
|
21
|
+
"README.md",
|
|
22
|
+
"HOW-TO-USE.md"
|
|
23
|
+
],
|
|
24
|
+
"publishConfig": {
|
|
25
|
+
"access": "public",
|
|
26
|
+
"registry": "https://registry.npmjs.org"
|
|
27
|
+
},
|
|
28
|
+
"keywords": [
|
|
29
|
+
"mda",
|
|
30
|
+
"markdown-ai",
|
|
31
|
+
"agent",
|
|
32
|
+
"cli",
|
|
33
|
+
"conformance"
|
|
34
|
+
],
|
|
35
|
+
"engines": {
|
|
36
|
+
"node": ">=20"
|
|
37
|
+
},
|
|
38
|
+
"scripts": {
|
|
39
|
+
"build": "node scripts/build.mjs",
|
|
40
|
+
"test": "node dist/cli.js --help >/dev/null && node dist/cli.js conformance --suite ../../conformance --level V --json >/dev/null && node test/e2e.mjs"
|
|
41
|
+
}
|
|
42
|
+
}
|