tessl install tessl/pypi-pyexcel-xlsx@0.6.0A wrapper library to read, manipulate and write data in xlsx and xlsm format
Agent Success
Agent success rate when using this tile
76%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.38x
Baseline
Agent success rate without this tile
55%
A small utility that relies on the XLSX plugin to let the spreadsheet toolkit read and write workbooks from disk paths, in-memory streams, and raw content bytes while keeping sheet order and empty sheets intact.
fixtures/sample.xlsx returns ordered sheets { "Budget": [["Item", "Cost"], ["Lunch", 12]], "Empty": [] }, preserving sheet order and the empty sheet. @test{ "Log": [["Row"], ["A"], ["B"]] }, the loader returns that mapping; writing { "Log": [["Row"], ["C"]], "Totals": [["Count", 1]] } to a new stream yields bytes that reload to the same rows. @test{ "Scores": [["Name", "Score"], ["Ada", 9], ["Turing", 10]] }, the loader returns that mapping; serializing { "Scores": [["Name", "Score"], ["Ada", 9], ["Turing", 10]] } back to bytes reloads to identical order and values. @test@generates
from typing import Any, BinaryIO, Dict, List, OrderedDict
def load_from_path(path: str) -> OrderedDict[str, List[List[Any]]]:
"""Load workbook data from a filesystem path, preserving sheet order and empty sheets."""
def load_from_stream(stream: BinaryIO) -> OrderedDict[str, List[List[Any]]]:
"""Load workbook data from an open binary stream; the stream may be reused after rewind."""
def load_from_content(content: bytes) -> OrderedDict[str, List[List[Any]]]:
"""Load workbook data from raw bytes."""
def save_to_path(data: Dict[str, List[List[Any]]], path: str) -> None:
"""Write sheet data to a filesystem path, preserving sheet order."""
def save_to_stream(data: Dict[str, List[List[Any]]]) -> bytes:
"""Write sheet data into an in-memory binary stream and return its bytes."""
def save_to_content(data: Dict[str, List[List[Any]]]) -> bytes:
"""Serialize sheet data to raw bytes suitable for reloading."""Spreadsheet read/write framework with plugin hooks.
Registers the XLSX IO plugin for file, memory stream, and content bytes handling.