Skip to main content

Voidmesh

A small Python 3.12+ library for building and displaying live, Obsidian-inspired force-directed graphs. Values are rendered inside draggable rounded nodes; links act like springs; gravity and repulsion settle the graph into place.

Install

uv add voidmesh

Or with pip:

python -m pip install voidmesh

For local development:

uv sync
uv run voidmesh-demo

Quick start

from voidmesh import Canvas

canvas = Canvas(title="My graph", grid=True)
python = canvas.add_node("Python", color="#fbbf24")
graphs = canvas.add_node("Graphs", color="#a78bfa")
edge = canvas.link(python, graphs, color="#38bdf8")

# Keep executing code while the window stays responsive.
canvas.show(block=False)

canvas.update_node(graphs, value="Live graphs", color="#34d399")
canvas.update_link(edge, color="#fb7185", elasticity=0.06)
canvas.wait()  # Keep the script alive until the window is closed.

All mutating methods update an open window immediately:

third = canvas.add_node("New")
canvas.relink(edge, target=third)
canvas.unlink(edge)  # or canvas.unlink(python, third)
canvas.delete_node(graphs)  # also deletes attached links
canvas.clear()
canvas.close()

Call canvas.show() without arguments for a blocking window. Drag nodes with the left mouse button, pan with the right mouse button, zoom with the wheel, and press Escape to close. fixed=True pins a node after it is dragged.

The Controls panel changes center force, repulsion, link force, and link distance while the graph is moving. Drag its heading to reposition it, or click the chevron to collapse it. Press F to hide or show the panel and G to toggle the background grid.

Physics and the grid can also be controlled from Python:

canvas.configure_physics(
    center_force=0.2,
    repel_force=8,
    link_force=0.4,
    link_distance=190,
    damping=0.92,
)
canvas.toggle_grid(True)

The same values can be passed to Canvas(...). Set controls=False for a minimal window without the controls panel. Controls scale automatically with the window; use ui_scale=1.5 (or another positive multiplier) to override their size on a HiDPI display. Graph zoom and UI scale are intentionally independent.

Switch to a deterministic, physics-free hierarchy with layout="tree", the Tree button in the panel, or the T key. Links are interpreted as parent to child in this view. See the bundled example:

uv run python examples/tree_view.py

Fonts, type size, node padding and roundness, link thickness, and grid color can be set on Canvas(...) or changed live with configure_style().

Development

uv run pytest
uv run ruff check .
uv build
uv run mkdocs serve

Complete documentation lives in docs/. Build it with uv run mkdocs build --strict.

Voidmesh is licensed under the MIT License.

Release files for voidmesh 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for voidmesh 1.0.0
File Size Uploaded
voidmesh-1.0.0.tar.gz 14.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for voidmesh 1.0.0
File Interpreter ABI Platform
voidmesh-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 31.8 kB

Release files / voidmesh-1.0.0.tar.gz

Download URL voidmesh-1.0.0.tar.gz
Size 14.3 kB
Tags Source
SHA-256 checksum
How to use checksums
02fbba8794a174c5a0a9a97b338d8d46a2c70c903b679bb1f46919ea592a69a1
BLAKE2b-256 checksum
How to use checksums
93e7ee24a6c3bc1c90b0f52ee84ee45f9220e7e3035c726c4ee8e782830e3244
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 21, 2026.

Transparency log

Release files / voidmesh-1.0.0-py3-none-any.whl

Download URL voidmesh-1.0.0-py3-none-any.whl
Size 17.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
27c4d3d1c39b8bd81474c70b55ba167e95b97e006a8ded43969338426b61e9a2
BLAKE2b-256 checksum
How to use checksums
2a274be4ce1b9e23caf92acb0f3ff2de801708c04469b9092502ed2e770ff1f2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 21, 2026.

Transparency log

Release history Release notifications | RSS feed

1.1.0

2 release files

This release

1.0.0 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page