dsh-office
办公三件套!Office document tools for DeepSeek Harness (dsh): generate, read, and edit spreadsheets (.xlsx), PDFs, and presentations (.pptx).
- Stars
- 12
- Language
- TypeScript
- Created
- Aug 14, 2026
- Updated
- Aug 16, 2026
Introduction
@huiliyi37/dsh-office
English | 中文
Office document tools for DeepSeek Harness (dsh): generate, read, and edit spreadsheets (.xlsx), PDFs, and presentations (.pptx).
Ported from the office plugins of the Tianshu terminal coding agent (Apache-2.0 licensed upstream), adapted to the dsh cordis tool model.
Tools
| Tool | What it does |
|---|---|
xlsx_read | List sheets of a .xlsx, or read one sheet as a markdown table (range-limited for large files; formula text preserved) |
xlsx_write | Write a 2D array to a new .xlsx (formula cells, header bold, column widths, number formats) |
xlsx_edit | Edit an existing .xlsx: add sheets, update cells (value or formula), append rows |
pdf_create | Generate a real PDF with headings, paragraphs, tables, lists, code blocks and footer page numbers; CJK text renders via an auto-detected system font |
pdf_read | Extract text from a PDF for reading into context |
pptx_create | Generate a .pptx deck from slide definitions (title / section / content / two-column / image / table / chart), with optional theme and speaker notes |
pptx_read | Extract slide text as markdown, optionally including speaker notes |
Install & load
Full load (all 9 tools)
dsh plugin --profile <name> add @huiliyi37/dsh-office
dsh --profile <name>
The first dsh plugin call initializes the profile (@deepseek-ai/dsh-base
is its first bundle) and appends this package to the profile's bundles list.
Launching the profile then registers all tools automatically.
Load only the families you need
Pass a config row in your profile's cordis.patch.yml to enable/disable
per family. Omitted families stay enabled; set a family to false to
exclude it (useful to keep the tool surface small):
# cordis.patch.yml
- insert:
- id: dsh-office
name: '@huiliyi37/dsh-office'
config:
enable:
xlsx: false # skip spreadsheet tools
pdf: true # keep PDF tools
ppt: false # skip presentations
docx: true # keep Word tools
Families: xlsx (xlsx_read/write/edit), pdf (pdf_create/read),
ppt (pptx_create/read), docx (docx_create/read).
Uninstall
dsh plugin --profile <name> remove @huiliyi37/dsh-office
Manual alternative
Install the package anywhere Node resolution can find it and reference it
from your own cordis.patch.yml (same config.enable switches apply):
npm install @huiliyi37/dsh-office
# cordis.patch.yml
- insert:
- id: dsh-office
name: '@huiliyi37/dsh-office'
Skill
The package ships a usage skill (skills/SKILL.md, anthropics-compatible
format) that teaches the model large-file pagination and generation
discipline. Install it into a skill discovery root:
mkdir -p ~/.dsh/skills && cp -r node_modules/@huiliyi37/dsh-office/skills/dsh-office ~/.dsh/skills/
Usage examples
// xlsx_write — create a workbook
{ "file_path": "report.xlsx", "data": [["Name", "Score"], ["Alice", 92]], "header_bold": true }
// pdf_create — document with a heading, table and list
{
"destination_path": "doc.pdf",
"title": "Quarterly Report",
"content": [
{ "type": "heading", "text": "Summary" },
{ "type": "table", "headers": ["Region", "Revenue"], "rows": [["APAC", "120"]] },
{ "type": "list", "items": ["Alpha", "Beta"] }
],
"page_numbers": true
}
// pptx_create — a deck with a title slide and a bullet slide
{
"destination_path": "deck.pptx",
"slides": [
{ "type": "title", "title": "Roadmap 2026" },
{ "type": "content", "title": "Highlights", "items": ["Plugin runtime", "Office tools"] }
]
}
Development
npm install
npm run build # tsc → lib/
npm test # vitest: round-trip tests through the tool execute path
License
Apache License 2.0. Tool logic ported from the Tianshu office plugins (also Apache-2.0 licensed, copyright Tianshu contributors); see file headers for per-module provenance.