Open source version of fusion 360
  • C++ 95.7%
  • Shell 2.6%
  • Python 1.1%
  • CMake 0.5%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
zbuddy c2e0e79ed5
All checks were successful
ci / actionlint (push) Successful in 7s
ci / format + asan + release + window (push) Successful in 4m6s
ci / rpm + install in clean Fedora + run (push) Successful in 3m8s
ci / CachyOS ci.sh + pacman package + install + run (push) Successful in 5m57s
feat(ui): run the assistant connector headless, and install its wiki page
Connector phase 5, ported onto the 0.2.0 connector. `anvil --mcp
--headless FILE` loads FILE into a session of its own and answers every
tool through the same answerAssistant the window uses: no window, no GL,
no socket, and FILE is created when missing. screenshot, set_view and
highlight are refused with the reason. A save tool writes the document,
since headless there is no user to press Ctrl+S; with a window it is
refused, because saving stays the user's.

The released "Using an AI assistant" wiki page gains phase 4 (checks,
export, the status-bar indicator) and headless use, and is installed to
the package's doc directory and listed in the RPM's %doc. The README and
--help name the new option.

mcp-smoke.py runs the headless mode on a copy of the bracket: refused a
screenshot, it changes a parameter, saves under a new name, and the
change is in the file by --inspect, with no socket opened.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019agRhQw1WAaNBtYSyd3ajv
2026-11-27 09:57:19 -05:00
.github/workflows fix(ci): pin the CI image by the digest its tag still resolves to 2026-11-24 12:47:46 -05:00
ci test(e2e): measure every export against the model it was drawn to be 2026-11-12 05:39:07 -05:00
core feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
docs feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
packaging feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
scripts feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
tests feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
third_party feat(ui): wire M2-M5 into the application, and fix a leak on every solve 2026-08-30 01:29:41 -04:00
ui feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
.clang-format chore: add licence, formatting and editor configuration 2026-08-29 22:59:22 -04:00
.editorconfig chore: add licence, formatting and editor configuration 2026-08-29 22:59:22 -04:00
.gitignore chore: keep agent worktrees out of the repository 2026-11-12 00:55:17 -05:00
.gitmodules feat(core): add the sketch model and the SolveSpace constraint solver 2026-08-30 00:46:14 -04:00
CHANGELOG.md feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
CLAUDE.md feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
CMakeLists.txt chore(release): 0.2.0 2026-11-25 00:17:13 -05:00
CMakePresets.json build: add CMake project, presets and vendored Dear ImGui 2026-08-29 22:59:22 -04:00
LICENSE chore: add licence, formatting and editor configuration 2026-08-29 22:59:22 -04:00
PLAN.md docs: say PLAN.md was approved and built from, and re-tag two TODOs that named a closed milestone 2026-11-11 22:20:13 -05:00
PROGRESS.md feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00
README.md feat(ui): run the assistant connector headless, and install its wiki page 2026-11-27 09:57:19 -05:00

Anvil

A lightweight parametric CAD application for Linux, built for 3D printing.

CI Release Licence: GPL-3.0-or-later

Anvil's main window: a bracket in the viewport, the browser and parameters on the left, the timeline along the bottom

User guide (wiki) — every part of the application explained for someone opening it for the first time. More screenshots in docs/screenshots.

Anvil is a native parametric solid modeller for people who design parts for their own printer: brackets, enclosures, adapters, jigs, replacement parts. The workflow is Fusion 360's — sketch, extrude, modify, change a number and watch everything follow — without the cloud, the licence or the weight. It starts in a fifth of a second and its package is two megabytes.

It is not a mesh editor, a slicer, or a general-purpose FreeCAD clone. Units are millimetres, always.

What it does

Sketching. Sketch on an origin plane, on any flat face, or on a construction plane. Lines, rectangles, circles, arcs, slots, polygons, ellipses, points and text; trim, extend, offset, fillet, chamfer, break, split, stretch, scale, mirror and patterns. Tools stay armed, the way Fusion's do. Type a number while you draw and it becomes a driving dimension; constraints are inferred as you go, with a glyph at the cursor showing what you will get (hold Ctrl to turn that off). The palette always says how many degrees of freedom are left, and Sketch Analysis points at the open loop when a sketch will not extrude.

A sketch open for editing, with dimensions driven by named parameters and the palette reading Fully constrained Drawing in a sketch: value boxes follow the cursor

Solid features. Extrude (blind, symmetric, two-sided, to a face, through all; taper; new body, join, cut, intersect), Revolve, Loft, and Box, Cylinder, Sphere and Torus that keep an editable footprint sketch. A first-class Hole feature with a fastener table: M2 to M8 in close, normal and loose clearance, tap-drill sizes and heat-set-insert presets, as simple, counterbored, countersunk or counterdrilled holes, flat-bottomed or drill-pointed.

The Extrude dialog on a cut, with the live preview The Hole dialog with a fastener size chosen

Modify. Fillet and Chamfer with tangent-chain and edge-loop selection, Shell, Draft, Scale, Combine, Split Body, Split Face, Move/Copy, Align, rectangular and circular patterns and Mirror -- of a whole body, or of features, so a hole is repeated across a plate and the plate stays one plate -- and Press Pull, which becomes an extrude, an offset or a fillet depending on what you pick.

Parametric all the way down. Named parameters with expressions (wall_thickness * 2 + 0.4), usable in every field. A timeline you can reorder, suppress, rename, edit, and roll back by dragging its marker. A persistent naming scheme so that a fillet stays on its edge when an upstream dimension changes — and, when a reference really is gone, a feature that turns red and says so instead of quietly rounding a different corner (how).

A filleted part The same part after a parameter change: the fillets are still on their edges

Construction. Offset, angled, mid, tangent, two-edge and three-point planes; axes through a cylinder, perpendicular at a point and where two planes meet; points at a vertex, where two edges meet and where an edge meets a plane.

The printing toolkit — the part a general CAD package does not have:

  • a build volume for your printer (presets, or your own), drawn in the viewport, with a warning when a body leaves it;
  • a manifold check that highlights the edges at fault;
  • wall-thickness analysis, as a heatmap against a minimum you set (twice the nozzle by default);
  • overhang analysis, shading faces by their angle from the plate;
  • hole compensation: round holes widened by a set amount when a mesh is exported, to counter the way printed holes come out small, without touching the model;
  • Place on Build Plate (pick a face, it goes down) and an elephant's-foot chamfer helper.

Wall-thickness analysis: thin regions drawn in red Overhang analysis: faces shaded by their angle from the build plate

Files. The native .anvil format is a ZIP of plain JSON you can grep and diff. Export 3MF (the default: millimetres, one object per body, names kept), STL (binary or ASCII, with the tessellation controls and a live triangle count) and STEP AP214. Import STEP as an editable body, STL and 3MF as reference meshes to sketch against and measure, and a picture on a plane, to scale, for tracing the part you are replacing.

Getting around. A view cube with all 26 faces, edges and corners; a right-click marking menu with flick gestures; S for a fuzzy command search you can pin from; measure, section view and mass properties; dark and light themes; every shortcut editable; autosave and crash recovery.

The S command search The right-click marking menu The light theme

An AI assistant, if you want one. Turn on Edit > Assistant connection and an assistant such as Claude Code can read the part you have open, look at the window, and make the changes you ask for -- set a parameter, round some edges, draw and dimension a sketch -- each one a step you can undo. It can also check the part for printing, point at what it means, and export it (claude mcp add anvil -- anvil --mcp; the wiki's Using an AI assistant page has the rest). Off unless you turn it on, and only on your own computer.

Not in v1, and greyed in the toolbar with a note saying so rather than missing: sweep, splines, threads, ribs, mesh-to-solid conversion and a scripting API. Assemblies, sheet metal and surfacing are out of scope for v1 altogether and have no place in the toolbar. PROGRESS.md is the honest record of what is built, what is deferred and what still needs a person.

Install

Fedora (the current release, x86_64):

sudo dnf config-manager addrepo --from-repofile=https://git.pandanas.net/api/packages/Code-Liberation-Front/rpm.repo
sudo dnf install anvil

CachyOS and Arch (x86_64): trust the repository's key, add the repository, install.

curl -fsSO https://git.pandanas.net/api/packages/Code-Liberation-Front/arch/repository.key
sudo pacman-key --add repository.key
sudo pacman-key --lsign-key 'Code-Liberation-Front@noreply.git.pandanas.net'
printf '\n[Code-Liberation-Front.main.git.pandanas.net]\nSigLevel = Required\nServer = https://git.pandanas.net/api/packages/Code-Liberation-Front/arch/main/$arch\n' |
    sudo tee -a /etc/pacman.conf
sudo pacman -Syu anvil

Each release also attaches both packages, their checksums and the signing keys. For anything newer than the latest release, build from source (below), or build the package with scripts/build-rpm.sh or scripts/build-arch.sh. Anvil needs OpenGL 4.5, on Wayland or X11.

Other distributions: packaging/flatpak/ holds a Flatpak manifest, built and run by scripts/flatpak-build.sh.

A first part

  1. Parameters panel: add width = 60, depth = 40, thick = 10.
  2. Create Sketch, click the XY plane. R, click the origin, click again. D, click a side, click beside it, type width; the same for depth. The palette reads Fully constrained. Finish Sketch.
  3. E for Extrude, click in Distance, type thick, Enter.
  4. G for the face filter, click the top face, H for Hole, choose M4 and Through all, Enter.
  5. R for the edge filter, click the four upright edges (shift-click to add), F, click in Radius, type a radius, Enter.
  6. Change width to 70 in the Parameters panel. Everything rebuilds; the hole and the fillets are where they were.
  7. Ctrl+S, then Utilities → Export 3MF, and open it in your slicer.

That is the part tests/e2e/bracket.script models in the real application on every CI run. Your first part in the wiki is the same walk with pictures.

Building from source

Fedora:

sudo dnf install cmake ninja-build gcc-c++ git clang-tools-extra libasan libubsan \
                 doctest-devel opencascade-devel eigen3-devel json-devel \
                 minizip-ng-devel pugixml-devel zlib-ng-compat-devel \
                 glfw-devel libglvnd-devel mesa-libGL-devel liberation-sans-fonts

CachyOS and Arch:

sudo pacman -S --needed base-devel cmake ninja git clang doctest opencascade eigen \
                        nlohmann-json minizip-ng pugixml glfw libglvnd mesa ttf-liberation

Then, on either:

git clone https://git.pandanas.net/Code-Liberation-Front/Anvil.git anvil && cd anvil
git submodule update --init

cmake --preset release
cmake --build --preset release
ctest --preset release

./build/release/bin/anvil

The two submodules are Dear ImGui and SolveSpace's constraint solver. --recursive is not needed: SolveSpace's own submodules belong to its application, and Anvil builds none of them.

Preset Purpose
debug-asan Debug with ASan + UBSan. What you develop against.
debug Debug without sanitizers.
relwithdebinfo Optimised with symbols, for profiling.
release Optimised. The configuration the budgets are measured against.

scripts/ci.sh is the whole gate, and what CI runs: the format check; debug-asan and release, each built with -Werror and each running both test suites; the real binary driven end to end through tests/e2e/ under Xvfb, with the files it exports measured by a script that shares no code with Anvil; and the performance budgets. Without the toolchain installed, scripts/in-container.sh scripts/ci.sh runs it in the CI image.

Command line

anvil [options] [FILE.anvil]

  --inspect FILE       Dump a document's JSON to stdout and exit.
  --script FILE        Drive the interface from a script, then exit.
  --screenshot PNG     Capture the window once it has settled, then exit.
  --assistant          Let AI assistants attach to this window.
  --mcp                Be an MCP server for an AI assistant, talking to the running Anvil.
  --mcp --headless FILE  The same with no window, on FILE.
  --startup-timing     Print milliseconds from launch to the first drawn frame.
  --log-level LEVEL    trace, debug, info, warn, error or off.
  --width / --height   Initial window size.

--inspect reads the document straight out of the container without building it, so it works on a file this build cannot fully open. --script is how the end-to-end tests and every screenshot on this page are made: docs/automation.md. --mcp is what an assistant's client runs: docs/assistant-connector.md.

Budgets

Measured on every CI run by scripts/budgets.sh, under Xvfb with software OpenGL:

Budget Measured
Cold start to the first frame < 500 ms about 150 ms
Memory with a 30-feature document open < 400 MB about 190 MB
CPU with the viewport static < 1 % 0 %
Full rebuild of a 50-feature document < 300 ms about 245 ms on the CI runner, 170–200 ms on a desktop
Installed size, binary and assets < 40 MB about 5 MB

The sixth, 60 fps while orbiting two million triangles, needs a real GPU to measure and is listed in PROGRESS.md for a person to take.

How it is put together

core/         a static library: no OpenGL, no ImGui, no window
  base/       math, Result, logging, ids
  document/   expressions, parameters, the feature tree, commands and undo
  sketch/     2D entities, constraints, the solver behind ISketchSolver
  features/   one class per feature
  kernel/     the ONLY place OpenCASCADE headers are included
  analysis/   manifold, wall thickness, overhang, measure
  io/         .anvil, JSON, STL, 3MF, STEP, PNG
ui/           the executable
  app/        window, main loop, session, settings, the script driver
  commands/   the command registry and the toolbar layout, which is data
  render/     GL loader, camera, grid, build plate, meshes, picking
  panels/     theme, docked panels, dialogs, sketch view, view cube
tests/        core/ links the core alone; ui/ drives the panels through real ImGui
              frames with no window; e2e/ drives the real binary
packaging/    the RPM spec, desktop entry, MIME type, AppStream data, Flatpak manifest
docs/         file format, naming scheme, script language, screenshots, the wiki's source

core/ is testable without a GPU or a window, and OpenCASCADE types never leave core/kernel/ — the core test target compiles without OpenCASCADE's include path at all, which is what proves it. Every change to a document is a command on the undo stack. A test fails if a toolbar command has no test that runs it and checks what it did.

File format

.anvil is a ZIP with every entry stored uncompressed, so a saved model stays greppable and diffable:

document.json    parameters, features, sketches, print settings, named views
metadata.json    application and format version, timestamps
thumbnail.png    a 256 x 256 preview, rendered on save
grep -a wall_thickness bracket.anvil      # works, by design
anvil --inspect bracket.anvil | jq .parameters

Roadmap

v1 is the scope in CLAUDE.md section 6, and it is built. What comes after, roughly in order: sweep and splines (the seams are there), threads, profiles with holes and guide curves for Loft, and mesh repair. Assemblies, sheet metal, CAM and anything in the cloud are not planned.

Licence

GPL-3.0-or-later. See LICENSE. Anvil links OpenCASCADE (LGPL-2.1 with an exception) and vendors Dear ImGui (MIT) and SolveSpace's solver (GPL-3.0-or-later).