mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-09-09 11:24:53 +00:00
docstring
This commit is contained in:
parent
adf80bc23d
commit
ab2f784f29
@ -83,7 +83,7 @@ impl Infer {
|
|||||||
// MPSC channel to communicate with the background batching task
|
// MPSC channel to communicate with the background batching task
|
||||||
let (response_tx, response_rx) = mpsc::unbounded_channel();
|
let (response_tx, response_rx) = mpsc::unbounded_channel();
|
||||||
|
|
||||||
// Try to append the request to the database
|
// Append the request to the database
|
||||||
self.db.append(Entry {
|
self.db.append(Entry {
|
||||||
request: validated_request,
|
request: validated_request,
|
||||||
response_tx,
|
response_tx,
|
||||||
|
@ -174,7 +174,7 @@ async fn generate_stream(
|
|||||||
|
|
||||||
yield Ok(Event::default().json_data(stream_token).unwrap())
|
yield Ok(Event::default().json_data(stream_token).unwrap())
|
||||||
}
|
}
|
||||||
// End is used for timings metadata and logging
|
// Yield event for last token and compute timings
|
||||||
InferStreamResponse::End {
|
InferStreamResponse::End {
|
||||||
token,
|
token,
|
||||||
generated_text,
|
generated_text,
|
||||||
|
Loading…
Reference in New Issue
Block a user