Replace the settings a story's runs override the model's defaults with.
PUT /ai/stories/{storyId}/settings
PUT https://dev.zanhosting.com/ai/stories/{storyId}/settings
| ID de operación |
ai.stories.storyId.settings.put
|
|---|---|
| Acceso | Signed in through ZanAuth: the access token cookie, with its ID token and refresh token companions. O: An access token the site's ZanAuth issuer minted for its app, or a static key. |
Parámetros
| Nombre | En | Tipo | Descripción | |
|---|---|---|---|---|
storyId
| Ruta | Obligatorio | string (snowflake) | The story. |
Cuerpo de la solicitud
Obligatorio, enviado como application/x-www-form-urlencoded, application/json.
Esquema: LlmSettingsBody
| Propiedad | Tipo | Descripción | |
|---|---|---|---|
temperature
| number (double), or null | Opcional | How freely the model picks its words: higher is more varied, lower more focused. |
dynatemp_range
| number (double), or null | Opcional | Lets the temperature move this far either way, higher where the model is unsure of the next word. 0 keeps it fixed. |
dynatemp_exponent
| number (double), or null | Opcional | How sharply the dynamic temperature follows the model's doubt. Only matters with a dynamic temperature range. |
top_k
| integer (int64), or null | Opcional | Picks only among this many likeliest next words. 0 sets no limit. |
top_p
| number (double), or null | Opcional | Picks only among the likeliest next words that together make up this share of the chance. 1 sets no limit. |
min_p
| number (double), or null | Opcional | Drops every word less likely than this share of the likeliest one. 0 drops none. |
typical_p
| number (double), or null | Opcional | Keeps the words about as surprising as the text so far, up to this share of the chance. 1 turns it off. |
top_n_sigma
| number (double), or null | Opcional | Keeps only the words within this many standard deviations of the likeliest one, whatever the temperature. -1 turns it off. |
xtc_probability
| number (double), or null | Opcional | How often XTC removes the likeliest words, for less predictable writing. 0 turns it off. |
xtc_threshold
| number (double), or null | Opcional | How likely a word must be for XTC to remove it; above 0.5 removes none. Only matters with an XTC probability. |
repeat_penalty
| number (double), or null | Opcional | Makes words already used less likely. 1 turns it off. |
repeat_last_n
| integer (int64), or null | Opcional | How many of the last tokens the repeat, presence and frequency penalties look back over. 0 turns them off; -1 looks over the whole context. |
presence_penalty
| number (double), or null | Opcional | Makes any word already used less likely, however often, nudging toward new topics. 0 turns it off. |
frequency_penalty
| number (double), or null | Opcional | Makes a word less likely the more often it was used. 0 turns it off. |
dry_multiplier
| number (double), or null | Opcional | How hard DRY pushes against repeating whole phrases. 0 turns it off. |
dry_base
| number (double), or null | Opcional | How fast DRY's push grows as a repeated phrase gets longer. Only matters with a DRY multiplier. |
dry_allowed_length
| integer (int64), or null | Opcional | How long a repeated phrase may run before DRY pushes against it. Only matters with a DRY multiplier. |
dry_penalty_last_n
| integer (int64), or null | Opcional | How many of the last tokens DRY looks back over for repeats. 0 turns it off; -1 looks over the whole context. Only matters with a DRY multiplier. |
mirostat
| one of: 0, 1, 2, null | Opcional | Steers how surprising the text is toward a target. While it is on, it replaces Top K, Top P, Min P and the other samplers. |
mirostat_tau
| number (double), or null | Opcional | How surprising Mirostat keeps the text: lower is more focused. Only matters with Mirostat on. |
mirostat_eta
| number (double), or null | Opcional | How quickly Mirostat corrects toward its target. Only matters with Mirostat on. |
max_tokens
| integer (int64), or null | Opcional | Where a reply is cut off, its thinking included. |
seed
| integer (int64), or null | Opcional | The same seed and settings give the same reply to the same prompt. -1 picks a new one each time. |
reasoning_effort
| one of: "none", "low", "medium", "xhigh", null | Opcional | How hard the model thinks before it answers. |
thinking_budget_tokens
| integer (int64), or null | Opcional | The most tokens the model may think for before it must answer. -1 sets no limit. |
Respuestas
| Estado | Descripción | Esquema | Tipo de contenido |
|---|---|---|---|
| 200 | Saved. | StoryAnswer | application/json |
| 422 | The input was rejected; errors names each failure. | ValidationProblem | application/json |
| Cualquier otro estado | The request was refused. The problem's type names why, and its detail explains it for people to read. | Problem | application/json |
200 Saved.
| Propiedad | Tipo | Descripción | |
|---|---|---|---|
ai_stories_id
| string (snowflake) | Obligatorio | |
ai_stories_title
| string | Obligatorio | |
ai_stories_model_id
| string (snowflake) | Obligatorio | |
model_label
| string, or null | Obligatorio | Null when the model is no longer offered. |
ai_stories_system_prompt
| string | Obligatorio | Who the model is while it plans and writes. Empty makes it a skilled fiction writer. |
ai_stories_planning_prompt
| string | Obligatorio | The idea, the characters you have in mind, the length: the plan is made from this. |
ai_stories_writing_prompt
| string | Obligatorio | Style, voice, length of each chapter. Empty asks for the complete story, chapter by chapter, in vivid prose. |
ai_stories_overrides
| LlmSettings | Obligatorio | |
progress
| StoryProgress | Obligatorio | |
models
| list of LlmModelOption | Obligatorio | The models one may pick. |
422 The input was rejected; errors names each failure.
| Propiedad | Tipo | Descripción | |
|---|---|---|---|
type
| string | Obligatorio | A URL that identifies the kind of problem. Its last segment, such as auth_required or input_invalid, is the code your app should check. |
title
| string | Obligatorio | The HTTP status as text, such as Not Found. |
status
| integer (int32) | Obligatorio | The HTTP status code of the response. |
detail
| string | Obligatorio | An explanation of what went wrong, written for people to read. |
instance
| string | Obligatorio | The path the request was sent to. |
errors
| InputErrors | Obligatorio | What is wrong with each refused value. Parameters come as a list, and body errors as a tree shaped like the body. |
Cualquier otro estado: The request was refused. The problem's type names why, and its detail explains it for people to read.
| Propiedad | Tipo | Descripción | |
|---|---|---|---|
type
| string | Obligatorio | A URL that identifies the kind of problem. Its last segment, such as auth_required or input_invalid, is the code your app should check. |
title
| string | Obligatorio | The HTTP status as text, such as Not Found. |
status
| integer (int32) | Obligatorio | The HTTP status code of the response. |
detail
| string | Obligatorio | An explanation of what went wrong, written for people to read. |
instance
| string | Obligatorio | The path the request was sent to. |
Ejemplo
curl -X PUT 'https://dev.zanhosting.com/ai/stories/{storyId}/settings' \
-H 'Authorization: Bearer <access token>' \
-H 'Content-Type: application/json' \
-d '{}'