File tree Expand file tree Collapse file tree 3 files changed +26
-4
lines changed
routes/page/agent/[agentId]/agent-components Expand file tree Collapse file tree 3 files changed +26
-4
lines changed Original file line number Diff line number Diff line change 1717 * @property {string? } model
1818 * @property {number } max_recursion_depth
1919 * @property {number? } [max_output_tokens]
20+ * @property {string? } [reasoning_effort_level]
2021 */
2122
2223
Original file line number Diff line number Diff line change 8787 const found = innerKnowledgeBases .find ((_ , index ) => index === idx);
8888 if (! found) return ;
8989
90- const vals = e .target .value . split ( " # " );
91- found .name = vals[ 0 ] ;
92- found .type = vals[ 1 ] ;
90+ const val = JSON . parse ( e .target .value );
91+ found .name = val ? . name ;
92+ found .type = val ? . type ;
9393 innerRefresh (innerKnowledgeBases);
9494 handleAgentChange ();
9595 }
219219 on: change= {e => changeKnowledgeBase (e, uid)}
220220 >
221221 {#each [... knowledgeBaseOptions] as option}
222- < option value= {` ${ option . name } # ${ option . type } ` } selected= {option .name == knowledge .name }>
222+ < option value= {` ${ JSON . stringify ( option) } ` } selected= {option .name == knowledge .name }>
223223 {option .displayName || option .name }
224224 < / option>
225225 {/ each}
Original file line number Diff line number Diff line change 9999 handleAgentChange ();
100100 }
101101
102+ /** @param {any} e */
103+ function changeReasoningEffortLevel (e ) {
104+ config .reasoning_effort_level = e .target .value || null ;
105+ handleAgentChange ();
106+ }
107+
102108 /** @param {any} e */
103109 function validateIntegerInput (e ) {
104110 const reg = new RegExp (INTEGER_REGEX , ' g' );
174180 / >
175181 < / div>
176182 < / div>
183+
184+ < div class = " mb-3 row" >
185+ < label for = " example-text-input" class = " col-md-3 col-form-label" >
186+ Reasoning level
187+ < / label>
188+ < div class = " col-md-9" >
189+ < Input type= " select" value= {config .reasoning_effort_level } on: change= {e => changeReasoningEffortLevel (e)}>
190+ {#each reasonLevelOptions as option}
191+ < option value= {option .value } selected= {option .value == config .reasoning_effort_level }>
192+ {option .label }
193+ < / option>
194+ {/ each}
195+ < / Input>
196+ < / div>
197+ < / div>
177198 < / CardBody>
178199< / Card>
You can’t perform that action at this time.
0 commit comments