From 106a09c36fba2d0d413384ef527a5cbbb87eee78 Mon Sep 17 00:00:00 2001 From: l2D <20911264+l2D@users.noreply.github.com> Date: Tue, 25 Jun 2024 23:59:48 +0700 Subject: [PATCH] chore: Add Swagger UI Log Message and Update `README.md` with API Access Information (#749) Signed-off-by: l2D <20911264+l2D@users.noreply.github.com> --- README.md | 7 +++++++ cortex-js/src/main.ts | 1 + 2 files changed, 8 insertions(+) diff --git a/README.md b/README.md index 3107bdb9d..238de39bf 100644 --- a/README.md +++ b/README.md @@ -35,8 +35,15 @@ cortex run llama3 To run Cortex as an API server: ```bash cortex serve + +# Output +# Started server at http://localhost:1337 +# Swagger UI available at http://localhost:1337/api ``` +You can now access the Cortex API server at `http://localhost:1337`, +and the Swagger UI at `http://localhost:1337/api`. + ## Build from Source To install Cortex from the source, follow the steps below: diff --git a/cortex-js/src/main.ts b/cortex-js/src/main.ts index cb6a6f079..804e9481e 100644 --- a/cortex-js/src/main.ts +++ b/cortex-js/src/main.ts @@ -12,6 +12,7 @@ async function bootstrap() { await app.listen(port, host); console.log(`Started server at http://${host}:${port}`); + console.log(`Swagger UI available at http://${host}:${port}/api`); } bootstrap();