SheetWise Documentation

PyPI version Python 3.10+ License: MIT

Welcome to SheetWise

SheetWise is a Python package for encoding spreadsheets for Large Language Models, implementing the SpreadsheetLLM research framework from Microsoft Research.

Key Features

  • Intelligent Compression: Up to 96% reduction in token usage

  • Auto-Configuration: Automatically optimizes compression settings

  • Multi-Table Support: Handles complex spreadsheets with multiple tables

  • Structural Analysis: Identifies and preserves important elements

  • Format-Aware: Preserves data type and formatting information

  • Formula Analysis: Extract and simplify Excel formulas

  • Multi-Sheet Support: Process entire workbooks

  • Visualization Tools: Generate visual reports

Quick Start

Installation

pip install sheetwise

Basic Usage

import pandas as pd
from sheetwise import SpreadsheetLLM

# Initialize the framework
sllm = SpreadsheetLLM()

# Load your spreadsheet
df = pd.read_excel("your_spreadsheet.xlsx")

# Compress and encode for LLM use
llm_ready_text = sllm.compress_and_encode_for_llm(df)

# Use this text with ChatGPT/Claude
print(llm_ready_text)

Table of Contents

Indices and tables