From ba1070abd33639e1b35c15a42696f42a4bfb8e3c Mon Sep 17 00:00:00 2001 From: WaseemH Date: Tue, 5 Dec 2023 20:56:30 -0500 Subject: [PATCH] Small doc fix for FastAPI section (#253) --- docs/concepts/fastapi.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/concepts/fastapi.md b/docs/concepts/fastapi.md index ccaea14e7..e915473f3 100644 --- a/docs/concepts/fastapi.md +++ b/docs/concepts/fastapi.md @@ -49,7 +49,8 @@ def endpoint_function(data: UserData) -> UserDetail: `FastAPI` supports streaming responses, which is useful for returning large amounts of data. This feature is particularly useful when working with large language models (LLMs) that generate a large amount of data. ```python hl_lines="6-7" -from fastapi import StreamingResponse +from fastapi.responses import StreamingResponse +from typing import Iterable # Route to handle SSE events and return users @app.post("/extract", response_class=StreamingResponse)