@rynx-ai/plugin-channel-lark 0.1.11-beta.8 → 0.1.11-beta.9

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.
@@ -35,7 +35,9 @@ export class CodexMirrorIndex {
35
35
  chatId: directory.chatId,
36
36
  threadId: directory.threadId,
37
37
  participants: directory.participants ?? [],
38
- model: session.execution.model,
38
+ // A null model means the provider CLI owns model selection. The mirror
39
+ // still needs a stable string label for transcript normalization.
40
+ model: session.execution.model ?? session.execution.provider,
39
41
  };
40
42
  }
41
43
  /** All Codex threads currently bound to a Feishu conversation (those whose
@@ -23,7 +23,7 @@ export declare class HostConversationRuntime implements LarkConversationRuntime
23
23
  runLive(input: ConversationStreamRequest): Promise<{
24
24
  provider: "codex" | "traex" | "claude";
25
25
  threadId: string;
26
- model: string;
26
+ model: string | null;
27
27
  authSource: "codex_cli" | "traex_cli" | "claude_cli";
28
28
  generator: AsyncGenerator<SessionEvent, any, any>;
29
29
  }>;
@@ -88,6 +88,8 @@ export class HostConversationRuntime {
88
88
  try {
89
89
  started = await this.host.sessions.run({
90
90
  sessionId: input.threadId,
91
+ model: input.model?.trim() || null,
92
+ reasoningEffort: input.reasoningEffort?.trim() || null,
91
93
  message: input.message,
92
94
  });
93
95
  runId = started.runId;
@@ -188,7 +190,7 @@ export class HostSessionProvisioner {
188
190
  throw new Error("host did not return a provisioned session id");
189
191
  this.resolvedExecutions.set(result.sessionId, {
190
192
  runtime: result.execution.provider,
191
- model: result.execution.model,
193
+ ...(result.execution.model ? { model: result.execution.model } : {}),
192
194
  ...(result.execution.reasoningEffort
193
195
  ? { reasoningEffort: result.execution.reasoningEffort }
194
196
  : {}),
@@ -206,7 +208,7 @@ export class HostSessionProvisioner {
206
208
  const session = await this.host.sessions.get({ sessionId });
207
209
  return {
208
210
  runtime: session.execution.provider,
209
- model: session.execution.model,
211
+ ...(session.execution.model ? { model: session.execution.model } : {}),
210
212
  ...(session.execution.reasoningEffort
211
213
  ? { reasoningEffort: session.execution.reasoningEffort }
212
214
  : {}),
package/dist/lark.js CHANGED
@@ -1308,11 +1308,9 @@ export class LarkMessageIngestor {
1308
1308
  const effort = pending.effort !== SETTINGS_DEFAULT_VALUE && allowedEfforts.includes(pending.effort)
1309
1309
  ? pending.effort
1310
1310
  : undefined;
1311
- // Execution is immutable once a Session is created. Any Provider, model, or
1312
- // reasoning-effort change therefore starts a fresh Session snapshot.
1313
- const rotate = runtime !== pending.currentRuntime ||
1314
- model !== pending.currentModel ||
1315
- effort !== pending.currentEffort;
1311
+ // Provider selects the immutable runtime implementation. Model and
1312
+ // reasoning effort are Turn settings and update the same idle Session.
1313
+ const rotate = runtime !== pending.currentRuntime;
1316
1314
  await this.activeSessionStore.applySettings(sessionKey, {
1317
1315
  runtime,
1318
1316
  model,
@@ -1715,7 +1713,7 @@ export class LarkMessageIngestor {
1715
1713
  // A user-triggered cancel needs no redundant chat reply (the card carries it).
1716
1714
  text: cancelled ? "" : `处理失败:${errorMessage}`,
1717
1715
  provider: started.provider,
1718
- model: started.model,
1716
+ ...(started.model ? { model: started.model } : {}),
1719
1717
  };
1720
1718
  }
1721
1719
  // The card carries the answer; only emit a plain-text reply when no card
@@ -1723,7 +1721,7 @@ export class LarkMessageIngestor {
1723
1721
  return {
1724
1722
  text: orchestrator.cardStarted ? "" : orchestrator.fallbackText.trim() || DEFAULT_EMPTY_RESPONSE,
1725
1723
  provider: started.provider,
1726
- model: started.model,
1724
+ ...(started.model ? { model: started.model } : {}),
1727
1725
  };
1728
1726
  }
1729
1727
  /**
@@ -1765,7 +1763,7 @@ export class LarkMessageIngestor {
1765
1763
  return {
1766
1764
  text: answer.trim() || DEFAULT_EMPTY_RESPONSE,
1767
1765
  provider: started.provider,
1768
- model: started.model,
1766
+ ...(started.model ? { model: started.model } : {}),
1769
1767
  };
1770
1768
  }
1771
1769
  catch (error) {
package/dist/runtime.js CHANGED
@@ -126117,14 +126117,14 @@ var envSchema = external_exports.object({
126117
126117
  /** Default model for the traex runtime; empty lets traex use its config. */
126118
126118
  TRAEX_MODEL: external_exports.string().optional().transform((value) => value?.trim() || void 0),
126119
126119
  /**
126120
- * Default model for the claude runtime (native `claude` CLI). Empty falls back
126121
- * to the latest balanced Sonnet; per-conversation `/model` overrides still apply.
126120
+ * Optional model override for the claude runtime (native `claude` CLI).
126121
+ * Empty leaves model selection to Claude Code itself.
126122
126122
  */
126123
- CLAUDE_MODEL: external_exports.string().optional().transform((value) => value?.trim() || "claude-sonnet-4-6"),
126123
+ CLAUDE_MODEL: external_exports.string().optional().transform((value) => value?.trim() || void 0),
126124
126124
  /** Codex-lineage approval default (legacy `CODEX_APPROVAL_POLICY` is honoured);
126125
126125
  * also helps derive Claude's unset permission posture. */
126126
126126
  AGENT_APPROVAL_POLICY: external_exports.enum(["never", "on-failure", "on-request", "untrusted"]).default("never"),
126127
- CODEX_MODEL: external_exports.string().optional().transform((value) => value?.trim() || "gpt-5.5"),
126127
+ CODEX_MODEL: external_exports.string().optional().transform((value) => value?.trim() || void 0),
126128
126128
  /** Codex-lineage sandbox default (legacy `CODEX_SANDBOX` is honoured); paired
126129
126129
  * with approval to derive Claude's unset permission posture. */
126130
126130
  AGENT_SANDBOX: external_exports.enum(["read-only", "workspace-write", "danger-full-access"]).default("danger-full-access"),
@@ -126238,7 +126238,8 @@ var agentSpecSchema = external_exports.object({
126238
126238
  instructions: trimmed.optional(),
126239
126239
  executor: external_exports.object({
126240
126240
  runtime: runtimeEnum.optional(),
126241
- model: trimmed.optional(),
126241
+ /** `null` explicitly delegates model selection to the Provider CLI. */
126242
+ model: trimmed.nullable().optional(),
126242
126243
  reasoningEffort: reasoningEffortSchema.optional(),
126243
126244
  // Runtime budget (borrowed from reference implementation's `ExecutorSpec`). All optional;
126244
126245
  // enforced per-runtime where supported (timeout everywhere; maxIterations
@@ -126415,7 +126416,7 @@ var executionBudgetSnapshotSchema = external_exports.object({
126415
126416
  var resolvedExecutionSnapshotSchema = external_exports.object({
126416
126417
  snapshotVersion: external_exports.literal(SESSION_EXECUTION_SNAPSHOT_VERSION),
126417
126418
  provider: external_exports.enum(["codex", "traex", "claude"]),
126418
- model: nonEmptyString,
126419
+ model: nonEmptyString.nullable(),
126419
126420
  reasoningEffort: nonEmptyString.nullable(),
126420
126421
  instructions: external_exports.string().nullable(),
126421
126422
  skills: external_exports.array(skillRefSchema2),
@@ -126933,6 +126934,8 @@ var HostConversationRuntime = class {
126933
126934
  try {
126934
126935
  started = await this.host.sessions.run({
126935
126936
  sessionId: input.threadId,
126937
+ model: input.model?.trim() || null,
126938
+ reasoningEffort: input.reasoningEffort?.trim() || null,
126936
126939
  message: input.message
126937
126940
  });
126938
126941
  runId = started.runId;
@@ -127022,7 +127025,7 @@ var HostSessionProvisioner = class {
127022
127025
  if (!result?.sessionId) throw new Error("host did not return a provisioned session id");
127023
127026
  this.resolvedExecutions.set(result.sessionId, {
127024
127027
  runtime: result.execution.provider,
127025
- model: result.execution.model,
127028
+ ...result.execution.model ? { model: result.execution.model } : {},
127026
127029
  ...result.execution.reasoningEffort ? { reasoningEffort: result.execution.reasoningEffort } : {},
127027
127030
  ...session.agent ? { agent: session.agent } : {}
127028
127031
  });
@@ -127038,7 +127041,7 @@ var HostSessionProvisioner = class {
127038
127041
  const session = await this.host.sessions.get({ sessionId });
127039
127042
  return {
127040
127043
  runtime: session.execution.provider,
127041
- model: session.execution.model,
127044
+ ...session.execution.model ? { model: session.execution.model } : {},
127042
127045
  ...session.execution.reasoningEffort ? { reasoningEffort: session.execution.reasoningEffort } : {}
127043
127046
  };
127044
127047
  } catch (error51) {
@@ -130412,7 +130415,7 @@ ${transcript}` : header;
130412
130415
  const selectedModel = pending.models.find((candidate) => candidate.value === pending.model);
130413
130416
  const allowedEfforts = selectedModel?.supportedEfforts?.length ? selectedModel.supportedEfforts : SETTINGS_EFFORT_VALUES;
130414
130417
  const effort = pending.effort !== SETTINGS_DEFAULT_VALUE && allowedEfforts.includes(pending.effort) ? pending.effort : void 0;
130415
- const rotate = runtime !== pending.currentRuntime || model !== pending.currentModel || effort !== pending.currentEffort;
130418
+ const rotate = runtime !== pending.currentRuntime;
130416
130419
  await this.activeSessionStore.applySettings(sessionKey, {
130417
130420
  runtime,
130418
130421
  model,
@@ -130810,13 +130813,13 @@ ${transcript}` : header;
130810
130813
  // A user-triggered cancel needs no redundant chat reply (the card carries it).
130811
130814
  text: cancelled ? "" : `\u5904\u7406\u5931\u8D25\uFF1A${errorMessage}`,
130812
130815
  provider: started.provider,
130813
- model: started.model
130816
+ ...started.model ? { model: started.model } : {}
130814
130817
  };
130815
130818
  }
130816
130819
  return {
130817
130820
  text: orchestrator.cardStarted ? "" : orchestrator.fallbackText.trim() || DEFAULT_EMPTY_RESPONSE,
130818
130821
  provider: started.provider,
130819
- model: started.model
130822
+ ...started.model ? { model: started.model } : {}
130820
130823
  };
130821
130824
  }
130822
130825
  /**
@@ -130856,7 +130859,7 @@ ${transcript}` : header;
130856
130859
  return {
130857
130860
  text: answer.trim() || DEFAULT_EMPTY_RESPONSE,
130858
130861
  provider: started.provider,
130859
- model: started.model
130862
+ ...started.model ? { model: started.model } : {}
130860
130863
  };
130861
130864
  } catch (error51) {
130862
130865
  const errorMessage = toErrorMessage(error51);
package/dist/settings.js CHANGED
@@ -126053,14 +126053,14 @@ var envSchema = external_exports.object({
126053
126053
  /** Default model for the traex runtime; empty lets traex use its config. */
126054
126054
  TRAEX_MODEL: external_exports.string().optional().transform((value) => value?.trim() || void 0),
126055
126055
  /**
126056
- * Default model for the claude runtime (native `claude` CLI). Empty falls back
126057
- * to the latest balanced Sonnet; per-conversation `/model` overrides still apply.
126056
+ * Optional model override for the claude runtime (native `claude` CLI).
126057
+ * Empty leaves model selection to Claude Code itself.
126058
126058
  */
126059
- CLAUDE_MODEL: external_exports.string().optional().transform((value) => value?.trim() || "claude-sonnet-4-6"),
126059
+ CLAUDE_MODEL: external_exports.string().optional().transform((value) => value?.trim() || void 0),
126060
126060
  /** Codex-lineage approval default (legacy `CODEX_APPROVAL_POLICY` is honoured);
126061
126061
  * also helps derive Claude's unset permission posture. */
126062
126062
  AGENT_APPROVAL_POLICY: external_exports.enum(["never", "on-failure", "on-request", "untrusted"]).default("never"),
126063
- CODEX_MODEL: external_exports.string().optional().transform((value) => value?.trim() || "gpt-5.5"),
126063
+ CODEX_MODEL: external_exports.string().optional().transform((value) => value?.trim() || void 0),
126064
126064
  /** Codex-lineage sandbox default (legacy `CODEX_SANDBOX` is honoured); paired
126065
126065
  * with approval to derive Claude's unset permission posture. */
126066
126066
  AGENT_SANDBOX: external_exports.enum(["read-only", "workspace-write", "danger-full-access"]).default("danger-full-access"),
@@ -126174,7 +126174,8 @@ var agentSpecSchema = external_exports.object({
126174
126174
  instructions: trimmed.optional(),
126175
126175
  executor: external_exports.object({
126176
126176
  runtime: runtimeEnum.optional(),
126177
- model: trimmed.optional(),
126177
+ /** `null` explicitly delegates model selection to the Provider CLI. */
126178
+ model: trimmed.nullable().optional(),
126178
126179
  reasoningEffort: reasoningEffortSchema.optional(),
126179
126180
  // Runtime budget (borrowed from reference implementation's `ExecutorSpec`). All optional;
126180
126181
  // enforced per-runtime where supported (timeout everywhere; maxIterations
@@ -126283,7 +126284,7 @@ var executionBudgetSnapshotSchema = external_exports.object({
126283
126284
  var resolvedExecutionSnapshotSchema = external_exports.object({
126284
126285
  snapshotVersion: external_exports.literal(SESSION_EXECUTION_SNAPSHOT_VERSION),
126285
126286
  provider: external_exports.enum(["codex", "traex", "claude"]),
126286
- model: nonEmptyString,
126287
+ model: nonEmptyString.nullable(),
126287
126288
  reasoningEffort: nonEmptyString.nullable(),
126288
126289
  instructions: external_exports.string().nullable(),
126289
126290
  skills: external_exports.array(skillRefSchema2),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rynx-ai/plugin-channel-lark",
3
- "version": "0.1.11-beta.8",
3
+ "version": "0.1.11-beta.9",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/rynx-ai/rynx.git",
@@ -28,8 +28,8 @@
28
28
  },
29
29
  "dependencies": {
30
30
  "@larksuiteoapi/node-sdk": "^1.60.0",
31
- "@rynx-ai/core": "0.1.11-beta.8",
32
- "@rynx-ai/plugin-sdk": "0.1.11-beta.8"
31
+ "@rynx-ai/core": "0.1.11-beta.9",
32
+ "@rynx-ai/plugin-sdk": "0.1.11-beta.9"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@fontsource-variable/inter": "^5.0.0",
@@ -46,7 +46,7 @@
46
46
  "tailwindcss": "^4.0.0",
47
47
  "typescript": "^6.0.2",
48
48
  "vite": "^6.1.0",
49
- "@rynx-ai/ui": "0.1.11-beta.8"
49
+ "@rynx-ai/ui": "0.1.11-beta.9"
50
50
  },
51
51
  "scripts": {
52
52
  "build": "pnpm run build:runtime && pnpm run build:ui",