SuperAPI AI Directory

office-env-shell

Office & productivity

View repository

Updated 11-05 16:19

About this skill

When to use

When you need to run Python to process PDFs/spreadsheets, pip install dependencies, call pandoc/soffice, batch rename, etc.

Pre-checks

  1. Read the workspace ENV.md 's C/D tier and run status
  2. If not yet probed and the task depends on run:office-env-setup probe quickly or confirm directly with the user
  3. run off → do not execute commands; use the desktop/Markdown fallback and explain the configuration item

Tools

tools workflow run:

  • Default cwd = Agent workspace
  • Constrained by aistream.tools.file.runEnabled、runTimeoutMs、maxCommandOutputChars Constraints
  • Overly long output will be truncated → redirect the result write to a file and then read

Safety checklist

Before execution, explain:

  1. the command text
  2. impact(which files are written, whether pip uses the network)
  3. and run only after the user confirms (deletion, pip install, curl upload)

Common office commands

python script.py
pip install --user pypdf pdfplumber python-pptx pandas openpyxl matplotlib
pandoc report.md -o report.docx
soffice --headless --convert-to pdf file.docx

On Windows, mind path quoting; prefer paths relative to the workspace.

On failure

Error Handling
run disabled See office-env-setup → inform about runEnabled
python not found Try python3 / py -3; if still missing, fall back
pip fails Record stderr, do not retry the install; deliver via fallback
command does not exist pandoc/soffice/qpdf → switch to Python or the desktop path
timeout Split into smaller scripts or increase runTimeoutMs (requires the user to change the configuration)

Dependency reference: see office-env-setup task fallback table.

Prohibited

  • Do not execute rm -rf /, format disks, change the firewall, etc.
  • Global pip install without confirmation