Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
text-generation-inference
Commits
926fd9a0
Unverified
Commit
926fd9a0
authored
May 09, 2023
by
Sai Vinay G
Committed by
GitHub
May 09, 2023
Browse files
feat(router): Adding response schema for compat_generate (#292)
parent
e9b01b34
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
router/src/server.rs
router/src/server.rs
+5
-1
No files found.
router/src/server.rs
View file @
926fd9a0
...
@@ -37,7 +37,11 @@ use utoipa_swagger_ui::SwaggerUi;
...
@@ -37,7 +37,11 @@ use utoipa_swagger_ui::SwaggerUi;
path
=
"/"
,
path
=
"/"
,
request_body
=
CompatGenerateRequest,
request_body
=
CompatGenerateRequest,
responses(
responses(
(status
=
200
,
description
=
"See /generate or /generate_stream"
),
(status
=
200
,
description
=
"See /generate or /generate_stream"
,
content(
(
"application/json"
=
GenerateResponse),
(
"text/event-stream"
=
StreamResponse),
)),
(status
=
424
,
description
=
"Generation Error"
,
body
=
ErrorResponse,
(status
=
424
,
description
=
"Generation Error"
,
body
=
ErrorResponse,
example
=
json
!
(
{
"error"
:
"Request failed during generation"
}
)),
example
=
json
!
(
{
"error"
:
"Request failed during generation"
}
)),
(status
=
429
,
description
=
"Model is overloaded"
,
body
=
ErrorResponse,
(status
=
429
,
description
=
"Model is overloaded"
,
body
=
ErrorResponse,
...
...
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