skein_theme
The caller's visual theme — colours, fonts, sizes, spacing. Call action="instructions" FIRST when the user asks for visual changes ("change the color", "another font", "make it darker", "like Alice's"): it returns the canonical fork → preview → confirm → persist workflow and the onboarding script, and improvising without it is the documented way to get this wrong. Built-in light/dark are read-only, so editing always starts with action="fork". Read-only actions: instructions, describe.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"action": "<action>"
},
"name": "skein_theme"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Name for the new theme; unique among your own themes (another user's theme of the same name never collides), 1..100 chars. Required for fork. | |
| action | Yes | What to do: - "instructions" → the canonical theme-editing guide (workflow, onboarding script, anti-patterns). Returns markdown, not JSON; cache it for the session. - "describe" → the token schema, the caller's active theme, every saved theme, and their recent Inspect-mode clicks. - "fork" → copy a theme (or a builtin) into a new editable one and activate it for the caller. - "preview_variables" → push an ephemeral preview to the caller's open tabs; nothing is saved. Applies your map verbatim, and warns (response `warning` + `roles[]`) about any key the current role dictionary does not declare — such a key paints nothing. - "set_variables" → merge variables into a saved theme and persist them. Refuses the WHOLE patch with `unknown_theme_role` (+ `roles[]`, with the successor of each retired name) if any key is not a current role: nothing is written, because a dead key in a saved row paints nothing and gets silently deleted by the frontend's next migration write-back. - "inspect_clear" → drop the caller's accumulated Inspect-mode selections. | |
| source | No | What to fork: "active" (the caller's current theme, falling back to their builtin), "builtin-light", "builtin-dark", or a theme UUID from describe. Required for fork. | |
| themeId | No | UUID of the theme to write to, as returned by fork or describe. Required for set_variables. | |
| variables | No | Partial map of CSS variable name → value. Supplied keys overwrite, absent keys are preserved (unlike the REST PATCH, which replaces the whole map). Required for set_variables and preview_variables. Every key must be a role of the CURRENT dictionary (action="describe", or the summary in action="instructions"): the pre-redesign names have no alias layer and resolve to nothing. set_variables refuses such a patch outright (`unknown_theme_role`); preview_variables applies it as sent and warns. |