Xlsx 标志

Xlsx

组织
sinaptik-ai
xlsx

Use this skill any time a spreadsheet file is the primary input or output — opening, reading, editing, or creating .xlsx, .xlsm, .csv, or .tsv files. Trigger for data formatting, formula creation, charting, financial modeling, or converting between tabular formats. Also trigger for cleaning messy tabular data into proper spreadsheets.

Add to TypingMind

概览

发布者sinaptik-ai
代码仓库starpod
技能名称xlsx
星标数
80
复刻数
20
附带文件
5
许可协议MIT
链接
  • Markdown 格式的指令

    模型按需加载 SKILL.md 文件,因此只有在请求确实与该技能匹配时才会消耗 Token。

  • 兼容任何大语言模型

    AI 技能采用纯 Markdown,而非特定提供商的代码,因此可搭配 GPT、Claude、Gemini、Grok 或本地模型使用。

  • 5 个附带文件

    模型执行任务时可读取的脚本、模板和参考资料。这些文件为只读文件,绝不会被执行。

  • 开源

    由 sinaptik-ai 发布于 GitHub。请在安装前查看技能的源文件。

安装

在 TypingMind 中安装 Xlsx AI 技能,即可搭配任意大语言模型使用;也可以将其放入其他支持读取 SKILL.md 的智能体中。

1

安装到 TypingMind

TypingMind 可直接从 GitHub 文件夹安装技能:读取 SKILL.md,打包资源文件,并将结果保存在本地。

  1. 打开应用,前往“插件 → 技能”。
  2. 选择“从 GitHub 安装”。
  3. 粘贴下方的技能文件夹 URL 并确认。
    https://github.com/sinaptik-ai/starpod/tree/main/crates/starpod/skills/xlsx
  4. 请在每个需要使用该技能的聊天中启用它。
依次选择“插件 → 技能 → 添加技能 → 从 GitHub URL 导入”,然后粘贴文件夹 URL 并点击“继续”。
2

安装到其他智能体

任何支持 Agent Skills 格式的智能体都可以使用此技能,只需将文件夹复制到该智能体的技能目录中。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/sinaptik-ai/starpod.git /tmp/starpod
mkdir -p .claude/skills
cp -r /tmp/starpod/crates/starpod/skills/xlsx .claude/skills/xlsx
复制后,请重启 Claude Code,以加载新技能。

在 TypingMind 中使用此技能

在任意 TypingMind 聊天中启用 Xlsx,后续即可交由模型处理。技能的名称和描述会放在系统提示词中,一旦请求匹配,模型就会自动加载完整指令,无需您手动调用,且在实际使用前不会消耗 Token。

一旦请求与技能匹配,模型就会自动加载 Xlsx。

兼容任何 AI 模型

AI 技能是纯 Markdown 指令,而非特定提供商的代码,因此 Xlsx 不局限于最初适配的模型。只需在 TypingMind 中安装一次,即可搭配 GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 或您自行运行的本地模型使用,全程使用您自己的 API 密钥。

  • 仅在需要时加载

    系统提示词中仅包含技能名称和描述。首次遇到匹配的请求时才会加载完整指令,因此技能未使用时,这些指令不会消耗 Token。

  • 在聊天中切换模型

    技能是指令而非代码,因此切换模型不会导致技能失效,新模型会读取同一个 SKILL.md。

技能指令

这是模型会加载的 SKILL.md 内容。请在安装前阅读,因为技能就是模型将遵循的指令。

XLSX Skill

Decision Tree

TaskTool
Data analysis, bulk operationspandas
Formulas, formatting, stylesopenpyxl
High-performance chart creationxlsxwriter
Read calculated values (no formulas)openpyxl with data_only=True

CRITICAL: Use Excel Formulas, Not Hardcoded Values

python
# ❌ WRONG — calculating in Python
total = df['Sales'].sum()
sheet['B10'] = total

# ✅ CORRECT — let Excel calculate
sheet['B10'] = '=SUM(B2:B9)'
sheet['C5'] = '=(C4-C2)/C2'
sheet['D20'] = '=AVERAGE(D2:D19)'

Always use Excel formulas so spreadsheets remain dynamic and updateable.

Reading & Analyzing

pandas (data analysis)

python
import pandas as pd

df = pd.read_excel('file.xlsx')                          # first sheet
all_sheets = pd.read_excel('file.xlsx', sheet_name=None)  # all sheets as dict

df.describe()                         # statistics
df.groupby('Category')['Amount'].sum()  # aggregation
df.to_excel('output.xlsx', index=False)

openpyxl (preserve formulas/formatting)

python
from openpyxl import load_workbook

wb = load_workbook('file.xlsx')
sheet = wb.active
for row in sheet.iter_rows(min_row=2, values_only=True):
    print(row)

Creating New Spreadsheets

openpyxl with formulas and formatting

python
from openpyxl import Workbook
from openpyxl.styles import Font, PatternFill, Alignment, numbers

wb = Workbook()
ws = wb.active
ws.title = "Revenue Model"

# Headers
headers = ["Quarter", "Revenue", "COGS", "Gross Profit", "Margin"]
for col, h in enumerate(headers, 1):
    cell = ws.cell(row=1, column=col, value=h)
    cell.font = Font(bold=True, color="FFFFFF")
    cell.fill = PatternFill("solid", fgColor="333333")
    cell.alignment = Alignment(horizontal="center")

# Data with formulas
quarters = ["Q1", "Q2", "Q3", "Q4"]
revenues = [120000, 145000, 168000, 192000]
cogs_pct = 0.35

for i, (q, rev) in enumerate(zip(quarters, revenues), 2):
    ws.cell(row=i, column=1, value=q)
    ws.cell(row=i, column=2, value=rev).number_format = '$#,##0'
    ws.cell(row=i, column=3).value = f'=B{i}*{cogs_pct}'
    ws.cell(row=i, column=3).number_format = '$#,##0'
    ws.cell(row=i, column=4).value = f'=B{i}-C{i}'
    ws.cell(row=i, column=4).number_format = '$#,##0'
    ws.cell(row=i, column=5).value = f'=D{i}/B{i}'
    ws.cell(row=i, column=5).number_format = '0.0%'

# Totals row
total_row = len(quarters) + 2
ws.cell(row=total_row, column=1, value="Total").font = Font(bold=True)
for col in [2, 3, 4]:
    cell = ws.cell(row=total_row, column=col)
    cell.value = f'=SUM({chr(64+col)}2:{chr(64+col)}{total_row-1})'
    cell.font = Font(bold=True)
    cell.number_format = '$#,##0'

# Column widths
for col_letter, width in [("A", 12), ("B", 15), ("C", 15), ("D", 15), ("E", 12)]:
    ws.column_dimensions[col_letter].width = width

wb.save("revenue_model.xlsx")

xlsxwriter (charts)

python
import xlsxwriter

wb = xlsxwriter.Workbook("chart_report.xlsx")
ws = wb.add_worksheet("Sales")

data = [["Month", "Sales"], ["Jan", 5000], ["Feb", 6200], ["Mar", 7100], ["Apr", 6800]]
for r, row in enumerate(data):
    for c, val in enumerate(row):
        ws.write(r, c, val)

chart = wb.add_chart({"type": "column"})
chart.add_series({
    "name": "Sales",
    "categories": ["Sales", 1, 0, len(data)-1, 0],
    "values": ["Sales", 1, 1, len(data)-1, 1],
    "fill": {"color": "#1E2761"},
})
chart.set_title({"name": "Monthly Sales"})
chart.set_size({"width": 600, "height": 400})
ws.insert_chart("D2", chart)

wb.close()

Editing Existing Files

python
from openpyxl import load_workbook

wb = load_workbook('existing.xlsx')
ws = wb['Sheet1']

ws['A1'] = 'Updated Value'
ws.insert_rows(2)               # insert row at position 2
ws.delete_cols(3)               # delete column C
new_ws = wb.create_sheet('Summary')
new_ws['A1'] = '=Sheet1!B10'    # cross-sheet reference

wb.save('modified.xlsx')

Warning: load_workbook('f.xlsx', data_only=True) reads calculated values but permanently loses formulas if saved.

Financial Model Standards

Color coding (industry standard)

ColorMeaning
Blue text (0,0,255)Hardcoded inputs / assumptions
Black text (0,0,0)All formulas and calculations
Green text (0,128,0)Cross-sheet links within workbook
Red text (255,0,0)External links to other files
Yellow backgroundKey assumptions needing attention

Number formatting

TypeFormat
Currency$#,##0 with units in header ("Revenue ($mm)")
YearsText format (avoid "2,024")
Percentages0.0% (one decimal)
Multiples0.0x (EV/EBITDA, P/E)
NegativesParentheses (123) not minus -123
ZerosDisplay as - via $#,##0;($#,##0);"-"

Formula rules

  • Place ALL assumptions in separate cells — never hardcode in formulas
  • Use =B5*(1+$B$6) not =B5*1.05
  • Document sources for hardcoded values: "Source: Company 10-K, FY2024, Page 45"
  • Test formulas on 2–3 cells before applying broadly

Recalculating Formulas

openpyxl writes formulas as strings without calculated values. Use the bundled script:

bash
python scripts/recalc.py output.xlsx [timeout_seconds]

The script:

  • Installs a LibreOffice macro on first run
  • Recalculates all formulas in all sheets
  • Scans every cell for Excel errors (#REF!, #DIV/0!, etc.)
  • Returns JSON with error locations and counts
json
{
  "status": "success",
  "total_errors": 0,
  "total_formulas": 42,
  "error_summary": {}
}

If status is "errors_found", fix the issues and re-run.

Common Pitfalls

  • Cell indices are 1-based in openpyxl (row=1, column=1 = A1)
  • data_only=True + save = formulas permanently lost
  • For large files: read_only=True for reading, write_only=True for writing
  • Specify dtypes to avoid pandas inference: pd.read_excel('f.xlsx', dtype={'id': str})
  • Always verify cross-sheet references use correct format: Sheet1!A1

附带文件

技能加载后,模型会按需读取这些文件。它们仅作为可读文件提供,绝不会被执行。

常见问题

Xlsx AI 技能有什么作用?

Use this skill any time a spreadsheet file is the primary input or output — opening, reading, editing, or creating .xlsx, .xlsm, .csv, or .tsv files. Trigger for data formatting, formula creation, charting, financial modeling, or converting between tabular formats. Also trigger for cleaning messy tabular data into proper spreadsheets.

为什么在 TypingMind 中使用 Xlsx?

因为您只需安装一次,就能搭配任何模型使用。Xlsx 采用纯 Markdown 格式,而非特定提供商专用的代码,因此同一技能可用于 GPT-5、Claude、Gemini、Grok 或本地模型。您甚至可以在聊天中途切换模型,而不会影响技能的正常使用。TypingMind 使用您自己的 API 密钥,因此您直接向提供商付费,而不是按席位订阅;您的技能和聊天记录也都保留在您自己的存储空间中。

如何在 TypingMind 中安装 Xlsx?

在 TypingMind 中打开“插件 → 技能 → 从 GitHub 安装”,然后粘贴 https://github.com/sinaptik-ai/starpod/tree/main/crates/starpod/skills/xlsx。TypingMind 会读取其中的 SKILL.md,打包相关文件,并将其安装为技能,供您在各个聊天中按需启用。

哪些 AI 模型可以使用 Xlsx?

您在 TypingMind 中连接的任何模型都可以。AI 技能采用纯 Markdown 指令,而非特定提供商专用的代码,因此 GPT、Claude、Gemini、Grok 和本地模型都能在请求匹配时加载此技能。

Xlsx 可以搭配多少个 AI 模型使用?

数量不限。只要模型支持技能,您就可以将它与 Xlsx 搭配使用。GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 等模型都可以通过您自己的 API 密钥接入 TypingMind。

Xlsx AI 技能免费吗?

是的。sinaptik-ai 已在 GitHub 上根据 MIT 许可证发布了该技能。您只需向自己的 AI 提供商支付所用 Token 的费用。

什么是 AI 技能?

AI 技能是一组可复用的指令,用于教会 AI 模型完成某项特定任务。它遵循开放的 Agent Skills 格式:包含名称和描述的 SKILL.md 文件,以及模型可能需要的脚本、模板或参考文件。模型仅在您的请求与技能匹配时才会读取这些指令,因此已安装的技能在使用前不会产生任何费用。

AI 技能与插件或 MCP 服务器有何不同?

插件或 MCP 服务器为模型提供可调用的新工具,也就是在某处运行并返回结果的代码。AI 技能则为模型提供知识和流程:如何处理任务、遵循哪些步骤,以及怎样的输出才算优质。技能采用纯 Markdown 格式,因此不需要服务器、API 密钥或运行时环境,并且适用于任何模型。

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇