File tree Expand file tree Collapse file tree 9 files changed +33
-21
lines changed Expand file tree Collapse file tree 9 files changed +33
-21
lines changed Original file line number Diff line number Diff line change 1616
1717 let innerText = ' ' ;
1818 $: {
19+ if (typeof text !== ' string' ) {
20+ text = ` ${ JSON .stringify (text)} ` ;
21+ }
1922 const markedText = ! rawText ? replaceNewLine (marked (replaceMarkdown (text || ' ' ))? .toString ()) : marked (text || ' ' )? .toString ();
2023 if (!! markedText && markedText .endsWith (' <br>' )) {
2124 const idx = markedText .lastIndexOf (' <br>' );
Original file line number Diff line number Diff line change 3333 * @property {string } provider
3434 * @property {string } model
3535 * @property {string? } [template_name]
36+ * @property {string? } [user_name]
3637 * @property {string } user_message
3738 * @property {string? } [system_instruction]
3839 * @property {string } completion_text
Original file line number Diff line number Diff line change 9595 padding : 10px 5px ;
9696
9797 .instruction-log-message {
98+ margin-top : 10px ;
9899 overflow-y : auto ;
99100 max-height : 350px ;
100101 scrollbar-width : none ;
Original file line number Diff line number Diff line change 374374 </div>
375375 </CardBody>
376376 {#if showStateSearch}
377- <CardBody class="border-bottom" style="display: flex; justify-content: flex-end;">
378- <StateSearch bind:states={states} onSearch={q => handleStateSearch(q)}/>
377+ <CardBody class="border-bottom">
378+ <Row class="g-3 justify-content-end">
379+ <Col lg="6">
380+ <StateSearch bind:states={states} onSearch={q => handleStateSearch(q)}/>
381+ </Col>
382+ </Row>
379383 </CardBody>
380384 {/if}
381385 <CardBody class="border-bottom">
Original file line number Diff line number Diff line change 3636>
3737 {#each states as state , idx }
3838 <div class =" state-search-item" >
39- <div >
39+ <div style = " flex: 1; " >
4040 <RemoteSearchInput
4141 bind:value ={state .key }
4242 maxLength ={maxLength }
4343 onSearch ={e => onSearch (e )}
4444 placeholder =" Search States"
4545 />
4646 </div >
47- <div >
47+ <div style = " flex: 1; " >
4848 <Input
4949 type =" text"
5050 bind:value ={state .value }
6767 </div >
6868 {/each }
6969 {#if states .length < limit }
70- <div >
71- <Button
72- color =" link"
73- style =" padding-left: 0px;"
74- on:click ={() => addState ()}
75- >
76- Add +
77- </Button >
78- </div >
70+ <div class =" d-flex justify-content-end" >
71+ <Button
72+ color =" link"
73+ style =" padding-left: 0px;"
74+ on:click ={() => addState ()}
75+ >
76+ Add +
77+ </Button >
78+ <div style =" flex: 0 0 13px;" ></div >
79+ </div >
7980 {/if }
8081</div >
8182
Original file line number Diff line number Diff line change 201201
202202
203203< HeadTitle title= " {$_('Instruction Log')}" / >
204- < Breadcrumb pagetitle= " {$_('Instruction Log')}" title= " {$_('Instruction')}" / >
204+ < Breadcrumb pagetitle= " {$_('Log')}" title= " {$_('Instruction')}" / >
205205< LoadingToComplete isLoading= {isLoading} / >
206206
207207< Row>
260260 < thead>
261261 < tr>
262262 < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Agent' )}< / th>
263- < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Provider' )}< / th>
264- < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Model' )}< / th>
263+ < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Llm Provider' )}< / th>
264+ < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Llm Model' )}< / th>
265265 < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Template' )}< / th>
266+ < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Caller' )}< / th>
266267 < th scope= " col" class = " instruction-log-col ellipsis" > {$_ (' Created Time' )}< / th>
267268 < th scope= " col" > {$_ (' ' )}< / th>
268269 < / tr>
Original file line number Diff line number Diff line change 2020 <td class ="instruction-log-col ellipsis" >{item .provider }</td >
2121 <td class ="instruction-log-col ellipsis" >{item .model }</td >
2222 <td class ="instruction-log-col ellipsis" >{item .template_name || ' N/A' }</td >
23+ <td class ="instruction-log-col ellipsis" >{item .user_name || ' N/A' }</td >
2324 <td class ="instruction-log-col ellipsis" >{utcToLocal (item .created_time )}</td >
2425 <td >
2526 <ul class =" list-unstyled hstack gap-1 mb-0" style =" justify-content: center;" >
Original file line number Diff line number Diff line change 88 import HeadTitle from ' $lib/common/HeadTitle.svelte' ;
99 import Breadcrumb from ' $lib/common/Breadcrumb.svelte' ;
1010 import Markdown from ' $lib/common/markdown/Markdown.svelte' ;
11- import InstructionState from ' ./instruction-components/instruction-state.svelte' ;
11+ import InstructionState from ' .. /instruction-components/instruction-state.svelte' ;
1212 import { getAgents } from ' $lib/services/agent-service' ;
1313 import LoadingToComplete from ' $lib/common/LoadingToComplete.svelte' ;
1414 import { sendChatCompletion } from ' $lib/services/instruct-service' ;
1515 import { getLlmConfigs } from ' $lib/services/llm-provider-service' ;
1616 import { LlmModelType } from ' $lib/helpers/enums' ;
1717 import NavBar from ' $lib/common/nav-bar/NavBar.svelte' ;
1818 import NavItem from ' $lib/common/nav-bar/NavItem.svelte' ;
19- import InstructionTemplate from ' ./instruction-components/instruction-template.svelte' ;
20- import InstructionLlm from ' ./instruction-components/instruction-llm.svelte' ;
19+ import InstructionTemplate from ' .. /instruction-components/instruction-template.svelte' ;
20+ import InstructionLlm from ' .. /instruction-components/instruction-llm.svelte' ;
2121
2222 const maxLength = 64000 ;
2323 const DEFAULT_PROVIDER = ' openai' ;
165165< / script>
166166
167167< HeadTitle title= " {$_('Instruction')}" / >
168- < Breadcrumb pagetitle= " {$_('Instruction ')}" title= " {$_('Instruction')}" / >
168+ < Breadcrumb pagetitle= " {$_('Testing ')}" title= " {$_('Instruction')}" / >
169169< LoadingToComplete isLoading= {isLoading} / >
170170
171171< div class = " d-xl-flex" >
Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ const config = {
5252 "/page/agent/[agentId]" ,
5353 "/page/agent/[agentId]/build" ,
5454 "/page/agent/[agentId]/train" ,
55- "/page/instruction" ,
55+ "/page/instruction/testing " ,
5656 "/page/instruction/log" ,
5757 "/page/conversation" ,
5858 "/page/conversation/[conversationId]" ,
You can’t perform that action at this time.
0 commit comments