@ynhcj/xiaoyi-channel 0.0.121-beta → 0.0.122-beta

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/dist/index.d.ts CHANGED
@@ -1,9 +1,11 @@
1
1
  import type { OpenClawPluginApi } from "openclaw/plugin-sdk";
2
- declare const plugin: {
2
+ declare const _default: {
3
3
  id: string;
4
4
  name: string;
5
5
  description: string;
6
- configSchema: import("openclaw/plugin-sdk").OpenClawPluginConfigSchema;
7
- register(api: OpenClawPluginApi): void;
6
+ configSchema: import("openclaw/plugin-sdk").ChannelConfigSchema;
7
+ register: (api: OpenClawPluginApi) => void;
8
+ channelPlugin: import("openclaw/plugin-sdk").ChannelPlugin;
9
+ setChannelRuntime?: (runtime: import("openclaw/plugin-sdk").PluginRuntime) => void;
8
10
  };
9
- export default plugin;
11
+ export default _default;
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { emptyPluginConfigSchema } from "openclaw/plugin-sdk";
1
+ import { defineChannelPluginEntry } from "openclaw/plugin-sdk/core";
2
2
  import { xiaoyiProvider } from "./src/provider.js";
3
3
  import { xyPlugin } from "./src/channel.js";
4
4
  import { callCsplApi } from "./src/cspl/call-api.js";
@@ -9,14 +9,13 @@ import { tryInjectSteer } from "./src/steer-injector.js";
9
9
  import { registerSelfEvolutionToolResultNudge } from "./src/self-evolution-tool-result-nudge.js";
10
10
  import { createBeforePromptBuildHandler } from "./src/skill-retriever/hooks.js";
11
11
  import { normalizeToolRetrieverConfig } from "./src/skill-retriever/config.js";
12
- const plugin = {
12
+ export default defineChannelPluginEntry({
13
13
  id: "xiaoyi-channel",
14
14
  name: "Xiaoyi Channel",
15
15
  description: "Xiaoyi channel plugin - Xiaoyi A2A protocol integration",
16
- configSchema: emptyPluginConfigSchema(),
17
- register(api) {
18
- setXYRuntime(api.runtime);
19
- api.registerChannel({ plugin: xyPlugin });
16
+ plugin: xyPlugin,
17
+ setRuntime: setXYRuntime,
18
+ registerFull(api) {
20
19
  api.registerProvider(xiaoyiProvider);
21
20
  // SKILL RETRIEVER HOOK: before_prompt_build hook
22
21
  const pluginConfig = api.pluginConfig || {};
@@ -67,5 +66,4 @@ const plugin = {
67
66
  }
68
67
  });
69
68
  },
70
- };
71
- export default plugin;
69
+ });
@@ -1,3 +1,3 @@
1
- import type { ProviderPlugin } from "openclaw/plugin-sdk/provider-models";
1
+ import type { ProviderPlugin } from "openclaw/plugin-sdk/provider-model-shared";
2
2
  export declare function applySelfEvolutionPrompt(systemPrompt: string | undefined, enabled: boolean): string;
3
3
  export declare const xiaoyiProvider: ProviderPlugin;
@@ -1,11 +1,3 @@
1
- import type { PluginRuntime } from "openclaw/plugin-sdk";
2
- /**
3
- * Set the Xiaoyi channel runtime instance.
4
- * This should be called once during plugin initialization.
5
- */
6
- export declare function setXYRuntime(next: PluginRuntime): void;
7
- /**
8
- * Get the current Xiaoyi channel runtime instance.
9
- * Throws an error if the runtime has not been initialized.
10
- */
11
- export declare function getXYRuntime(): PluginRuntime;
1
+ import type { PluginRuntime } from "openclaw/plugin-sdk/core";
2
+ declare const setXYRuntime: (next: PluginRuntime) => void, getXYRuntime: () => PluginRuntime;
3
+ export { getXYRuntime, setXYRuntime };
@@ -1,18 +1,6 @@
1
- let runtime = null;
2
- /**
3
- * Set the Xiaoyi channel runtime instance.
4
- * This should be called once during plugin initialization.
5
- */
6
- export function setXYRuntime(next) {
7
- runtime = next;
8
- }
9
- /**
10
- * Get the current Xiaoyi channel runtime instance.
11
- * Throws an error if the runtime has not been initialized.
12
- */
13
- export function getXYRuntime() {
14
- if (!runtime) {
15
- throw new Error("Xiaoyi runtime not initialized. Call setXYRuntime() first.");
16
- }
17
- return runtime;
18
- }
1
+ import { createPluginRuntimeStore } from "openclaw/plugin-sdk/runtime-store";
2
+ const { setRuntime: setXYRuntime, getRuntime: getXYRuntime } = createPluginRuntimeStore({
3
+ pluginId: "xiaoyi-channel",
4
+ errorMessage: "Xiaoyi runtime not initialized. Call setXYRuntime() first.",
5
+ });
6
+ export { getXYRuntime, setXYRuntime };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ynhcj/xiaoyi-channel",
3
- "version": "0.0.121-beta",
3
+ "version": "0.0.122-beta",
4
4
  "description": "OpenClaw Xiaoyi Channel plugin - Xiaoyi A2A protocol integration",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -49,7 +49,7 @@
49
49
  }
50
50
  },
51
51
  "peerDependencies": {
52
- "openclaw": ">=2026.3.24"
52
+ "openclaw": ">=2026.5.6"
53
53
  },
54
54
  "peerDependenciesMeta": {
55
55
  "openclaw": {