dirac-lang 0.1.101 → 0.1.102

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.
@@ -2,8 +2,8 @@ import {
2
2
  SessionServer,
3
3
  getSocketPath,
4
4
  isSessionRunning
5
- } from "./chunk-2QNE7JD6.js";
6
- import "./chunk-36II47FL.js";
5
+ } from "./chunk-GS33Y77U.js";
6
+ import "./chunk-FWTYD7GV.js";
7
7
  import "./chunk-53QJQ2CC.js";
8
8
  import "./chunk-HRHAMPOB.js";
9
9
  import "./chunk-EAM7IZWA.js";
@@ -487,12 +487,12 @@ async function executeIf(session, element) {
487
487
  const condition = await evaluatePredicate(session, conditionElement);
488
488
  if (condition) {
489
489
  if (thenElement) {
490
- const { integrateChildren: integrateChildren2 } = await import("./interpreter-SN3LLYFD.js");
490
+ const { integrateChildren: integrateChildren2 } = await import("./interpreter-VO4BMOSU.js");
491
491
  await integrateChildren2(session, thenElement);
492
492
  }
493
493
  } else {
494
494
  if (elseElement) {
495
- const { integrateChildren: integrateChildren2 } = await import("./interpreter-SN3LLYFD.js");
495
+ const { integrateChildren: integrateChildren2 } = await import("./interpreter-VO4BMOSU.js");
496
496
  await integrateChildren2(session, elseElement);
497
497
  }
498
498
  }
@@ -505,7 +505,7 @@ async function evaluatePredicate(session, predicateElement) {
505
505
  return await evaluateCondition(session, predicateElement);
506
506
  }
507
507
  const outputLengthBefore = session.output.length;
508
- const { integrate: integrate2 } = await import("./interpreter-SN3LLYFD.js");
508
+ const { integrate: integrate2 } = await import("./interpreter-VO4BMOSU.js");
509
509
  await integrate2(session, predicateElement);
510
510
  const newOutputChunks = session.output.slice(outputLengthBefore);
511
511
  const result = newOutputChunks.join("").trim();
@@ -528,11 +528,11 @@ async function evaluateCondition(session, condElement) {
528
528
  }
529
529
  const outputLengthBefore = session.output.length;
530
530
  const args = [];
531
- const { integrate: integrate2 } = await import("./interpreter-SN3LLYFD.js");
531
+ const { integrate: integrate2 } = await import("./interpreter-VO4BMOSU.js");
532
532
  for (const child of condElement.children) {
533
533
  if (child.tag.toLowerCase() === "arg") {
534
534
  const argOutputStart = session.output.length;
535
- const { integrateChildren: integrateChildren2 } = await import("./interpreter-SN3LLYFD.js");
535
+ const { integrateChildren: integrateChildren2 } = await import("./interpreter-VO4BMOSU.js");
536
536
  await integrateChildren2(session, child);
537
537
  const newChunks = session.output.slice(argOutputStart);
538
538
  const argValue = newChunks.join("");
@@ -2103,7 +2103,7 @@ async function executeTagCheck(session, element) {
2103
2103
  const executeTag = correctedTag || tagName;
2104
2104
  console.error(`[tag-check] Executing <${executeTag}/> as all checks passed and execute=true.`);
2105
2105
  const elementToExecute = correctedTag ? { ...child, tag: correctedTag } : child;
2106
- const { integrate: integrate2 } = await import("./interpreter-SN3LLYFD.js");
2106
+ const { integrate: integrate2 } = await import("./interpreter-VO4BMOSU.js");
2107
2107
  await integrate2(session, elementToExecute);
2108
2108
  }
2109
2109
  }
@@ -2112,7 +2112,7 @@ async function executeTagCheck(session, element) {
2112
2112
  // src/tags/throw.ts
2113
2113
  async function executeThrow(session, element) {
2114
2114
  const exceptionName = element.attributes?.name || "exception";
2115
- const { integrateChildren: integrateChildren2 } = await import("./interpreter-SN3LLYFD.js");
2115
+ const { integrateChildren: integrateChildren2 } = await import("./interpreter-VO4BMOSU.js");
2116
2116
  const exceptionDom = {
2117
2117
  tag: "exception-content",
2118
2118
  attributes: { name: exceptionName },
@@ -2125,7 +2125,7 @@ async function executeThrow(session, element) {
2125
2125
  // src/tags/try.ts
2126
2126
  async function executeTry(session, element) {
2127
2127
  setExceptionBoundary(session);
2128
- const { integrateChildren: integrateChildren2 } = await import("./interpreter-SN3LLYFD.js");
2128
+ const { integrateChildren: integrateChildren2 } = await import("./interpreter-VO4BMOSU.js");
2129
2129
  await integrateChildren2(session, element);
2130
2130
  unsetExceptionBoundary(session);
2131
2131
  }
@@ -2135,7 +2135,7 @@ async function executeCatch(session, element) {
2135
2135
  const exceptionName = element.attributes?.name || "exception";
2136
2136
  const caughtCount = lookupException(session, exceptionName);
2137
2137
  if (caughtCount > 0) {
2138
- const { integrateChildren: integrateChildren2 } = await import("./interpreter-SN3LLYFD.js");
2138
+ const { integrateChildren: integrateChildren2 } = await import("./interpreter-VO4BMOSU.js");
2139
2139
  await integrateChildren2(session, element);
2140
2140
  }
2141
2141
  flushCurrentException(session);
@@ -2144,7 +2144,7 @@ async function executeCatch(session, element) {
2144
2144
  // src/tags/exception.ts
2145
2145
  async function executeException(session, element) {
2146
2146
  const exceptions = getCurrentExceptions(session);
2147
- const { integrateChildren: integrateChildren2 } = await import("./interpreter-SN3LLYFD.js");
2147
+ const { integrateChildren: integrateChildren2 } = await import("./interpreter-VO4BMOSU.js");
2148
2148
  for (const exceptionDom of exceptions) {
2149
2149
  await integrateChildren2(session, exceptionDom);
2150
2150
  }
@@ -2345,7 +2345,7 @@ async function executeLoadContext(session, element) {
2345
2345
  query = element.text.trim();
2346
2346
  }
2347
2347
  if (!query && element.children.length > 0) {
2348
- const { integrate: integrate2 } = await import("./interpreter-SN3LLYFD.js");
2348
+ const { integrate: integrate2 } = await import("./interpreter-VO4BMOSU.js");
2349
2349
  const beforeOutput = session.output.length;
2350
2350
  for (const child of element.children) {
2351
2351
  await integrate2(session, child);
@@ -3230,7 +3230,7 @@ async function executeForeach(session, element) {
3230
3230
  const parser2 = new DiracParser2();
3231
3231
  try {
3232
3232
  const fromElement = parser2.parse(fromAttr);
3233
- const { integrate: integrate2 } = await import("./interpreter-SN3LLYFD.js");
3233
+ const { integrate: integrate2 } = await import("./interpreter-VO4BMOSU.js");
3234
3234
  await integrate2(session, fromElement);
3235
3235
  } catch (e) {
3236
3236
  session.output = savedOutput;
@@ -3895,8 +3895,13 @@ async function executeTask(session, element, name, getIsRunning, setIsRunning) {
3895
3895
  return;
3896
3896
  }
3897
3897
  setIsRunning(true);
3898
+ console.log(`[schedule] Executing task: ${name}`);
3898
3899
  try {
3900
+ session.output = [];
3899
3901
  await integrateChildren(session, element);
3902
+ if (session.output.length > 0) {
3903
+ console.log(session.output.join(""));
3904
+ }
3900
3905
  } catch (error) {
3901
3906
  console.error(`[schedule] Task "${name}" failed:`, error.message);
3902
3907
  } finally {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  integrate
3
- } from "./chunk-36II47FL.js";
3
+ } from "./chunk-FWTYD7GV.js";
4
4
  import {
5
5
  DiracParser
6
6
  } from "./chunk-HRHAMPOB.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  integrate
3
- } from "./chunk-36II47FL.js";
3
+ } from "./chunk-FWTYD7GV.js";
4
4
  import {
5
5
  DiracParser
6
6
  } from "./chunk-HRHAMPOB.js";
package/dist/cli.js CHANGED
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  execute
4
- } from "./chunk-VECLLEZT.js";
4
+ } from "./chunk-OTP437A4.js";
5
5
  import {
6
6
  BraKetParser
7
- } from "./chunk-36II47FL.js";
7
+ } from "./chunk-FWTYD7GV.js";
8
8
  import "./chunk-53QJQ2CC.js";
9
9
  import "./chunk-HRHAMPOB.js";
10
10
  import "./chunk-EAM7IZWA.js";
@@ -16,7 +16,7 @@ import "dotenv/config";
16
16
  // package.json
17
17
  var package_default = {
18
18
  name: "dirac-lang",
19
- version: "0.1.100",
19
+ version: "0.1.101",
20
20
  description: "LLM-Augmented Declarative Execution",
21
21
  type: "module",
22
22
  main: "dist/index.js",
@@ -150,7 +150,7 @@ async function main() {
150
150
  const args = process.argv.slice(2);
151
151
  const calledAs = process.argv[1];
152
152
  if (calledAs && calledAs.endsWith("/dish")) {
153
- const { DiracShell } = await import("./shell-JYSUSQA7.js");
153
+ const { DiracShell } = await import("./shell-LEAR2OVM.js");
154
154
  const shellConfig = loadShellConfig(args);
155
155
  const shell = new DiracShell(shellConfig);
156
156
  await shell.start();
@@ -199,11 +199,11 @@ async function main() {
199
199
  if (args[0] === "agent") {
200
200
  const subcommand = args[1];
201
201
  if (subcommand === "daemon") {
202
- const { runAgentDaemon } = await import("./agent-ZJTJX7UU.js");
202
+ const { runAgentDaemon } = await import("./agent-2KA6H3VE.js");
203
203
  await runAgentDaemon();
204
204
  return;
205
205
  }
206
- const { AgentCLI } = await import("./agent-ZJTJX7UU.js");
206
+ const { AgentCLI } = await import("./agent-2KA6H3VE.js");
207
207
  const agent = new AgentCLI();
208
208
  switch (subcommand) {
209
209
  case "start":
@@ -230,8 +230,8 @@ async function main() {
230
230
  return;
231
231
  }
232
232
  if (args[0] === "shell") {
233
- const { DiracShell } = await import("./shell-JYSUSQA7.js");
234
- const { SessionServer, isSessionRunning, getSocketPath } = await import("./session-server-CQID6HFD.js");
233
+ const { DiracShell } = await import("./shell-LEAR2OVM.js");
234
+ const { SessionServer, isSessionRunning, getSocketPath } = await import("./session-server-CMHI5CQ5.js");
235
235
  const { SessionClient } = await import("./session-client-3VTC5MLO.js");
236
236
  const daemonMode = args.includes("--daemon") || args.includes("-d");
237
237
  const agentMode = args.includes("--agent") || args.includes("-a");
@@ -277,7 +277,7 @@ async function main() {
277
277
  return;
278
278
  }
279
279
  if (args[0] === "daemon") {
280
- const { SessionServer } = await import("./session-server-CQID6HFD.js");
280
+ const { SessionServer } = await import("./session-server-CMHI5CQ5.js");
281
281
  const server = new SessionServer();
282
282
  await server.start();
283
283
  console.log("Session daemon started");
@@ -3,7 +3,7 @@ import {
3
3
  listCronJobs,
4
4
  stopAllCronJobs,
5
5
  stopCronJob
6
- } from "./chunk-36II47FL.js";
6
+ } from "./chunk-FWTYD7GV.js";
7
7
  import "./chunk-53QJQ2CC.js";
8
8
  import "./chunk-HRHAMPOB.js";
9
9
  import "./chunk-EAM7IZWA.js";
package/dist/index.js CHANGED
@@ -2,10 +2,10 @@ import {
2
2
  createLLMAdapter,
3
3
  execute,
4
4
  executeUserCommand
5
- } from "./chunk-VECLLEZT.js";
5
+ } from "./chunk-OTP437A4.js";
6
6
  import {
7
7
  integrate
8
- } from "./chunk-36II47FL.js";
8
+ } from "./chunk-FWTYD7GV.js";
9
9
  import "./chunk-53QJQ2CC.js";
10
10
  import {
11
11
  DiracParser
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  integrate,
3
3
  integrateChildren
4
- } from "./chunk-36II47FL.js";
4
+ } from "./chunk-FWTYD7GV.js";
5
5
  import "./chunk-53QJQ2CC.js";
6
6
  import "./chunk-HRHAMPOB.js";
7
7
  import "./chunk-EAM7IZWA.js";
@@ -3,7 +3,7 @@ import {
3
3
  cancelScheduledRun,
4
4
  executeRunAt,
5
5
  listScheduledRuns
6
- } from "./chunk-36II47FL.js";
6
+ } from "./chunk-FWTYD7GV.js";
7
7
  import "./chunk-53QJQ2CC.js";
8
8
  import "./chunk-HRHAMPOB.js";
9
9
  import "./chunk-EAM7IZWA.js";
@@ -3,7 +3,7 @@ import {
3
3
  listScheduledTasks,
4
4
  stopAllScheduledTasks,
5
5
  stopScheduledTask
6
- } from "./chunk-36II47FL.js";
6
+ } from "./chunk-FWTYD7GV.js";
7
7
  import "./chunk-53QJQ2CC.js";
8
8
  import "./chunk-HRHAMPOB.js";
9
9
  import "./chunk-EAM7IZWA.js";
@@ -2,8 +2,8 @@ import {
2
2
  SessionServer,
3
3
  getSocketPath,
4
4
  isSessionRunning
5
- } from "./chunk-2QNE7JD6.js";
6
- import "./chunk-36II47FL.js";
5
+ } from "./chunk-GS33Y77U.js";
6
+ import "./chunk-FWTYD7GV.js";
7
7
  import "./chunk-53QJQ2CC.js";
8
8
  import "./chunk-HRHAMPOB.js";
9
9
  import "./chunk-EAM7IZWA.js";
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  BraKetParser,
4
4
  integrate
5
- } from "./chunk-36II47FL.js";
5
+ } from "./chunk-FWTYD7GV.js";
6
6
  import "./chunk-53QJQ2CC.js";
7
7
  import {
8
8
  DiracParser
@@ -358,7 +358,7 @@ var DiracShell = class {
358
358
  if (this.client) {
359
359
  this.client.disconnect();
360
360
  }
361
- import("./schedule-PTDHH2QD.js").then(({ stopAllScheduledTasks }) => {
361
+ import("./schedule-OGJDCWSV.js").then(({ stopAllScheduledTasks }) => {
362
362
  stopAllScheduledTasks();
363
363
  console.log("\nGoodbye!");
364
364
  process.exit(0);
@@ -818,7 +818,7 @@ Examples:
818
818
  break;
819
819
  case "tasks":
820
820
  try {
821
- const { listScheduledTasks } = await import("./schedule-PTDHH2QD.js");
821
+ const { listScheduledTasks } = await import("./schedule-OGJDCWSV.js");
822
822
  const tasks = listScheduledTasks();
823
823
  if (tasks.length === 0) {
824
824
  console.log("No scheduled tasks running.");
@@ -837,7 +837,7 @@ Examples:
837
837
  console.log("Usage: :stop <task-name>");
838
838
  } else {
839
839
  try {
840
- const { stopScheduledTask } = await import("./schedule-PTDHH2QD.js");
840
+ const { stopScheduledTask } = await import("./schedule-OGJDCWSV.js");
841
841
  const taskName = args[0];
842
842
  const stopped = stopScheduledTask(taskName);
843
843
  if (stopped) {
@@ -852,7 +852,7 @@ Examples:
852
852
  break;
853
853
  case "stopall":
854
854
  try {
855
- const { stopAllScheduledTasks } = await import("./schedule-PTDHH2QD.js");
855
+ const { stopAllScheduledTasks } = await import("./schedule-OGJDCWSV.js");
856
856
  stopAllScheduledTasks();
857
857
  console.log("All scheduled tasks stopped.");
858
858
  } catch (error) {
@@ -861,7 +861,7 @@ Examples:
861
861
  break;
862
862
  case "crons":
863
863
  try {
864
- const { listCronJobs } = await import("./cron-LCLEKEPF.js");
864
+ const { listCronJobs } = await import("./cron-3C3H6QMC.js");
865
865
  const jobs = listCronJobs();
866
866
  if (jobs.length === 0) {
867
867
  console.log("No cron jobs running.");
@@ -881,7 +881,7 @@ Examples:
881
881
  console.log("Usage: :stopcron <job-name>");
882
882
  } else {
883
883
  try {
884
- const { stopCronJob } = await import("./cron-LCLEKEPF.js");
884
+ const { stopCronJob } = await import("./cron-3C3H6QMC.js");
885
885
  const jobName = args[0];
886
886
  const stopped = stopCronJob(jobName);
887
887
  if (stopped) {
@@ -896,7 +896,7 @@ Examples:
896
896
  break;
897
897
  case "stopallcrons":
898
898
  try {
899
- const { stopAllCronJobs } = await import("./cron-LCLEKEPF.js");
899
+ const { stopAllCronJobs } = await import("./cron-3C3H6QMC.js");
900
900
  stopAllCronJobs();
901
901
  console.log("All cron jobs stopped.");
902
902
  } catch (error) {
@@ -905,7 +905,7 @@ Examples:
905
905
  break;
906
906
  case "scheduled":
907
907
  try {
908
- const { listScheduledRuns } = await import("./run-at-FTMMGQU5.js");
908
+ const { listScheduledRuns } = await import("./run-at-Q437F5V3.js");
909
909
  const runs = listScheduledRuns();
910
910
  if (runs.length === 0) {
911
911
  console.log("No scheduled runs pending.");
@@ -925,7 +925,7 @@ Examples:
925
925
  console.log("Usage: :cancel <run-name>");
926
926
  } else {
927
927
  try {
928
- const { cancelScheduledRun } = await import("./run-at-FTMMGQU5.js");
928
+ const { cancelScheduledRun } = await import("./run-at-Q437F5V3.js");
929
929
  const runName = args[0];
930
930
  const cancelled = cancelScheduledRun(runName);
931
931
  if (cancelled) {
@@ -940,7 +940,7 @@ Examples:
940
940
  break;
941
941
  case "cancelall":
942
942
  try {
943
- const { cancelAllScheduledRuns } = await import("./run-at-FTMMGQU5.js");
943
+ const { cancelAllScheduledRuns } = await import("./run-at-Q437F5V3.js");
944
944
  cancelAllScheduledRuns();
945
945
  console.log("All scheduled runs cancelled.");
946
946
  } catch (error) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  integrate
3
- } from "./chunk-36II47FL.js";
3
+ } from "./chunk-FWTYD7GV.js";
4
4
  import "./chunk-53QJQ2CC.js";
5
5
  import {
6
6
  DiracParser
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dirac-lang",
3
- "version": "0.1.101",
3
+ "version": "0.1.102",
4
4
  "description": "LLM-Augmented Declarative Execution",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",