@dot-skill/protocol 0.4.2 → 0.5.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 +36 -0
- package/dist/authoring.d.ts +14 -0
- package/dist/authoring.js +260 -0
- package/dist/contract.d.ts +190 -0
- package/dist/contract.js +1 -0
- package/dist/extract.d.ts +89 -0
- package/dist/extract.js +299 -0
- package/dist/index.d.ts +7 -3
- package/dist/index.js +4 -2
- package/dist/recipe.d.ts +3 -0
- package/dist/recipe.js +1 -0
- package/dist/source.d.ts +23 -1
- package/dist/source.js +50 -1
- package/dist/types.d.ts +126 -5
- package/dist/types.js +3 -3
- package/package.json +21 -4
- package/skill-contract.schema.json +105 -0
package/dist/types.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/** Open .skill Protocol v0.
|
|
2
|
-
export const PROTOCOL_VERSION = "0.
|
|
1
|
+
/** Open .skill Protocol v0.5 — semantic types for portable `.skill` packages. */
|
|
2
|
+
export const PROTOCOL_VERSION = "0.5.0";
|
|
3
3
|
export const CONTAINER_VERSION = "1.0";
|
|
4
|
-
export const WORKFLOW_DIALECT_VERSION = "1.
|
|
4
|
+
export const WORKFLOW_DIALECT_VERSION = "1.1";
|
|
5
5
|
/** Media type for a packaged `.skill` archive (zip). */
|
|
6
6
|
export const MEDIA_TYPE = "application/vnd.dot-skill+zip";
|
|
7
7
|
/** Media type for the manifest JSON document inside a `.skill` archive. */
|
package/package.json
CHANGED
|
@@ -1,12 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dot-skill/protocol",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.5.0",
|
|
4
|
+
"description": "Types, schemas, and completeness rules for portable .skill packages",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Bharat Dudeja",
|
|
8
8
|
"url": "https://github.com/bharatdudeja13-cmd"
|
|
9
9
|
},
|
|
10
|
+
"keywords": [
|
|
11
|
+
"skill",
|
|
12
|
+
"dot-skill",
|
|
13
|
+
".skill",
|
|
14
|
+
"ai-agents",
|
|
15
|
+
"agent-skills",
|
|
16
|
+
"protocol",
|
|
17
|
+
"types"
|
|
18
|
+
],
|
|
10
19
|
"type": "module",
|
|
11
20
|
"main": "./dist/index.js",
|
|
12
21
|
"types": "./dist/index.d.ts",
|
|
@@ -18,14 +27,22 @@
|
|
|
18
27
|
"url": "https://github.com/dot-skill/dot-skill.git",
|
|
19
28
|
"directory": "packages/protocol"
|
|
20
29
|
},
|
|
30
|
+
"homepage": "https://github.com/dot-skill/dot-skill#readme",
|
|
31
|
+
"bugs": {
|
|
32
|
+
"url": "https://github.com/dot-skill/dot-skill/issues"
|
|
33
|
+
},
|
|
21
34
|
"files": [
|
|
22
|
-
"dist"
|
|
35
|
+
"dist",
|
|
36
|
+
"skill-contract.schema.json",
|
|
37
|
+
"README.md",
|
|
38
|
+
"LICENSE"
|
|
23
39
|
],
|
|
24
40
|
"exports": {
|
|
25
41
|
".": {
|
|
26
42
|
"import": "./dist/index.js",
|
|
27
43
|
"types": "./dist/index.d.ts"
|
|
28
|
-
}
|
|
44
|
+
},
|
|
45
|
+
"./skill-contract.schema.json": "./skill-contract.schema.json"
|
|
29
46
|
},
|
|
30
47
|
"scripts": {
|
|
31
48
|
"build": "rm -rf dist && tsc",
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://dot-skill.org/schema/0.5/skill-contract.schema.json",
|
|
4
|
+
"title": "Open .skill 0.5 authoring contract",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"kind",
|
|
9
|
+
"contract_version",
|
|
10
|
+
"skill_kind",
|
|
11
|
+
"title",
|
|
12
|
+
"intent",
|
|
13
|
+
"sensitivity",
|
|
14
|
+
"triggers",
|
|
15
|
+
"inputs",
|
|
16
|
+
"preconditions",
|
|
17
|
+
"steps",
|
|
18
|
+
"branches",
|
|
19
|
+
"human_decisions",
|
|
20
|
+
"capabilities",
|
|
21
|
+
"permissions",
|
|
22
|
+
"forbidden_actions",
|
|
23
|
+
"outputs",
|
|
24
|
+
"recovery",
|
|
25
|
+
"verification",
|
|
26
|
+
"corrections",
|
|
27
|
+
"provenance"
|
|
28
|
+
],
|
|
29
|
+
"properties": {
|
|
30
|
+
"kind": { "const": "skill_contract" },
|
|
31
|
+
"contract_version": { "const": "0.5" },
|
|
32
|
+
"skill_kind": { "enum": ["knowledge", "procedure", "integration"] },
|
|
33
|
+
"title": { "type": "string", "minLength": 1 },
|
|
34
|
+
"intent": { "type": "string", "minLength": 1 },
|
|
35
|
+
"sensitivity": { "enum": ["private", "shareable_redacted", "public"] },
|
|
36
|
+
"triggers": { "$ref": "#/$defs/declaration" },
|
|
37
|
+
"inputs": { "$ref": "#/$defs/declaration" },
|
|
38
|
+
"preconditions": { "$ref": "#/$defs/declaration" },
|
|
39
|
+
"steps": { "$ref": "#/$defs/declaration" },
|
|
40
|
+
"branches": { "$ref": "#/$defs/declaration" },
|
|
41
|
+
"human_decisions": { "$ref": "#/$defs/declaration" },
|
|
42
|
+
"capabilities": { "$ref": "#/$defs/declaration" },
|
|
43
|
+
"permissions": { "$ref": "#/$defs/declaration" },
|
|
44
|
+
"forbidden_actions": { "$ref": "#/$defs/declaration" },
|
|
45
|
+
"outputs": { "$ref": "#/$defs/declaration" },
|
|
46
|
+
"recovery": { "$ref": "#/$defs/declaration" },
|
|
47
|
+
"verification": { "$ref": "#/$defs/declaration" },
|
|
48
|
+
"corrections": { "$ref": "#/$defs/declaration" },
|
|
49
|
+
"provenance": {
|
|
50
|
+
"type": "object",
|
|
51
|
+
"additionalProperties": false,
|
|
52
|
+
"required": ["evidence", "limitations", "human_review"],
|
|
53
|
+
"properties": {
|
|
54
|
+
"evidence": { "$ref": "#/$defs/declaration" },
|
|
55
|
+
"limitations": { "$ref": "#/$defs/declaration" },
|
|
56
|
+
"human_review": {
|
|
57
|
+
"oneOf": [
|
|
58
|
+
{
|
|
59
|
+
"type": "object",
|
|
60
|
+
"additionalProperties": false,
|
|
61
|
+
"required": ["status"],
|
|
62
|
+
"properties": { "status": { "const": "not_reviewed" } }
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"type": "object",
|
|
66
|
+
"additionalProperties": false,
|
|
67
|
+
"required": ["status", "actor", "at", "scope"],
|
|
68
|
+
"properties": {
|
|
69
|
+
"status": { "const": "reviewed" },
|
|
70
|
+
"actor": { "type": "string", "minLength": 1 },
|
|
71
|
+
"at": { "type": "string", "format": "date-time" },
|
|
72
|
+
"scope": { "type": "array", "minItems": 1, "items": { "type": "string" } },
|
|
73
|
+
"digest": { "type": "string" }
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
]
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
"$defs": {
|
|
82
|
+
"declaration": {
|
|
83
|
+
"oneOf": [
|
|
84
|
+
{
|
|
85
|
+
"type": "object",
|
|
86
|
+
"additionalProperties": false,
|
|
87
|
+
"required": ["status", "items"],
|
|
88
|
+
"properties": {
|
|
89
|
+
"status": { "const": "specified" },
|
|
90
|
+
"items": { "type": "array", "minItems": 1, "items": { "type": ["object", "string"] } }
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"type": "object",
|
|
95
|
+
"additionalProperties": false,
|
|
96
|
+
"required": ["status", "reason"],
|
|
97
|
+
"properties": {
|
|
98
|
+
"status": { "enum": ["none", "not_applicable"] },
|
|
99
|
+
"reason": { "type": "string", "minLength": 1 }
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
]
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|