@sema-agent/cli 1.0.15 → 1.0.17
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/npm-shrinkwrap.json +14 -14
- package/package.json +5 -5
- package/sema.js +132 -23
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sema-agent/cli",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.17",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@sema-agent/cli",
|
|
9
|
-
"version": "1.0.
|
|
9
|
+
"version": "1.0.17",
|
|
10
10
|
"license": "BUSL-1.1",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@sema-agent/sdk": "0.0.53",
|
|
13
|
-
"@sema-agent/server": "1.
|
|
13
|
+
"@sema-agent/server": "1.225.0"
|
|
14
14
|
},
|
|
15
15
|
"bin": {
|
|
16
16
|
"sema": "sema.js"
|
|
@@ -629,9 +629,9 @@
|
|
|
629
629
|
}
|
|
630
630
|
},
|
|
631
631
|
"node_modules/@sema-agent/core": {
|
|
632
|
-
"version": "1.
|
|
633
|
-
"resolved": "https://registry.npmjs.org/@sema-agent/core/-/core-1.
|
|
634
|
-
"integrity": "sha512-
|
|
632
|
+
"version": "1.318.0",
|
|
633
|
+
"resolved": "https://registry.npmjs.org/@sema-agent/core/-/core-1.318.0.tgz",
|
|
634
|
+
"integrity": "sha512-Ans8S1njiD+9UjYiKI7pApVt4RCZAyO2IZuMrZNp8GIO3/qIPCPLFwed9hygok21KFmMVIwbXgPNYVZ01maTtw==",
|
|
635
635
|
"license": "BUSL-1.1",
|
|
636
636
|
"dependencies": {
|
|
637
637
|
"@modelcontextprotocol/sdk": "1.29.0",
|
|
@@ -645,9 +645,9 @@
|
|
|
645
645
|
}
|
|
646
646
|
},
|
|
647
647
|
"node_modules/@sema-agent/registry-core": {
|
|
648
|
-
"version": "0.10.
|
|
649
|
-
"resolved": "https://registry.npmjs.org/@sema-agent/registry-core/-/registry-core-0.10.
|
|
650
|
-
"integrity": "sha512-
|
|
648
|
+
"version": "0.10.19",
|
|
649
|
+
"resolved": "https://registry.npmjs.org/@sema-agent/registry-core/-/registry-core-0.10.19.tgz",
|
|
650
|
+
"integrity": "sha512-cRqXxGfcnRGY7UM6/ljYZucTt1NcCC0nXt0g1ChDzy+KiiHKuYwgN0jf7iTaT1yyHl+15bYlbA6TMJ2/dEoOQA==",
|
|
651
651
|
"license": "BUSL-1.1",
|
|
652
652
|
"dependencies": {
|
|
653
653
|
"zod": "^3.24.0"
|
|
@@ -678,13 +678,13 @@
|
|
|
678
678
|
}
|
|
679
679
|
},
|
|
680
680
|
"node_modules/@sema-agent/server": {
|
|
681
|
-
"version": "1.
|
|
682
|
-
"resolved": "https://registry.npmjs.org/@sema-agent/server/-/server-1.
|
|
683
|
-
"integrity": "sha512-
|
|
681
|
+
"version": "1.225.0",
|
|
682
|
+
"resolved": "https://registry.npmjs.org/@sema-agent/server/-/server-1.225.0.tgz",
|
|
683
|
+
"integrity": "sha512-mdHSZ9xL46PjQEa5ZnzPeGXvfWmNWIgXFxtX6uJLRpRMdhL8bRnV0ZHIMNPdrVJ02Gyp/jgQsw9tdOaDGiAimw==",
|
|
684
684
|
"license": "BUSL-1.1",
|
|
685
685
|
"dependencies": {
|
|
686
|
-
"@sema-agent/core": "^1.
|
|
687
|
-
"@sema-agent/registry-core": "^0.10.
|
|
686
|
+
"@sema-agent/core": "^1.316.0",
|
|
687
|
+
"@sema-agent/registry-core": "^0.10.16",
|
|
688
688
|
"e2b": "^2.28.0",
|
|
689
689
|
"libsodium-wrappers": "^0.8.4",
|
|
690
690
|
"mysql2": "^3.22.4",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sema-agent/cli",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.17",
|
|
4
4
|
"description": "Sema — your own Claude Code-grade coding agent, in the terminal.",
|
|
5
5
|
"license": "BUSL-1.1",
|
|
6
6
|
"bin": {
|
|
@@ -22,13 +22,13 @@
|
|
|
22
22
|
],
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"@sema-agent/sdk": "0.0.53",
|
|
25
|
-
"@sema-agent/server": "1.
|
|
25
|
+
"@sema-agent/server": "1.225.0"
|
|
26
26
|
},
|
|
27
27
|
"overrides": {
|
|
28
|
-
"@sema-agent/core": "1.
|
|
29
|
-
"@sema-agent/registry-core": "0.10.
|
|
28
|
+
"@sema-agent/core": "1.318.0",
|
|
29
|
+
"@sema-agent/registry-core": "0.10.19"
|
|
30
30
|
},
|
|
31
|
-
"semaEngineVersion": "server 1.
|
|
31
|
+
"semaEngineVersion": "server 1.225.0 / core 1.318.0 / registry-core 0.10.19",
|
|
32
32
|
"engines": {
|
|
33
33
|
"node": ">=18"
|
|
34
34
|
}
|
package/sema.js
CHANGED
|
@@ -157572,11 +157572,41 @@ function ultracodeFromInput(humanInput) {
|
|
|
157572
157572
|
function ultracodeForRequest(humanInput) {
|
|
157573
157573
|
return getUltracodePreset() || ultracodeFromInput(humanInput) ? true : void 0;
|
|
157574
157574
|
}
|
|
157575
|
-
|
|
157575
|
+
function workflowFromInput(humanInput) {
|
|
157576
|
+
return typeof humanInput === "string" && WORKFLOW_KEYWORD.test(humanInput) ? true : void 0;
|
|
157577
|
+
}
|
|
157578
|
+
function deferOptedOut(env5) {
|
|
157579
|
+
const raw2 = env5[WORKFLOW_DEFER_ENV];
|
|
157580
|
+
const s = typeof raw2 === "string" ? raw2.trim().toLowerCase() : "";
|
|
157581
|
+
return s === "0" || s === "false" || s === "no" || s === "off";
|
|
157582
|
+
}
|
|
157583
|
+
function workflowDeferForRequest(humanInput, env5 = process.env) {
|
|
157584
|
+
if (deferOptedOut(env5)) return void 0;
|
|
157585
|
+
if (getUltracodePreset() || ultracodeFromInput(humanInput) || workflowFromInput(humanInput)) return void 0;
|
|
157586
|
+
return ["Workflow"];
|
|
157587
|
+
}
|
|
157588
|
+
function extraDeferFromEnv(env5) {
|
|
157589
|
+
const raw2 = env5[DEFER_TOOLS_ENV];
|
|
157590
|
+
if (typeof raw2 !== "string" || raw2.trim().length === 0) return [];
|
|
157591
|
+
return raw2.split(",").map((s) => s.trim()).filter((s) => s.length > 0);
|
|
157592
|
+
}
|
|
157593
|
+
function deferToolsForRequest(humanInput, env5 = process.env) {
|
|
157594
|
+
const workflowLane = workflowDeferForRequest(humanInput, env5) ?? [];
|
|
157595
|
+
const extra = extraDeferFromEnv(env5).filter(
|
|
157596
|
+
(name) => name !== "Workflow" || workflowLane.length > 0
|
|
157597
|
+
// activation wins over the env list for Workflow
|
|
157598
|
+
);
|
|
157599
|
+
const merged = [.../* @__PURE__ */ new Set([...workflowLane, ...extra])];
|
|
157600
|
+
return merged.length > 0 ? merged : void 0;
|
|
157601
|
+
}
|
|
157602
|
+
var ultracodePreset, ULTRACODE_KEYWORD, WORKFLOW_KEYWORD, WORKFLOW_DEFER_ENV, DEFER_TOOLS_ENV;
|
|
157576
157603
|
var init_ultracodeWireCaps = __esm({
|
|
157577
157604
|
"build-src/src/sema/ultracodeWireCaps.ts"() {
|
|
157578
157605
|
ultracodePreset = false;
|
|
157579
157606
|
ULTRACODE_KEYWORD = /\bultracode\b/i;
|
|
157607
|
+
WORKFLOW_KEYWORD = /\bworkflows?\b/i;
|
|
157608
|
+
WORKFLOW_DEFER_ENV = "SEMA_WORKFLOW_DEFER";
|
|
157609
|
+
DEFER_TOOLS_ENV = "SEMA_DEFER_TOOLS";
|
|
157580
157610
|
}
|
|
157581
157611
|
});
|
|
157582
157612
|
|
|
@@ -268590,7 +268620,7 @@ var require_websocket2 = __commonJS({
|
|
|
268590
268620
|
var http3 = __require("http");
|
|
268591
268621
|
var net = __require("net");
|
|
268592
268622
|
var tls = __require("tls");
|
|
268593
|
-
var { randomBytes: randomBytes26, createHash:
|
|
268623
|
+
var { randomBytes: randomBytes26, createHash: createHash28 } = __require("crypto");
|
|
268594
268624
|
var { Duplex, Readable: Readable5 } = __require("stream");
|
|
268595
268625
|
var { URL: URL6 } = __require("url");
|
|
268596
268626
|
var PerMessageDeflate2 = require_permessage_deflate2();
|
|
@@ -269258,7 +269288,7 @@ var require_websocket2 = __commonJS({
|
|
|
269258
269288
|
abortHandshake(websocket, socket, "Invalid Upgrade header");
|
|
269259
269289
|
return;
|
|
269260
269290
|
}
|
|
269261
|
-
const digest =
|
|
269291
|
+
const digest = createHash28("sha1").update(key + GUID).digest("base64");
|
|
269262
269292
|
if (res.headers["sec-websocket-accept"] !== digest) {
|
|
269263
269293
|
abortHandshake(websocket, socket, "Invalid Sec-WebSocket-Accept header");
|
|
269264
269294
|
return;
|
|
@@ -269627,7 +269657,7 @@ var require_websocket_server = __commonJS({
|
|
|
269627
269657
|
var EventEmitter5 = __require("events");
|
|
269628
269658
|
var http3 = __require("http");
|
|
269629
269659
|
var { Duplex } = __require("stream");
|
|
269630
|
-
var { createHash:
|
|
269660
|
+
var { createHash: createHash28 } = __require("crypto");
|
|
269631
269661
|
var extension2 = require_extension();
|
|
269632
269662
|
var PerMessageDeflate2 = require_permessage_deflate2();
|
|
269633
269663
|
var subprotocol2 = require_subprotocol();
|
|
@@ -269934,7 +269964,7 @@ var require_websocket_server = __commonJS({
|
|
|
269934
269964
|
);
|
|
269935
269965
|
}
|
|
269936
269966
|
if (this._state > RUNNING) return abortHandshake(socket, 503);
|
|
269937
|
-
const digest =
|
|
269967
|
+
const digest = createHash28("sha1").update(key + GUID).digest("base64");
|
|
269938
269968
|
const headers = [
|
|
269939
269969
|
"HTTP/1.1 101 Switching Protocols",
|
|
269940
269970
|
"Upgrade: websocket",
|
|
@@ -331873,9 +331903,9 @@ function streamingTailWrap(unstableSuffix) {
|
|
|
331873
331903
|
var import_compiler_runtime43, import_react43, import_jsx_runtime53, TOKEN_CACHE_MAX, tokenCache, MD_SYNTAX_RE;
|
|
331874
331904
|
var init_Markdown = __esm({
|
|
331875
331905
|
"build-src/src/components/Markdown.tsx"() {
|
|
331876
|
-
import_compiler_runtime43 = __toESM(require_compiler_runtime()
|
|
331906
|
+
import_compiler_runtime43 = __toESM(require_compiler_runtime());
|
|
331877
331907
|
init_marked_esm();
|
|
331878
|
-
import_react43 = __toESM(require_react()
|
|
331908
|
+
import_react43 = __toESM(require_react());
|
|
331879
331909
|
init_useSettings();
|
|
331880
331910
|
init_ink2();
|
|
331881
331911
|
init_cliHighlight();
|
|
@@ -331883,7 +331913,7 @@ var init_Markdown = __esm({
|
|
|
331883
331913
|
init_markdown();
|
|
331884
331914
|
init_messages4();
|
|
331885
331915
|
init_MarkdownTable();
|
|
331886
|
-
import_jsx_runtime53 = __toESM(require_jsx_runtime()
|
|
331916
|
+
import_jsx_runtime53 = __toESM(require_jsx_runtime());
|
|
331887
331917
|
TOKEN_CACHE_MAX = 500;
|
|
331888
331918
|
tokenCache = /* @__PURE__ */ new Map();
|
|
331889
331919
|
MD_SYNTAX_RE = /[#*`|[>\-_~]|\n\n|^\d+\. |\n\d+\. /;
|
|
@@ -356412,7 +356442,7 @@ var import_react71, import_jsx_runtime101, MD_SYNTAX_RE2;
|
|
|
356412
356442
|
var init_exitplanmode = __esm({
|
|
356413
356443
|
"build-src/src/sema/overrides/exitplanmode.tsx"() {
|
|
356414
356444
|
init_marked_esm();
|
|
356415
|
-
import_react71 = __toESM(require_react());
|
|
356445
|
+
import_react71 = __toESM(require_react(), 1);
|
|
356416
356446
|
init_ink2();
|
|
356417
356447
|
init_useSettings();
|
|
356418
356448
|
init_MarkdownTable();
|
|
@@ -356422,7 +356452,7 @@ var init_exitplanmode = __esm({
|
|
|
356422
356452
|
init_teammateMailbox();
|
|
356423
356453
|
init_ShutdownMessage();
|
|
356424
356454
|
init_TaskAssignmentMessage();
|
|
356425
|
-
import_jsx_runtime101 = __toESM(require_jsx_runtime());
|
|
356455
|
+
import_jsx_runtime101 = __toESM(require_jsx_runtime(), 1);
|
|
356426
356456
|
MD_SYNTAX_RE2 = /[#*`|[>\-_~]|\n\n|^\d+\. |\n\d+\. /;
|
|
356427
356457
|
}
|
|
356428
356458
|
});
|
|
@@ -433337,6 +433367,10 @@ function toTaskRequest(params) {
|
|
|
433337
433367
|
if (selfOrchestration && process.env.SEMA_DEBUG) {
|
|
433338
433368
|
console.error("[sema][seamQuery] selfOrchestration wire: SEMA_SELF_ORCHESTRATION \u2192 TaskRequest.selfOrchestration=true (run_workflow)");
|
|
433339
433369
|
}
|
|
433370
|
+
const deferTools = selfOrchestration ? deferToolsForRequest(objective) : void 0;
|
|
433371
|
+
if (deferTools && process.env.SEMA_DEBUG) {
|
|
433372
|
+
console.error("[sema][seamQuery] deferTools wire: Workflow deferred (no activation source this turn)");
|
|
433373
|
+
}
|
|
433340
433374
|
const retainBackground = process.env.SEMA_LIVE_BASEURL ? retainBackgroundFromEnv() : void 0;
|
|
433341
433375
|
if (retainBackground && process.env.SEMA_DEBUG) {
|
|
433342
433376
|
console.error("[sema][seamQuery] retainBackground wire: SEMA_RETAIN_BACKGROUND \u2192 TaskRequest.retainBackgroundProcesses=true");
|
|
@@ -433420,6 +433454,9 @@ ${objective}`;
|
|
|
433420
433454
|
// Workflow super-set: the top-level selfOrchestration flag (SEMA_SELF_ORCHESTRATION env opt-in, live-gated).
|
|
433421
433455
|
// Present ⇒ the SERVICE mounts core run_workflow (gated on its deployment/tenant policy); absent ⇒ no stamp.
|
|
433422
433456
|
...selfOrchestration ? { selfOrchestration } : {},
|
|
433457
|
+
// Workflow deferred-disclosure ([1052]①): absent = fully exposed (activation turn / opt-out); present =
|
|
433458
|
+
// core 1.314 placeholder-on-wire, schema bytes out of the cache prefix, ToolSearch-activatable.
|
|
433459
|
+
...deferTools ? { deferTools } : {},
|
|
433423
433460
|
...retainBackground ? { retainBackgroundProcesses: retainBackground } : {},
|
|
433424
433461
|
// Fork super-set: the top-level enableFork flag — EXPLICIT boolean on live (core ≥1.257 treats absent
|
|
433425
433462
|
// as granted; the shell's default-OFF product decision must be spelled out). Mock path stays unstamped.
|
|
@@ -450671,7 +450708,7 @@ function Settings({
|
|
|
450671
450708
|
var import_react113, import_jsx_runtime192;
|
|
450672
450709
|
var init_cmd_config = __esm({
|
|
450673
450710
|
"build-src/src/sema/overrides/cmd-config.tsx"() {
|
|
450674
|
-
import_react113 = __toESM(require_react()
|
|
450711
|
+
import_react113 = __toESM(require_react());
|
|
450675
450712
|
init_useKeybinding();
|
|
450676
450713
|
init_useExitOnCtrlCDWithKeybindings();
|
|
450677
450714
|
init_useTerminalSize();
|
|
@@ -450682,7 +450719,7 @@ var init_cmd_config = __esm({
|
|
|
450682
450719
|
init_Config();
|
|
450683
450720
|
init_settings_usage();
|
|
450684
450721
|
init_Stats();
|
|
450685
|
-
import_jsx_runtime192 = __toESM(require_jsx_runtime()
|
|
450722
|
+
import_jsx_runtime192 = __toESM(require_jsx_runtime());
|
|
450686
450723
|
}
|
|
450687
450724
|
});
|
|
450688
450725
|
|
|
@@ -479549,8 +479586,8 @@ var init_sema_brand = __esm({
|
|
|
479549
479586
|
"Slash-command gating wired to the fleet capability handshake"
|
|
479550
479587
|
]
|
|
479551
479588
|
},
|
|
479552
|
-
productVersion: "1.0.
|
|
479553
|
-
announcement: "sema 1.0.
|
|
479589
|
+
productVersion: "1.0.17",
|
|
479590
|
+
announcement: "sema 1.0.17 \u2014 background commands you start with & now survive turn teardown: the engine settles the parent shell immediately and no longer sweeps detached grandchildren into cleanup (spooled stdio, CC-parity). Servers you launch keep listening after the run ends."
|
|
479554
479591
|
};
|
|
479555
479592
|
}
|
|
479556
479593
|
});
|
|
@@ -482484,8 +482521,8 @@ var require_sema_brand = __commonJS({
|
|
|
482484
482521
|
"Slash-command gating wired to the fleet capability handshake"
|
|
482485
482522
|
]
|
|
482486
482523
|
},
|
|
482487
|
-
productVersion: "1.0.
|
|
482488
|
-
announcement: "sema 1.0.
|
|
482524
|
+
productVersion: "1.0.17",
|
|
482525
|
+
announcement: "sema 1.0.17 \u2014 background commands you start with & now survive turn teardown: the engine settles the parent shell immediately and no longer sweeps detached grandchildren into cleanup (spooled stdio, CC-parity). Servers you launch keep listening after the run ends."
|
|
482489
482526
|
};
|
|
482490
482527
|
}
|
|
482491
482528
|
});
|
|
@@ -496971,7 +497008,7 @@ function extraBodyUnsafe(v2) {
|
|
|
496971
497008
|
function workerRouteKey(w2) {
|
|
496972
497009
|
return w2.routePrefix ?? w2.name;
|
|
496973
497010
|
}
|
|
496974
|
-
var SECRET_LITERAL_RE, ENV_NAME, hasNul, NON_SECRET_URL, K8S_QUANTITY, TCP_PORT, ModelCost, SEALED_BOX_ALG, BASE64_SHAPE, SealedApiKey, ModelEntry2, ModelRole, RoleTarget, TierBindings, TierGroup, ModelsConfig, RosterEntry, RostersConfig, ScenarioEntry, ScenarioConfig, DELIVER_DENYLIST, SystemEntry, SystemsConfig, SystemStatusEntry, RuntimeConfig, GovernanceConfig, EntitlementBudget, TokenQuota, BudgetGroupMember, BudgetGroup, ScenarioAssignments, EntitlementRuntimeCaps, EntitlementTier, EntitlementOverride, EntitlementSubject, EntitlementGroupBinding, EntitlementConfig, SESSION_MIRROR_ENGINE_URL, SessionMirrorPolicy, ExecutionPublicKey, ExecutionPolicy, PROJECT_ID_REGEX, ProjectRegistration, ProjectsConfig, CollabTopology, CollabFinalizerType, CollabEarlyStop, CollabPersistence, CollabMember, CollabSlot, CollabTemplate, CollabConfig, DURATION, WorkerLifecycle, WorkerSecretRefs, RESERVED_WORKER_ENV, RESERVED_ENV_FIELD, WorkerSpec, WorkersConfig, WorkerCondition, WorkerStatus, HOST_NAME_MAX, HOSTS_ARRAY_MAX, HostEntry, HostsConfig, PROBE_CPU_CORES_MAX, PROBE_MEM_BYTES_MAX, HostProbes, HostStatus, SkillSpec, SkillsConfig, McpEnvRefs, HTTP_HEADER_NAME, McpHeaderRefs, McpTransport, McpServerSpec, McpConfig, PLUGIN_ORIGIN, GIT_COMMIT_SHA, PluginSource, PluginSpec, PluginsConfig, DOMAIN_SCHEMAS, SettingSource, EffectiveKey, DOMAINS;
|
|
497011
|
+
var SECRET_LITERAL_RE, ENV_NAME, hasNul, NON_SECRET_URL, K8S_QUANTITY, TCP_PORT, ModelCost, SEALED_BOX_ALG, BASE64_SHAPE, SealedApiKey, ModelEntry2, ModelRole, RoleTarget, TierBindings, TierGroup, ModelsConfig, RosterEntry, RostersConfig, ScenarioEntry, ScenarioConfig, DELIVER_DENYLIST, SystemEntry, SystemsConfig, SystemStatusEntry, RuntimeConfig, GovernanceConfig, EntitlementBudget, TokenQuota, BudgetGroupMember, BudgetGroup, ScenarioAssignments, EntitlementRuntimeCaps, EntitlementTier, EntitlementOverride, EntitlementSubject, EntitlementGroupBinding, EntitlementConfig, SESSION_MIRROR_ENGINE_URL, SessionMirrorPolicy, ExecutionPublicKey, ExecutionPolicy, PROJECT_ID_REGEX, ProjectRegistration, ProjectsConfig, CollabTopology, CollabFinalizerType, CollabEarlyStop, CollabPersistence, CollabMember, CollabSlot, CollabTemplate, CollabConfig, DURATION, WorkerLifecycle, WorkerSecretRefs, RESERVED_WORKER_ENV, RESERVED_ENV_FIELD, WorkerSpec, WorkersConfig, WorkerCondition, WorkerStatus, HOST_NAME_MAX, HOSTS_ARRAY_MAX, HostEntry, HostsConfig, PROBE_CPU_CORES_MAX, PROBE_MEM_BYTES_MAX, HostProbes, HostStatus, SkillSpec, SkillsConfig, McpEnvRefs, HTTP_HEADER_NAME, McpHeaderRefs, McpTransport, McpServerSpec, McpConfig, PLUGIN_ORIGIN, GIT_COMMIT_SHA, PluginSource, PluginSpec, PluginsConfig, PromptTextDeclaration, PromptBinding, PromptsConfig, EffectivePrompts, DOMAIN_SCHEMAS, SettingSource, EffectiveKey, DOMAINS;
|
|
496975
497012
|
var init_types19 = __esm({
|
|
496976
497013
|
"node_modules/@sema-agent/registry-core/dist/types.js"() {
|
|
496977
497014
|
init_zod2();
|
|
@@ -497157,7 +497194,6 @@ var init_types19 = __esm({
|
|
|
497157
497194
|
ScenarioEntry = external_exports3.object({
|
|
497158
497195
|
name: external_exports3.string().regex(/^[a-z][a-z0-9-]{1,31}$/, "lowercase slug, 2-32 chars (a-z, 0-9, -)"),
|
|
497159
497196
|
toolset: external_exports3.string().regex(/^[a-z][a-z0-9-]{0,63}$/, "toolset key (lowercase slug)"),
|
|
497160
|
-
prompt: external_exports3.string().max(4096).optional(),
|
|
497161
497197
|
enabled: external_exports3.boolean().default(true),
|
|
497162
497198
|
notes: external_exports3.string().optional()
|
|
497163
497199
|
});
|
|
@@ -497784,6 +497820,36 @@ var init_types19 = __esm({
|
|
|
497784
497820
|
seen.add(p.name);
|
|
497785
497821
|
});
|
|
497786
497822
|
});
|
|
497823
|
+
PromptTextDeclaration = external_exports3.object({
|
|
497824
|
+
id: external_exports3.string().min(1).max(128),
|
|
497825
|
+
slot: external_exports3.enum(["identity", "scenario", "behavior"]),
|
|
497826
|
+
text: external_exports3.string().max(65536),
|
|
497827
|
+
contentHash: external_exports3.string().regex(/^sha256:[0-9a-f]{64}$/).optional()
|
|
497828
|
+
});
|
|
497829
|
+
PromptBinding = external_exports3.object({
|
|
497830
|
+
level: external_exports3.enum(["global", "worker", "scenario"]),
|
|
497831
|
+
worker: external_exports3.string().min(1).max(190).optional(),
|
|
497832
|
+
scenario: external_exports3.string().regex(/^[a-z][a-z0-9-]{1,31}$/).optional(),
|
|
497833
|
+
declarations: external_exports3.array(PromptTextDeclaration).max(64),
|
|
497834
|
+
enabled: external_exports3.boolean().default(true),
|
|
497835
|
+
notes: external_exports3.string().optional()
|
|
497836
|
+
}).superRefine((b3, ctx) => {
|
|
497837
|
+
if (b3.level === "worker" && !b3.worker)
|
|
497838
|
+
ctx.addIssue({ code: "custom", message: "level=worker requires `worker`" });
|
|
497839
|
+
if (b3.level === "scenario" && !b3.scenario)
|
|
497840
|
+
ctx.addIssue({ code: "custom", message: "level=scenario requires `scenario`" });
|
|
497841
|
+
if (b3.level === "global" && (b3.worker || b3.scenario))
|
|
497842
|
+
ctx.addIssue({ code: "custom", message: "level=global must not carry a selector" });
|
|
497843
|
+
});
|
|
497844
|
+
PromptsConfig = external_exports3.object({
|
|
497845
|
+
bindings: external_exports3.array(PromptBinding).max(256).default([])
|
|
497846
|
+
});
|
|
497847
|
+
EffectivePrompts = external_exports3.object({
|
|
497848
|
+
packId: external_exports3.string().regex(/^center:[0-9a-f]{12}$/),
|
|
497849
|
+
contentDigest: external_exports3.string().regex(/^sha256:[0-9a-f]{64}$/),
|
|
497850
|
+
sections: external_exports3.array(PromptTextDeclaration),
|
|
497851
|
+
scenarioOverrides: external_exports3.record(external_exports3.string(), external_exports3.array(PromptTextDeclaration)).optional()
|
|
497852
|
+
});
|
|
497787
497853
|
DOMAIN_SCHEMAS = {
|
|
497788
497854
|
models: ModelsConfig,
|
|
497789
497855
|
rosters: RostersConfig,
|
|
@@ -497799,7 +497865,8 @@ var init_types19 = __esm({
|
|
|
497799
497865
|
governance: GovernanceConfig,
|
|
497800
497866
|
entitlement: EntitlementConfig,
|
|
497801
497867
|
execution: ExecutionPolicy,
|
|
497802
|
-
projects: ProjectsConfig
|
|
497868
|
+
projects: ProjectsConfig,
|
|
497869
|
+
prompts: PromptsConfig
|
|
497803
497870
|
};
|
|
497804
497871
|
SettingSource = external_exports3.discriminatedUnion("axis", [
|
|
497805
497872
|
external_exports3.object({ axis: external_exports3.literal("layer"), layer: external_exports3.enum(["MANAGED", "PROJECT", "LOCAL"]), applied: external_exports3.boolean().optional(), reason: external_exports3.string().optional() }),
|
|
@@ -552734,7 +552801,8 @@ var init_epoch = __esm({
|
|
|
552734
552801
|
orchestrationEnabled: false,
|
|
552735
552802
|
awarenessEnabled: false,
|
|
552736
552803
|
goalEnabled: false,
|
|
552737
|
-
worktreeIsolated: false
|
|
552804
|
+
worktreeIsolated: false,
|
|
552805
|
+
teammateEnabled: false
|
|
552738
552806
|
};
|
|
552739
552807
|
PROBE_FACTS_ON = Object.fromEntries(Object.keys(PROBE_FACTS_OFF).map((k2) => [k2, true]));
|
|
552740
552808
|
PROBE_VECTORS = [
|
|
@@ -552819,6 +552887,7 @@ var init_scheduler = __esm({
|
|
|
552819
552887
|
});
|
|
552820
552888
|
|
|
552821
552889
|
// node_modules/@sema-agent/core/dist/engine/execution-env/node-execution-env.js
|
|
552890
|
+
var EXEC_SPOOL_ROTATE_BYTES, EXEC_SPOOL_FINAL_TAIL_BYTES, EXEC_SPOOL_HARD_CAP_BYTES;
|
|
552822
552891
|
var init_node_execution_env = __esm({
|
|
552823
552892
|
"node_modules/@sema-agent/core/dist/engine/execution-env/node-execution-env.js"() {
|
|
552824
552893
|
init_types25();
|
|
@@ -552827,6 +552896,9 @@ var init_node_execution_env = __esm({
|
|
|
552827
552896
|
init_exec_output_tail();
|
|
552828
552897
|
init_background_shell();
|
|
552829
552898
|
init_scheduler();
|
|
552899
|
+
EXEC_SPOOL_ROTATE_BYTES = 8 * 1024 * 1024;
|
|
552900
|
+
EXEC_SPOOL_FINAL_TAIL_BYTES = 8 * 1024 * 1024;
|
|
552901
|
+
EXEC_SPOOL_HARD_CAP_BYTES = 16 * 1024 * 1024;
|
|
552830
552902
|
}
|
|
552831
552903
|
});
|
|
552832
552904
|
|
|
@@ -553524,6 +553596,20 @@ An object or array parameter value must be a single JSON value \u2014 never writ
|
|
|
553524
553596
|
}
|
|
553525
553597
|
});
|
|
553526
553598
|
|
|
553599
|
+
// node_modules/@sema-agent/core/dist/prompts/coordinator.js
|
|
553600
|
+
var TEAMMATE_COMMUNICATION_ADDENDUM;
|
|
553601
|
+
var init_coordinator = __esm({
|
|
553602
|
+
"node_modules/@sema-agent/core/dist/prompts/coordinator.js"() {
|
|
553603
|
+
TEAMMATE_COMMUNICATION_ADDENDUM = `# Agent Teammate Communication
|
|
553604
|
+
|
|
553605
|
+
IMPORTANT: You are running as a named agent in a team. To communicate, use the SendMessage tool \u2014 \`to: "main"\` sends an update to the spawning conversation; \`to: "<name>"\` continues a teammate that has COMPLETED its run (a running teammate cannot receive messages yet \u2014 wait for its completion).
|
|
553606
|
+
|
|
553607
|
+
Just writing a response in text is not visible to others on your team - you MUST use the SendMessage tool.
|
|
553608
|
+
|
|
553609
|
+
The user interacts primarily with the spawning conversation. Your work is coordinated through teammate messaging.`;
|
|
553610
|
+
}
|
|
553611
|
+
});
|
|
553612
|
+
|
|
553527
553613
|
// node_modules/@sema-agent/core/dist/prompt-assembly/packs/sema-default.js
|
|
553528
553614
|
function harnessHeadText(inputs) {
|
|
553529
553615
|
return harnessHeadLines(inputs.facts);
|
|
@@ -553533,6 +553619,7 @@ var init_sema_default = __esm({
|
|
|
553533
553619
|
"node_modules/@sema-agent/core/dist/prompt-assembly/packs/sema-default.js"() {
|
|
553534
553620
|
init_default6();
|
|
553535
553621
|
init_supervisor();
|
|
553622
|
+
init_coordinator();
|
|
553536
553623
|
CORE = {
|
|
553537
553624
|
owner: "core",
|
|
553538
553625
|
trust: "locked",
|
|
@@ -553590,6 +553677,7 @@ var init_sema_default = __esm({
|
|
|
553590
553677
|
content: (i) => i.roleAppend,
|
|
553591
553678
|
legacyBlockId: "role.append"
|
|
553592
553679
|
},
|
|
553680
|
+
{ id: "core/mode.teammate", slot: "scenario", rank: 405, ...CORE, admit: (i) => i.facts.teammateEnabled, content: () => TEAMMATE_COMMUNICATION_ADDENDUM, legacyBlockId: "mode.teammate" },
|
|
553593
553681
|
{
|
|
553594
553682
|
id: "core/discovery.mcp-instructions",
|
|
553595
553683
|
slot: "discovery",
|
|
@@ -555817,7 +555905,7 @@ var init_subagent_steps = __esm({
|
|
|
555817
555905
|
});
|
|
555818
555906
|
|
|
555819
555907
|
// node_modules/@sema-agent/core/dist/agents/subagent.js
|
|
555820
|
-
var EXTRA_TOOLS_MAX_FACTORY_CALLS_PER_TREE, EXTRA_TOOLS_BUDGET_NOTE, SESSION_BG_DEFAULT_TIMEOUT_SEC, RETAIN_DEFAULT_TTL_MS, FAILED_SESSION_RETAIN_TTL_MS;
|
|
555908
|
+
var EXTRA_TOOLS_MAX_FACTORY_CALLS_PER_TREE, EXTRA_TOOLS_BUDGET_NOTE, SESSION_BG_DEFAULT_TIMEOUT_SEC, RETAIN_DEFAULT_TTL_MS, FAILED_SESSION_RETAIN_TTL_MS, uplinkSeqGlobal;
|
|
555821
555909
|
var init_subagent = __esm({
|
|
555822
555910
|
"node_modules/@sema-agent/core/dist/agents/subagent.js"() {
|
|
555823
555911
|
init_build3();
|
|
@@ -555844,6 +555932,7 @@ var init_subagent = __esm({
|
|
|
555844
555932
|
SESSION_BG_DEFAULT_TIMEOUT_SEC = 30 * 60;
|
|
555845
555933
|
RETAIN_DEFAULT_TTL_MS = 30 * 60 * 1e3;
|
|
555846
555934
|
FAILED_SESSION_RETAIN_TTL_MS = 15 * 60 * 1e3;
|
|
555935
|
+
uplinkSeqGlobal = Date.now();
|
|
555847
555936
|
}
|
|
555848
555937
|
});
|
|
555849
555938
|
|
|
@@ -557168,6 +557257,13 @@ var init_workflow_run_store_contract = __esm({
|
|
|
557168
557257
|
}
|
|
557169
557258
|
});
|
|
557170
557259
|
|
|
557260
|
+
// node_modules/@sema-agent/core/dist/agents/roster-store.js
|
|
557261
|
+
var init_roster_store = __esm({
|
|
557262
|
+
"node_modules/@sema-agent/core/dist/agents/roster-store.js"() {
|
|
557263
|
+
init_task_registry();
|
|
557264
|
+
}
|
|
557265
|
+
});
|
|
557266
|
+
|
|
557171
557267
|
// node_modules/@sema-agent/core/dist/agents/agent-definition.js
|
|
557172
557268
|
var init_agent_definition = __esm({
|
|
557173
557269
|
"node_modules/@sema-agent/core/dist/agents/agent-definition.js"() {
|
|
@@ -557268,6 +557364,8 @@ var init_routing = __esm({
|
|
|
557268
557364
|
var init_explain = __esm({
|
|
557269
557365
|
"node_modules/@sema-agent/core/dist/prompt-assembly/explain.js"() {
|
|
557270
557366
|
init_event_registry();
|
|
557367
|
+
init_sema_default();
|
|
557368
|
+
init_default6();
|
|
557271
557369
|
}
|
|
557272
557370
|
});
|
|
557273
557371
|
|
|
@@ -557405,6 +557503,9 @@ var init_dist9 = __esm({
|
|
|
557405
557503
|
init_workflow_run_store_contract();
|
|
557406
557504
|
init_workflow_journal_store();
|
|
557407
557505
|
init_untrusted_egress();
|
|
557506
|
+
init_roster_store();
|
|
557507
|
+
init_task_registry();
|
|
557508
|
+
init_coordinator();
|
|
557408
557509
|
init_subagent();
|
|
557409
557510
|
init_agent_definition();
|
|
557410
557511
|
init_builtin_agents();
|
|
@@ -629528,6 +629629,10 @@ async function* ask(params) {
|
|
|
629528
629629
|
if (selfOrchestration && process.env.SEMA_DEBUG) {
|
|
629529
629630
|
console.error("[sema] print-mode ask: selfOrchestration wire \u2192 TaskRequest.selfOrchestration=true (run_workflow)");
|
|
629530
629631
|
}
|
|
629632
|
+
const deferTools = selfOrchestration ? deferToolsForRequest(objective) : void 0;
|
|
629633
|
+
if (deferTools && process.env.SEMA_DEBUG) {
|
|
629634
|
+
console.error("[sema] print-mode ask: deferTools wire \u2192 Workflow deferred (no activation source)");
|
|
629635
|
+
}
|
|
629531
629636
|
const retainBackground = process.env.SEMA_LIVE_BASEURL ? retainBackgroundFromEnv() : void 0;
|
|
629532
629637
|
if (retainBackground && process.env.SEMA_DEBUG) {
|
|
629533
629638
|
console.error("[sema] print-mode ask: retainBackground wire \u2192 TaskRequest.retainBackgroundProcesses=true");
|
|
@@ -629723,6 +629828,8 @@ async function* ask(params) {
|
|
|
629723
629828
|
...interactiveToolsField.interactiveTools === false ? { interactiveTools: false } : {},
|
|
629724
629829
|
...webSearch || wireHooks ? { settings: { ...webSearch ? { webSearch } : {}, ...wireHooks ? { hooks: wireHooks } : {} } } : {},
|
|
629725
629830
|
...selfOrchestration ? { selfOrchestration } : {},
|
|
629831
|
+
// Workflow deferred-disclosure ([1052]①): absent = fully exposed (activation turn / opt-out).
|
|
629832
|
+
...deferTools ? { deferTools } : {},
|
|
629726
629833
|
...retainBackground ? { retainBackgroundProcesses: retainBackground } : {},
|
|
629727
629834
|
...enableFork !== void 0 ? { enableFork } : {},
|
|
629728
629835
|
...attachments ? { attachments } : {},
|
|
@@ -629914,6 +630021,7 @@ var init_seamQueryEngine = __esm({
|
|
|
629914
630021
|
init_mockClient();
|
|
629915
630022
|
init_webSearchWireCaps();
|
|
629916
630023
|
init_selfOrchestrationWireCaps();
|
|
630024
|
+
init_ultracodeWireCaps();
|
|
629917
630025
|
init_retainBackgroundWireCaps();
|
|
629918
630026
|
init_forkWireCaps();
|
|
629919
630027
|
init_attachmentsWireCaps();
|
|
@@ -653829,7 +653937,7 @@ Auth: unix socket -R \u2192 local proxy`, "info");
|
|
|
653829
653937
|
pendingHookMessages
|
|
653830
653938
|
}, renderAndRun);
|
|
653831
653939
|
}
|
|
653832
|
-
}).version("sema 1.0.
|
|
653940
|
+
}).version("sema 1.0.17", "-v, --version", "Output the version number");
|
|
653833
653941
|
program2.option("-w, --worktree [name]", "Create a new git worktree for this session (optionally specify a name)");
|
|
653834
653942
|
program2.option("--tmux", "Create a tmux session for the worktree (requires --worktree). Uses iTerm2 native panes when available; use --tmux=classic for traditional tmux.");
|
|
653835
653943
|
if (canUserConfigureAdvisor()) {
|
|
@@ -657695,7 +657803,7 @@ var init_local_load = __esm({
|
|
|
657695
657803
|
// node_modules/@sema-agent/registry-core/dist/scheduler-store-node.js
|
|
657696
657804
|
import { mkdirSync as mkdirSync24, readFileSync as readFileSync51, writeFileSync as writeFileSync21, renameSync as renameSync10 } from "node:fs";
|
|
657697
657805
|
import { dirname as dirname88 } from "node:path";
|
|
657698
|
-
import { randomBytes as randomBytes25 } from "node:crypto";
|
|
657806
|
+
import { randomBytes as randomBytes25, createHash as createHash27 } from "node:crypto";
|
|
657699
657807
|
function loadSchedulerStore(path27) {
|
|
657700
657808
|
try {
|
|
657701
657809
|
return parseSchedulerStore(readFileSync51(path27, "utf-8"));
|
|
@@ -657736,6 +657844,7 @@ function mutateSchedulerStore(path27, fn2, opts) {
|
|
|
657736
657844
|
var init_scheduler_store_node = __esm({
|
|
657737
657845
|
"node_modules/@sema-agent/registry-core/dist/scheduler-store-node.js"() {
|
|
657738
657846
|
init_scheduler_store();
|
|
657847
|
+
init_hash2();
|
|
657739
657848
|
}
|
|
657740
657849
|
});
|
|
657741
657850
|
|