wps-office

Routes your request to the right WPS office tool when you don't say if you need a document, spreadsheet, or presentation.

Installation
Run `npx skills add "https://github.com/ttnan/wps-agent-skills" --skill "wps-office"` to install this skill, then follow its SKILL.md instructions for my next request.

Paste this into Claude Code, Cursor, or any agent that can run commands.

What this skill does
What it does: Routes your request to the correct WPS application skill. WPS Office includes three different applications: Writer for documents, Spreadsheets for tables, and Presentation for slideshows. This skill figures out which one you need based on what you say. When to use it: Use this when you mention WPS or Kingsoft Office but do not specify whether you want to work with a document, spreadsheet, or presentation. It will direct you to the right tool. Also use it if you need to do tasks that involve more than one WPS application, like putting a chart from a spreadsheet into a presentation.
SKILL.mdShow the author's original SKILL.md (not in English)
---
name: wps-office
description: >
  用户说"用 WPS"但没说是文字/表格/演示时,先用这个路由 skill 判断。
  触发词:WPS、金山办公、金山、wps、et、dps、做文档(未指明类型时)。
  只做路由和跨应用编排,不直接操作 COM。
version: 0.1.0
compatibility: windows + wps-office
---

# wps-office(路由)

很薄的一层:判断该用哪个业务 skill,以及处理跨应用任务。

## 路由规则

| 用户说什么 | 用哪个 skill |
|---|---|
| 文字、报告、合同、docx、wps文件、转PDF(文档) | `wps-writer` |
| 表格、xlsx、et文件、求和、填表、图表 | `wps-spreadsheets` |
| 演示、PPT、pptx、dps文件、幻灯片 | `wps-presentation` |
| 没说清是哪种("帮我做个文档") | 先问;或按文件扩展名判断:`.docx/.wps`→writer,`.xlsx/.et`→spreadsheets,`.pptx/.dps`→presentation |
| 目标是 Microsoft Office 不是 WPS | 不用本仓库的任何 skill,用通用 office skill |

## 跨应用任务

表格出图 → 贴进 PPT 这类组合:两个 skill 的 `Invoke-WpsSession.ps1` 各跑各的会话,
不要试图复用同一个 COM 实例。中间文件放 `$env:TEMP`,例如:

1. `wps-spreadsheets`:用 `scripts/Export-WpsRangePng.ps1`(⚠️ 真机未验证,先跑一遍看 OK)把区域导出到 `$env:TEMP\chart.png`,不要自己手写 CopyPicture
2. `wps-presentation`:`AddPicture("$env:TEMP\chart.png", ...)` 贴进幻灯片

## 用户已经开着 WPS 时

三个业务 skill 的包装器都会检测:附着到用户已开的实例时**跳过 `Quit()`**,
只关闭自己打开的文档/工作簿/文稿。跨应用任务里每个会话独立判断,不互相干扰。

Mirrored from the author's public source. Install counts from the open skills registry.

The systems behind these skills get built for partners every week.

Partner with us