AI Task Hub
Formerly skill-hub-gateway.
Public package boundary:
- Only orchestrates
portal.skill.execute, portal.skill.poll, and portal.skill.presentation.
- Does not exchange
api_key or userToken inside this package.
- Does not handle recharge or payment flows inside this package.
- Assumes host runtime injects short-lived task tokens and attachment URLs.
Chinese documentation: SKILL.zh-CN.md
When to Use This Skill
Use this skill when the user asks to:
- detect people, faces, hands, keypoints, or tags from images
- remove backgrounds or generate cutout/matting results for products or portraits
- transcribe uploaded audio into text (
speech to text, audio transcription)
- generate speech from text input (
text to speech, voice generation)
- convert uploaded files into markdown (
document to markdown)
- start async jobs and check status later (
poll, check job status)
- fetch rendered visual outputs such as
overlay, mask, and cutout
- run embedding or reranking tasks for retrieval workflows
Common Requests
Example requests that should trigger this skill:
- "Detect faces in this image and return bounding boxes."
- "Tag this image and summarize the main objects."
- "Remove the background from this product photo."
- "Create a clean cutout from this portrait image."
- "Transcribe this meeting audio into text."
- "Generate speech from this paragraph."
- "Convert this PDF file into markdown."
- "Start this job now and let me poll the run status later."
- "Fetch overlay and mask files for run_456."
- "Generate embeddings for this text list and rerank the candidates."
Search-Friendly Capability Aliases
vision aliases: face detection, human detection, person detection, image tagging
background aliases: remove background, background removal, cutout, matting, product-cutout
asr aliases: speech to text, audio transcription, transcribe audio
tts aliases: text to speech, voice generation, speech synthesis
markdown_convert aliases: document to markdown, file to markdown, markdown conversion
poll aliases: check job status, poll long-running task, async run status
presentation aliases: rendered output, overlay, mask, cutout files
embeddings/reranker aliases: vectorization, semantic vectors, relevance reranking
Runtime Contract
Default API base URL: https://gateway-api.binaryworks.app
Action to endpoint mapping:
portal.skill.execute -> POST /agent/skill/execute
portal.skill.poll -> GET /agent/skill/runs/:run_id
portal.skill.presentation -> GET /agent/skill/runs/:run_id/presentation
Auth Contract (Host-Managed)
Every request must include:
X-Agent-Task-Token: <jwt_or_paseto>
Recommended token claims:
sub (user_id)
agent_uid
conversation_id
scope (execute|poll|presentation)
exp
jti
CLI argument order for scripts/skill.mjs:
[agent_task_token] <action> <payload_json> [base_url]
- If token arg is omitted, script reads
AGENT_TASK_TOKEN from environment.
- Host runtime should refresh and inject short-lived
AGENT_TASK_TOKEN automatically to avoid user-facing auth friction.
Payload Contract
portal.skill.execute: payload requires capability and input.
payload.request_id is optional and passed through.
portal.skill.poll and portal.skill.presentation: payload requires run_id.
portal.skill.presentation supports include_files (defaults to true).
Attachment normalization:
- Prefer explicit
image_url / audio_url / file_url.
attachment.url is mapped to target media field by capability.
- Local
file_path is disabled in the published package.
- Host must upload chat attachments first, then pass URL fields.
- Example host upload endpoint:
/api/blob/upload-file.
Error Contract
- Preserve gateway envelope:
request_id, data, error.
- Preserve
POINTS_INSUFFICIENT and pass through error.details.recharge_url.
Bundled Files
scripts/skill.mjs
scripts/agent-task-auth.mjs
scripts/base-url.mjs
scripts/attachment-normalize.mjs
scripts/telemetry.mjs (compatibility shim)
references/capabilities.json
references/openapi.json
SKILL.zh-CN.md
1---2name: ai-task-hub3description: AI task hub for image analysis, background removal, speech-to-text, text-to-speech, markdown conversion, and async execute/poll/presentation orchestration. Use when users need hosted AI outcomes while host runtime manages identity, credits, payment, and risk control.4---56# AI Task Hub78Formerly `skill-hub-gateway`.910Public package boundary:1112- Only orchestrates `portal.skill.execute`, `portal.skill.poll`, and `portal.skill.presentation`.13- Does not exchange `api_key` or `userToken` inside this package.14- Does not handle recharge or payment flows inside this package.15- Assumes host runtime injects short-lived task tokens and attachment URLs.1617Chinese documentation: `SKILL.zh-CN.md`1819## When to Use This Skill2021Use this skill when the user asks to:2223- detect people, faces, hands, keypoints, or tags from images24- remove backgrounds or generate cutout/matting results for products or portraits25- transcribe uploaded audio into text (`speech to text`, `audio transcription`)26- generate speech from text input (`text to speech`, `voice generation`)27- convert uploaded files into markdown (`document to markdown`)28- start async jobs and check status later (`poll`, `check job status`)29- fetch rendered visual outputs such as `overlay`, `mask`, and `cutout`30- run embedding or reranking tasks for retrieval workflows3132## Common Requests3334Example requests that should trigger this skill:3536- "Detect faces in this image and return bounding boxes."37- "Tag this image and summarize the main objects."38- "Remove the background from this product photo."39- "Create a clean cutout from this portrait image."40- "Transcribe this meeting audio into text."41- "Generate speech from this paragraph."42- "Convert this PDF file into markdown."43- "Start this job now and let me poll the run status later."44- "Fetch overlay and mask files for run_456."45- "Generate embeddings for this text list and rerank the candidates."4647## Search-Friendly Capability Aliases4849- `vision` aliases: face detection, human detection, person detection, image tagging50- `background` aliases: remove background, background removal, cutout, matting, product-cutout51- `asr` aliases: speech to text, audio transcription, transcribe audio52- `tts` aliases: text to speech, voice generation, speech synthesis53- `markdown_convert` aliases: document to markdown, file to markdown, markdown conversion54- `poll` aliases: check job status, poll long-running task, async run status55- `presentation` aliases: rendered output, overlay, mask, cutout files56- `embeddings/reranker` aliases: vectorization, semantic vectors, relevance reranking5758## Runtime Contract5960Default API base URL: `https://gateway-api.binaryworks.app`6162Action to endpoint mapping:6364- `portal.skill.execute` -> `POST /agent/skill/execute`65- `portal.skill.poll` -> `GET /agent/skill/runs/:run_id`66- `portal.skill.presentation` -> `GET /agent/skill/runs/:run_id/presentation`6768## Auth Contract (Host-Managed)6970Every request must include:7172- `X-Agent-Task-Token: <jwt_or_paseto>`7374Recommended token claims:7576- `sub` (user_id)77- `agent_uid`78- `conversation_id`79- `scope` (`execute|poll|presentation`)80- `exp`81- `jti`8283CLI argument order for `scripts/skill.mjs`:8485- `[agent_task_token] <action> <payload_json> [base_url]`86- If token arg is omitted, script reads `AGENT_TASK_TOKEN` from environment.87- Host runtime should refresh and inject short-lived `AGENT_TASK_TOKEN` automatically to avoid user-facing auth friction.8889## Payload Contract9091- `portal.skill.execute`: payload requires `capability` and `input`.92- `payload.request_id` is optional and passed through.93- `portal.skill.poll` and `portal.skill.presentation`: payload requires `run_id`.94- `portal.skill.presentation` supports `include_files` (defaults to `true`).9596Attachment normalization:9798- Prefer explicit `image_url` / `audio_url` / `file_url`.99- `attachment.url` is mapped to target media field by capability.100- Local `file_path` is disabled in the published package.101- Host must upload chat attachments first, then pass URL fields.102- Example host upload endpoint: `/api/blob/upload-file`.103104## Error Contract105106- Preserve gateway envelope: `request_id`, `data`, `error`.107- Preserve `POINTS_INSUFFICIENT` and pass through `error.details.recharge_url`.108109## Bundled Files110111- `scripts/skill.mjs`112- `scripts/agent-task-auth.mjs`113- `scripts/base-url.mjs`114- `scripts/attachment-normalize.mjs`115- `scripts/telemetry.mjs` (compatibility shim)116- `references/capabilities.json`117- `references/openapi.json`118- `SKILL.zh-CN.md`