server : handle bytes
This commit is contained in:
parent
d37be8dc9e
commit
7f02fead8c
1 changed files with 15 additions and 11 deletions
|
@ -424,17 +424,21 @@
|
||||||
const popoverChildren = html`
|
const popoverChildren = html`
|
||||||
<div>
|
<div>
|
||||||
${completion_probabilities.map((cp, i) => {
|
${completion_probabilities.map((cp, i) => {
|
||||||
return cp.probs.map((p, j) => {
|
return html`
|
||||||
return html`
|
<div key={i} style=${{ borderBottom: '1px solid #ccc', padding: '0.3em' }}>
|
||||||
<div style=${{
|
${cp.probs.map((p, j) => {
|
||||||
padding: '0.3em',
|
return html`
|
||||||
backgroundColor: p.tok_str === msg.content ? probColor(p.prob) : 'transparent'
|
<div key=${`${i}-${j}`} style=${{
|
||||||
}}>
|
padding: '0.3em',
|
||||||
<span>${p.tok_str}: </span>
|
backgroundColor: p.tok_str === cp.content ? probColor(p.prob) : 'transparent'
|
||||||
<span>${p.prob}</span>
|
}}>
|
||||||
</div>
|
<span>${p.tok_str}: </span>
|
||||||
`
|
<span>${p.prob}</span>
|
||||||
})
|
</div>
|
||||||
|
`
|
||||||
|
})}
|
||||||
|
</div>
|
||||||
|
`
|
||||||
})}
|
})}
|
||||||
</div>
|
</div>
|
||||||
`
|
`
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue