Index of every page on this site: llms.txt
All skills
surgepix avatar

/surgepix-ppt-translate

@eb31c56
Run it yourself

Translate a PowerPoint file (PPT/PPTX only) to a target language via SurgePix API and return a download URL. Use when the user says "translate ppt", "翻译PPT", "PPT翻译", "pptx translate", or wants a deck localized. Language: always pass --language as the target (ja / Japanese / 日语 / en / zh, etc.). Do NOT use for pdf/docx — unsupported. Output rule: show ONLY the download URL; NEVER fabricate links.

Use this Skill: https://skilld.dev/gh/surgepix/agent-skills/surgepix-ppt-translate

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈109 tokens for metadata: the name and description. ≈801 when used: this file.

Description uses 5.3% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈424 characters, or 5.3%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

SurgePix PPT / PPTX Translate

Translate a .ppt / .pptx deck to a target language and return the translated file download URL. PDF and DOCX are not supported.

Language consistency

--language is the target language for the translated deck, not the agent's reply language. Free-text values are accepted (e.g. ja, Japanese, 日语).

Priority Rule
1 User names a target ("翻译成日文", "to English") → pass that as --language
2 Ambiguous → ask which target language
3 Never silently pick an unrelated default
  • Reply to the user in the same language they used in their request.

When to use

  • User says "翻译PPT", "PPT翻译", "translate ppt", "translate pptx", "把幻灯片翻成英文"
  • User has a local .ppt/.pptx or a URL to one

Prerequisites

  • Node.js >= 18
  • SURGEPIX_API_KEY and SURGEPIX_BASE_URL configured (see Step 0)

What the Skill Does

Action Description
Translate PPT Upload local file if needed, then call translate API
Reject non-PPT Fail early on pdf/docx (and other extensions)
Async / sync Default poll for result; --nowait true returns taskId
Download Return download URL of the translated pptx

Multi-page decks can take a long time — prefer --nowait true and surgepix-query-task for large files.


Setup

Requirement: Set SURGEPIX_API_KEY and SURGEPIX_BASE_URL via surgepix-setup. Do not ask the user to paste the API key into chat.

Script: <skills-dir>/surgepix-ppt-translate/scripts/ppt_translate.mjs.


Usage Examples

Local file → Japanese (sync):

node "<skills-dir>/surgepix-ppt-translate/scripts/ppt_translate.mjs" \
  ./deck.pptx \
  --language Japanese

URL + async (recommended for long decks):

node "<skills-dir>/surgepix-ppt-translate/scripts/ppt_translate.mjs" \
  --path "https://example.com/files/deck.pptx" \
  --language zh \
  --nowait true
# Then query with surgepix-query-task

Workflow

Step 0: Check environment

node "<skills-dir>/surgepix-setup/scripts/check_env.mjs"

Step 1: Collect inputs

  • Source: local .ppt/.pptx or HTTPS URL
  • Target language: required (--language)
  • If user offers pdf/docx → refuse and ask for ppt/pptx

Step 2: Run

node "<skills-dir>/surgepix-ppt-translate/scripts/ppt_translate.mjs" \
  "<path-or-url>" \
  --language "<target>" \
  [--session-id <id>] \
  [--nowait <true|false>]

Step 3: Present result

  • Show only API download / taskId
  • Never invent URLs; never expose tokens

Parameters

Parameter Required Default Description
<path-or-url> / --path Yes — Local ppt/pptx or URL
--language Yes — Target language free text
--session-id No auto Session for iteration
--nowait No false true = async taskId

Notes

  • Only .ppt / .pptx. Not pdf/docx.
  • Local files are uploaded by the script — never pass raw local paths to the API.
  • Missing env → surgepix-setup.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 warning1mo3 checks · Risk SAFE
  • Gen Agent Trust Hub1mo

    This skill allows translating PowerPoint presentations (.ppt and .pptx) using the SurgePix API. It supports local file uploads and remote URLs, requiring a user-provided API key and base URL for operation. The skill follows secure configuration practices and provides clear instructions for its use.

  • Socket1mo

    1 alert: gptAnomaly

  • Snyk1mo

    Risk: LOW · No issues

Signed by skilld at eb31c56. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 4 weeks ago.

Activeupdated 3 months ago

README badge

README badge for surgepix/agent-skills/surgepix-ppt-translate