[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-92585":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":16,"stars30d":17,"stars90d":16,"forks30d":16,"starsTrendScore":16,"compositeScore":18,"rankGlobal":10,"rankLanguage":10,"license":19,"archived":20,"fork":20,"defaultBranch":21,"hasWiki":22,"hasPages":20,"topics":23,"createdAt":10,"pushedAt":10,"updatedAt":34,"readmeContent":35,"aiSummary":36,"trendingCount":16,"starSnapshotCount":16,"syncStatus":13,"lastSyncTime":37,"discoverSource":38},92585,"hilbert-editor","aburousan\u002Fhilbert-editor","aburousan","Hilbert — an offline editor for Typst (Unofficial). Live PDF preview, physics\u002Fmath tooling, live Python\u002FJulia\u002FWolfram, and a desktop app.","https:\u002F\u002Fgithub.com\u002Faburousan\u002Fhilbert-editor",null,"JavaScript",71,2,3,1,0,16,43.03,"MIT License",false,"main",true,[24,25,26,27,28,29,30,31,32,33],"editor","electron","hilbert","latex-alternative","offline","pdf","physics","react","tauri2","typst","2026-07-22 04:02:06","# Hilbert: an unofficial scientific-writing IDE for Typst\n\n> **Unofficial.** Hilbert is an independent, community-built application. It is not\n> the Typst web app, IDE, or compiler, and is not affiliated with or endorsed by\n> the Typst team. \"Typst\" is a trademark of its respective owners; this project\n> merely builds on top of the open-source Typst compiler.\n\n> **Website:** [rousan.netlify.app\u002Fhilbert](https:\u002F\u002Frousan.netlify.app\u002Fhilbert\u002F). The\n> landing page has a feature overview and download links.\n\n> **Automatic updates:** Hilbert updates itself. Install it once and every future\n> version arrives on its own (it asks before installing). Grab it from the\n> [latest release](https:\u002F\u002Fgithub.com\u002Faburousan\u002Fhilbert-editor\u002Freleases\u002Flatest).\n> On Linux the AppImage auto-updates; the `.deb` does not.\n\nIt started as \"an offline, Overleaf-feeling place to write physics and maths,\" and\ngrew into a full scientific-writing IDE: a real code editor on the left, a live PDF\non the right, and everything in between. Equations, matrices, plots, diagrams,\ntheorems, citations, and running code are one click away instead of something you\nmemorise. It runs entirely on your machine, works offline, and can execute your\nPython, Julia, or Wolfram snippets and drop the result straight into the document.\n\n![Hilbert](docs\u002Fscreenshot.png)\n\n---\n\n## Contents\n\n- [Why you'll like it](#why-youll-like-it)\n- [Feature tour (with demos)](#feature-tour)\n- [Everything in the box](#everything-in-the-box): the full list\n- [What you need](#what-you-need)\n- [Get it (downloads & install)](#get-it)\n- [Run from source](#run-from-source)\n- [Tips](#a-few-tips) · [Troubleshooting](#troubleshooting) · [Configuration](#configuration) · [Security](#security-model)\n- [What's next](#whats-next)\n\n---\n\n## Why you'll like it\n\nThe PDF re-renders as you type, and the editor is Monaco, the same one VS Code runs\non, with real Typst hover-docs and autocomplete. The whole thing is up and usable in\nwell under a second.\n\nMost of the things you'd normally have to memorise are a click away instead:\nequations, matrices, tables, figures, theorem boxes, citations by DOI or arXiv, 2D\nand 3D plots, commutative and Feynman diagrams. Each drops in as clean, editable\nTypst that stays yours. And it'll do the actual maths: run a Python, Julia, or\nWolfram snippet and get the result back as a typeset equation, or highlight an\nexpression and simplify, solve, or integrate it where it sits.\n\nUnderneath it behaves like a real workspace. Open any folder the way you would in VS\nCode, split a document across `#include`d chapters, drag files around the tree,\nsearch the whole project at once.\n\nIt's also genuinely light: the Tauri build idles around 12 MB of memory and installs\nin under 9 MB, a fraction of what a typical Electron editor costs\n([benchmarks](docs\u002FPERFORMANCE.md)). It works offline, updates itself, and keeps\ncrashes contained (a broken tool shows an error instead of blanking the editor). On\nWindows it never flashes a console window at you.\n\n---\n\n## Feature tour\n\nA live PDF preview recompiles as you type, with zoom, fit-to-width, and a dark mode.\nDouble-click any word in the PDF to jump to it in the source.\n\n![Live preview](docs\u002Fgifs\u002Flive-preview.gif)\n\nPlot Studio is one tool for every plot: 2D functions (`y=f(x)`, implicit,\nparametric), 2D data (line, scatter, bar), and 3D surfaces, plus a one-click launch\ninto the interactive 3D studio and the Python\u002Fmatplotlib runner. It emits `cetz` and\n`cetz-plot`.\n\n![Plot Studio](docs\u002Fplot-studio.png)\n\ncetz Canvas lets you draw diagrams visually. Click shapes from a palette onto a live\npreview, then set each one's position, size, rotation, and colour. No blind\ncoordinates.\n\n![cetz Canvas](docs\u002Fgifs\u002Fcetz-canvas.gif)\n\nCommutative diagrams are drawn in a bundled, offline copy of\n[quiver](https:\u002F\u002Fgithub.com\u002Fvarkor\u002Fquiver), which produces editable `fletcher` code.\n\n![Commutative diagram with quiver](docs\u002Fgifs\u002Fquiver-diagram.gif)\n\nRun Python, Julia, or Wolfram and insert the result as text, a figure, or a typeset\nequation.\n\n![Run code to equation](docs\u002Fgifs\u002Frun-code-equation.gif)\n\nColour anything with a draggable colour-grid picker.\n\n![Text colour picker](docs\u002Fgifs\u002Ftext-colour.gif)\n\nSketch a symbol and get its Typst code (experimental).\n\n![Draw a symbol](docs\u002Fgifs\u002Fdraw-symbol.gif)\n\nCite by DOI or arXiv id: Hilbert looks the paper up, saves it to `refs.bib`, and\ncites it.\n\n![Citations](docs\u002Fgifs\u002Fcitations.gif)\n\nBrowse Typst Universe templates with a rendered preview.\n\n![Template preview](docs\u002Fgifs\u002Ftemplate-preview.gif)\n\nToggle a dark PDF preview, like Overleaf.\n\n![Dark PDF](docs\u002Fgifs\u002Fdark-pdf.gif)\n\n### More visual builders\n\nFeynman diagrams support fermion, photon, gluon, scalar, and ghost propagators,\nloops, hatched or shaded blobs, vertices, and labels, all producing editable `cetz`.\n\n![Feynman diagram builder](docs\u002Ffeynman-builder.png)\n\nMatrix Studio is a visual grid with fills, borders, brackets, and a code-array mode.\n\n![Matrix Studio](docs\u002Fmatrix-studio.png)\n\n3D Plot Studio lets you rotate a surface to the exact angle you want, then insert\nthat view.\n\n![3D Plot Studio](docs\u002Fplot3d-studio.png)\n\nFlowchart to Code: draw the logic, and it writes the `while`, `if`, and `for`.\n\n![Flowchart to code](docs\u002Fflowchart-code.png)\n\n> Everything happens on your computer. A tiny local server drives the Typst compiler\n> and (optional) code execution. Nothing leaves the machine unless you deliberately\n> turn on Google Drive or WebDAV sync.\n\n---\n\n## Everything in the box\n\nThe full list, grouped by what you're doing.\n\n### Editing & preview\n- **Monaco editor** with Typst highlighting, plus hover documentation and smart\n  autocomplete powered by [tinymist](https:\u002F\u002Fgithub.com\u002FMyriad-Dreamin\u002Ftinymist):\n  hover any function for its signature and docs, and get completions for every\n  builtin, package export, and label. There's also `@`-reference autocomplete and\n  image-path autocomplete inside `image(\"…\")`.\n- **Live PDF preview** that recompiles as you type, with zoom, fit-to-width, a dark\n  PDF mode, and double-click-to-source (it uses the surrounding words to land on the\n  right occurrence).\n- **Multi-file projects.** The preview compiles the project root (`main.typ` or the\n  `typst.toml` entrypoint), so `#include`d chapters that share a bibliography or\n  labels render as a whole. The root shows a MAIN badge; right-click any `.typ` and\n  choose **Set as main file** to change it.\n- A clickable **Problems** panel, a **File Outline**, resizable panes, and a live\n  word count of the rendered document (read from the PDF, so `#set`\u002F`#import`\u002Fmarkup\n  don't inflate it).\n- Control-flow completions that offer both `{ }` code and `[ ]` content bodies for\n  `if`, `for`, and `while`.\n\n### Project & file management (VS Code-style)\n- **Open Folder** makes any folder on disk the workspace (edits save straight back on\n  the desktop app and in Chrome\u002FEdge), with **File → Open Recent**.\n- **File tree**: multi-select, drag-and-drop move, rename, duplicate, delete, cut,\n  copy, paste, a right-click context menu, new file and folder (styled in-app\n  dialogs), image\u002Fasset upload, compress to `.zip`, and reveal-in-file-manager.\n- **Full-text search** across the workspace with jump-to-line.\n\n### Inserting the annoying stuff\n- Title blocks, headings, abstracts, authors, institutes.\n- Inline, block, aligned, and numbered equations (numbering on by default; toggle it\n  under the cursor with **⌘⇧N**).\n- **Matrices** (visual Matrix Studio), tables, figures, images, and lists, most with\n  a *center on page* toggle.\n- **Page Setup builder** (Formatting → Page Setup): paper size, per-side margins,\n  header\u002Ffooter, and page numbers, which writes the `#set page(...)` rule.\n- **Text formatting**: bold, italic, super- and subscript, a draggable colour picker,\n  underline, highlight, strike-through, boxed selections (fill, border, texture),\n  font-size dropdown, alignment, rotation, and small caps.\n- **Cross-references**: add a label (`= Intro \u003Csec:intro>`), type `@`, and pick it.\n- **Image editor**: crop and rotate raster images (PNG\u002FJPG) before inserting; SVGs\n  open as a safe preview.\n\n### Maths & physics\n- A **maths and physics symbol picker** (`physica`), and, experimentally, a\n  draw-a-symbol pad.\n- **Theorems, proofs, and lemmas**, plain or in coloured boxes, each kind numbered.\n- A **Physics & Cosmology menu** of ready-made, compile-checked equations: bra-kets,\n  commutators, the Dirac and Klein-Gordon equations, the QED Lagrangian, Einstein's\n  field equations, Christoffel symbols, the FRW metric, the Friedmann equations, and\n  more.\n- An **equation gallery** of fill-in templates.\n\n### Plots & diagrams\n- **Plot Studio**, the unified plotting tool: 2D functions (explicit, implicit,\n  parametric), 2D data (line, scatter, bar), 3D `cetz` surfaces, plus launchers for\n  the interactive 3D studio and the Python\u002Fmatplotlib runner.\n- **cetz Canvas**, a visual shape builder: 13 primitives (circle, ellipse, rectangle,\n  triangle, hexagon, line, arrow, arc, curve, grid, point, axes, label) with a live\n  preview and per-shape position, size (grid range \u002F radius \u002F length), rotation, and\n  colour.\n- **3D Plot Studio**, an interactive surface you rotate, then insert exactly that\n  view.\n- **Commutative diagrams** via bundled offline [quiver](https:\u002F\u002Fgithub.com\u002Fvarkor\u002Fquiver),\n  producing editable `fletcher`.\n- **Feynman diagrams** drawn visually, producing editable `cetz`.\n- **Flowchart to Code**: draw logic, get `while`, `if`, and `for`.\n- 2D plotting via `cetz` and `cetz-plot`.\n\n### Maths that computes\n- **Run code, insert result** (Python, Julia, Wolfram): take the text output, a\n  generated figure, or, in *equation mode*, write plain maths like\n  `diff(sin(x**2), x)` and get a typeset equation back automatically.\n- **Compute on a selection**: highlight an expression and simplify, solve,\n  differentiate, integrate, or evaluate it with sympy, dropped back in as an equation.\n- **Ready-made physics examples** in the runner: General Relativity with\n  [xAct](http:\u002F\u002Fwww.xact.es\u002F) (Schwarzschild curvature to the Ricci tensor and the\n  Kretschmann scalar), Penrose (conformal) diagrams, and Clebsch-Gordan and Wigner\n  3-j coefficients, as a rendered image or a typeset equation.\n\n### References & bibliography\n- A **reference and label manager** listing every label and `@reference`, flagging\n  undefined, duplicate, or unused ones.\n- A **citation manager**: look a paper up by DOI or arXiv id, save it to `refs.bib`,\n  and cite it with `@key` (the bibliography section is added for you).\n\n### Getting things in and out\n- Import data (CSV, JSON, YAML, TOML) with the matching Typst reader wired up.\n- **Import your own fonts** (`.ttf` \u002F `.otf`) via File → Import Font.\n- **Templates** from Typst Universe with a rendered preview.\n- **Git**: init, commit, push to GitHub.\n- **Export** to PDF, HTML, `.typ`, a local folder, Google Drive, or WebDAV\n  (Nextcloud \u002F ownCloud).\n- **Manage installed Typst packages**: search, download, remove.\n\n### Reliability & platform\n- **Auto-updater** (Tauri build): checks on launch, asks before installing, and is\n  best-effort. If the check can't run, the app still starts normally.\n- **Crash isolation**: heavy tools (3D studio, Plot Studio, whiteboard, code runner)\n  are sandboxed, so an error shows a dismissible message instead of blanking the\n  editor.\n- A failed compile keeps your last good preview; on Windows, background tools never\n  flash a console window; the backend survives a misbehaving tool.\n- **Offline**: bundled Typst packages are cached locally, so documents compile with\n  no network and no downloads.\n\n---\n\n## What you need\n\nHilbert drives external tools rather than reimplementing them, so a couple of things\nmust be on your `PATH`:\n\n- **[Typst CLI](https:\u002F\u002Fgithub.com\u002Ftypst\u002Ftypst) 0.14 or newer**, required for\n  compiling. Install it with `brew install typst`, `winget install Typst.Typst`,\n  `cargo install typst-cli`, or a release binary. Verify with `typst --version`.\n- Optional but recommended: **[tinymist](https:\u002F\u002Fgithub.com\u002FMyriad-Dreamin\u002Ftinymist)**,\n  the Typst language server, for hover docs and smart autocomplete.\n  - **macOS:** `brew install tinymist`\n  - **Windows:** `winget install Myriad-Dreamin.tinymist` (or `scoop install tinymist`)\n  - **Linux, or any OS with Rust:** `cargo install tinymist`\n  Without it the editor still works fully; those two features just stay quiet.\n- Optional, only for running code:\n  - **Python 3** with `numpy`, `matplotlib`, `sympy`\n  - **Julia** (`Latexify` for equation mode)\n  - **WolframScript**\n- **Node.js 18+**, only if you run from source.\n\n---\n\n## Get it\n\nThe **[landing page](https:\u002F\u002Frousan.netlify.app\u002Fhilbert\u002F)** has an overview and\ndownload links. Prebuilt installers are on the\n[**Releases**](https:\u002F\u002Fgithub.com\u002Faburousan\u002Fhilbert-editor\u002Freleases) page. The app is\ntiny (~9 MB), light on memory, and it auto-updates.\n\n| Platform | Download |\n| --- | --- |\n| **Windows** | `.exe` \u002F `.msi` |\n| **macOS, Apple Silicon** | `…-macOS-arm64.dmg` |\n| **macOS, Intel** | `…-macOS-x64.dmg` |\n| **Linux** | `.AppImage` (auto-updates) \u002F `.deb` |\n\nOn a Mac, pick Apple Silicon for M-series chips and Intel for older Macs (*About This\nMac* tells you which). The desktop app still needs the **Typst CLI** on your `PATH`.\n\n> **macOS, first launch.** The app isn't notarised (there's no paid Apple developer\n> account), so macOS quarantines it, and renaming or moving the `.app` can break its\n> ad-hoc signature. If it won't open or says it's *\"damaged\"*, run these two commands\n> once:\n> ```bash\n> xattr -cr \"\u002FApplications\u002FHilbert.app\"\n> codesign --force --deep --sign - \"\u002FApplications\u002FHilbert.app\"\n> ```\n> **Run these as two separate commands, one per line.** If you paste them joined onto\n> a single line, the shell reads `--force` as an option to `xattr` and reports it as\n> unrecognised. Enter the first line, press return, then the second. (Adjust the path\n> if the app is elsewhere, e.g. `~\u002FDownloads`.) The code is open, so you can audit or\n> build it yourself. This is a one-time step.\n\n### Windows\nDownload the `.exe` (or `.msi`) from Releases and run it. It behaves like a normal\nWindows app: launching tools never flashes a console window, and a failed compile\nshows an error panel instead of closing. You still need the **Typst CLI** on `PATH`.\n\n---\n\n## Run from source\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Faburousan\u002Fhilbert-editor.git\ncd hilbert-editor\nbash scripts\u002Fsetup.sh   # installs Typst + Python deps and runs npm install (macOS\u002FLinux)\nnpm run dev             # Vite UI on http:\u002F\u002Flocalhost:5173, backend on http:\u002F\u002F127.0.0.1:3001\n```\n`npm run dev` serves the UI with Vite and starts the Rust backend (the Tauri binary\nin headless mode) on port 3001, so it needs the sibling `..\u002Ftypst-editor-tauri`\ncheckout and a Rust toolchain. To build the desktop app, run `cargo tauri build` in\n`..\u002Ftypst-editor-tauri`.\n\nOn Windows, run from source with:\n```powershell\nwinget install Typst.Typst\ngit clone https:\u002F\u002Fgithub.com\u002Faburousan\u002Fhilbert-editor.git\ncd hilbert-editor ; npm install ; npm run dev   # then open http:\u002F\u002Flocalhost:5173\n```\n\n---\n\n## A few tips\n\n- **Compile**: edits recompile after a short pause; **⌘S** saves and recompiles now.\n- **Numbering**: put the cursor on a heading or block equation and press **⌘⇧N**.\n- **Cross-references**: add a label (`= Intro \u003Csec:intro>`), then type `@` and pick it.\n- **Cite a paper**: Insert → References → Citations, look it up by DOI\u002FarXiv, hit **Cite**.\n- **Plots**: Insert → Plots → **Plot Studio** for everything, or **cetz Canvas** for\n  free-form diagrams.\n- **Compute**: select an expression, Insert → Math → Compute Selection.\n\n---\n\n## Troubleshooting\n\n- **macOS says the app is \"damaged\" or won't open.** This is Gatekeeper quarantine, or\n  a broken signature from renaming the `.app`. Fix it with the two commands in\n  [Get it](#get-it), run **one per line, as two separate commands** (pasting them onto\n  one line makes the shell treat `--force` as an argument to `xattr`, and it errors):\n  ```bash\n  xattr -cr \"\u002FApplications\u002FHilbert.app\"\n  codesign --force --deep --sign - \"\u002FApplications\u002FHilbert.app\"\n  ```\n- **Window is blank, or it says \"couldn't start its local engine\".** Something else is\n  using port 3001. Quit it and reopen.\n- **It opens but nothing compiles.** The **Typst CLI** isn't installed or on `PATH`.\n  Install it and confirm `typst --version` works.\n- **A template fails with an error inside `@preview\u002F…`.** That's a package\n  compatibility problem, not the editor: some Typst Universe templates pull in helper\n  packages written for an older Typst. Pick a different template, or match the Typst\n  version the template expects. Your own document is fine.\n- **`npm run dev` only prints the concurrently line and stops.** The dev dependencies\n  aren't installed. Run a full `npm install` (not `--production`).\n\n---\n\n## Configuration\n\n| Variable | Default | Purpose |\n| --- | --- | --- |\n| `ALLOW_CODE_EXECUTION` | `1` | Set to `0` to disable all code execution. |\n| `EXEC_TIMEOUT_MS` | `45000` | Per-run wall-clock limit. |\n\nInterpreters (including conda environments) are auto-detected; choose the default per\nlanguage in **App Settings → Interpreters**. Your documents live in\n`~\u002FDocuments\u002FHilbert`.\n\n---\n\n## Security model\n\nThe backend is built for **local, single-user** use:\n- Binds to `127.0.0.1` only; CORS limited to `localhost` \u002F `127.0.0.1`.\n- File access is confined to the workspace (path traversal rejected).\n- Code execution is opt-outable (`ALLOW_CODE_EXECUTION=0`), time-limited, runs in a\n  `sandbox\u002F` dir, and is screened for process \u002F network \u002F shell \u002F destructive calls.\n\nThese are guardrails, not a hardened sandbox: code runs with your user privileges.\nDon't expose port 3001 to a network, and don't run untrusted documents. For untrusted\nuse you'd want real OS-level isolation (a container or VM).\n\nCloud credentials (Google Drive OAuth, WebDAV) live only in your browser's local\nstorage.\n\n---\n\n## What's next\n\nHilbert already does most of what a scientific-writing IDE should, so the next\nreleases are about making what's here rock-solid: fixing rough edges, and making it\nfaster and lighter (tracked in the [benchmarks](docs\u002FPERFORMANCE.md)) rather than\npiling on more. If something breaks or feels slow, that's exactly what I want to hear.\nOpen a [Discussion](https:\u002F\u002Fgithub.com\u002Faburousan\u002Fhilbert-editor\u002Fdiscussions).\n\n## Support\n\nBuilt and maintained by [Kazi Abu Rousan](https:\u002F\u002Frousan.netlify.app\u002F). If it saves\nyou time, you can [buy me a coffee](https:\u002F\u002Fbuymeacoffee.com\u002Frousan). It's genuinely\nappreciated (there's also a button in the app's **About** dialog).\n\n## License\n\nMIT; see [LICENSE](LICENSE). Bundled third-party software:\n[quiver](https:\u002F\u002Fgithub.com\u002Fvarkor\u002Fquiver) (MIT, © varkor) with\n[KaTeX](https:\u002F\u002Fkatex.org\u002F) (MIT) under `public\u002Fquiver\u002F`.\n","Hilbert 是一款面向科学写作的离线 Typst 编辑器，专为物理、数学等领域的文档创作设计。核心功能包括实时 PDF 预览、内置 Monaco 代码编辑器（支持 Typst 语法高亮与自动补全）、一键插入公式\u002F矩阵\u002F图表\u002F定理框\u002F引用（DOI\u002FarXiv），并原生支持在文档中执行 Python\u002FJulia\u002FWolfram 代码片段，将计算结果直接嵌入排版。基于 Tauri 构建，轻量高效，完全离线运行。适用于科研人员、教师及学生撰写论文、讲义、笔记等需兼顾代码计算与高质量排版的学术场景。","2026-07-09 02:30:25","CREATED_QUERY"]