Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
40828ce5
Unverified
Commit
40828ce5
authored
Mar 20, 2025
by
Wang, Yi
Committed by
GitHub
Mar 19, 2025
Browse files
fix "Total generated tokens:" is 0 if using --backend tgi and --endpo… (#14673)
Signed-off-by:
Wang, Yi A
<
yi.a.wang@intel.com
>
parent
ffa443af
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
benchmarks/backend_request_func.py
benchmarks/backend_request_func.py
+5
-1
No files found.
benchmarks/backend_request_func.py
View file @
40828ce5
...
@@ -63,7 +63,7 @@ async def async_request_tgi(
...
@@ -63,7 +63,7 @@ async def async_request_tgi(
"temperature"
:
0.01
,
# TGI does not accept 0.0 temperature.
"temperature"
:
0.01
,
# TGI does not accept 0.0 temperature.
"top_p"
:
0.99
,
# TGI does not accept 1.0 top_p.
"top_p"
:
0.99
,
# TGI does not accept 1.0 top_p.
"truncate"
:
request_func_input
.
prompt_len
,
"truncate"
:
request_func_input
.
prompt_len
,
# TGI does not accept
ignore_eos
flag.
"ignore_eos_token"
:
request_func_input
.
ignore_eos
,
}
}
payload
=
{
payload
=
{
"inputs"
:
request_func_input
.
prompt
,
"inputs"
:
request_func_input
.
prompt
,
...
@@ -71,6 +71,10 @@ async def async_request_tgi(
...
@@ -71,6 +71,10 @@ async def async_request_tgi(
}
}
output
=
RequestFuncOutput
()
output
=
RequestFuncOutput
()
output
.
prompt_len
=
request_func_input
.
prompt_len
output
.
prompt_len
=
request_func_input
.
prompt_len
if
request_func_input
.
ignore_eos
:
output
.
output_tokens
=
request_func_input
.
output_len
else
:
output
.
output_tokens
=
None
ttft
=
0.0
ttft
=
0.0
st
=
time
.
perf_counter
()
st
=
time
.
perf_counter
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment