@yaklabs-ai/plugin-protocol 0.8.4

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 YakLabs
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,58 @@
1
+ # @yaklabs-ai/plugin-protocol
2
+
3
+ The **`kay.plugin.v1` manifest schema** — the same Zod schema Kay's daemon uses
4
+ to parse `kay-plugin.json` at load time.
5
+
6
+ Published to the public npm registry under the MIT licence, always at the same
7
+ version as `@yaklabs-ai/plugin-sdk`. No registry configuration and no access
8
+ token are needed. See `@yaklabs-ai/plugin-sdk`'s README for the full authoring
9
+ flow.
10
+
11
+ ```json
12
+ {
13
+ "dependencies": {
14
+ "@kay/plugin-protocol": "npm:@yaklabs-ai/plugin-protocol@^0.8.4"
15
+ }
16
+ }
17
+ ```
18
+
19
+ ## Why you want this
20
+
21
+ Validate your manifest in your own CI, against the real schema, instead of a
22
+ hand-written approximation:
23
+
24
+ ```js
25
+ import { KayPluginManifestV1 } from "@kay/plugin-protocol";
26
+
27
+ const parsed = KayPluginManifestV1.safeParse(
28
+ JSON.parse(await readFile("kay-plugin.json", "utf8")),
29
+ );
30
+ if (!parsed.success) {
31
+ for (const issue of parsed.error.issues) {
32
+ console.error(`${issue.path.join(".") || "<root>"}: ${issue.message}`);
33
+ }
34
+ process.exit(1);
35
+ }
36
+ ```
37
+
38
+ A hand-rolled field check drifts from the contract it claims to enforce and
39
+ passes while the host rejects the plugin at load. This is the host's own schema,
40
+ so it cannot drift — and unlike resolving it out of a Kay checkout, it needs no
41
+ clone, no build, and no `KAY_REPO` environment variable.
42
+
43
+ ## Version it against your Kay app
44
+
45
+ The schema changes over time — it gains fields, and it can also **remove** one.
46
+ Three skews follow, and only the first two fail on your machine:
47
+
48
+ - Validating against a **newer** schema than your Kay app runs can accept a
49
+ manifest the host will reject.
50
+ - Validating against an **older** schema can reject a manifest the host would
51
+ happily load.
52
+ - Validating against an **older** schema can also _accept_ a field the host has
53
+ since removed. `KayPluginManifestV1` parses with `strictObject`, so an
54
+ unrecognized key is a hard rejection: your local validation goes green, and
55
+ Kay drops the plugin at load with a diagnostic you never see.
56
+
57
+ Keep this package in step with the Kay version you target — the third skew is
58
+ the one a green local run will not warn you about.
@@ -0,0 +1,23 @@
1
+ {
2
+ "schemaVersion": 1,
3
+ "package": "@yaklabs-ai/plugin-protocol",
4
+ "version": "0.8.4",
5
+ "target": "npm",
6
+ "firstPartyLicense": "MIT",
7
+ "bundled": [],
8
+ "external": [
9
+ {
10
+ "name": "zod",
11
+ "license": "MIT",
12
+ "source": "https://github.com/colinhacks/zod",
13
+ "note": "Installed as a consumer dependency; it is not bundled into the staged artifacts.",
14
+ "versionRange": "^4.0.0"
15
+ },
16
+ {
17
+ "name": "@typesafe-ai/sdk",
18
+ "license": "MIT",
19
+ "source": "https://github.com/typesafe-ai/typesafe-sdk-js",
20
+ "note": "Types-only: the SDK re-exports the vendor's Jev client types, and the vendor's nominal class must stay a single declaration across entrypoints. Installed as a consumer dependency; a plugin never declares it itself."
21
+ }
22
+ ]
23
+ }
@@ -0,0 +1,5 @@
1
+ # Third-party notices
2
+
3
+ This package bundles 0 first-party-selected component(s). The notices below are reproduced verbatim from each component's upstream MIT license source.
4
+
5
+ The package's own code is licensed under the MIT License in `LICENSE`.