Change a writing style
Code Mode: praxis.studio.styles.update
HTTP: PATCH /studio/v1/styles/{style}
Change a style: its name, its description, its samples, its picture samples, its use and avoid lists, or its glossary. Send update_mask naming exactly the fields you change; a list the mask names is replaced whole. Adding a term to the glossary or to avoid also changes what the deterministic checks flag, so a work that uses this style sees new findings on its next check.
Signature
praxis.studio.styles.update(args:{path:{/** e.g. "sty_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ style:string};body:{/** Field paths this call changes, such as description, samples or avoid; a list named here is replaced whole and a field left out keeps its value. */ update_mask:Array<string>;/** New name of the style, replacing the previous one when name is named in the update mask. e.g. "克制的白描(修订)" */ name?:string;/** New description of the voice, replacing the previous one. e.g. "短句为主,少形容词,情绪靠动作和物件带出。" */ description?:string;/** Complete set of sample paragraphs, replacing the previous ones; removing a sample removes it from every later context pack. */ samples?:Array<string>;/** Complete picture gallery for this style, replacing the previous one and keeping the order you send; a picture left out stops being shown. */ pictures?:Array<string|{/** Identifier of the uploaded file, from the file service; the bytes stay there and the gallery only references them, so attaching the same file to several entries e.g. "file_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ file:string;/** Short name shown under the picture, such as a view or a costume; at most 40 characters after trimming. e.g. "定妆 · 正面" */ name:string;/** What this particular picture shows and why it was chosen, such as the lighting or the angle; at most 200 characters, and an empty string means no description. e.g. "冷光,半身,衣领扣到最上面一颗。" */ description:string}>;/** Complete set of wording and habits to keep, replacing the previous ones. */ use?:Array<string>;/** Complete set of words and phrases to avoid, replacing the previous ones and with them the banned-word check. */ avoid?:Array<string>;/** Complete glossary, replacing the previous one; a pair removed here stops being checked. e.g. {"沙盒":"沙箱"} */ glossary?:{[key:string]:string}}}):Promise<{/** Style identifier; a style has no name-based address, so this is what the style path takes. e.g. "sty_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ id:string;/** Resource kind marker, always studio.style for this shape. e.g. "studio.style" */ object:string;/** Creation time in RFC 3339 UTC. e.g. "2026-11-04T09:40:00Z" */ create_time?:string;/** Time of the last change to this style in RFC 3339 UTC. e.g. "2026-11-04T10:11:20Z" */ update_time?:string;/** Console address that opens this style, where its samples can be read beside a piece written with it. e.g. "https://console.deepraxis.com/studio/styles/sty_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ viewer_url:string;/** Name of the style, used by people to pick it when attaching it to a work or a draft. e.g. "克制的白描" */ name:string;/** Short description of the voice; the samples do the real work, so this is a label rather than an instruction. e.g. "短句为主,少形容词,情绪靠动作带出。" */ description:string;/** One to five paragraphs of writing the piece should sound like; these paragraphs reach the context pack, so they carry the style. */ samples:Array<string>;/** Picture samples of this style, in the order they were written; they show what the voice looks like on the page and are not sent to a writer. */ pictures:Array<{/** Identifier of the uploaded file, from the file service; the bytes stay there and the gallery only references them, so attaching the same file to several entries e.g. "file_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ file:string;/** Short name shown under the picture, such as a view or a costume; at most 40 characters after trimming. e.g. "定妆 · 正面" */ name:string;/** What this particular picture shows and why it was chosen, such as the lighting or the angle; at most 200 characters, and an empty string means no description. e.g. "冷光,半身,衣领扣到最上面一颗。" */ description:string}>;/** Work this style belongs to, or null for a style that belongs to no single work; a work may only use its own styles, so attaching a style of another work is refu e.g. "wk_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ work:string;/** Wording and habits to keep, such as a preferred term or a sentence rhythm, stated as instructions a writer can follow. */ use:Array<string>;/** Words and stock phrases to avoid; they also become the banned-word check for any draft that uses this style. */ avoid:Array<string>;/** Terms mapped from a wrong spelling to the right one; the glossary check flags the wrong spelling wherever it appears. e.g. {"沙盒":"沙箱"} */ glossary:{[key:string]:string}}>;Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| style | path | string | yes | Style being addressed, by its sty_ identifier; a style has no name-based address, so read the style list first when only the name is known. |
Request body
| Required | Content types | Description |
|---|---|---|
| yes | application/json | The style fields to change, with the update mask that names them. |
Responses
| Status | Content types | Description |
|---|---|---|
| 200 | application/json | The updated style as it now reads. |
| 400 | application/json | INVALID_PARAMS means a field is missing, malformed or not allowed for this resource; correct the named field and repeat the call. |
| 401 | application/json | The API key is missing, invalid or carries no organization; send a valid organization key in the Authorization header. |
| 404 | application/json | STYLE_NOT_FOUND means no style in this organization has that identifier; read the style list and pass one of its identifiers. |
| 500 | application/json | INTERNAL means the request could not complete; re-read the resource before retrying a write, because the write may already have landed. |