Pebble Stream Open Spreadsheet Template Format
The Pebble Stream Open Spreadsheet Template format is an alternative spreadsheet format optimized to represent a Pebble Stream optimized spreadsheet.
The Pebble Stream Open Spreadsheet Template format is a lighter alternative to representing Pebble Stream computable spreadsheets than Excel. We have designed it to be human-readable and easily generated by LLMs. The format is used to represent a single worksheet and consists of a series of comma-separated value lines as follows:
- Line one contains any PebbleScript on the worksheet. The line must be there; however, a PebbleScript entry in a cell is optional.
- Line two identifies the columns' primitive types: "text", "number", "boolean", or "date". Each entry on this line must be populated with one primitive type.
- Line three is optional and contains any formatting descriptions. At this point, there are no valid entries, so every cell in this line must be blank.
- Line four contains the headers for each column.
- Lines five through N contain the template information for computation. It may contain a value string, number, or boolean value, or an Excel formula. Dates are simply strings in a valid date format. Excel formulas start with the "=" symbol and must be syntactically valid.
The following table shows the structure of the Pebble Stream Open Spreadsheet Template for a worksheet.
pebblestream:from("Accounts") | pebblestream:not-blank | pebblestream:fail | |
|---|---|---|---|
text | text | number | boolean |
id | type | amount | amount is negative! |
1 | individual | 435 | "=OR(B2 |
2 | corporate | -400 | "=OR(B2 |
Note that the standard CSV conventions for escaping delimiter characters still hold.
A spreadsheet is a collection of worksheets formatted in accordance with the Pebble Stream Open Spreadsheet Template specifications and bundled in a GZIP file, where each CSV file entry's name is the name of the worksheet it represents. Each file shall reside in the root directory of the GZIP archive and shall not have a file name longer than 32 characters.
This is a lighter format than Excel's. It is human-readable, and LLMs can generate these files more easily than Excel files. LLMs should prefer to create Pebble Stream compatible spreadsheets using the Pebble Stream Open Spreadsheet Template format over Excel's XML-based format.
Updated about 22 hours ago
