Add /v1/internal/logits endpoint (#4650)
This commit is contained in:
parent
8f4f4daf8b
commit
0fa1af296c
4 changed files with 71 additions and 9 deletions
|
@ -97,6 +97,29 @@ curl http://127.0.0.1:5000/v1/chat/completions \
|
|||
}'
|
||||
```
|
||||
|
||||
#### Logits
|
||||
|
||||
```
|
||||
curl -k http://127.0.0.1:5000/v1/internal/logits \
|
||||
-H "Content-Type: application/json" \
|
||||
-d '{
|
||||
"prompt": "Who is best, Asuka or Rei? Answer:",
|
||||
"use_samplers": false
|
||||
}'
|
||||
```
|
||||
|
||||
#### Logits after sampling parameters
|
||||
|
||||
```
|
||||
curl -k http://127.0.0.1:5000/v1/internal/logits \
|
||||
-H "Content-Type: application/json" \
|
||||
-d '{
|
||||
"prompt": "Who is best, Asuka or Rei? Answer:",
|
||||
"use_samplers": true,
|
||||
"top_k": 3
|
||||
}'
|
||||
```
|
||||
|
||||
#### Python chat example
|
||||
|
||||
```python
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue