work-agent
БесплатноБез исполняемых скриптовНе проверенUse when the user wants to create, configure, schedule, or run an agent in Treasure Work. Covers AGENTS.md authoring, the `agent_*` MCP tools, on-demand vs…
от treasure-data★ 23 звезды на GitHubОб этом скилле
Agent Creator
Create global agents in Treasure Work — either on-demand (invoked from the UI, chat, or @mention) or scheduled (cron-driven). Both share one AGENTS.md format and lifecycle. Setting a schedule: field is the single switch that turns an agent into a scheduled one.
Agent Location
Each agent is its own directory with a single AGENTS.md:
- Global (the only scope this skill creates):
~/.treasure-work/agents/{name}/AGENTS.md - Workspace (read-only via MCP; edit through the AgentSettings UI):
{workspace}/agents/{name}/AGENTS.md
The directory is the agent's working directory at run time, so the body can reference relative paths and the agent can create supporting files as needed. No subdirectories are required.
Workflow
CRITICAL: Never just create and stop. Always run the agent and iterate until it works.
- Capture intent — what the agent should do, how often (if scheduled), what tools / skills it needs, where results should go.
- Ask the user for notification channels (
notify.on_success/notify.on_failure) before writing. Never assume a Slack channel — always confirm.
- Ask the user for notification channels (
- Create — call
agent_createwithname,body(the system prompt), and the initial frontmatter (description, icon, skills,scheduleif recurring, etc.). New agents default tostatus: draftso scheduled ones don't fire until activated. - Test run — call
agent_run_nowto trigger an immediate run. It returns achatId. - Inspect output — call
chat_readwith thatchatId. Whilein_progress: truethe run is still streaming — poll until it goes false. Read the last assistant turn to confirm the agent did what was intended. - Review — load the
agent-reviewskill for a structure + quality audit. - Iterate — call
agent_updateto patch any field (body, skills,allowed_tools,schedule, …). Re-run withagent_run_now. - Activate — once the test run is clean,
agent_updatewithstatus: active. Scheduled agents start firing on their cron; on-demand agents become first-class in the UI list.
Steps 3–5 are mandatory — an agent is not done until it has been run and reviewed at least once.
AGENTS.md Anatomy
YAML frontmatter + Markdown body. The body is the system prompt the agent sees on every run — write it in the second person as instructions, not as a task description.
---
name: daily-sales-report
display_name: Daily Sales Report
description: Fetch sales data, analyze trends, and post to Slack
icon: 📊
color: blue
status: draft # draft | active | paused | resting
schedule: "0 9 * * 1-5" # 5-field cron, ≥5-minute granularity; omit for on-demand
catch_up: false # true = catch up one missed run after app restart
model: claude-sonnet-4-6 # optional per-agent model override
max_turns: 20
timeout: 600 # seconds, max 3600
autonomous: false # true = Supervisor Agent auto-continues across turns
skills:
- sql-skills:trino
allowed_tools:
- Bash
- Write
- slack_post_message
- slack_upload_file
notify:
on_success: slack:channel-name # or slack:dm
on_failure: slack:channel-name # or slack:dm
---
You are the Daily Sales Report agent. Each weekday morning:
1. Query yesterday's sales (`td_query` against the orders table) and gather revenue, order count, top products.
2. Compare with the previous run by looking at the last successful chat (use `chat_read` if needed).
3. Post a Slack summary; if revenue < $10K, flag the dip in the message.
4. If anything fails, retry once then surface the error via `notify.on_failure`.
Frontmatter field reference
| Field | Purpose |
|---|---|
name (required) |
Slug (lowercase, hyphens / underscores, ≤64 chars). Becomes the directory name. Renaming is not supported — use agent_create + agent_delete to migrate. |
display_name |
Human-readable label shown in the agent list. |
description |
One-line summary for search / UI. |
icon |
Single emoji shown in the agent list. |
color |
UI accent: blue / cyan / green / yellow / red / magenta. |
status |
Lifecycle: draft (default — not listed prominently, never auto-fires) / active (listed, fires schedule) / paused / resting. Only active fires scheduled runs. |
schedule |
5-field cron, ≥5-minute granularity. Setting this turns the agent into a scheduled agent. Empty string clears it. |
catch_up |
When true, one missed run is caught up after the app restarts. |
model |
Per-agent model override (e.g. claude-sonnet-4-6, claude-opus-4-7, claude-haiku-4-5). |
max_turns |
Per-run turn cap. |
timeout |
Per-run timeout in seconds (1–3600). |
autonomous |
When true, runs in Supervisor / autonomous mode (no per-tool prompts). |
skills |
Skill ids to load (max 20). |
guides |
Guide ids to load (max 20). |
allowed_tools |
Tool-permission allowlist. Omit / empty = allow all controllable tools. Read- |
Установить work-agent в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл work-agent?
Use when the user wants to create, configure, schedule, or run an agent in Treasure Work. Covers AGENTS.md authoring, the `agent_*` MCP tools, on-demand vs scheduled agents, lifecycle (draft → active → paused), and chat-based result inspection. Triggers on "create an agent", "set up an agent", "schedule a task", "set up a recurring job", "automate daily report", "cron job", "run X every weekday", etc.
Как установить скилл work-agent?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл work-agent запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
docx
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include…
от AnthropicUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple…
от Anthropicxlsx
Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing…
от Anthropicpptx
Use this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or…
от Anthropic