server : minor
This commit is contained in:
parent
f4800d54e7
commit
7635b13ad7
2 changed files with 20 additions and 20 deletions
|
@ -436,7 +436,7 @@ Notice that each `probs` is an array of length `n_probs`.
|
|||
"next_token": {
|
||||
"has_next_token": true,
|
||||
"n_remain": -1,
|
||||
"num_tokens_predicted": 0,
|
||||
"n_decoded": 0,
|
||||
"stopped_eos": false,
|
||||
"stopped_limit": false,
|
||||
"stopped_word": false,
|
||||
|
|
|
@ -845,7 +845,7 @@ struct llama_server_context {
|
|||
{"token_text", tokens_to_output_formatted_string(ctx, result.tok)},
|
||||
{"has_next_token", slot.has_next_token},
|
||||
{"n_remain", slot.n_remaining},
|
||||
{"num_tokens_predicted", slot.n_decoded},
|
||||
{"n_decoded", slot.n_decoded},
|
||||
{"stopped_eos", slot.stopped_eos},
|
||||
{"stopped_word", slot.stopped_word},
|
||||
{"stopped_limit", slot.stopped_limit},
|
||||
|
@ -1185,7 +1185,7 @@ struct llama_server_context {
|
|||
slot_data["next_token"] = {
|
||||
{"has_next_token", slot.has_next_token},
|
||||
{"n_remain", slot.n_remaining},
|
||||
{"num_tokens_predicted", slot.n_decoded},
|
||||
{"n_decoded", slot.n_decoded},
|
||||
{"stopped_eos", slot.stopped_eos},
|
||||
{"stopped_word", slot.stopped_word},
|
||||
{"stopped_limit", slot.stopped_limit},
|
||||
|
@ -2913,9 +2913,9 @@ int main(int argc, char ** argv) {
|
|||
json prompt;
|
||||
if (body.count("input") != 0) {
|
||||
prompt = body["input"];
|
||||
// batch
|
||||
if (prompt.is_array()) {
|
||||
json data = json::array();
|
||||
|
||||
int i = 0;
|
||||
for (const json & elem : prompt) {
|
||||
const int id_task = llama.queue_tasks.get_new_id();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue