Skip to content

Commit 4af77c6

Browse files
committed
add readme
1 parent c103816 commit 4af77c6

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

templates/types/streaming/fastapi/README-template.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,16 @@ Second, generate the embeddings of the documents in the `./data` directory (if t
2121
poetry run generate
2222
```
2323

24-
Third, run the development server:
24+
Third, if you want to use the app with a chat UI, you will need to build the frontend once. If not, you can skip this step:
2525

2626
```
27-
python main.py
27+
poetry run build
28+
```
29+
30+
Finally, run the app:
31+
32+
```
33+
poetry run dev
2834
```
2935

3036
The example provides two different API endpoints:
@@ -50,7 +56,7 @@ curl --location 'localhost:8000/api/chat/request' \
5056

5157
You can start editing the API endpoints by modifying `app/api/routers/chat.py`. The endpoints auto-update as you save the file. You can delete the endpoint you're not using.
5258

53-
Open [http://localhost:8000/docs](http://localhost:8000/docs) with your browser to see the Swagger UI of the API.
59+
If you have built the frontend, open [http://localhost:8000](http://localhost:8000) in your browser to access the chat UI. If not, open [http://localhost:8000/docs](http://localhost:8000/docs) to view the Swagger UI documentation for the API.
5460

5561
The API allows CORS for all origins to simplify development. You can change this behavior by setting the `ENVIRONMENT` environment variable to `prod`:
5662

0 commit comments

Comments
 (0)