bare-agent 0.46.6 → 0.48.0

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/types/index.d.ts CHANGED
@@ -142,8 +142,13 @@ export interface GenerateResult {
142
142
  * tool call" and retries; `usage`/`model` still flow so the round is metered. The JSON is NEVER
143
143
  * repaired. Absent on a clean round. OpenAI-compatible + Ollama string-arguments only; Anthropic
144
144
  * arrives pre-parsed and cannot hit this.
145
+ *
146
+ * `rawArguments`/`rawTruncated` (BA-27 follow-up) are present only when the provider was
147
+ * constructed with `exposeMalformedArgs: true` (default off, mirrors `exposeErrorBody`) AND the
148
+ * raw `function.arguments` was a string: the raw value verbatim, capped at 500 chars, with
149
+ * `rawTruncated: true` added only when it was longer.
145
150
  */
146
- malformedToolCall?: { name: string | undefined; error: string };
151
+ malformedToolCall?: { name: string | undefined; error: string; rawArguments?: string; rawTruncated?: true };
147
152
  /**
148
153
  * BA-7 — provider-native content blocks the normalized `{text, toolCalls}` shape cannot express
149
154
  * (Anthropic `thinking` / `redacted_thinking`), captured opaquely so the Loop can put them on the