@band-ai/sdk 0.4.3 → 0.4.4

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/adapters.cjs CHANGED
@@ -1698,15 +1698,20 @@ function systemUpdateParts(participantsMessage, contactsMessage) {
1698
1698
  }
1699
1699
  function buildConversationPrompt(options) {
1700
1700
  const parts = [];
1701
- if (options.isSessionBootstrap && options.history.length > 0) {
1702
- const historyText = options.history.raw.slice(-(options.maxHistoryMessages ?? 50)).map(formatHistoryLine).join("\n");
1703
- parts.push(`${options.historyHeader}
1701
+ if (options.isSessionBootstrap) {
1702
+ const historyText = options.history.raw.slice(-(options.maxHistoryMessages ?? 50)).filter(isTextHistoryEntry).map(formatHistoryLine).join("\n");
1703
+ if (historyText) {
1704
+ parts.push(`${options.historyHeader}
1704
1705
  ${historyText}`);
1706
+ }
1705
1707
  }
1706
1708
  parts.push(...systemUpdateParts(options.participantsMessage, options.contactsMessage));
1707
1709
  parts.push(options.currentMessage);
1708
1710
  return parts.join("\n\n");
1709
1711
  }
1712
+ function isTextHistoryEntry(entry) {
1713
+ return entry.message_type === void 0 || entry.message_type === "text";
1714
+ }
1710
1715
  function formatHistoryLine(entry) {
1711
1716
  const sender = String(entry.sender_name ?? entry.sender_type ?? "Unknown");
1712
1717
  const content = String(entry.content ?? "");
package/dist/adapters.js CHANGED
@@ -37,7 +37,7 @@ import {
37
37
  VercelAISDKToolCallingModel,
38
38
  applySessionConfigSelections,
39
39
  runSingleToolRound
40
- } from "./chunk-VHYPQAQ5.js";
40
+ } from "./chunk-STUSNTHF.js";
41
41
  import "./chunk-UL3Y5C4J.js";
42
42
  import "./chunk-JDW5WSGF.js";
43
43
  import {
@@ -483,15 +483,20 @@ function systemUpdateParts(participantsMessage, contactsMessage) {
483
483
  }
484
484
  function buildConversationPrompt(options) {
485
485
  const parts = [];
486
- if (options.isSessionBootstrap && options.history.length > 0) {
487
- const historyText = options.history.raw.slice(-(options.maxHistoryMessages ?? 50)).map(formatHistoryLine).join("\n");
488
- parts.push(`${options.historyHeader}
486
+ if (options.isSessionBootstrap) {
487
+ const historyText = options.history.raw.slice(-(options.maxHistoryMessages ?? 50)).filter(isTextHistoryEntry).map(formatHistoryLine).join("\n");
488
+ if (historyText) {
489
+ parts.push(`${options.historyHeader}
489
490
  ${historyText}`);
491
+ }
490
492
  }
491
493
  parts.push(...systemUpdateParts(options.participantsMessage, options.contactsMessage));
492
494
  parts.push(options.currentMessage);
493
495
  return parts.join("\n\n");
494
496
  }
497
+ function isTextHistoryEntry(entry) {
498
+ return entry.message_type === void 0 || entry.message_type === "text";
499
+ }
495
500
  function formatHistoryLine(entry) {
496
501
  const sender = String(entry.sender_name ?? entry.sender_type ?? "Unknown");
497
502
  const content = String(entry.content ?? "");
package/dist/index.cjs CHANGED
@@ -8344,15 +8344,20 @@ function systemUpdateParts(participantsMessage, contactsMessage) {
8344
8344
  }
8345
8345
  function buildConversationPrompt(options) {
8346
8346
  const parts = [];
8347
- if (options.isSessionBootstrap && options.history.length > 0) {
8348
- const historyText = options.history.raw.slice(-(options.maxHistoryMessages ?? 50)).map(formatHistoryLine).join("\n");
8349
- parts.push(`${options.historyHeader}
8347
+ if (options.isSessionBootstrap) {
8348
+ const historyText = options.history.raw.slice(-(options.maxHistoryMessages ?? 50)).filter(isTextHistoryEntry).map(formatHistoryLine).join("\n");
8349
+ if (historyText) {
8350
+ parts.push(`${options.historyHeader}
8350
8351
  ${historyText}`);
8352
+ }
8351
8353
  }
8352
8354
  parts.push(...systemUpdateParts(options.participantsMessage, options.contactsMessage));
8353
8355
  parts.push(options.currentMessage);
8354
8356
  return parts.join("\n\n");
8355
8357
  }
8358
+ function isTextHistoryEntry(entry) {
8359
+ return entry.message_type === void 0 || entry.message_type === "text";
8360
+ }
8356
8361
  function formatHistoryLine(entry) {
8357
8362
  const sender = String(entry.sender_name ?? entry.sender_type ?? "Unknown");
8358
8363
  const content = String(entry.content ?? "");
package/dist/index.js CHANGED
@@ -24,7 +24,7 @@ import {
24
24
  OpencodeAdapter,
25
25
  VercelAISDKAdapter,
26
26
  applySessionConfigSelections
27
- } from "./chunk-VHYPQAQ5.js";
27
+ } from "./chunk-STUSNTHF.js";
28
28
  import "./chunk-UL3Y5C4J.js";
29
29
  import "./chunk-JDW5WSGF.js";
30
30
  import {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@band-ai/sdk",
3
- "version": "0.4.3",
3
+ "version": "0.4.4",
4
4
  "description": "Band TypeScript SDK core runtime",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -95,7 +95,7 @@
95
95
  },
96
96
  "dependencies": {
97
97
  "@band-ai/band-sdk-core": "2.5.0",
98
- "@band-ai/rest-client": "0.0.143",
98
+ "@band-ai/rest-client": "0.0.146",
99
99
  "js-yaml": "^5.4.2",
100
100
  "phoenix": "^1.8.14",
101
101
  "ws": "^8.21.3",
@@ -175,17 +175,17 @@
175
175
  },
176
176
  "devDependencies": {
177
177
  "@agentclientprotocol/sdk": "^1.4.0",
178
- "@anthropic-ai/claude-agent-sdk": "^0.3.270",
179
- "@linear/sdk": "^95.0.0",
178
+ "@anthropic-ai/claude-agent-sdk": "^0.3.276",
179
+ "@linear/sdk": "^95.1.0",
180
180
  "@modelcontextprotocol/sdk": "^1.30.0",
181
- "@openai/codex-sdk": "^0.154.0",
181
+ "@openai/codex-sdk": "^0.155.0",
182
182
  "@opencode-ai/sdk": "^1.18.30",
183
183
  "@types/express": "^5.0.6",
184
184
  "@types/node": "^26.5.1",
185
185
  "@typescript-eslint/eslint-plugin": "^8.70.0",
186
186
  "@typescript-eslint/parser": "^8.70.0",
187
187
  "@vitest/coverage-v8": "5.0.1",
188
- "ai": "^7.0.99",
188
+ "ai": "^7.0.106",
189
189
  "c8": "12.0.0",
190
190
  "eslint": "^10.10.0",
191
191
  "tsup": "^8.5.1",