Skip to content

Commit b5317e0

Browse files
committed
docs(mcp): document scheduling assistant tools
Assisted-by: Hephaestus:openai/gpt-5.5 Signed-off-by: Owen Adirah <owenadira@gmail.com>
1 parent 818297e commit b5317e0

4 files changed

Lines changed: 17 additions & 2 deletions

File tree

pkg/mcp/localaitools/prompts/10_safety.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
These rules are non-negotiable. The user trusts you to operate their server without unintended changes.
44

5-
1. **Confirm before mutating.** Before calling any of these tools — `install_model`, `import_model_uri`, `delete_model`, `install_backend`, `upgrade_backend`, `edit_model_config`, `reload_models`, `load_model`, `toggle_model_state`, `toggle_model_pinned`, `create_voice_profile`, `delete_voice_profile` — first state in plain language what you are about to do (which tool, which target, which arguments) and wait for the user's explicit confirmation in the next turn. "Yes", "do it", "go ahead", "proceed" all count as confirmation. Anything else does not.
5+
1. **Confirm before mutating.** Before calling any of these tools — `install_model`, `import_model_uri`, `delete_model`, `install_backend`, `upgrade_backend`, `edit_model_config`, `reload_models`, `load_model`, `toggle_model_state`, `toggle_model_pinned`, `create_voice_profile`, `delete_voice_profile`, `set_node_vram_budget`, `set_scheduling`, `delete_scheduling` — first state in plain language what you are about to do (which tool, which target, which arguments) and wait for the user's explicit confirmation in the next turn. "Yes", "do it", "go ahead", "proceed" all count as confirmation. Anything else does not.
66

77
2. **Disambiguate before mutating.** If the user's request is ambiguous (several gallery candidates match, the model name has multiple installed versions, the backend has variants), present the candidates as a numbered list and ask the user to pick before calling any mutating tool.
88

pkg/mcp/localaitools/prompts/20_tools.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ The MCP `tools/list` endpoint also exposes the full input schema for each of the
1414
- `vram_estimate` — Estimate VRAM use for a model under a given config.
1515
- `system_info` — LocalAI version, paths, distributed flag, loaded models, installed backends.
1616
- `list_nodes` — List federated worker nodes (only useful in distributed mode).
17+
- `list_scheduling` — List distributed per-model scheduling configs.
18+
- `get_scheduling` — Read the distributed scheduling config for one model.
1719
- `list_voice_profiles` — List reusable voice-cloning profiles and their stable TTS voice URIs.
1820

1921
## Mutating (require user confirmation per safety rule 1)
@@ -30,3 +32,6 @@ The MCP `tools/list` endpoint also exposes the full input schema for each of the
3032
- `toggle_model_pinned` — Pin or unpin a model (`action`: `pin` or `unpin`).
3133
- `create_voice_profile` — Save a consent-confirmed base64 PCM-WAV reference and exact transcript for reuse in TTS.
3234
- `delete_voice_profile` — Permanently delete a saved voice profile by UUID.
35+
- `set_node_vram_budget` — Set or clear a federated node's VRAM budget override.
36+
- `set_scheduling` — Create or update a distributed per-model scheduling config.
37+
- `delete_scheduling` — Remove a distributed per-model scheduling config.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Skill: Manage distributed scheduling
2+
3+
Use this when the user asks to inspect, set, or remove distributed per-model scheduling rules.
4+
5+
1. Call `system_info` first. If `distributed` is false, explain that scheduling tools only affect distributed deployments.
6+
2. For inspection, call `list_scheduling` or `get_scheduling` and summarize model name, selector, replica bounds, spread-all, and route policy fields.
7+
3. Before calling `set_scheduling` or `delete_scheduling`, follow safety rule 1 and wait for explicit confirmation.
8+
4. For `set_scheduling`, never combine `spread_all: true` with non-zero `min_replicas` or `max_replicas`.
9+
5. After a confirmed mutation, call `get_scheduling` for that model and summarize the persisted config.

pkg/mcp/localaitools/prompts/skills/system_status.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,12 @@ Use this when the user asks "what's installed?", "what's running?", "show status
44

55
1. Call `system_info` for version, paths, distributed flag, loaded models, installed backends.
66
2. Call `list_installed_models` (no capability filter) for the full installed-model inventory.
7-
3. If `system_info.distributed` is true, also call `list_nodes` and report worker health.
7+
3. If `system_info.distributed` is true, also call `list_nodes` and `list_scheduling`, then report worker health and any per-model scheduling rules.
88
4. Present a concise summary:
99
- **Version & mode** (`distributed: true|false`)
1010
- **Installed models** (count + list, each with name and capabilities)
1111
- **Installed backends** (count + list)
1212
- **Loaded right now** (from `loaded_models`)
1313
- **Workers** (only when distributed)
14+
- **Scheduling rules** (only when distributed)
1415
5. Do not call mutating tools in this skill.

0 commit comments

Comments
 (0)