E

表格使用技能

辦公效率v1.0.0
作者:user_90d58900更新於 2026-11-05excel01@user_90d58900/excel01
表格處理

據 AlphaMoat 統計,截至 2026-10,表格使用技能 累計下載 18,695 次、獲 7 個星標,按累計下載量在本次參與排名的 10,914 個 AI 技能中排名第 1,504 位,在「辦公效率」分類(909 個)中排名第 177 位。

列表預設按累計下載量排序,也可按星標排序;詳情頁排名按累計下載量計算。

累計下載
1.9萬
星標
7
全站下載量排名
#1,504
全站前 14% · 「辦公效率」前 20%
平台累計下載星標評論
SkillHub ↗1.9萬7—

各平台的計數口徑不同,統計時間不一致。

這個技能是做什麼的

當電子表格是主要輸入或交付物時,使用該技能讀取、建立、編輯、修復、清理或轉換 Excel、CSV、TSV 等表格檔案。修改已有模板時應保留其既有格式;包含公式時需重新計算並檢查公式錯誤,交付物應為電子表格檔案。

資料釋出於 2026-10-27

可以用來做什麼

  • 清理和重組表格資料或修復工作簿
  • 建立、編輯或轉換電子表格檔案

什麼時候用

  • 需要處理表格檔案並交付電子表格結果時
  • 需要保留現有模板格式或驗證公式時

示例提示詞

以下是根據技能文件生成的示例,不代表實際執行結果。

修改這個工作簿時保留原有模板,並檢查公式計算結果。

月度資料趨勢

累計下載1.9萬
01萬2萬2026-03 · 累計下載 2332026-05 · 累計下載 10472026-06 · 累計下載 23002026-08 · 累計下載 55492026-09 · 累計下載 72682026-10 · 累計下載 1.9萬26-0326-0926-10
星標7
0482026-03 · 星標 -2026-05 · 星標 -2026-06 · 星標 22026-08 · 星標 72026-09 · 星標 72026-10 · 星標 726-0326-0926-10

2026-09 起統計方法調整:同名技能按作者分別統計,並覆蓋全部技能。圖中虛線為調整前的月份,與之後的資料不直接比較,也不計算跨越調整的增長。

月份累計下載環比星標
2026-101.9萬—7
2026-097268—7
2026-085549—7
2026-062300+119.7%2
2026-051047—-
2026-03233—-

SKILL.md 原文

以下是作者釋出的原始檔案,按純文字顯示,本站未做修改或稽核;其中的連結不可點選,命令請核實後再執行。抓取於 2026-10-23。

15 KB · SkillHub v1.0.0
---
name: xlsx
description: "Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like \"the xlsx in my downloads\") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved."
license: Proprietary. LICENSE.txt has complete terms
---

# Requirements for Outputs

## All Excel files

展開全部(共 365 行)
### Professional Font
- Use a consistent, professional font (e.g., Arial, Times New Roman) for all deliverables unless otherwise instructed by the user

### Zero Formula Errors
- Every Excel model MUST be delivered with ZERO formula errors (#REF!, #DIV/0!, #VALUE!, #N/A, #NAME?)

### Preserve Existing Templates (when updating templates)
- Study and EXACTLY match existing format, style, and conventions when modifying files
- Never impose standardized formatting on files with established patterns
- Existing template conventions ALWAYS override these guidelines

## Financial models

### Color Coding Standards
Unless otherwise stated by the user or existing template

#### Industry-Standard Color Conventions
- **Blue text (RGB: 0,0,255)**: Hardcoded inputs, and numbers users will change for scenarios
- **Black text (RGB: 0,0,0)**: ALL formulas and calculations
- **Green text (RGB: 0,128,0)**: Links pulling from other worksheets within same workbook
- **Red text (RGB: 255,0,0)**: External links to other files
- **Yellow background (RGB: 255,255,0)**: Key assumptions needing attention or cells that need to be updated

### Number Formatting Standards

#### Required Format Rules
- **Years**: Format as text strings (e.g., "2024" not "2,024")
- **Currency**: Use $#,##0 format; ALWAYS specify units in headers ("Revenue ($mm)")
- **Zeros**: Use number formatting to make all zeros "-", including percentages (e.g., "$#,##0;($#,##0);-")
- **Percentages**: Default to 0.0% format (one decimal)
- **Multiples**: Format as 0.0x for valuation multiples (EV/EBITDA, P/E)
- **Negative numbers**: Use parentheses (123) not minus -123

### Formula Construction Rules

#### Assumptions Placement
- Place ALL assumptions (growth rates, margins, multiples, etc.) in separate assumption cells
- Use cell references instead of hardcoded values in formulas
- Example: Use =B5*(1+$B$6) instead of =B5*1.05

#### Formula Error Prevention
- Verify all cell references are correct
- Check for off-by-one errors in ranges
- Ensure consistent formulas across all projection periods
- Test with edge cases (zero values, negative numbers)
- Verify no unintended circular references

#### Documentation Requirements for Hardcodes
- Comment or in cells beside (if end of table). Format: "Source: [System/Document], [Date], [Specific Reference], [URL if applicable]"
- Examples:
  - "Source: Company 10-K, FY2024, Page 45, Revenue Note, [SEC EDGAR URL]"
  - "Source: Company 10-Q, Q2 2025, Exhibit 99.1, [SEC EDGAR URL]"
  - "Source: Bloomberg Terminal, 8/15/2025, AAPL US Equity"
  - "Source: FactSet, 8/20/2025, Consensus Estimates Screen"

# XLSX creation, editing, and analysis

## Overview

A user may ask you to create, edit, or analyze the contents of an .xlsx file. You have different tools and workflows available for different tasks.

## Important Requirements

**LibreOffice Required for Formula Recalculation**: You can assume LibreOffice is installed for recalculating formula values using the `scripts/recalc.py` script. The script automatically configures LibreOffice on first run, including in sandboxed environments where Unix sockets are restricted (handled by `scripts/office/soffice.py`)

## CSV Encoding Rules

**CRITICAL: Always use `utf-8-sig` (UTF-8 with BOM) when writing CSV files that may be opened in Excel (any platform).**

Excel identifies a CSV file's encoding by checking for a BOM at the start of the file. Without a BOM, Excel falls back to the system locale encoding (GBK on Chinese Windows), which causes Chinese characters to display as garbled text.

### ❌ WRONG - Missing encoding or BOM

```python
df.to_csv('output.csv')                        # Uses system locale — unreliable cross-platform
df.to_csv('output.csv', encoding='utf-8')      # No BOM — Excel opens as GBK, Chinese becomes garbage
```

### ✅ CORRECT - UTF-8 with BOM (for Excel)

```python
df.to_csv('output.csv', encoding='utf-8-sig')  # BOM included — Excel recognises UTF-8 correctly
```

### macOS Compatibility Warning

`utf-8-sig` works correctly with **Excel for Mac** and **LibreOffice Calc on macOS**, but has known issues with other macOS tools:

- **macOS Numbers.app**: Older versions may show the BOM as a visible `` prefix in the first cell of the first row. If the output CSV is intended for Numbers, use plain `utf-8` instead and instruct the user to open it via File > Open to select encoding manually.
- **macOS command-line tools** (`cat`, `awk`, `grep`, `sort`, etc.): The 3-byte BOM (`\xef\xbb\xbf`) will appear at the start of the first line, breaking pattern matches and column splits that target column 1.
- **Python `read_csv` with `encoding='utf-8'`**: The BOM appears as `\ufeff` prepended to the first column name, causing column-name mismatches. Always read back with `encoding='utf-8-sig'` to strip the BOM automatically.

**Decision guide — which encoding to use when writing CSV:**

| Target consumer | Encoding |
|----------------|---------|
| Excel (Windows or Mac) | `utf-8-sig` |
| Excel for Mac + LibreOffice Calc | `utf-8-sig` |
| macOS Numbers.app | `utf-8` (no BOM) |
| macOS / Linux command-line tools or scripts | `utf-8` (no BOM) |
| Unknown / general purpose | `utf-8-sig` (safest for human users) |

If the target is unknown, prefer `utf-8-sig` — it is transparent to most modern applications and essential for Windows Excel.

### Reading CSV files

When reading a CSV that may have been created on a Chinese Windows system, detect the encoding first:

```python
import chardet

with open('input.csv', 'rb') as f:
    raw = f.read()
    encoding = chardet.detect(raw)['encoding'] or 'utf-8'

df = pd.read_csv('input.csv', encoding=encoding)
```

When reading a CSV that was written with `utf-8-sig`, use the matching encoding to strip the BOM:

```python
df = pd.read_csv('input.csv', encoding='utf-8-sig')  # BOM stripped automatically
```

### Rule summary

| Scenario | Required encoding |
|----------|------------------|
| Writing CSV for Excel (any platform) | `utf-8-sig` |
| Writing CSV for Numbers.app (macOS) | `utf-8` (no BOM) |
| Writing CSV for command-line / scripts | `utf-8` (no BOM) |
| Writing CSV for unknown / general use | `utf-8-sig` |
| Reading CSV from unknown source | detect with `chardet`, fallback to `utf-8` |
| Reading CSV known to be UTF-8 with BOM | `utf-8-sig` |
| Reading CSV from Chinese Windows | `gbk` or `gb18030` |

---

## Reading and analyzing data

### Data analysis with pandas
For data analysis, visualization, and basic operations, use **pandas** which provides powerful data manipulation capabilities:

```python
import pandas as pd

# Read Excel
df = pd.read_excel('file.xlsx')  # Default: first sheet
all_sheets = pd.read_excel('file.xlsx', sheet_name=None)  # All sheets as dict

# Analyze
df.head()      # Preview data
df.info()      # Column info
df.describe()  # Statistics

# Write Excel
df.to_excel('output.xlsx', index=False)
```

## Excel File Workflows

## CRITICAL: Use Formulas, Not Hardcoded Values

**Always use Excel formulas instead of calculating values in Python and hardcoding them.** This ensures the spreadsheet remains dynamic and updateable.

### ❌ WRONG - Hardcoding Calculated Values
```python
# Bad: Calculating in Python and hardcoding result
total = df['Sales'].sum()
sheet['B10'] = total  # Hardcodes 5000

# Bad: Computing growth rate in Python
growth = (df.iloc[-1]['Revenue'] - df.iloc[0]['Revenue']) / df.iloc[0]['Revenue']
sheet['C5'] = growth  # Hardcodes 0.15

# Bad: Python calculation for average
avg = sum(values) / len(values)
sheet['D20'] = avg  # Hardcodes 42.5
```

### ✅ CORRECT - Using Excel Formulas
```python
# Good: Let Excel calculate the sum
sheet['B10'] = '=SUM(B2:B9)'

# Good: Growth rate as Excel formula
sheet['C5'] = '=(C4-C2)/C2'

# Good: Average using Excel function
sheet['D20'] = '=AVERAGE(D2:D19)'
```

This applies to ALL calculations - totals, percentages, ratios, differences, etc. The spreadsheet should be able to recalculate when source data changes.

## Common Workflow
1. **Choose tool**: pandas for data, openpyxl for formulas/formatting
2. **Create/Load**: Create new workbook or load existing file
3. **Modify**: Add/edit data, formulas, and formatting
4. **Save**: Write to file
5. **Recalculate formulas (MANDATORY IF USING FORMULAS)**: Use the scripts/recalc.py script
   ```bash
   python scripts/recalc.py output.xlsx
   ```
6. **Verify and fix any errors**: 
   - The script returns JSON with error details
   - If `status` is `errors_found`, check `error_summary` for specific error types and locations
   - Fix the identified errors and recalculate again
   - Common errors to fix:
     - `#REF!`: Invalid cell references
     - `#DIV/0!`: Division by zero
     - `#VALUE!`: Wrong data type in formula
     - `#NAME?`: Unrecognized formula name

### Creating new Excel files

```python
# Using openpyxl for formulas and formatting
from openpyxl import Workbook
from openpyxl.styles import Font, PatternFill, Alignment

wb = Workbook()
sheet = wb.active

# Add data
sheet['A1'] = 'Hello'
sheet['B1'] = 'World'
sheet.append(['Row', 'of', 'data'])

# Add formula
sheet['B2'] = '=SUM(A1:A10)'

# Formatting
sheet['A1'].font = Font(bold=True, color='FF0000')
sheet['A1'].fill = PatternFill('solid', start_color='FFFF00')
sheet['A1'].alignment = Alignment(horizontal='center')

# Column width
sheet.column_dimensions['A'].width = 20

wb.save('output.xlsx')
```

### Editing existing Excel files

```python
# Using openpyxl to preserve formulas and formatting
from openpyxl import load_workbook

# Load existing file
wb = load_workbook('existing.xlsx')
sheet = wb.active  # or wb['SheetName'] for specific sheet

# Working with multiple sheets
for sheet_name in wb.sheetnames:
    sheet = wb[sheet_name]
    print(f"Sheet: {sheet_name}")

# Modify cells
sheet['A1'] = 'New Value'
sheet.insert_rows(2)  # Insert row at position 2
sheet.delete_cols(3)  # Delete column 3

# Add new sheet
new_sheet = wb.create_sheet('NewSheet')
new_sheet['A1'] = 'Data'

wb.save('modified.xlsx')
```

## Recalculating formulas

Excel files created or modified by openpyxl contain formulas as strings but not calculated values. Use the provided `scripts/recalc.py` script to recalculate formulas:

```bash
python scripts/recalc.py <excel_file> [timeout_seconds]
```

Example:
```bash
python scripts/recalc.py output.xlsx 30
```

The script:
- Automatically sets up LibreOffice macro on first run
- Recalculates all formulas in all sheets
- Scans ALL cells for Excel errors (#REF!, #DIV/0!, etc.)
- Returns JSON with detailed error locations and counts
- Works on both Linux and macOS

## Formula Verification Checklist

Quick checks to ensure formulas work correctly:

### Essential Verification
- [ ] **Test 2-3 sample references**: Verify they pull correct values before building full model
- [ ] **Column mapping**: Confirm Excel columns match (e.g., column 64 = BL, not BK)
- [ ] **Row offset**: Remember Excel rows are 1-indexed (DataFrame row 5 = Excel row 6)

### Common Pitfalls
- [ ] **NaN handling**: Check for null values with `pd.notna()`
- [ ] **Far-right columns**: FY data often in columns 50+ 
- [ ] **Multiple matches**: Search all occurrences, not just first
- [ ] **Division by zero**: Check denominators before using `/` in formulas (#DIV/0!)
- [ ] **Wrong references**: Verify all cell references point to intended cells (#REF!)
- [ ] **Cross-sheet references**: Use correct format (Sheet1!A1) for linking sheets

### Formula Testing Strategy
- [ ] **Start small**: Test formulas on 2-3 cells before applying broadly
- [ ] **Verify dependencies**: Check all cells referenced in formulas exist
- [ ] **Test edge cases**: Include zero, negative, and very large values

### Interpreting scripts/recalc.py Output
The script returns JSON with error details:
```json
{
  "status": "success",           // or "errors_found"
  "total_errors": 0,              // Total error count
  "total_formulas": 42,           // Number of formulas in file
  "error_summary": {              // Only present if errors found
    "#REF!": {
      "count": 2,
      "locations": ["Sheet1!B5", "Sheet1!C10"]
    }
  }
}
```

## Best Practices

### Library Selection
- **pandas**: Best for data analysis, bulk operations, and simple data export
- **openpyxl**: Best for complex formatting, formulas, and Excel-specific features

### Working with openpyxl
- Cell indices are 1-based (row=1, column=1 refers to cell A1)
- Use `data_only=True` to read calculated values: `load_workbook('file.xlsx', data_only=True)`
- **Warning**: If opened with `data_only=True` and saved, formulas are replaced with values and permanently lost
- For large files: Use `read_only=True` for reading or `write_only=True` for writing
- Formulas are preserved but not evaluated - use scripts/recalc.py to update values

### Working with pandas
- Specify data types to avoid inference issues: `pd.read_excel('file.xlsx', dtype={'id': str})`
- For large files, read specific columns: `pd.read_excel('file.xlsx', usecols=['A', 'C', 'E'])`
- Handle dates properly: `pd.read_excel('file.xlsx', parse_dates=['date_column'])`

## Code Style Guidelines
**IMPORTANT**: When generating Python code for Excel operations:
- Write minimal, concise Python code without unnecessary comments
- Avoid verbose variable names and redundant operations
- Avoid unnecessary print statements

**For Excel files themselves**:
- Add comments to cells with complex formulas or important assumptions
- Document data sources for hardcoded values
- Include notes for key calculations and model sections

「辦公效率」分類下的熱門技能

騰訊文件 TENCENT DOCS辦公效率

透過 MCP 在騰訊文件裡新建、編輯與管理線上文件的完整操作手冊。

↓ 218.4萬★ 327u_b0de8114
WPS Office 全家桶辦公效率

WPS Office 全家桶 - 四引擎(WPS/MS Office/LibreOffice/純Python)智慧識別使用者已安裝軟體,純Python模式支援排序/篩選/圖表/公式/統計,含文件模板(程式碼生成)、最佳實踐案例、故障排除大章(20+避坑+15 FAQ+15錯誤ID 統一索引)、自動重試、硬體自適應、環境自檢、Skill更新提醒;v5.1新增:kingdoc雲端橋接(白名單探測+配置預檢+subprocess上傳+差異檢查)、條件格式/資料驗證跨引擎IO(JSON中間格式保真往返)、會議紀要三段式要素化(待辦清單+決策記錄+風險異議)+說話人標註(MFCC聚類);v5.2新增:公文一鍵排版(GB/T 9704 規則庫約束+結構識別套版+紅頭預留位+聯合行文)、批次水印與敏感資訊打碼(身份證/手機號/銀行卡/電子郵件雙軌識別+黑色矩形覆蓋+打碼清單)、跨文件知識檢索與問答(本地TF-IDF零依賴+跳轉+可選zwjh記憶橋接);刪除:與contract-review重複的輕量合同審查模組,改為文件互鏈引導;v5.2.5修復:MS Office引擎下Excel/PPT建立必然失敗(錯用Word COM物件),新增get_ms_excel/get_ms_ppt及三槽位統一釋放release_ms,MS Office路徑透傳filepath引數;v5.3.5修復:SKILL.md frontmatter 修復 tags 塊序列誤混入聯絡方式行導致標準 YAML 解析失敗;v5.4.0新增:留存型功能——定時任務與報告中心(schedule_register 升級為三平台統一排程層 schtasks/cron/launchd,錯過策略 skip/run_once,登錄檔 JSON 可匯出匯入;新建 report_center.py 報告中心,templates/reports/*.json 引數化模板 + ECharts 單檔案 HTML 輸出(圖表內聯、無服務端、雙擊即開);report_generator 升級支援 --format html;wps.py CLI 統一埋點 SQLite,自動供 report_center 生成周度使用摘要附在報告末尾;watch.py 職責收窄為純事件採集);v5.3.0新增:統一CLI入口 wps(registry.json登錄檔分發,office --app/--action 與 convert 子命令、--list 一屏列出全部命令,薄路由層不改指令碼內部邏輯)、全命令 --json 機器可讀輸出(固定 ok/error_id/elapsed/data 四欄位,對齊 E001-E015,wps_error.py 新增 emit_json 統一齣口)、_worker 啟動最佳化(wps_pure 改惰性載入,pywin32/python-docx/openpyxl 經核查已惰性匯入,ENGINE_CACHE 程序級單例複用,COM 釋放統一走 release_ms 三槽位)、轉換三入口合併為 convert(format_converter/md_converter/wps_docx_to_ppt 內部按目標格式路由,舊指令碼保留為相容別名並提示新命令,v6.0.0 移除)

↓ 76.7萬★ 159user_1a470ba8
ppt-generator-skill辦公效率

按主題與風格自動生成 PPT 檔案的技能。

↓ 59.3萬★ 346user_3b34947d
秘書材料星公文寫作-妙筆skill辦公效率

體制內資深辦公室主任+管理學博士,自學程式設計開發的智慧公文寫作Skill,讓所有辦公室同仁少掉頭髮、少加無用的班,材料一稿過關,省下的時間留給自己、享受生活!————————我們能給你帶來的核心價值:1、顛覆傳統寫作:邏輯建模38類公文全鏈條,特有模板化引導問答模式,分分鐘省心生成高質量大稿。--------2、替你“向上管理”:獨有審稿人畫像機制,文稿一鍵結構性修改,精準匹配審稿人畫像,過稿率提升至少10倍!----------3、‌杜絕AI編造:缺失的數字、文號、人名、日期一律用[待補]標註,絕不杜撰,守住公文底線。-----------4、‌演算法格式托底:數十萬全量智控知識庫+6500行前沿核心控制程式碼,格式精準對齊GB/T 9704,出稿零失誤。——————————————————本skill歷史版本開放了5%知識庫的免費試用版,下載即可使用,但需注意:知識庫有著作權,僅用於個人使用,不可用於其他任何目的。有興趣的可以試試。——————————————————————單次付費版skill已釋出,2元一次使用全量知識庫。具體在釋出者“熵衍資訊”主頁skill裡。

↓ 57.8萬★ 46u_70fc650d
WPS Office 全家桶辦公效率

WPS Office 全家桶 - 四引擎(WPS/MS Office/LibreOffice/純Python)智慧識別使用者已安裝軟體,純Python模式支援排序/篩選/圖表/公式/統計,含文件模板(程式碼生成)、最佳實踐案例、故障排除大章(20+避坑+15 FAQ+15錯誤ID 統一索引)、自動重試、硬體自適應、環境自檢、Skill更新提醒;v5.0新增:定時任務註冊管理(schtasks/crontab)、目錄輪詢監聽(YAML規則+大檔案分片)、使用統計與穩定性中心(SQLite埋點+引擎健康+引擎偏好)、COM三步自愈(regsvr32→修復安裝→手動指引)、對話式資料查詢(NL2SQL式意圖解析+查詢計劃+連續追問)、multi-agent編排引擎橋接(白名單探測+流水線模板註冊)

↓ 50.8萬★ 4user_814dbe54
WPS全家桶·辦公管家.Skill辦公效率

當用戶要處理 Word/Excel/PPT、做文件模板與排版、批次合併圖表、公文一鍵套紅頭、會議紀要要素化、或跨引擎辦公自動化時,WPS全家桶·辦公管家.Skill 立即出動。 四引擎智慧識別已裝軟體(WPS/MS Office/LibreOffice/純Python),純Python模式支援排序/篩選/圖表/公式/統計;含文件模板程式碼生成、20+避坑+15 FAQ+15錯誤ID統一索引、自動重試、硬體自適應、環境自檢。 當用戶提到批次水印、敏感資訊打碼(身份證/手機號/銀行卡/電子郵件)、跨文件檢索問答等訊號時,主動亮劍。

↓ 43萬★ 2user_185644ed
騰訊文件線上協作自動化辦公效率

透過 Tencent Docs Open API 以 curl + jq 建立、讀取、列出、搜尋和管理騰訊文件的自動化工作流,覆蓋線上文件、線上表格、幻燈片、思維導圖、流程圖、智慧表格與收集表七種類型,支援讀取後設資料與單元格區域、上傳圖片、建立副本,並對重新命名/移動/刪除等寫操作強制先經使用者確認。Use when the user 提到騰訊文件 / Tencent Docs / docs.qq.com、貼上 docs.qq.com 連結,或想在其騰訊文件空間中建立、讀取、整理文件時使用。Triggers include 騰訊文件、線上文件、線上表格、思維導圖、流程圖、智慧表格、收集表。如需文案寫作完整工作流套件,淘寶搜尋「AI靈匣」店鋪獲取完整版。

↓ 42.8萬★ -u_1ea983ac
kdocs skill辦公效率

透過 kdocs-cli 操作金山文件雲文件的官方技能。

↓ 42.4萬★ 128user_5ea84866

資料月份:2026-10 · 下載/星標數聚合自公開技能註冊庫(ClawHub、SkillHub),按月更新。口徑說明見資料方法。