open-agents-ai 0.187.437 → 0.187.438

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.js CHANGED
@@ -515414,15 +515414,51 @@ var init_crl = __esm({
515414
515414
  * Decode CRL expression to natural language
515415
515415
  */
515416
515416
  decode(crl) {
515417
+ const hasCRLStructure = /[\[\]∀∃∴∵→⇒⇐∩∪⊂⊃∈∉]/.test(crl);
515418
+ if (!hasCRLStructure) {
515419
+ return crl;
515420
+ }
515421
+ let result = this.expand(crl);
515417
515422
  const parser2 = new CRLParser();
515418
- const ast = parser2.parse(crl);
515419
- return this.renderStatement(ast);
515423
+ const ast = parser2.parse(result);
515424
+ if (ast.nodes.length > 0) {
515425
+ const rendered = this.renderStatement(ast);
515426
+ if (rendered && rendered.trim().length > 0) {
515427
+ return rendered;
515428
+ }
515429
+ }
515430
+ return result;
515420
515431
  }
515421
515432
  /**
515422
515433
  * Render a statement node
515423
515434
  */
515424
515435
  renderStatement(node) {
515425
- return node.nodes.map((n2) => this.renderNode(n2)).filter(Boolean).join(". ");
515436
+ const results = [];
515437
+ const nodes = node.nodes;
515438
+ for (let i2 = 0; i2 < nodes.length; i2++) {
515439
+ const current = nodes[i2];
515440
+ if (current.type === "concept" && i2 + 2 < nodes.length) {
515441
+ const next = nodes[i2 + 1];
515442
+ const afterNext = nodes[i2 + 2];
515443
+ if (next.type === "relation" && afterNext.type === "concept") {
515444
+ const relationNode = {
515445
+ type: "relation",
515446
+ from: current,
515447
+ operator: next.raw || "",
515448
+ to: afterNext,
515449
+ raw: `${current.raw}${next.raw}${afterNext.raw}`,
515450
+ position: { start: current.position.start, end: afterNext.position.end }
515451
+ };
515452
+ results.push(this.renderRelation(relationNode));
515453
+ i2 += 2;
515454
+ continue;
515455
+ }
515456
+ }
515457
+ const rendered = this.renderNode(current);
515458
+ if (rendered)
515459
+ results.push(rendered);
515460
+ }
515461
+ return results.filter(Boolean).join(". ");
515426
515462
  }
515427
515463
  /**
515428
515464
  * Render any CRL node
@@ -515547,9 +515583,15 @@ var init_crl = __esm({
515547
515583
  };
515548
515584
  let result = text;
515549
515585
  for (const [symbol3, expansion] of Object.entries(expansions)) {
515550
- result = result.replace(new RegExp(symbol3, "g"), ` ${expansion} `);
515586
+ result = result.replace(new RegExp(`(^|[.!?]\\s*)${symbol3}`, "g"), (match, prefix) => {
515587
+ const capitalized = expansion.charAt(0).toUpperCase() + expansion.slice(1);
515588
+ return `${prefix}${capitalized}`;
515589
+ });
515590
+ result = result.replace(new RegExp(`(?<!^)(?<![.!?]\\s*)${symbol3}`, "g"), expansion);
515551
515591
  }
515552
- return result.replace(/\s+/g, " ").trim();
515592
+ result = result.replace(/\s+([.,;:!?])/g, "$1");
515593
+ result = result.replace(/\s+/g, " ").trim();
515594
+ return result;
515553
515595
  }
515554
515596
  };
515555
515597
  CRLTemplateResolver = class {
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "open-agents-ai",
3
- "version": "0.187.437",
3
+ "version": "0.187.438",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "open-agents-ai",
9
- "version": "0.187.437",
9
+ "version": "0.187.438",
10
10
  "hasInstallScript": true,
11
11
  "license": "CC-BY-NC-4.0",
12
12
  "dependencies": {
@@ -3944,9 +3944,9 @@
3944
3944
  "license": "MIT"
3945
3945
  },
3946
3946
  "node_modules/electron-to-chromium": {
3947
- "version": "1.5.343",
3948
- "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.343.tgz",
3949
- "integrity": "sha512-YHnQ3MXI08icvL9ZKnEBy05F2EQ8ob01UaMOuMbM8l+4UcAq6MPPbBTJBbsBUg3H8JeZNt+O4fjsoWth3p6IFg==",
3947
+ "version": "1.5.344",
3948
+ "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.344.tgz",
3949
+ "integrity": "sha512-4MxfbmNDm+KPh066EZy+eUnkcDPcZ35wNmOWzFuh/ijvHsve6kbLTLURy88uCNK5FbpN+yk2nQY6BYh1GEt+wg==",
3950
3950
  "license": "ISC",
3951
3951
  "peer": true
3952
3952
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "open-agents-ai",
3
- "version": "0.187.437",
3
+ "version": "0.187.438",
4
4
  "description": "AI coding agent powered by open-source models (Ollama/vLLM) — interactive TUI with agentic tool-calling loop",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",