xiaohongshu
xiaohongshu
excel-formula-analyzer
Analyze Excel spreadsheet formulas to build dependency DAGs (Directed Acyclic Graphs) and understand calculation chains. This skill should be used when the user wants to reverse-engineer Excel formula dependencies, trace how values are calculated from inputs to outputs, validate formula logic, or...
Full skill instructions
To trace formula dependencies in an Excel workbook:
python .claude/skills/excel-formula-analyzer/scripts/trace-formula-dag.py "Workbook.xlsx" "Sheet Name" \
--table MyTable \
--columns 16-36,57,58,59
Sample output:
[Col 36] End of Harvest
= =IF([@[Actual End of Harvest]]="",[@[Expected End of Harvest]],[@[Actual ...
Depends on: ['Actual End of Harvest', 'Expected End of Harvest']
|- [31] Expected End of Harvest
= =[@[Expected Beginning of Harvest]]+[@[Harvest Window]]+[@[Additional ...
|- [28] Expected Beginning of Harvest (calculated)
|- [59] Harvest Window (INPUT)
|- [33] Additional Days of Harvest (INPUT)
This skill enables analysis of Excel spreadsheet formulas to understand how calculations flow from inputs to outputs. It builds dependency graphs (DAGs) from formula references and can help create equivalent code implementations.
Load with data_only=False to get formulas instead of computed values:
import openpyxl
wb = openpyxl.load_workbook("spreadsheet.xlsx", data_only=False)
ws = wb["SheetName"]
Excel tables use structured references like TableName[[#This Row],[Column]]. See references/structured-refs.md for complete syntax details.
Key patterns:
Table[[#This Row],[Column]] - Same-row referenceTable[Column] - Full column reference (used in XLOOKUP)Run the trace script to analyze dependencies:
python .claude/skills/excel-formula-analyzer/scripts/trace-formula-dag.py "file.xlsx" "Sheet" --columns 16-36
Translate formulas to TypeScript/Python using patterns in references/formula-patterns.md.
formulas LibraryThe Python formulas library can parse Excel formulas into ASTs, but fails on structured table references:
Error: Not a valid formula: =MEDIAN(Crops[Revenue - Copy])
The library expects A1-style references and cannot handle TableName[Column] syntax.
xlwings can use Excel's native DirectPrecedents API, but:
While Excel can convert structured refs to A1 notation (Table menu > Convert to Range), this destroys the semantic meaning and makes the formulas harder to understand.
Excel stores dates as numbers (days since 1900-01-01, with a leap year bug):
from datetime import datetime, timedelta
def excel_to_date(excel_num):
if excel_num is None or excel_num < 1:
return None
return datetime(1899, 12, 30) + timedelta(days=excel_num)
data_only=True: Returns calculated values (requires the file was saved with calculations)data_only=False: Returns formulas as stringsTo get both, load the workbook twice.
Excel implements COALESCE with IF(ISBLANK()). In code, use nullish coalescing:
const value = actualValue ?? plannedValue;
xiaohongshu
technical spec
product ux expert
database patterns
Conduct multi-agent task orchestration and workflow coordination.
Initialize project with Conductor artifacts (product definition,
Expert in web animations, transitions, and motion design using Framer Motion and CSS
Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...
PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.
Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...
Display project status, active tracks, and next actions
Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.
Generate, edit, and beat-sync AI video with leading models in one workspace.
The world's fastest calendar for remote work
Transform Your Design with AI Designer by ImgCreator.ai
Revolutionizing Video Production with AI-Powered Creativity
Extend an image past the frame and let AI fill the new aspect ratio.
Discover your celebrity doppelgänger with StarByFace!
ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.
Opus.ai: Revolutionize Your Web Experience