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
28821bfd
Commit
28821bfd
authored
Dec 13, 2023
by
OlivierDehaene
Browse files
fix: default max_new_tokens to 100
parent
88aae259
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
docs/openapi.json
docs/openapi.json
+1
-1
router/src/lib.rs
router/src/lib.rs
+2
-2
No files found.
docs/openapi.json
View file @
28821bfd
...
...
@@ -523,7 +523,7 @@
"max_new_tokens"
:
{
"type"
:
"integer"
,
"format"
:
"int32"
,
"default"
:
"
null
"
,
"default"
:
"
20
"
,
"example"
:
"20"
,
"nullable"
:
true
,
"minimum"
:
0
...
...
router/src/lib.rs
View file @
28821bfd
...
...
@@ -107,7 +107,7 @@ pub(crate) struct GenerateParameters {
#[schema(default
=
"false"
,
example
=
true
)]
pub
do_sample
:
bool
,
#[serde(default
=
"default_max_new_tokens"
)]
#[schema(nullable
=
true
,
default
=
"
null
"
,
example
=
"20"
)]
#[schema(nullable
=
true
,
default
=
"
100
"
,
example
=
"20"
)]
pub
max_new_tokens
:
Option
<
u32
>
,
#[serde(default)]
#[schema(nullable
=
true
,
default
=
"null"
,
example
=
false
)]
...
...
@@ -141,7 +141,7 @@ pub(crate) struct GenerateParameters {
}
fn
default_max_new_tokens
()
->
Option
<
u32
>
{
None
Some
(
100
)
}
fn
default_parameters
()
->
GenerateParameters
{
...
...
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