Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

datasette-agent-modeler

PyPI Changelog Tests License

3D modelling tools for Datasette Agent - create and edit 3D models from chat

Screenshot

A Datasette Agent chat session - user has prompted "put the cat in the pot" - result is a 3D rendered cat sitting in a pot in a panel that allows for rotation of the model.

Installation

Install this plugin in the same environment as Datasette.

datasette install datasette-agent-modeler

Usage

This plugin adds 3D modelling tools to Datasette Agent. Ask the agent to build something - "make me a 3D model of a rocket ship" - and it will assemble one from primitive shapes and display it inline in the chat in an interactive viewer (drag to orbit, scroll to zoom, right-drag to pan). Then ask for changes - "make the fins purple and twice as tall" - and the agent edits the stored model and shows the updated result.

Four tools are registered with the agent:

  • create_model(name, objects, background?) - creates a model from a list of primitive shapes (box, sphere, cylinder, cone, torus, capsule, plane), each with optional position, rotation (degrees), scale, color and opacity. Returns a model_id.
  • edit_model(model_id, operations) - applies an ordered list of edit operations atomically: add_object, update_object (changed fields only - params are merged), remove_object, set_name, set_background.
  • get_model(model_id) - returns the current JSON document and revision number.
  • list_models() - lists stored models.

Models are stored in Datasette's internal database. Every edit saves a full snapshot as a new revision, and each viewer embedded in the chat transcript shows the model as it was at that revision, so the conversation doubles as a visual edit history.

The viewer is a <datasette-model-3d> custom element that renders with three.js (loaded from esm.sh), so browsing models requires internet access from the browser.

Permissions

The plugin registers a datasette-agent-modeler permission which gates all four tools - actors without it never see them. The --root user holds it by default:

datasette mydata.db --internal internal.db --root

See DESIGN.md for the full design notes, including the model document format and the 3D library research.

Development

To set up this plugin locally, first checkout the code. You can confirm it is available like this:

cd datasette-agent-modeler
# Confirm the plugin is visible
uv run datasette plugins

To run the tests:

uv run pytest

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

datasette_agent_modeler-0.1a0.tar.gz (18.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

datasette_agent_modeler-0.1a0-py3-none-any.whl (16.4 kB view details)

Uploaded Python 3

File details

Details for the file datasette_agent_modeler-0.1a0.tar.gz.

File metadata

  • Download URL: datasette_agent_modeler-0.1a0.tar.gz
  • Upload date:
  • Size: 18.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for datasette_agent_modeler-0.1a0.tar.gz
Algorithm Hash digest
SHA256 1bbd5e39c6735fcfe364f02c58cb3aac54e9c5fec3eeea57a61152bc3965f5de
MD5 bddf6c10872ab65afa471e1471eccf9c
BLAKE2b-256 4761ba64566e5c77688fcd97a983476ceddc2715607ceb87a25cdfb1d78c6fbc

See more details on using hashes here.

Provenance

The following attestation bundles were made for datasette_agent_modeler-0.1a0.tar.gz:

Publisher: publish.yml on datasette/datasette-agent-modeler

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file datasette_agent_modeler-0.1a0-py3-none-any.whl.

File metadata

File hashes

Hashes for datasette_agent_modeler-0.1a0-py3-none-any.whl
Algorithm Hash digest
SHA256 49f6eb6afa3232c75dd2227702570fefc1bd03ac10a59246aef0ac20b42849f4
MD5 bb7b386f3463ae38031e8e57b8ae8a56
BLAKE2b-256 c9f40c11bf40c3f08cab8b5d51c68dc03fc2b2ee6f25b111bd3702052dd4445a

See more details on using hashes here.

Provenance

The following attestation bundles were made for datasette_agent_modeler-0.1a0-py3-none-any.whl:

Publisher: publish.yml on datasette/datasette-agent-modeler

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page