bilig-workpaper 0.32.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Greg Konush
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,71 @@
1
+ # bilig-workpaper
2
+
3
+ Bilig WorkPaper runtime for Node.js services, agent tools, and server-side spreadsheet formulas.
4
+
5
+ This is the unscoped npm entrypoint for the Bilig headless runtime. Use it when business logic is easiest to review as workbook cells and formulas, but the calculation needs to run in a backend service, queue worker, serverless route, test, or coding-agent tool.
6
+
7
+ ## Install
8
+
9
+ ```sh
10
+ npm install bilig-workpaper
11
+ ```
12
+
13
+ ## Use A WorkPaper In Node
14
+
15
+ ```ts
16
+ import { WorkPaper } from 'bilig-workpaper'
17
+
18
+ const workbook = WorkPaper.buildFromSheets({
19
+ Inputs: [
20
+ ['Metric', 'Value'],
21
+ ['Units', 40],
22
+ ['Price', 1200],
23
+ ],
24
+ Summary: [
25
+ ['Metric', 'Value'],
26
+ ['Revenue', '=Inputs!B2*Inputs!B3'],
27
+ ],
28
+ })
29
+
30
+ const inputs = workbook.getSheetId('Inputs')
31
+ const summary = workbook.getSheetId('Summary')
32
+
33
+ if (inputs === undefined || summary === undefined) {
34
+ throw new Error('Expected sheets to exist')
35
+ }
36
+
37
+ workbook.setCellContents({ sheet: inputs, row: 1, col: 1 }, 48)
38
+ workbook.setCellContents({ sheet: inputs, row: 2, col: 1 }, 1500)
39
+
40
+ console.log(workbook.getCellValue({ sheet: summary, row: 1, col: 1 }))
41
+ console.log(workbook.exportSnapshot())
42
+
43
+ workbook.dispose()
44
+ ```
45
+
46
+ ## XLSX Import And Export
47
+
48
+ ```ts
49
+ import { WorkPaper } from 'bilig-workpaper'
50
+ import { exportXlsx, importXlsx } from 'bilig-workpaper/xlsx'
51
+ ```
52
+
53
+ Use `xlsx-formula-recalc` when you only need to edit and recalculate XLSX files. Use `exceljs-formula-recalc` when you already use ExcelJS and need recalculated formula results after changing inputs.
54
+
55
+ ## Agent Tools And MCP
56
+
57
+ ```ts
58
+ import { createWorkPaperMcpServer } from 'bilig-workpaper/mcp'
59
+ ```
60
+
61
+ For a runnable starter, use:
62
+
63
+ ```sh
64
+ npm create @bilig/workpaper
65
+ ```
66
+
67
+ ## Scope
68
+
69
+ Bilig is not a desktop Excel clone. It is a formula workbook runtime for service-owned calculations, JSON persistence, XLSX import/export, and agent-readable readback. Unsupported Excel functions, external workbook links, macros, and volatile functions may need review.
70
+
71
+ Full docs: <https://proompteng.github.io/bilig/>
@@ -0,0 +1 @@
1
+ export * from '@bilig/headless';
package/dist/index.js ADDED
@@ -0,0 +1,2 @@
1
+ export * from '@bilig/headless';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAA"}
package/dist/mcp.d.ts ADDED
@@ -0,0 +1 @@
1
+ export * from '@bilig/headless/mcp';
package/dist/mcp.js ADDED
@@ -0,0 +1,2 @@
1
+ export * from '@bilig/headless/mcp';
2
+ //# sourceMappingURL=mcp.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mcp.js","sourceRoot":"","sources":["../src/mcp.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAA"}
package/dist/xlsx.d.ts ADDED
@@ -0,0 +1 @@
1
+ export * from '@bilig/headless/xlsx';
package/dist/xlsx.js ADDED
@@ -0,0 +1,2 @@
1
+ export * from '@bilig/headless/xlsx';
2
+ //# sourceMappingURL=xlsx.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"xlsx.js","sourceRoot":"","sources":["../src/xlsx.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAA"}
package/package.json ADDED
@@ -0,0 +1,78 @@
1
+ {
2
+ "name": "bilig-workpaper",
3
+ "version": "0.32.1",
4
+ "description": "Bilig WorkPaper runtime for Node.js services, agent tools, and server-side spreadsheet formulas.",
5
+ "keywords": [
6
+ "agent-tools",
7
+ "ai-agents",
8
+ "bilig",
9
+ "bilig-workpaper",
10
+ "excel",
11
+ "excel-calculation-engine",
12
+ "excel-formulas",
13
+ "exceljs",
14
+ "formula-engine",
15
+ "formula-recalculation",
16
+ "headless-spreadsheet",
17
+ "hyperformula",
18
+ "node",
19
+ "server-side-spreadsheet",
20
+ "sheetjs",
21
+ "spreadsheet",
22
+ "spreadsheet-automation",
23
+ "spreadsheet-engine",
24
+ "spreadsheet-formulas",
25
+ "workbook",
26
+ "workbook-api",
27
+ "workpaper",
28
+ "xlsx",
29
+ "xlsx-calc",
30
+ "xlsx-formula",
31
+ "xlsx-recalculation"
32
+ ],
33
+ "homepage": "https://proompteng.github.io/bilig/",
34
+ "bugs": {
35
+ "url": "https://github.com/proompteng/bilig/issues"
36
+ },
37
+ "license": "MIT",
38
+ "repository": {
39
+ "type": "git",
40
+ "url": "git+https://github.com/proompteng/bilig.git",
41
+ "directory": "packages/bilig"
42
+ },
43
+ "files": [
44
+ "dist",
45
+ "README.md",
46
+ "LICENSE"
47
+ ],
48
+ "type": "module",
49
+ "sideEffects": false,
50
+ "main": "./dist/index.js",
51
+ "types": "./dist/index.d.ts",
52
+ "exports": {
53
+ ".": {
54
+ "types": "./dist/index.d.ts",
55
+ "import": "./dist/index.js"
56
+ },
57
+ "./mcp": {
58
+ "types": "./dist/mcp.d.ts",
59
+ "import": "./dist/mcp.js"
60
+ },
61
+ "./xlsx": {
62
+ "types": "./dist/xlsx.d.ts",
63
+ "import": "./dist/xlsx.js"
64
+ }
65
+ },
66
+ "publishConfig": {
67
+ "access": "public"
68
+ },
69
+ "dependencies": {
70
+ "@bilig/headless": "0.32.1"
71
+ },
72
+ "engines": {
73
+ "node": ">=22.0.0"
74
+ },
75
+ "scripts": {
76
+ "build": "pnpm --dir ../.. --filter @bilig/headless build && rm -rf dist tsconfig.tsbuildinfo && tsc -p tsconfig.json"
77
+ }
78
+ }