@lumerahq/cli 0.32.9 → 0.33.1
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/{chunk-E4D7E7QO.js → chunk-BCSUKRDA.js} +2 -2
- package/dist/{functions-PH4ZJA7U.js → functions-BAJ3PCNO.js} +1 -1
- package/dist/index.js +9 -9
- package/dist/{project-6ILDGQUF.js → project-O7ZZQXFN.js} +1 -1
- package/dist/{resources-IIOCZU23.js → resources-IY3XSYJH.js} +10 -1
- package/package.json +1 -1
- package/templates/default/pyproject.toml +1 -1
|
@@ -5,8 +5,8 @@ import { join, resolve } from "path";
|
|
|
5
5
|
import pc from "picocolors";
|
|
6
6
|
|
|
7
7
|
// src/lib/functions-sdk.ts
|
|
8
|
-
var FUNCTIONS_SDK_VERSION_RANGE = ">=0.
|
|
9
|
-
var FUNCTIONS_SDK_COMPATIBILITY_RANGE = ">=0.34.0,<0.
|
|
8
|
+
var FUNCTIONS_SDK_VERSION_RANGE = ">=0.43.0,<0.44.0";
|
|
9
|
+
var FUNCTIONS_SDK_COMPATIBILITY_RANGE = ">=0.34.0,<0.44.0";
|
|
10
10
|
var FUNCTIONS_SDK_REQUIREMENT = `lumera[functions]${FUNCTIONS_SDK_COMPATIBILITY_RANGE}`;
|
|
11
11
|
var DEFAULT_FUNCTIONS_SDK_REQUIREMENT = `lumera[functions]${FUNCTIONS_SDK_VERSION_RANGE}`;
|
|
12
12
|
var RELEASE_SDK_REQUIREMENT = `lumera[release]${FUNCTIONS_SDK_VERSION_RANGE}`;
|
package/dist/index.js
CHANGED
|
@@ -242,25 +242,25 @@ async function main() {
|
|
|
242
242
|
switch (command) {
|
|
243
243
|
// Resource commands
|
|
244
244
|
case "plan":
|
|
245
|
-
await import("./resources-
|
|
245
|
+
await import("./resources-IY3XSYJH.js").then((m) => m.plan(args.slice(1)));
|
|
246
246
|
break;
|
|
247
247
|
case "apply":
|
|
248
|
-
await import("./resources-
|
|
248
|
+
await import("./resources-IY3XSYJH.js").then((m) => m.apply(args.slice(1)));
|
|
249
249
|
break;
|
|
250
250
|
case "pull":
|
|
251
|
-
await import("./resources-
|
|
251
|
+
await import("./resources-IY3XSYJH.js").then((m) => m.pull(args.slice(1)));
|
|
252
252
|
break;
|
|
253
253
|
case "destroy":
|
|
254
|
-
await import("./resources-
|
|
254
|
+
await import("./resources-IY3XSYJH.js").then((m) => m.destroy(args.slice(1)));
|
|
255
255
|
break;
|
|
256
256
|
case "list":
|
|
257
|
-
await import("./resources-
|
|
257
|
+
await import("./resources-IY3XSYJH.js").then((m) => m.list(args.slice(1)));
|
|
258
258
|
break;
|
|
259
259
|
case "show":
|
|
260
|
-
await import("./resources-
|
|
260
|
+
await import("./resources-IY3XSYJH.js").then((m) => m.show(args.slice(1)));
|
|
261
261
|
break;
|
|
262
262
|
case "diff":
|
|
263
|
-
await import("./resources-
|
|
263
|
+
await import("./resources-IY3XSYJH.js").then((m) => m.diff(args.slice(1)));
|
|
264
264
|
break;
|
|
265
265
|
// Development
|
|
266
266
|
case "dev":
|
|
@@ -270,12 +270,12 @@ async function main() {
|
|
|
270
270
|
await import("./run-4XFA5ZDJ.js").then((m) => m.run(args.slice(1)));
|
|
271
271
|
break;
|
|
272
272
|
case "functions":
|
|
273
|
-
await import("./functions-
|
|
273
|
+
await import("./functions-BAJ3PCNO.js").then(
|
|
274
274
|
(m) => m.functions(subcommand, args.slice(2))
|
|
275
275
|
);
|
|
276
276
|
break;
|
|
277
277
|
case "project":
|
|
278
|
-
await import("./project-
|
|
278
|
+
await import("./project-O7ZZQXFN.js").then(
|
|
279
279
|
(m) => m.project(subcommand, args.slice(2))
|
|
280
280
|
);
|
|
281
281
|
break;
|
|
@@ -3387,6 +3387,7 @@ async function planAgents(api, localAgents, projectId, localSourceSkillSlugs = /
|
|
|
3387
3387
|
changes.push({ type: "create", resource: "agent", id: agent.external_id, name: agent.name });
|
|
3388
3388
|
} else {
|
|
3389
3389
|
const diffs = [];
|
|
3390
|
+
if (allowedFunctionsChanged(remote.allowed_functions, agent.allowed_functions)) diffs.push("allowed_functions");
|
|
3390
3391
|
if (remote.name !== agent.name) diffs.push("name");
|
|
3391
3392
|
if ((remote.description || "") !== (agent.description || "")) diffs.push("description");
|
|
3392
3393
|
if ((remote.system_prompt || "").trim() !== systemPrompt.trim()) diffs.push("system_prompt");
|
|
@@ -3497,6 +3498,7 @@ async function applyAgents(api, localAgents, projectId, localSourceSkillSlugs =
|
|
|
3497
3498
|
...agent.thinking_level !== void 0 ? { thinking_level: agent.thinking_level } : {},
|
|
3498
3499
|
idle_reap_timeout_seconds: agent.idle_reap_timeout_seconds ?? 0,
|
|
3499
3500
|
skill_ids: skillIds,
|
|
3501
|
+
...agent.allowed_functions !== void 0 ? { allowed_functions: agent.allowed_functions } : {},
|
|
3500
3502
|
policy_script: policyScript || "",
|
|
3501
3503
|
policy_enabled: agent.policy_enabled || false,
|
|
3502
3504
|
policy_description: agent.policy_description || ""
|
|
@@ -3517,6 +3519,10 @@ async function applyAgents(api, localAgents, projectId, localSourceSkillSlugs =
|
|
|
3517
3519
|
}
|
|
3518
3520
|
return errors;
|
|
3519
3521
|
}
|
|
3522
|
+
function allowedFunctionsChanged(remote, local) {
|
|
3523
|
+
if (local === void 0) return false;
|
|
3524
|
+
return JSON.stringify([...remote ?? []].sort()) !== JSON.stringify([...local].sort());
|
|
3525
|
+
}
|
|
3520
3526
|
async function pullAgents(api, platformDir, filterName, projectId, appName) {
|
|
3521
3527
|
const agentsDir = join2(platformDir, "agents");
|
|
3522
3528
|
mkdirSync(agentsDir, { recursive: true });
|
|
@@ -3554,6 +3560,7 @@ async function pullAgents(api, platformDir, filterName, projectId, appName) {
|
|
|
3554
3560
|
name: agent.name
|
|
3555
3561
|
};
|
|
3556
3562
|
if (agent.description) config.description = agent.description;
|
|
3563
|
+
config.allowed_functions = agent.allowed_functions ?? [];
|
|
3557
3564
|
if (agent.model) config.model = agent.model;
|
|
3558
3565
|
if (agent.thinking_level) config.thinking_level = agent.thinking_level;
|
|
3559
3566
|
if (agent.idle_reap_timeout_seconds) config.idle_reap_timeout_seconds = agent.idle_reap_timeout_seconds;
|
|
@@ -5022,8 +5029,10 @@ async function diff(args) {
|
|
|
5022
5029
|
console.log(` policy_enabled: ${pc2.red(String(remote.policy_enabled || false))} \u2192 ${pc2.green(String(local.agent.policy_enabled || false))}`);
|
|
5023
5030
|
const promptChanged = (remote.system_prompt || "").trim() !== local.systemPrompt.trim();
|
|
5024
5031
|
const policyChanged = (remote.policy_script || "").trim() !== (local.policyScript || "").trim();
|
|
5032
|
+
const functionsChanged = allowedFunctionsChanged(remote.allowed_functions, local.agent.allowed_functions);
|
|
5033
|
+
if (functionsChanged) console.log(` allowed_functions: ${JSON.stringify(remote.allowed_functions ?? [])} \u2192 ${JSON.stringify(local.agent.allowed_functions ?? [])}`);
|
|
5025
5034
|
const thinkingLevelChanged = local.agent.thinking_level !== void 0 && (remote.thinking_level || "") !== local.agent.thinking_level;
|
|
5026
|
-
if (!promptChanged && !policyChanged && !thinkingLevelChanged && remote.name === local.agent.name && (remote.description || "") === (local.agent.description || "") && (remote.model || "") === (local.agent.model || "") && (remote.idle_reap_timeout_seconds ?? 0) === (local.agent.idle_reap_timeout_seconds ?? 0) && (remote.policy_enabled || false) === (local.agent.policy_enabled || false)) {
|
|
5035
|
+
if (!functionsChanged && !promptChanged && !policyChanged && !thinkingLevelChanged && remote.name === local.agent.name && (remote.description || "") === (local.agent.description || "") && (remote.model || "") === (local.agent.model || "") && (remote.idle_reap_timeout_seconds ?? 0) === (local.agent.idle_reap_timeout_seconds ?? 0) && (remote.policy_enabled || false) === (local.agent.policy_enabled || false)) {
|
|
5027
5036
|
console.log(pc2.green(` \u2713 No changes`));
|
|
5028
5037
|
} else {
|
|
5029
5038
|
if (promptChanged) renderFullDiff("system_prompt.md", remote.system_prompt || "", local.systemPrompt);
|
package/package.json
CHANGED