[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M78DAKJAM0Z3MGM2738BARH8":3,"skill-same:01M78DAKJAM0Z3MGM2738BARH8":43},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":23,"commitSha":24,"skillDirectory":25,"forksCount":13,"repositoryHtmlUrl":26,"repositoryHomepageUrl":6,"ownerHtmlUrl":27,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":28,"install":29,"resources":42},"01M78DAKJAM0Z3MGM2738BARH8","officecli",null,"Create, analyze, proofread, and modify Office documents (.docx, .xlsx, .pptx) using the officecli CLI tool. Use when the user wants to create, inspect, check formatting, find issues, add charts, or modify Office documents.","Grong\u002Fopenhub-client","Grong","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F4919858?v=4","01M78DABC3WYM9Z67DC6JSDGQF","01M78DABD6RAC4TNESYHD8WT4B",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fcrates\u002Fbackend\u002Fopenhub-app\u002Fassets\u002Fbuiltin-skills\u002Fauto-inject\u002Fofficecli\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: officecli\ndescription: Create, analyze, proofread, and modify Office documents (.docx, .xlsx, .pptx) using the officecli CLI tool. Use when the user wants to create, inspect, check formatting, find issues, add charts, or modify Office documents.\n---\n\n# officecli\n\nAI-friendly CLI for .docx, .xlsx, .pptx. Single binary, no dependencies, no Office installation needed.\n\n## Install\n\nIf `officecli` is not installed:\n\n```bash\n# macOS \u002F Linux\ncurl -fsSL https:\u002F\u002Fd.officecli.ai\u002Finstall.sh | bash\n\n# Windows (PowerShell)\nirm https:\u002F\u002Fd.officecli.ai\u002Finstall.ps1 | iex\n```\n\nVerify with `officecli --version`. If still not found after install, open a new terminal.\n\n---\n\n## Strategy\n\n**L1 (read) → L2 (DOM edit) → L3 (raw XML)**. Always prefer higher layers. Add `--json` for structured output.\n\n**Before doc work, check Specialized Skills** (bottom of this file). Fundraising decks, academic papers, financial models, dashboards, and Morph animations need their own skill loaded first — `load_skill` once, then proceed.\n\n---\n\n## Help System (IMPORTANT)\n\n**When unsure about property names, value formats, or command syntax, ALWAYS run help instead of guessing.** One help query beats guess-fail-retry loops.\n\n`officecli help` ≡ `officecli --help`, and `officecli \u003Ccmd> --help` ≡ `officecli help \u003Ccmd>` — same content.\n\n```bash\nofficecli help                                  # All commands + global options + schema entry points\nofficecli help docx                             # List all docx elements\nofficecli help docx paragraph                   # Full schema: properties, aliases, examples, readbacks\nofficecli help docx set paragraph               # Verb-filtered: only props usable with `set`\nofficecli help docx paragraph --json            # Structured schema (machine-readable)\n```\n\nFormat aliases: `word`→`docx`, `excel`→`xlsx`, `ppt`\u002F`powerpoint`→`pptx`. Verbs: `add`, `set`, `get`, `query`, `remove`. MCP exposes the same schema via `{\"command\":\"help\",\"format\":\"docx\",\"type\":\"paragraph\"}`.\n\n---\n\n## Performance: Resident Mode\n\n**Every command auto-starts a resident on first access** (60s idle timeout) — file-lock conflicts are automatically avoided. Explicit `open`\u002F`close` is still recommended for longer sessions (12min idle):\n```bash\nofficecli open report.docx       # explicitly keep in memory\nofficecli set report.docx ...    # no file I\u002FO overhead\nofficecli close report.docx      # save and release\n```\n\nOpt out of auto-start: `OFFICECLI_NO_AUTO_RESIDENT=1`.\n\n---\n\n## Quick Start\n\n**PPT:**\n```bash\nofficecli create slides.pptx\nofficecli add slides.pptx \u002F --type slide --prop title=\"Q4 Report\" --prop background=1A1A2E\nofficecli add slides.pptx '\u002Fslide[1]' --type shape --prop text=\"Revenue grew 25%\" --prop x=2cm --prop y=5cm --prop font=Arial --prop size=24 --prop color=FFFFFF\n```\n\n**Word:**\n```bash\nofficecli create report.docx\nofficecli add report.docx \u002Fbody --type paragraph --prop text=\"Executive Summary\" --prop style=Heading1\nofficecli add report.docx \u002Fbody --type paragraph --prop text=\"Revenue increased by 25% year-over-year.\"\n```\n\n**Excel:**\n```bash\nofficecli create data.xlsx\nofficecli set data.xlsx \u002FSheet1\u002FA1 --prop value=\"Name\" --prop bold=true\nofficecli set data.xlsx \u002FSheet1\u002FA2 --prop value=\"Alice\"\n```\n\n---\n\n## L1: Create, Read & Inspect\n\n```bash\nofficecli create \u003Cfile>               # Create blank .docx\u002F.xlsx\u002F.pptx (type from extension)\nofficecli view \u003Cfile> \u003Cmode>          # outline | stats | issues | text | annotated | html\nofficecli get \u003Cfile> \u003Cpath> --depth N # Get a node and its children [--json]\nofficecli query \u003Cfile> \u003Cselector>     # CSS-like query\nofficecli validate \u003Cfile>             # Validate against OpenXML schema\n```\n\n### view modes\n\n| Mode | Description | Useful flags |\n|------|-------------|-------------|\n| `outline` | Document structure | |\n| `stats` | Statistics (pages, words, shapes) | |\n| `issues` | Formatting\u002Fcontent\u002Fstructure problems | `--type format\\|content\\|structure`, `--limit N` |\n| `text` | Plain text extraction | `--start N --end N`, `--max-lines N` |\n| `annotated` | Text with formatting annotations | |\n| `html` | Static HTML snapshot — same renderer as `watch`, no server needed | `--browser`, `--page N` (docx), `--start N --end N` (pptx) |\n\nUse `view html` for one-shot snapshots (CI artifacts, archival, diffing); use `watch` when you need live refresh or browser-side click-to-select.\n\n### get\n\nAny XML path via element localName. Use `--depth N` to expand children. Add `--json` for structured output. Default text output is grep-friendly: `path (type) \"text\" key=val key=val ...`\n\n```bash\nofficecli get report.docx '\u002Fbody\u002Fp[3]' --depth 2 --json\nofficecli get slides.pptx '\u002Fslide[1]' --depth 1          # list all shapes on slide 1\nofficecli get data.xlsx '\u002FSheet1\u002FB2' --json\n```\n\n### Stable ID Addressing\n\nElements with stable IDs return `@attr=value` paths instead of positional indices. Prefer these in multi-step workflows — positional indices shift on insert\u002Fdelete, stable IDs do not.\n\n```\n\u002Fslide[1]\u002Fshape[@id=550950021]                    # PPT shape\n\u002Fslide[1]\u002Ftable[@id=1388430425]\u002Ftr[1]\u002Ftc[2]       # PPT table\n\u002Fbody\u002Fp[@paraId=1A2B3C4D]                         # Word paragraph\n\u002Fcomments\u002Fcomment[@commentId=1]                    # Word comment\n```\n\nPPT also accepts `@name=` (e.g. `shape[@name=Title 1]`), with morph `!!` prefix awareness. Elements without stable IDs (slide, run, tr\u002Ftc, row) fall back to positional indices.\n\n### query\n\nCSS-like selectors: `[attr=value]`, `[attr!=value]`, `[attr~=text]`, `[attr>=value]`, `[attr\u003C=value]`, `:contains(\"text\")`, `:empty`, `:has(formula)`, `:no-alt`.\n\n```bash\nofficecli query report.docx 'paragraph[style=Normal] > run[font!=Arial]'\nofficecli query slides.pptx 'shape[fill=FF0000]'\n```\n\n---\n\n## Watch & Interactive Selection\n\nLive HTML preview that auto-refreshes on every file change. Browsers can click \u002F shift-click \u002F box-drag to select shapes; the CLI can read the current browser selection and act on it.\n\n```bash\nofficecli watch \u003Cfile> [--port N]      # Start preview server (default port 26315)\nofficecli unwatch \u003Cfile>               # Stop\nofficecli goto \u003Cfile> \u003Cpath>           # Scroll watching browser(s) to element (docx: p \u002F table \u002F tr \u002F tc)\n```\n\nOpen the printed `http:\u002F\u002Flocalhost:N` URL. Click to select; shift\u002Fcmd\u002Fctrl+click to multi-select; drag from empty space to box-select. PPT\u002FWord use blue outline; Excel uses native-style green selection (double-click cell to edit inline; drag a chart to reposition).\n\n### `get \u003Cfile> selected` — read what the user clicked\n\n```bash\nofficecli get \u003Cfile> selected [--json]\n```\n\nReturns DocumentNodes for whatever is currently selected. Empty result if nothing selected. Exit code != 0 if no watch is running.\n\n```bash\n# User clicks shapes in the browser, then asks \"make these red\"\nPATHS=$(officecli get deck.pptx selected --json | jq -r '.data.Results[].path')\nfor p in $PATHS; do officecli set deck.pptx \"$p\" --prop fill=FF0000; done\n```\n\n### Key properties\n\n- **Selection survives file edits.** Paths use stable `@id=` form.\n- **All connected browsers share one selection.** Last-write-wins.\n- **Same-file single-watch.** A given file can have only one watch process at a time.\n- **Group shapes select as a whole.** Drilling into individual children of a group is not supported in v1.\n- **Coverage:** `.pptx` shapes\u002Fpictures\u002Ftables\u002Fcharts\u002Fconnectors\u002Fgroups; `.docx` top-level paragraphs and tables. Inherited layout\u002Fmaster decorations and Word nested elements (table cells, run-level) are not addressable. **`.xlsx` does not emit `data-path`** — `mark`\u002F`selection` on xlsx always resolve `stale=true` (v2 candidate).\n\n### Marks — edit proposals waiting for review\n\nUse `mark` when changes need human review BEFORE they hit the file. Marks live in the watch process only; a separate `set` pipeline applies accepted ones. For one-shot changes use `set` directly; for permanent file annotations use `add --type comment` (Word native).\n\n```bash\nofficecli mark \u003Cfile> \u003Cpath> [--prop find=... color=... note=... tofix=... regex=true] [--json]\nofficecli unmark \u003Cfile> [--path \u003Cp> | --all] [--json]\nofficecli get-marks \u003Cfile> [--json]\n```\n\nProps: `find` (literal or regex when `regex=true`; raw form `find='r\"[abc]\"'`), `color` (hex \u002F `rgb(...)` \u002F 22 named whitelist), `note`, `tofix` (drives apply pipeline). **Path** must be `data-path` format from watch HTML — see subskills for full pipeline.\n\n---\n\n## L2: DOM Operations\n\n### set — modify properties\n\n```bash\nofficecli set \u003Cfile> \u003Cpath> --prop key=value [--prop ...]\n```\n\n**Any XML attribute is settable** via element path (found via `get --depth N`) — even attributes not currently present. Without `find=`, `set` applies format to the entire element.\n\n**Value formats:**\n\n| Type | Format | Examples |\n|------|--------|---------|\n| Colors | Hex (with\u002Fwithout `#`), named, RGB, theme | `FF0000`, `#FF0000`, `red`, `rgb(255,0,0)`, `accent1`..`accent6` |\n| Spacing | Unit-qualified | `12pt`, `0.5cm`, `1.5x`, `150%` |\n| Dimensions | EMU or suffixed | `914400`, `2.54cm`, `1in`, `72pt`, `96px` |\n\n**Dotted-attr aliases** — `font.\u003Cattr>` forms accepted on shape\u002Frun\u002Fparagraph\u002Ftable\u002Frow\u002Fcell\u002Fsection\u002Fstyles, e.g. `--prop font.color=red --prop font.bold=true --prop font.size=14pt`. Run `officecli help \u003Cfmt> \u003Celement>` for the full list.\n\n### find — format or replace matched text\n\nUse `find=` with `set` to target specific text for formatting or replacement. Format props are separate `--prop` flags — do NOT nest them.\n\n```bash\n# Format matched text (auto-splits runs)\nofficecli set doc.docx '\u002Fbody\u002Fp[1]' --prop find=weather --prop bold=true --prop color=red\n\n# Regex matching\nofficecli set doc.docx '\u002Fbody\u002Fp[1]' --prop 'find=\\d+%' --prop regex=true --prop color=red\n\n# Replace text (use `\u002F` for whole-document scope)\nofficecli set doc.docx \u002F --prop find=draft --prop replace=final\n\n# PPT — same syntax, different paths\nofficecli set slides.pptx \u002F --prop find=draft --prop replace=final\n```\n\n**Path controls search scope:** `\u002F` = whole document, `\u002Fbody\u002Fp[1]` or `\u002Fslide[N]\u002Fshape[M]` = specific element, `\u002Fheader[1]` \u002F `\u002Ffooter[1]` = headers\u002Ffooters.\n\n**Notes:**\n- Case-sensitive by default. Case-insensitive: `--prop 'find=(?i)error' --prop regex=true`\n- Matches work across run boundaries\n- No match = silent success. `--json` includes `\"matched\": N`\n- **Excel:** only `find` + `replace` supported (no find + format props)\n\n### add — add elements or clone\n\n```bash\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> [--prop ...]\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> --after \u003Cpath> [--prop ...]   # insert after anchor\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> --before \u003Cpath> [--prop ...]  # insert before anchor\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> --index N [--prop ...]        # 0-based position (legacy)\nofficecli add \u003Cfile> \u003Cparent> --from \u003Cpath>                               # clone existing element\n```\n\n`--after`, `--before`, `--index` are mutually exclusive. No position flag = append to end.\n\n**Element types (with aliases):**\n\n| Format | Types |\n|--------|-------|\n| **pptx** | slide (incl. hidden), shape (textbox — font.latin\u002Fea\u002Fcs, direction=rtl), picture (SVG, brightness\u002Fcontrast\u002Fglow\u002Fshadow), chart (direction=rtl), table (cell direction=rtl), row (tr), connector (connection\u002Fline), group, video (audio\u002Fmedia, trim), equation (formula\u002Fmath), notes (direction=rtl, lang), comment (RTL via U+200F bidi mark; full CRUD via \u002Fslide[N]\u002Fcomment[M]), paragraph (para), run, zoom (slidezoom), ole (oleobject\u002Fobject\u002Fembed), placeholder (phType=title\u002Fbody\u002Fsubtitle\u002Ffooter\u002F...). slideLayout\u002FslideMaster direction inheritance. |\n| **docx** | paragraph (para — direction\u002Ffont.latin\u002Fea\u002Fcs, bold.cs\u002Fitalic.cs\u002Fsize.cs for RTL\u002FCJK; lang.latin\u002Fea\u002Fcs BCP-47 tags on run; wordWrap toggle), run, table (direction=rtl → bidiVisual), row (tr), cell (td), image (picture\u002Fimg — SVG supported), header (direction), footer (direction), section (pageNumFmt full ECMA-376 enum incl. Hindi\u002FArabic\u002FThai\u002FCJK numerals; direction=rtl on Add\u002FSet; rtlGutter; pgBorders=box shorthand), bookmark, comment, footnote, endnote, formfield (text\u002Fcheckbox\u002Fdropdown), sdt (contentcontrol), chart, equation, field (28 types incl. mergefield\u002Fref\u002Fseq\u002Fstyleref\u002Fdocproperty\u002Fif), hyperlink, style (direction round-trip), toc, watermark, break (pagebreak\u002Fcolumnbreak), ole, **num \u002F abstractNum \u002F lvl** (numbering\u002Flist system), **tab** (paragraph or paragraph\u002Ftable style tab stops). docDefaults.rtl document-wide override; `get \u002F` exposes `locale`. Document protection: `set \u002F --prop protection=forms\\|readOnly\\|comments\\|trackedChanges\\|none` |\n| **xlsx** | sheet (visible\u002Fhidden\u002FveryHidden, print margins, printTitleRows\u002FCols, rightToLeft sheetView, cascade-aware rename), row, cell (type=richtext+runs, merge=range\u002Fsweep, direction=rtl, phonetic guide on add), chart (direction=rtl on per-axis txPr \u002F title; incl. pareto), image (picture — SVG), comment (direction=rtl), table (listobject), namedrange (definedname, volatile, `[@name=X]` selector), pivottable (pivot, calculatedField), sparkline, validation (datavalidation), autofilter, shape, textbox, databar\u002Fcolorscale\u002Ficonset\u002Fformulacf\u002FcellIs\u002FtopN\u002FaboveAverage (conditional formatting), ole, csv (tsv). Query supports `merge`\u002F`mergedrange` aliases for `mergeCell`. Workbook: password. `value=\"=SUM(...)\"` auto-detects as formula. Chart\u002Fpicture\u002Fshape\u002Fslicer accept `anchor=A1:E10`. |\n\n### Pivot tables (xlsx)\n\n```bash\nofficecli add data.xlsx \u002FSheet1 --type pivottable \\\n  --prop source=\"Sheet1!A1:E100\" --prop rows=Region,Category \\\n  --prop cols=Year --prop values=\"Sales:sum,Qty:count\" \\\n  --prop grandTotals=rows --prop subtotals=off --prop sort=asc\n```\n\nKey props: `rows`, `cols`, `values` (Field:func[:showDataAs]), `filters`, `source`, `position`, `layout` (compact\u002Foutline\u002Ftabular), `repeatLabels`, `blankRows`, `aggregate`, `showDataAs` (percent_of_total\u002Frow\u002Fcol, running_total), `grandTotals`, `subtotals`, `sort`. Aggregators: sum, count, average, max, min, product, stdDev, stdDevp, var, varp, countNums. Date columns auto-group. Run `officecli help xlsx pivottable` for full schema.\n\n### Document-level properties (all formats)\n\n```bash\nofficecli set doc.docx \u002F --prop docDefaults.font=Arial --prop docDefaults.fontSize=11pt\nofficecli set doc.docx \u002F --prop protection=forms --prop evenAndOddHeaders=true\nofficecli set data.xlsx \u002F --prop calc.mode=manual --prop calc.refMode=r1c1\nofficecli set slides.pptx \u002F --prop defaultFont=Arial --prop show.loop=true --prop print.what=handouts\n```\n\nRun `officecli help \u003Cformat> \u002F` for all document-level properties (docDefaults, docGrid, CJK spacing, calc, print, show, theme, extended).\n\n### Sort (xlsx)\n\n```bash\nofficecli set data.xlsx \u002FSheet1 --prop sort=\"C desc\" --prop sortHeader=true\nofficecli set data.xlsx '\u002FSheet1\u002FA1:D100' --prop sort=\"A asc\" --prop sortHeader=true\n```\n\nFormat: `COL DIR[, COL DIR ...]`. Rejects ranges with merged cells or formulas. Sidecar metadata (hyperlinks, comments, conditional formatting, drawings) follows rows automatically.\n\n### Text-anchored insert (`--after find:X` \u002F `--before find:X`)\n\nLocate an insertion point by text match within a paragraph. Inline types (run, picture, hyperlink) insert within the paragraph; block types (table, paragraph) auto-split it. PPT only supports inline.\n\n```bash\n# Word: inline run after matched text\nofficecli add doc.docx '\u002Fbody\u002Fp[1]' --type run --after find:weather --prop text=\" (sunny)\"\n\n# Word: block table after matched text (auto-splits paragraph)\nofficecli add doc.docx '\u002Fbody\u002Fp[1]' --type table --after \"find:First sentence.\" --prop rows=2 --prop cols=2\n```\n\n### Clone\n\n`officecli add \u003Cfile> \u002F --from '\u002Fslide[1]'` — copies with all cross-part relationships.\n\n### move, swap, remove\n\n```bash\nofficecli move \u003Cfile> \u003Cpath> [--to \u003Cparent>] [--index N] [--after \u003Cpath>] [--before \u003Cpath>]\nofficecli swap \u003Cfile> \u003Cpath1> \u003Cpath2>\nofficecli remove \u003Cfile> '\u002Fbody\u002Fp[4]'\n```\n\nWhen using `--after` or `--before`, `--to` can be omitted — the target container is inferred from the anchor.\n\n### batch — multiple operations in one save cycle\n\nContinues on error by default (returns exit 1 if any item fails). Use `--stop-on-error` to abort on the first failure. `--force` is the docx-protection bypass.\n\n`officecli dump \u003Cfile.docx> [\u003Cpath>]` emits a replayable batch JSON for round-trip. Path defaults to `\u002F` (whole document); pass a subtree path (`\u002Fbody`, `\u002Fbody\u002Fp[N]`, `\u002Fbody\u002Ftbl[N]`, `\u002Ftheme`, `\u002Fsettings`, `\u002Fnumbering`, `\u002Fstyles`) to scope the dump. `officecli refresh \u003Cfile.docx>` recalculates TOC page numbers \u002F PAGE \u002F cross-references after replay (Word backend on Windows; headless-HTML fallback elsewhere).\n\n```bash\necho '[\n  {\"command\":\"set\",\"path\":\"\u002FSheet1\u002FA1\",\"props\":{\"value\":\"Name\",\"bold\":\"true\"}},\n  {\"command\":\"set\",\"path\":\"\u002FSheet1\u002FB1\",\"props\":{\"value\":\"Score\",\"bold\":\"true\"}}\n]' | officecli batch data.xlsx --json\n\nofficecli batch data.xlsx --commands '[{\"op\":\"set\",\"path\":\"\u002FSheet1\u002FA1\",\"props\":{\"value\":\"Done\"}}]' --json\nofficecli batch data.xlsx --input updates.json --force --json\n```\n\nSupports: `add`, `set`, `get`, `query`, `remove`, `move`, `swap`, `view`, `raw`, `raw-set`, `validate`. Fields: `command` (or `op`), `path`, `parent`, `type`, `from`, `to`, `index`, `after`, `before`, `props`, `selector`, `mode`, `depth`, `part`, `xpath`, `action`, `xml`.\n\n---\n\n## L3: Raw XML\n\nUse when L2 cannot express what you need. No xmlns declarations needed — prefixes auto-registered.\n\n```bash\nofficecli raw \u003Cfile> \u003Cpart>                          # view raw XML\nofficecli raw-set \u003Cfile> \u003Cpart> --xpath \"...\" --action replace --xml '\u003Cw:p>...\u003C\u002Fw:p>'\nofficecli add-part \u003Cfile> \u003Cparent>                   # create new document part (returns rId)\n```\n\n`raw-set` actions: `append`, `prepend`, `insertbefore`, `insertafter`, `replace`, `remove`, `setattr`. Run `officecli help \u003Cformat> raw` for available parts.\n\n---\n\n## Common Pitfalls\n\n| Pitfall | Correct Approach |\n|---------|-----------------|\n| `--name \"foo\"` | Use `--prop name=\"foo\"` — all attributes go through `--prop` |\n| Unquoted `[N]` paths in zsh\u002Fbash | Always quote: `'\u002Fslide[1]'` or `\"\u002Fslide[1]\"` (shell glob-expands brackets) |\n| PPT `shape[1]` for content | `shape[1]` is typically the title placeholder. Use `shape[2]+` for content shapes |\n| `\u002Fshape[myname]` | Name indexing not supported. Use numeric index or `@name=` (PPT only) |\n| Guessing property names | Run `officecli help \u003Cformat> \u003Celement>` to see exact names |\n| Modifying an open file | Close the file in PowerPoint\u002FWPS first |\n| `\\n` in shell strings | Use `\\\\n` for newlines in `--prop text=\"...\"` |\n| `$` in shell text | `--prop text=\"$15M\"` strips `$15`. Use single quotes: `--prop text='$15M'`, or heredoc batch |\n\n---\n\n## Specialized Skills\n\n`officecli load_skill \u003Cname>` — output is a SKILL.md, follow its rules.\n\n**Loading rule**:\n- Pick the most specific match in \"When to use\"; if none fits, load the format default (`word` \u002F `pptx` \u002F `excel`).\n- Scenes already contain the format default's rules — load **one** skill per artifact, never stack.\n- Loaded rules persist across turns; don't re-load each reply.\n- Two distinct artifacts → two separate loads.\n\n### Word (.docx)\n\n| Name | When to use |\n|------|-------------|\n| `word` | Reports, letters, memos, proposals, generic documents |\n| `academic-paper` | Journal \u002F conference \u002F thesis: APA \u002F Chicago \u002F IEEE \u002F MLA citations, equations, SEQ + PAGEREF cross-refs, multi-column journal layout, bibliography. NOT for business reports or letters (route those to `word`) |\n\n### PowerPoint (.pptx)\n\n| Name | When to use |\n|------|-------------|\n| `pptx` | Generic decks: board reviews, sales decks, all-hands, product launches |\n| `pitch-deck` | **Fundraising only** — seed \u002F Series A-C \u002F SAFE \u002F convertible \u002F strategic raise. NOT for sales \u002F product \u002F board decks (route those to `pptx`) |\n| `morph-ppt` | Cinematic Morph-animated presentations. NOT for static decks (route those to `pptx`) |\n| `morph-ppt-3d` | 3D Morph: GLB models, camera moves, depth. NOT for 2D-only Morph (route those to `morph-ppt`) |\n\n### Excel (.xlsx)\n\n| Name | When to use |\n|------|-------------|\n| `excel` | Generic workbooks, formulas, pivots, trackers |\n| `financial-model` | Financial models, scenarios, projections. NOT for general data analysis (route those to `excel`) |\n| `data-dashboard` | CSV\u002Ftabular data → KPI \u002F analytics \u002F executive dashboards with charts and sparklines. NOT for raw data tracking (route those to `excel`) |\n\nExample: a fundraising deck task → `officecli load_skill pitch-deck` → use the printed rules.\n\n---\n\n## Notes\n\n- Paths are **1-based** (XPath convention): `'\u002Fbody\u002Fp[3]'` = third paragraph\n- `--index` is **0-based** (array convention): `--index 0` = first position\n- **Excel exception**: for `add --type row` and `add --type col`, `--index N` is **1-based** (matches OOXML RowIndex \u002F column letter index). `--index 5` inserts at row 5 \u002F column 5.\n- After modifications, verify with `validate` and\u002For `view issues`\n- **When unsure**, run `officecli help \u003Cformat> \u003Celement>` instead of guessing\n","# officecli\n\nAI-friendly CLI for .docx, .xlsx, .pptx. Single binary, no dependencies, no Office installation needed.\n\n## Install\n\nIf `officecli` is not installed:\n\n```bash\n# macOS \u002F Linux\ncurl -fsSL https:\u002F\u002Fd.officecli.ai\u002Finstall.sh | bash\n\n# Windows (PowerShell)\nirm https:\u002F\u002Fd.officecli.ai\u002Finstall.ps1 | iex\n```\n\nVerify with `officecli --version`. If still not found after install, open a new terminal.\n\n---\n\n## Strategy\n\n**L1 (read) → L2 (DOM edit) → L3 (raw XML)**. Always prefer higher layers. Add `--json` for structured output.\n\n**Before doc work, check Specialized Skills** (bottom of this file). Fundraising decks, academic papers, financial models, dashboards, and Morph animations need their own skill loaded first — `load_skill` once, then proceed.\n\n---\n\n## Help System (IMPORTANT)\n\n**When unsure about property names, value formats, or command syntax, ALWAYS run help instead of guessing.** One help query beats guess-fail-retry loops.\n\n`officecli help` ≡ `officecli --help`, and `officecli \u003Ccmd> --help` ≡ `officecli help \u003Ccmd>` — same content.\n\n```bash\nofficecli help                                  # All commands + global options + schema entry points\nofficecli help docx                             # List all docx elements\nofficecli help docx paragraph                   # Full schema: properties, aliases, examples, readbacks\nofficecli help docx set paragraph               # Verb-filtered: only props usable with `set`\nofficecli help docx paragraph --json            # Structured schema (machine-readable)\n```\n\nFormat aliases: `word`→`docx`, `excel`→`xlsx`, `ppt`\u002F`powerpoint`→`pptx`. Verbs: `add`, `set`, `get`, `query`, `remove`. MCP exposes the same schema via `{\"command\":\"help\",\"format\":\"docx\",\"type\":\"paragraph\"}`.\n\n---\n\n## Performance: Resident Mode\n\n**Every command auto-starts a resident on first access** (60s idle timeout) — file-lock conflicts are automatically avoided. Explicit `open`\u002F`close` is still recommended for longer sessions (12min idle):\n```bash\nofficecli open report.docx       # explicitly keep in memory\nofficecli set report.docx ...    # no file I\u002FO overhead\nofficecli close report.docx      # save and release\n```\n\nOpt out of auto-start: `OFFICECLI_NO_AUTO_RESIDENT=1`.\n\n---\n\n## Quick Start\n\n**PPT:**\n```bash\nofficecli create slides.pptx\nofficecli add slides.pptx \u002F --type slide --prop title=\"Q4 Report\" --prop background=1A1A2E\nofficecli add slides.pptx '\u002Fslide[1]' --type shape --prop text=\"Revenue grew 25%\" --prop x=2cm --prop y=5cm --prop font=Arial --prop size=24 --prop color=FFFFFF\n```\n\n**Word:**\n```bash\nofficecli create report.docx\nofficecli add report.docx \u002Fbody --type paragraph --prop text=\"Executive Summary\" --prop style=Heading1\nofficecli add report.docx \u002Fbody --type paragraph --prop text=\"Revenue increased by 25% year-over-year.\"\n```\n\n**Excel:**\n```bash\nofficecli create data.xlsx\nofficecli set data.xlsx \u002FSheet1\u002FA1 --prop value=\"Name\" --prop bold=true\nofficecli set data.xlsx \u002FSheet1\u002FA2 --prop value=\"Alice\"\n```\n\n---\n\n## L1: Create, Read & Inspect\n\n```bash\nofficecli create \u003Cfile>               # Create blank .docx\u002F.xlsx\u002F.pptx (type from extension)\nofficecli view \u003Cfile> \u003Cmode>          # outline | stats | issues | text | annotated | html\nofficecli get \u003Cfile> \u003Cpath> --depth N # Get a node and its children [--json]\nofficecli query \u003Cfile> \u003Cselector>     # CSS-like query\nofficecli validate \u003Cfile>             # Validate against OpenXML schema\n```\n\n### view modes\n\n| Mode | Description | Useful flags |\n|------|-------------|-------------|\n| `outline` | Document structure | |\n| `stats` | Statistics (pages, words, shapes) | |\n| `issues` | Formatting\u002Fcontent\u002Fstructure problems | `--type format\\|content\\|structure`, `--limit N` |\n| `text` | Plain text extraction | `--start N --end N`, `--max-lines N` |\n| `annotated` | Text with formatting annotations | |\n| `html` | Static HTML snapshot — same renderer as `watch`, no server needed | `--browser`, `--page N` (docx), `--start N --end N` (pptx) |\n\nUse `view html` for one-shot snapshots (CI artifacts, archival, diffing); use `watch` when you need live refresh or browser-side click-to-select.\n\n### get\n\nAny XML path via element localName. Use `--depth N` to expand children. Add `--json` for structured output. Default text output is grep-friendly: `path (type) \"text\" key=val key=val ...`\n\n```bash\nofficecli get report.docx '\u002Fbody\u002Fp[3]' --depth 2 --json\nofficecli get slides.pptx '\u002Fslide[1]' --depth 1          # list all shapes on slide 1\nofficecli get data.xlsx '\u002FSheet1\u002FB2' --json\n```\n\n### Stable ID Addressing\n\nElements with stable IDs return `@attr=value` paths instead of positional indices. Prefer these in multi-step workflows — positional indices shift on insert\u002Fdelete, stable IDs do not.\n\n```\n\u002Fslide[1]\u002Fshape[@id=550950021]                    # PPT shape\n\u002Fslide[1]\u002Ftable[@id=1388430425]\u002Ftr[1]\u002Ftc[2]       # PPT table\n\u002Fbody\u002Fp[@paraId=1A2B3C4D]                         # Word paragraph\n\u002Fcomments\u002Fcomment[@commentId=1]                    # Word comment\n```\n\nPPT also accepts `@name=` (e.g. `shape[@name=Title 1]`), with morph `!!` prefix awareness. Elements without stable IDs (slide, run, tr\u002Ftc, row) fall back to positional indices.\n\n### query\n\nCSS-like selectors: `[attr=value]`, `[attr!=value]`, `[attr~=text]`, `[attr>=value]`, `[attr\u003C=value]`, `:contains(\"text\")`, `:empty`, `:has(formula)`, `:no-alt`.\n\n```bash\nofficecli query report.docx 'paragraph[style=Normal] > run[font!=Arial]'\nofficecli query slides.pptx 'shape[fill=FF0000]'\n```\n\n---\n\n## Watch & Interactive Selection\n\nLive HTML preview that auto-refreshes on every file change. Browsers can click \u002F shift-click \u002F box-drag to select shapes; the CLI can read the current browser selection and act on it.\n\n```bash\nofficecli watch \u003Cfile> [--port N]      # Start preview server (default port 26315)\nofficecli unwatch \u003Cfile>               # Stop\nofficecli goto \u003Cfile> \u003Cpath>           # Scroll watching browser(s) to element (docx: p \u002F table \u002F tr \u002F tc)\n```\n\nOpen the printed `http:\u002F\u002Flocalhost:N` URL. Click to select; shift\u002Fcmd\u002Fctrl+click to multi-select; drag from empty space to box-select. PPT\u002FWord use blue outline; Excel uses native-style green selection (double-click cell to edit inline; drag a chart to reposition).\n\n### `get \u003Cfile> selected` — read what the user clicked\n\n```bash\nofficecli get \u003Cfile> selected [--json]\n```\n\nReturns DocumentNodes for whatever is currently selected. Empty result if nothing selected. Exit code != 0 if no watch is running.\n\n```bash\n# User clicks shapes in the browser, then asks \"make these red\"\nPATHS=$(officecli get deck.pptx selected --json | jq -r '.data.Results[].path')\nfor p in $PATHS; do officecli set deck.pptx \"$p\" --prop fill=FF0000; done\n```\n\n### Key properties\n\n- **Selection survives file edits.** Paths use stable `@id=` form.\n- **All connected browsers share one selection.** Last-write-wins.\n- **Same-file single-watch.** A given file can have only one watch process at a time.\n- **Group shapes select as a whole.** Drilling into individual children of a group is not supported in v1.\n- **Coverage:** `.pptx` shapes\u002Fpictures\u002Ftables\u002Fcharts\u002Fconnectors\u002Fgroups; `.docx` top-level paragraphs and tables. Inherited layout\u002Fmaster decorations and Word nested elements (table cells, run-level) are not addressable. **`.xlsx` does not emit `data-path`** — `mark`\u002F`selection` on xlsx always resolve `stale=true` (v2 candidate).\n\n### Marks — edit proposals waiting for review\n\nUse `mark` when changes need human review BEFORE they hit the file. Marks live in the watch process only; a separate `set` pipeline applies accepted ones. For one-shot changes use `set` directly; for permanent file annotations use `add --type comment` (Word native).\n\n```bash\nofficecli mark \u003Cfile> \u003Cpath> [--prop find=... color=... note=... tofix=... regex=true] [--json]\nofficecli unmark \u003Cfile> [--path \u003Cp> | --all] [--json]\nofficecli get-marks \u003Cfile> [--json]\n```\n\nProps: `find` (literal or regex when `regex=true`; raw form `find='r\"[abc]\"'`), `color` (hex \u002F `rgb(...)` \u002F 22 named whitelist), `note`, `tofix` (drives apply pipeline). **Path** must be `data-path` format from watch HTML — see subskills for full pipeline.\n\n---\n\n## L2: DOM Operations\n\n### set — modify properties\n\n```bash\nofficecli set \u003Cfile> \u003Cpath> --prop key=value [--prop ...]\n```\n\n**Any XML attribute is settable** via element path (found via `get --depth N`) — even attributes not currently present. Without `find=`, `set` applies format to the entire element.\n\n**Value formats:**\n\n| Type | Format | Examples |\n|------|--------|---------|\n| Colors | Hex (with\u002Fwithout `#`), named, RGB, theme | `FF0000`, `#FF0000`, `red`, `rgb(255,0,0)`, `accent1`..`accent6` |\n| Spacing | Unit-qualified | `12pt`, `0.5cm`, `1.5x`, `150%` |\n| Dimensions | EMU or suffixed | `914400`, `2.54cm`, `1in`, `72pt`, `96px` |\n\n**Dotted-attr aliases** — `font.\u003Cattr>` forms accepted on shape\u002Frun\u002Fparagraph\u002Ftable\u002Frow\u002Fcell\u002Fsection\u002Fstyles, e.g. `--prop font.color=red --prop font.bold=true --prop font.size=14pt`. Run `officecli help \u003Cfmt> \u003Celement>` for the full list.\n\n### find — format or replace matched text\n\nUse `find=` with `set` to target specific text for formatting or replacement. Format props are separate `--prop` flags — do NOT nest them.\n\n```bash\n# Format matched text (auto-splits runs)\nofficecli set doc.docx '\u002Fbody\u002Fp[1]' --prop find=weather --prop bold=true --prop color=red\n\n# Regex matching\nofficecli set doc.docx '\u002Fbody\u002Fp[1]' --prop 'find=\\d+%' --prop regex=true --prop color=red\n\n# Replace text (use `\u002F` for whole-document scope)\nofficecli set doc.docx \u002F --prop find=draft --prop replace=final\n\n# PPT — same syntax, different paths\nofficecli set slides.pptx \u002F --prop find=draft --prop replace=final\n```\n\n**Path controls search scope:** `\u002F` = whole document, `\u002Fbody\u002Fp[1]` or `\u002Fslide[N]\u002Fshape[M]` = specific element, `\u002Fheader[1]` \u002F `\u002Ffooter[1]` = headers\u002Ffooters.\n\n**Notes:**\n- Case-sensitive by default. Case-insensitive: `--prop 'find=(?i)error' --prop regex=true`\n- Matches work across run boundaries\n- No match = silent success. `--json` includes `\"matched\": N`\n- **Excel:** only `find` + `replace` supported (no find + format props)\n\n### add — add elements or clone\n\n```bash\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> [--prop ...]\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> --after \u003Cpath> [--prop ...]   # insert after anchor\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> --before \u003Cpath> [--prop ...]  # insert before anchor\nofficecli add \u003Cfile> \u003Cparent> --type \u003Ctype> --index N [--prop ...]        # 0-based position (legacy)\nofficecli add \u003Cfile> \u003Cparent> --from \u003Cpath>                               # clone existing element\n```\n\n`--after`, `--before`, `--index` are mutually exclusive. No position flag = append to end.\n\n**Element types (with aliases):**\n\n| Format | Types |\n|--------|-------|\n| **pptx** | slide (incl. hidden), shape (textbox — font.latin\u002Fea\u002Fcs, direction=rtl), picture (SVG, brightness\u002Fcontrast\u002Fglow\u002Fshadow), chart (direction=rtl), table (cell direction=rtl), row (tr), connector (connection\u002Fline), group, video (audio\u002Fmedia, trim), equation (formula\u002Fmath), notes (direction=rtl, lang), comment (RTL via U+200F bidi mark; full CRUD via \u002Fslide[N]\u002Fcomment[M]), paragraph (para), run, zoom (slidezoom), ole (oleobject\u002Fobject\u002Fembed), placeholder (phType=title\u002Fbody\u002Fsubtitle\u002Ffooter\u002F...). slideLayout\u002FslideMaster direction inheritance. |\n| **docx** | paragraph (para — direction\u002Ffont.latin\u002Fea\u002Fcs, bold.cs\u002Fitalic.cs\u002Fsize.cs for RTL\u002FCJK; lang.latin\u002Fea\u002Fcs BCP-47 tags on run; wordWrap toggle), run, table (direction=rtl → bidiVisual), row (tr), cell (td), image (picture\u002Fimg — SVG supported), header (direction), footer (direction), section (pageNumFmt full ECMA-376 enum incl. Hindi\u002FArabic\u002FThai\u002FCJK numerals; direction=rtl on Add\u002FSet; rtlGutter; pgBorders=box shorthand), bookmark, comment, footnote, endnote, formfield (text\u002Fcheckbox\u002Fdropdown), sdt (contentcontrol), chart, equation, field (28 types incl. mergefield\u002Fref\u002Fseq\u002Fstyleref\u002Fdocproperty\u002Fif), hyperlink, style (direction round-trip), toc, watermark, break (pagebreak\u002Fcolumnbreak), ole, **num \u002F abstractNum \u002F lvl** (numbering\u002Flist system), **tab** (paragraph or paragraph\u002Ftable style tab stops). docDefaults.rtl document-wide override; `get \u002F` exposes `locale`. Document protection: `set \u002F --prop protection=forms\\|readOnly\\|comments\\|trackedChanges\\|none` |\n| **xlsx** | sheet (visible\u002Fhidden\u002FveryHidden, print margins, printTitleRows\u002FCols, rightToLeft sheetView, cascade-aware rename), row, cell (type=richtext+runs, merge=range\u002Fsweep, direction=rtl, phonetic guide on add), chart (direction=rtl on per-axis txPr \u002F title; incl. pareto), image (picture — SVG), comment (direction=rtl), table (listobject), namedrange (definedname, volatile, `[@name=X]` selector), pivottable (pivot, calculatedField), sparkline, validation (datavalidation), autofilter, shape, textbox, databar\u002Fcolorscale\u002Ficonset\u002Fformulacf\u002FcellIs\u002FtopN\u002FaboveAverage (conditional formatting), ole, csv (tsv). Query supports `merge`\u002F`mergedrange` aliases for `mergeCell`. Workbook: password. `value=\"=SUM(...)\"` auto-detects as formula. Chart\u002Fpicture\u002Fshape\u002Fslicer accept `anchor=A1:E10`. |\n\n### Pivot tables (xlsx)\n\n```bash\nofficecli add data.xlsx \u002FSheet1 --type pivottable \\\n  --prop source=\"Sheet1!A1:E100\" --prop rows=Region,Category \\\n  --prop cols=Year --prop values=\"Sales:sum,Qty:count\" \\\n  --prop grandTotals=rows --prop subtotals=off --prop sort=asc\n```\n\nKey props: `rows`, `cols`, `values` (Field:func[:showDataAs]), `filters`, `source`, `position`, `layout` (compact\u002Foutline\u002Ftabular), `repeatLabels`, `blankRows`, `aggregate`, `showDataAs` (percent_of_total\u002Frow\u002Fcol, running_total), `grandTotals`, `subtotals`, `sort`. Aggregators: sum, count, average, max, min, product, stdDev, stdDevp, var, varp, countNums. Date columns auto-group. Run `officecli help xlsx pivottable` for full schema.\n\n### Document-level properties (all formats)\n\n```bash\nofficecli set doc.docx \u002F --prop docDefaults.font=Arial --prop docDefaults.fontSize=11pt\nofficecli set doc.docx \u002F --prop protection=forms --prop evenAndOddHeaders=true\nofficecli set data.xlsx \u002F --prop calc.mode=manual --prop calc.refMode=r1c1\nofficecli set slides.pptx \u002F --prop defaultFont=Arial --prop show.loop=true --prop print.what=handouts\n```\n\nRun `officecli help \u003Cformat> \u002F` for all document-level properties (docDefaults, docGrid, CJK spacing, calc, print, show, theme, extended).\n\n### Sort (xlsx)\n\n```bash\nofficecli set data.xlsx \u002FSheet1 --prop sort=\"C desc\" --prop sortHeader=true\nofficecli set data.xlsx '\u002FSheet1\u002FA1:D100' --prop sort=\"A asc\" --prop sortHeader=true\n```\n\nFormat: `COL DIR[, COL DIR ...]`. Rejects ranges with merged cells or formulas. Sidecar metadata (hyperlinks, comments, conditional formatting, drawings) follows rows automatically.\n\n### Text-anchored insert (`--after find:X` \u002F `--before find:X`)\n\nLocate an insertion point by text match within a paragraph. Inline types (run, picture, hyperlink) insert within the paragraph; block types (table, paragraph) auto-split it. PPT only supports inline.\n\n```bash\n# Word: inline run after matched text\nofficecli add doc.docx '\u002Fbody\u002Fp[1]' --type run --after find:weather --prop text=\" (sunny)\"\n\n# Word: block table after matched text (auto-splits paragraph)\nofficecli add doc.docx '\u002Fbody\u002Fp[1]' --type table --after \"find:First sentence.\" --prop rows=2 --prop cols=2\n```\n\n### Clone\n\n`officecli add \u003Cfile> \u002F --from '\u002Fslide[1]'` — copies with all cross-part relationships.\n\n### move, swap, remove\n\n```bash\nofficecli move \u003Cfile> \u003Cpath> [--to \u003Cparent>] [--index N] [--after \u003Cpath>] [--before \u003Cpath>]\nofficecli swap \u003Cfile> \u003Cpath1> \u003Cpath2>\nofficecli remove \u003Cfile> '\u002Fbody\u002Fp[4]'\n```\n\nWhen using `--after` or `--before`, `--to` can be omitted — the target container is inferred from the anchor.\n\n### batch — multiple operations in one save cycle\n\nContinues on error by default (returns exit 1 if any item fails). Use `--stop-on-error` to abort on the first failure. `--force` is the docx-protection bypass.\n\n`officecli dump \u003Cfile.docx> [\u003Cpath>]` emits a replayable batch JSON for round-trip. Path defaults to `\u002F` (whole document); pass a subtree path (`\u002Fbody`, `\u002Fbody\u002Fp[N]`, `\u002Fbody\u002Ftbl[N]`, `\u002Ftheme`, `\u002Fsettings`, `\u002Fnumbering`, `\u002Fstyles`) to scope the dump. `officecli refresh \u003Cfile.docx>` recalculates TOC page numbers \u002F PAGE \u002F cross-references after replay (Word backend on Windows; headless-HTML fallback elsewhere).\n\n```bash\necho '[\n  {\"command\":\"set\",\"path\":\"\u002FSheet1\u002FA1\",\"props\":{\"value\":\"Name\",\"bold\":\"true\"}},\n  {\"command\":\"set\",\"path\":\"\u002FSheet1\u002FB1\",\"props\":{\"value\":\"Score\",\"bold\":\"true\"}}\n]' | officecli batch data.xlsx --json\n\nofficecli batch data.xlsx --commands '[{\"op\":\"set\",\"path\":\"\u002FSheet1\u002FA1\",\"props\":{\"value\":\"Done\"}}]' --json\nofficecli batch data.xlsx --input updates.json --force --json\n```\n\nSupports: `add`, `set`, `get`, `query`, `remove`, `move`, `swap`, `view`, `raw`, `raw-set`, `validate`. Fields: `command` (or `op`), `path`, `parent`, `type`, `from`, `to`, `index`, `after`, `before`, `props`, `selector`, `mode`, `depth`, `part`, `xpath`, `action`, `xml`.\n\n---\n\n## L3: Raw XML\n\nUse when L2 cannot express what you need. No xmlns declarations needed — prefixes auto-registered.\n\n```bash\nofficecli raw \u003Cfile> \u003Cpart>                          # view raw XML\nofficecli raw-set \u003Cfile> \u003Cpart> --xpath \"...\" --action replace --xml '\u003Cw:p>...\u003C\u002Fw:p>'\nofficecli add-part \u003Cfile> \u003Cparent>                   # create new document part (returns rId)\n```\n\n`raw-set` actions: `append`, `prepend`, `insertbefore`, `insertafter`, `replace`, `remove`, `setattr`. Run `officecli help \u003Cformat> raw` for available parts.\n\n---\n\n## Common Pitfalls\n\n| Pitfall | Correct Approach |\n|---------|-----------------|\n| `--name \"foo\"` | Use `--prop name=\"foo\"` — all attributes go through `--prop` |\n| Unquoted `[N]` paths in zsh\u002Fbash | Always quote: `'\u002Fslide[1]'` or `\"\u002Fslide[1]\"` (shell glob-expands brackets) |\n| PPT `shape[1]` for content | `shape[1]` is typically the title placeholder. Use `shape[2]+` for content shapes |\n| `\u002Fshape[myname]` | Name indexing not supported. Use numeric index or `@name=` (PPT only) |\n| Guessing property names | Run `officecli help \u003Cformat> \u003Celement>` to see exact names |\n| Modifying an open file | Close the file in PowerPoint\u002FWPS first |\n| `\\n` in shell strings | Use `\\\\n` for newlines in `--prop text=\"...\"` |\n| `$` in shell text | `--prop text=\"$15M\"` strips `$15`. Use single quotes: `--prop text='$15M'`, or heredoc batch |\n\n---\n\n## Specialized Skills\n\n`officecli load_skill \u003Cname>` — output is a SKILL.md, follow its rules.\n\n**Loading rule**:\n- Pick the most specific match in \"When to use\"; if none fits, load the format default (`word` \u002F `pptx` \u002F `excel`).\n- Scenes already contain the format default's rules — load **one** skill per artifact, never stack.\n- Loaded rules persist across turns; don't re-load each reply.\n- Two distinct artifacts → two separate loads.\n\n### Word (.docx)\n\n| Name | When to use |\n|------|-------------|\n| `word` | Reports, letters, memos, proposals, generic documents |\n| `academic-paper` | Journal \u002F conference \u002F thesis: APA \u002F Chicago \u002F IEEE \u002F MLA citations, equations, SEQ + PAGEREF cross-refs, multi-column journal layout, bibliography. NOT for business reports or letters (route those to `word`) |\n\n### PowerPoint (.pptx)\n\n| Name | When to use |\n|------|-------------|\n| `pptx` | Generic decks: board reviews, sales decks, all-hands, product launches |\n| `pitch-deck` | **Fundraising only** — seed \u002F Series A-C \u002F SAFE \u002F convertible \u002F strategic raise. NOT for sales \u002F product \u002F board decks (route those to `pptx`) |\n| `morph-ppt` | Cinematic Morph-animated presentations. NOT for static decks (route those to `pptx`) |\n| `morph-ppt-3d` | 3D Morph: GLB models, camera moves, depth. NOT for 2D-only Morph (route those to `morph-ppt`) |\n\n### Excel (.xlsx)\n\n| Name | When to use |\n|------|-------------|\n| `excel` | Generic workbooks, formulas, pivots, trackers |\n| `financial-model` | Financial models, scenarios, projections. NOT for general data analysis (route those to `excel`) |\n| `data-dashboard` | CSV\u002Ftabular data → KPI \u002F analytics \u002F executive dashboards with charts and sparklines. NOT for raw data tracking (route those to `excel`) |\n\nExample: a fundraising deck task → `officecli load_skill pitch-deck` → use the printed rules.\n\n---\n\n## Notes\n\n- Paths are **1-based** (XPath convention): `'\u002Fbody\u002Fp[3]'` = third paragraph\n- `--index` is **0-based** (array convention): `--index 0` = first position\n- **Excel exception**: for `add --type row` and `add --type col`, `--index N` is **1-based** (matches OOXML RowIndex \u002F column letter index). `--index 5` inserts at row 5 \u002F column 5.\n- After modifications, verify with `validate` and\u002For `view issues`\n- **When unsure**, run `officecli help \u003Cformat> \u003Celement>` instead of guessing\n",{"name":5,"description":7},"main","89ebf7196eee1581caf96eeee57dd956e5b7c6f2","crates\u002Fbackend\u002Fopenhub-app\u002Fassets\u002Fbuiltin-skills\u002Fauto-inject\u002Fofficecli","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client","https:\u002F\u002Fgithub.com\u002FGrong","2026-07-28 18:22:19",{"source":8,"skillName":5,"commands":30,"prompt":40,"zipAvailable":41},[31,34,37],{"tool":32,"command":33},"npx","npx skills add Grong\u002Fopenhub-client --skill officecli",{"tool":35,"command":36},"bunx","bunx skills add Grong\u002Fopenhub-client --skill officecli",{"tool":38,"command":39},"pnpm","pnpm dlx skills add Grong\u002Fopenhub-client --skill officecli","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fcrates\u002Fbackend\u002Fopenhub-app\u002Fassets\u002Fbuiltin-skills\u002Fauto-inject\u002Fofficecli\u002FSKILL.md",true,[],[44,51,58,65,72,79],{"skillNo":45,"name":46,"nameZh":6,"description":47,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":48,"categories":49,"keywords":50,"publishedAt":18},"01M78DF6CKZ6Y19XWFFAFRMPVA","drive-openhub","Use to connect to and drive a OpenHub instance from an external agent (Claude Code \u002F Cursor \u002F any MCP client). Delegate goals to OpenHub's autonomous agent, drive its browser \u002F computer \u002F knowledge base \u002F files, and manage the platform — over MCP or REST, with a per-companion access token (you run AS the bound companion). Use this whenever the user asks to control, automate, or hand work off to \"OpenHub\", \"their OpenHub\", \"the desktop companion\", or a running OpenHub server.","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fdocs\u002Fskills\u002Fdrive-nomifun\u002FSKILL.md",[],[],{"skillNo":52,"name":53,"nameZh":6,"description":54,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":55,"categories":56,"keywords":57,"publishedAt":18},"01M78DF51T081P4306NA1XYJPE","example-skill","Fixture skill used by startup_materialize integration tests.","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fcrates\u002Fbackend\u002Fopenhub-extension\u002Ftests\u002Ffixtures\u002Fbuiltin-skills-fixture\u002Fexample-skill\u002FSKILL.md",[],[],{"skillNo":59,"name":60,"nameZh":6,"description":61,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":62,"categories":63,"keywords":64,"publishedAt":18},"01M78DF0Z8VS064W7300YJZ0KB","xiaohongshu-recruiter","用于准备在小红书上发布高质量的 AI 相关岗位招聘帖子。包含自动生成极客风格的招聘封面图和详情图，并提供确认门控的发布脚本。当用户需要发布招聘信息、寻找 Agent 设计师或其他 AI 领域人才时使用。","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fcrates\u002Fbackend\u002Fopenhub-app\u002Fassets\u002Fbuiltin-skills\u002Fxiaohongshu-recruiter\u002FSKILL.md",[],[],{"skillNo":66,"name":67,"nameZh":6,"description":68,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":69,"categories":70,"keywords":71,"publishedAt":18},"01M78DEZB3EKW0JZNZ21B2E4ZM","x-recruiter","用于在 X (x.com) 发布招聘帖子。包含文案规范、图片生成提示和自动化发布脚本。发布 AI 相关岗位或设计类岗位时优先使用。","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fcrates\u002Fbackend\u002Fopenhub-app\u002Fassets\u002Fbuiltin-skills\u002Fx-recruiter\u002FSKILL.md",[],[],{"skillNo":73,"name":74,"nameZh":6,"description":75,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":18},"01M78DEW7RT4CVH83HAKB5TQF5","weixin-file-send","Use when the user wants a local file or image sent back, such as \"send me the file\"\nor \"发给我\".","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fcrates\u002Fbackend\u002Fopenhub-app\u002Fassets\u002Fbuiltin-skills\u002Fweixin-file-send\u002FSKILL.md",[],[],{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":18},"01M78DERHW8WYJRWH6QCZ9HMSQ","ui-ux-pro-max","Professional UI\u002FUX design research skill with a bundled searchable database for product patterns, visual styles, color palettes, typography, landing-page structure, dashboard charts, UX practices, and stack guidance. Use when designing, building, reviewing, or improving interfaces.","https:\u002F\u002Fgithub.com\u002FGrong\u002Fopenhub-client\u002Fblob\u002Fmain\u002Fcrates\u002Fbackend\u002Fopenhub-app\u002Fassets\u002Fbuiltin-skills\u002Fui-ux-pro-max\u002FSKILL.md",[],[]]