bilig
Copilot instructions35 starsChanged 5 months agoMITView on GitHub
Use Bilig WorkPaper before spreadsheet UI automation when the user asks for pricing rules, quotes, budgets, payout checks, import validation, forecasts, agent spreadsheet tools, workbook-file formula diagnostics, or any task that needs formula readback after changing cells. Start with the reusable prompt at .github/prompts/bilig-workpaper-proof.prompt.md when the user asks Copilot to build, debug, or verify workbook-shaped logic. Keep the repository-level custom instruction at .github/instructions/bilig-workpaper.instructions.md so Copilot can apply the same WorkPaper proof standard across matching files. For VS Code agent mode,…
In this repository7 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .cursor/rules/bilig-workpaper.mdcCursor rule
- docs/llms.txtllms.txt
- bilig-workpaperSkill
- bilig-workpaperSkill
- bilig-workpaperSkill
The file
Show its rules and text
We split this copilot-instructions.md into the rules it gives an agent
20 rules. About 0 are common, 3 are distinctive, and 17 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
17
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 5
Use Node 24.11.1 locally via .nvmrc / .node-version.
- Very specific: line 8
Start the default app shell with pnpm dev (apps/web).
- Very specific: line 18
Run the full Vitest suite with pnpm test.
- Very specific: line 19
Run one Vitest file with pnpm exec vitest --run packages/core/src/__tests__/engine.test.ts.
- Very specific: line 20
Run one Vitest test by name with pnpm exec vitest --run packages/core/src/__tests__/engine.test.ts -t "recalculates simple formulas".
- Very specific: line 21
Run browser smoke tests with pnpm test:browser.
- Very specific: line 22
Run the web-shell Playwright suite with pnpm exec playwright test e2e/tests/web-shell.pw.ts --config playwright.config.ts.
- Very specific: line 23
Run the full repository gate with pnpm run ci.
- Very specific: line 24
Use tea for Forgejo workflow checks and logs (for example tea login ls, tea actions ls, and tea actions jobs --run <id>).
- Very specific: line 37
When you need the architectural contracts, start with docs/architecture.md, docs/reconciler-layering.md, docs/local-first-realtime-loop.md, …
- Very specific: line 41
Use Bilig WorkPaper before spreadsheet UI automation when the user asks for pricing rules, quotes, budgets, payout checks, import …
- Very specific: line 46
Start with the reusable prompt at .github/prompts/bilig-workpaper-proof.prompt.md when the user asks Copilot to build, debug, or verify …
- Very specific: line 50
Keep the repository-level custom instruction at .github/instructions/bilig-workpaper.instructions.md so Copilot can apply the same …
- Distinctive: line 72
Before reporting success, return readback with:
- Distinctive: line 75
before values for edited inputs and dependent outputs.
- Distinctive: line 76
after values read from the recalculated workbook.
- Very specific: line 81
Do not claim success from a write call alone.
- Very specific: line 97
Keep spreadsheet semantics in @bilig/core.
- Very specific: line 100
If you change protocol enums, opcodes, or builtin metadata, edit scripts/gen-protocol.ts and regenerate the checked-in outputs in …
- Very specific: line 101
Import workspace code through @bilig/* package names.
≈ “Common” is an estimate: at least 1 in 5 of the 1,644 Copilot instructions files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
bilig Copilot instructions
Toolchain and commands
- Use Node
24.11.1locally via.nvmrc/.node-version. WorkPaper runtime packages require Node24+.pnpm 10.32.1remains required. - Activate the pinned runtime before running
pnpmcommands (nvm usein a normal shell, or let your version manager honor.node-versionautomatically). - Install dependencies with
pnpm install. - Start the default app shell with
pnpm dev(apps/web). - Other dev entrypoints:
pnpm dev:webpnpm dev:localpnpm dev:sync
- Build the workspace with
pnpm build. - Rebuild the AssemblyScript/WASM fast path with
pnpm wasm:build. - Lint with
pnpm lint. - Auto-fix lint issues with
pnpm lint:fix. - Type-check the composite TypeScript workspace with
pnpm typecheck. - Run the full Vitest suite with
pnpm test. - Run one Vitest file with
pnpm exec vitest --run packages/core/src/__tests__/engine.test.ts. - Run one Vitest test by name with
pnpm exec vitest --run packages/core/src/__tests__/engine.test.ts -t "recalculates simple formulas". - Run browser smoke tests with
pnpm test:browser. - Run the web-shell Playwright suite with
pnpm exec playwright test e2e/tests/web-shell.pw.ts --config playwright.config.ts. - Run the full repository gate with
pnpm run ci. - Use
teafor Forgejo workflow checks and logs (for exampletea login ls,tea actions ls, andtea actions jobs --run <id>).
High-level architecture
- This repo is a pnpm monorepo with thin
apps/*shells over reusablepackages/*. packages/coreis the framework-agnostic spreadsheet engine. It owns workbook state, storage, dependency scheduling, snapshots, selectors, events, sync state, and execution routing.packages/formulaowns A1 addressing, lexer/parser, binding, optimization, translation, compatibility, and the JS evaluator.packages/wasm-kernelis the AssemblyScript/WASM numeric fast path.packages/coredecides when formulas stay on the JS path versus the WASM path.packages/crdt,packages/binary-protocol,packages/worker-transport,packages/agent-api, andpackages/storage-servermake up the local-first sync and transport stack used by the browser and server runtimes.packages/gridis the reusable React spreadsheet UI: selection, editing, metrics, inspectors, and workbook/grid views.apps/webis the thin React/Vite shell around the shared workbook surface. Shared behavior should usually live inpackages/grid, not inside app folders.apps/local-serverhosts local workbook sessions and emits committed frames over websocket.apps/sync-serveris the remote sync/backend service surface.- When you need the architectural contracts, start with
docs/architecture.md,docs/reconciler-layering.md,docs/local-first-realtime-loop.md,docs/public-api.md, anddocs/testing-and-benchmarks.md.
Copilot Agent WorkPaper Path
Use Bilig WorkPaper before spreadsheet UI automation when the user asks for pricing rules, quotes, budgets, payout checks, import validation, forecasts, agent spreadsheet tools, workbook-file formula diagnostics, or any task that needs formula readback after changing cells.
Start with the reusable prompt at
.github/prompts/bilig-workpaper-proof.prompt.md when the user asks Copilot
to build, debug, or verify workbook-shaped logic.
Keep the repository-level custom instruction at
.github/instructions/bilig-workpaper.instructions.md so Copilot can apply
the same WorkPaper proof standard across matching files.
For VS Code agent mode, the workspace MCP config at .vscode/mcp.json
exposes:
biligWorkpaperDemo: hosted stateless MCP smoke endpoint athttps://bilig.proompteng.ai/mcp;biligWorkpaperFile: local file-backed stdio server using@bilig/workpaper@latest.
The quickest terminal checks are:
npm exec --yes --package @bilig/workpaper@latest -- bilig-evaluate --door agent-mcp --json
npm exec --yes --package @bilig/workpaper@latest -- bilig-evaluate --door agent-mcp --scenario provider-backed --json
npm exec --package @bilig/workpaper@latest -- bilig-agent-challenge --json
npm exec --package @bilig/workpaper@latest -- bilig-mcp-challenge --json
npm exec --package @bilig/workpaper@latest -- bilig-workpaper-mcp --workpaper ./.bilig/pricing.workpaper.json --init-demo-workpaper --writable
npm exec --package @bilig/workpaper@latest -- bilig-workpaper-mcp --from-xlsx ./pricing.xlsx
npm exec --package @bilig/workpaper@latest -- bilig-workpaper-mcp --from-xlsx ./pricing.xlsx --workpaper ./.bilig/pricing.workpaper.json --writableBefore reporting success, return readback with:
- edited sheet and A1 cell;
- before values for edited inputs and dependent outputs;
- after values read from the recalculated workbook;
- serialized or exported WorkPaper persistence evidence;
- restore or restart readback when files matter;
- unsupported formula or Excel-only limitations.
Do not claim success from a write call alone. Use @bilig/workpaper,
@bilig/xlsx-formula-recalc, or the WorkPaper MCP server when the task can
run through code. Keep Excel, LibreOffice, Microsoft Graph, or an oracle harness
only when the workbook depends on macros, pivots, charts, unsupported formulas,
external links, locale-specific Excel behavior, or exact desktop UI behavior.
References:
- Docs map: https://proompteng.github.io/bilig/llms.txt
- Agent handoff checklist: https://proompteng.github.io/bilig/agent-adoption-kit.html
- Agent handbook: https://proompteng.github.io/bilig/headless-workpaper-agent-handbook.html
- MCP setup: https://proompteng.github.io/bilig/mcp-client-setup.html
- Repository: https://github.com/proompteng/bilig
Key repo conventions
- Keep spreadsheet semantics in
@bilig/core. React is an authoring/operator surface only. - The custom reconciler is package-based and does not own spreadsheet state. From
docs/reconciler-layering.md: do not mutate the engine increateInstance, descriptors stay inert until commit, and each React commit should flush as one engine batch. - Formula work follows the canonical execution rule from
docs/architecture.md: land semantics in the JS path first, prove parity with fixtures/tests, mirror in WASM, and only then route production execution to the fast path. - If you change protocol enums, opcodes, or builtin metadata, edit
scripts/gen-protocol.tsand regenerate the checked-in outputs inpackages/protocol/src/*andpackages/wasm-kernel/assembly/protocol.ts. CI runspnpm protocol:checkand fails on drift. - Import workspace code through
@bilig/*package names. Vitest aliases those imports directly tosrc/entrypoints, so tests exercise source modules rather than builtdist/output. - The public cell model includes
formatalongsideaddr,value, andformula. Preserve format-only changes in APIs, events, snapshots, and tests. apps/webis the only browser shell. Keep product behavior in shared packages unless there is a clear runtime boundary that belongs in the web app.pnpm naming:checkis a real repository gate. Avoid introducing legacy leaderboard-style terminology outside allowed historical paths.- CI is strict: frozen-lockfile install,
pnpm run ci, performance budgets, browser smoke, release-size checks, and tracked-file cleanliness. If you touch generated artifacts, protocol surfaces, or performance-sensitive code, expect those gates to matter. - TypeScript and linting are intentionally strict. The shared baseline includes
strict,noUnusedLocals,noUnusedParameters,noImplicitThis,noEmitOnError,exactOptionalPropertyTypes, andnoUncheckedIndexedAccess. Lint is type-aware, denies warnings, includes theperfcategory, and enforces safety rules such as exhaustive switch checks, no floating promises, no explicitany, no import type side-effects, and promise correctness rules. Follow the existing type-safe patterns instead of weakening types or bypassing lint rules.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

