跳至正文
OpenAgentSkill
浏览已开放 · 目录记录日期 2026-11-21 · 自动更新和账户服务暂时关闭。
演示文稿

officecli

Use when the task involves Office document or standalone image handling such as creating, modifying, or converting PPTX, DOCX, XLSX, Report, or IMG files, and the agent should first check whether officecli supports that workflow before choosing the execution path.

officecli · 已有 AI 审核记录

安装与使用

运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。

npx skills add officecli/officecli --skill officecli

技能说明


name: officecli description: Use when the task involves Office document or standalone image handling such as creating, modifying, or converting PPTX, DOCX, XLSX, Report, or IMG files, and the agent should first check whether officecli supports that workflow before choosing the execution path.

OfficeCLI

Overview

officecli is the OfficeCLI closed-source CLI for Office document and standalone image handling. It may support generation, modification, and format conversion workflows across pptx, docx, xlsx, report, and img, so this skill should first route supported artifact tasks into an officecli capability check before deciding how to execute them.

When To Use This Skill

Use this skill when the task involves:

  • creating a presentation, report deck, proposal, handout, or briefing in pptx
  • creating a written document, memo, draft, or report in docx
  • creating a worksheet, table-based deliverable, or structured sheet in xlsx
  • creating a workbook-backed HTML report from an .xlsx source
  • creating a standalone generated image with img
  • modifying an existing PowerPoint, Word, or Excel file
  • converting Office documents into another output format such as markdown, csv, pdf, or a different Office format
  • deciding whether a requested Office-file workflow is something officecli can handle directly

Do not use this skill for pure Q&A, rough brainstorming with no file output, or source-code maintenance guidance.

Core Product Behavior

  • officecli supports pptx, docx, xlsx, report, and standalone img generation flows
  • pptx enables auto-generated images by default when the content and layout are a good fit
  • --no-images disables image generation for pptx
  • standalone img generation always goes through the OfficeCLI server and requires platform/license config
  • standalone img does not use local llm.image_base_url, llm.image_api_key, or llm.image_model settings
  • standalone img supports ratio=square|landscape|portrait and one reference_image / --reference-image <path-or-url>; charging happens only after a successful image response, using one image generation count in external runtime mode or hosted credits in hosted runtime mode
  • free standalone img usage has a separate 3-per-day bucket from the 10-per-day free document bucket
  • standalone img publishes online by default when publishing is configured; pass publish=false or --no-publish for local-only output
  • when using agent-bridge, agents should treat capabilities/get -> document_generation.pptx.image_support as the authoritative machine-readable contract for PPT image behavior
  • when using agent-bridge, agents should treat capabilities/get -> image_generation as the authoritative machine-readable contract for standalone img behavior
  • when using agent-bridge, agents should treat capabilities/get -> update as the authoritative machine-readable contract for binary update availability
  • if image generation fails for a slide, the PPT should still be generated with that slide downgraded to a no-image version
  • installing the public skill can also attempt to install the officecli binary when it is missing
  • for agent-oriented integrations, officecli agent-bridge now exposes a structured JSON-RPC 2.0 over stdio protocol
  • persistent configuration is handled through officecli config ..., not through an init wizard
  • default runtime mode is visible through officecli config runtime and can be changed with officecli config set-runtime external|hosted
  • hosted runtime mode uses the OfficeCLI platform service and requires a platform OfficeCLI API key with hosted credits; users should not configure or handle aigateway keys directly
  • OfficeCLI should be installed through one channel at a time; if the user already has a Homebrew-installed officecli, do not suggest or run npm install -g officecli on top of it

Authentication

officecli supports three authentication modes:

  • anonymous — free hosted trial with limited daily quotas (default after install)
  • account — full hosted credits after browser login
  • api_key — automation credential set via officecli set-key <api-key>

Preferred authentication flow:

  • run officecli whoami to check the current authentication mode
  • if the mode is anonymous, guide the user to run officecli login to sign in with their account
  • officecli login opens a browser URL with a short device code; it also works on headless or remote shells
  • for CI or automation environments where a browser is unavailable, use officecli set-key <api-key> instead
  • run officecli doctor to diagnose platform connectivity or configuration issues
  • run officecli logout to clear the local account session

The environment check and fix scripts detect anonymous mode and surface a login recommendation automatically. When check-officecli-env.sh reports "auth_mode":"anonymous" with "account_login" in missing_items, the agent should tell the user to run officecli login before proceeding with generation.

Capability Check

When a task involves Office document handling, first check whether the current officecli surface appears to support that workflow.

  • before every office task, run fix-officecli-env.sh once so the agent refreshes the local skill bundle and repairs any missing officecli setup
  • check whether officecli is available before deciding on the final artifact path
  • after the repair step, run check-officecli-env.sh to detect whether officecli is missing, misconfigured, or already ready
  • treat exit code 0 as ready, 10 as repairable, and 20 as blocked
  • inspect the visible CLI surface first, such as officecli --help or relevant subcommand help, before assuming support
  • use the help output and public product description to judge whether the requested create, modify, or convert workflow is actually supported
  • if support is unclear, say that clearly instead of pr
阅读完整来源 ↗