victor HF Staff commited on
Commit
d1218ba
·
1 Parent(s): a86bb3a

Increase max assistant and user message lengths

Browse files

Updated the default values for LLM_ROUTER_MAX_ASSISTANT_LENGTH and LLM_ROUTER_MAX_PREV_USER_LENGTH from 500/400 to 1000 each to allow longer messages in the router prompt.

Files changed (1) hide show
  1. src/lib/server/router/arch.ts +2 -2
src/lib/server/router/arch.ts CHANGED
@@ -78,8 +78,8 @@ function toRouterPrompt(messages: EndpointMessage[], routes: Route[]) {
78
  name: r.name,
79
  description: r.description,
80
  }));
81
- const maxAssistantLength = parseInt(config.LLM_ROUTER_MAX_ASSISTANT_LENGTH || "500", 10);
82
- const maxPrevUserLength = parseInt(config.LLM_ROUTER_MAX_PREV_USER_LENGTH || "400", 10);
83
 
84
  const convo = messages
85
  .map((m) => ({ role: m.from, content: m.content }))
 
78
  name: r.name,
79
  description: r.description,
80
  }));
81
+ const maxAssistantLength = parseInt(config.LLM_ROUTER_MAX_ASSISTANT_LENGTH || "1000", 10);
82
+ const maxPrevUserLength = parseInt(config.LLM_ROUTER_MAX_PREV_USER_LENGTH || "1000", 10);
83
 
84
  const convo = messages
85
  .map((m) => ({ role: m.from, content: m.content }))