nsarrazin commited on
Commit
a327608
·
1 Parent(s): 4906f37

fix: rm error in retrying when tool calls are not parsed properly

Browse files
src/lib/server/textGeneration/tools.ts CHANGED
@@ -3,7 +3,6 @@ import { v4 as uuidV4 } from "uuid";
3
  import { getCallMethod, toolFromConfigs, type BackendToolContext } from "../tools";
4
  import {
5
  MessageToolUpdateType,
6
- MessageUpdateStatus,
7
  MessageUpdateType,
8
  type MessageUpdate,
9
  } from "$lib/types/MessageUpdate";
@@ -218,12 +217,6 @@ export async function* runTools(
218
  calls.push(...newCalls);
219
  } catch (e) {
220
  logger.warn({ rawCall: output.generated_text, error: e }, "Error while parsing tool calls");
221
- // error parsing the calls
222
- yield {
223
- type: MessageUpdateType.Status,
224
- status: MessageUpdateStatus.Error,
225
- message: "Error while parsing tool calls.",
226
- };
227
  }
228
  }
229
  }
 
3
  import { getCallMethod, toolFromConfigs, type BackendToolContext } from "../tools";
4
  import {
5
  MessageToolUpdateType,
 
6
  MessageUpdateType,
7
  type MessageUpdate,
8
  } from "$lib/types/MessageUpdate";
 
217
  calls.push(...newCalls);
218
  } catch (e) {
219
  logger.warn({ rawCall: output.generated_text, error: e }, "Error while parsing tool calls");
 
 
 
 
 
 
220
  }
221
  }
222
  }