pi-localgpt

extensionmaintained

Pi extension for LocalGPT — unified MCP bridge. 51 curated tools for design-log + Gen 3D world building.

by · v0.10.4 · published 5d ago

$ pi install npm:pi-localgpt
downloads/mo
710
stars
1
last push
1d ago
open issues
0

Signals

license: MITtestspi manifest: missinginstall size: —deps: 0peer deps: 0

Download trend

No downloads in the last 12 weeks.

README

Pi LocalGPT

Join dotfield.xyz on Discord

CI Publish npm version npm downloads License: MIT Pi package Trusted Publishing Buy Me A Coffee

51 curated tools for LocalGPT Gen 3D world building, via unified 1-shot MCP bridge.

What this is

pi-localgpt gives Pi agents tools to work with LocalGPT — a Rust-powered real-time 3D level design tool (Bevy engine, 80+ MCP tools).

All tools use a 1-shot MCP bridge: each call spawns localgpt-gen mcp-server --connect, sends one request, and exits. No persistent background process.

Not the unrelated Python RAG project also named "LocalGPT".

Features

  • Scene building — spawn/modify/delete entities, camera, lighting, environment
  • WorldGen pipeline — text description → layout plan → blockout → populate → evaluate → refine
  • Game mechanics — player, NPC, triggers, teleporters, collectibles, doors, physics
  • Terrain & environment — procedural terrain, water, foliage, sky, audio
  • Export — screenshot (including vault 4_Project/<project>/screenshots/), glTF, HTML, world skills, prompt-pack (vault 4_Project/<project>/prompt-packs/)
  • Generic call — unwrapped tools accessible via localgpt_gen_call

Prerequisites

  • localgpt-gen installed (cargo install localgpt-gen)
  • localgpt-gen running interactively (Bevy window open) — all tools connect via --connect relay on port 9878

Install

Install the published npm package with Pi:

pi install npm:pi-localgpt

Install into the current project instead of your user Pi settings:

pi install npm:pi-localgpt -l

Pin a specific version when you want reproducible installs:

pi install npm:pi-localgpt@0.10.4

Or install from GitHub:

pi install git:github.com/eiei114/pi-localgpt

Try it without permanently installing:

pi -e npm:pi-localgpt

Local development:

git clone https://github.com/eiei114/pi-localgpt.git
cd pi-localgpt
npm install
pi -e .

Alternative: raw .mcp.json

If you only need the upstream LocalGPT MCP server (without Pi extension tools, skills, or curated wrappers), add this to your Pi .mcp.json:

{
  "mcpServers": {
    "localgpt-gen": {
      "command": "localgpt-gen",
      "args": ["mcp-server", "--connect"]
    }
  }
}

localgpt-gen must still be running interactively (Bevy window open) so the --connect relay on port 9878 is available. Bridge failures may include a short, sanitized localgpt-gen stderr excerpt to help identify relay, protocol, binary, or missing-window causes. Prefer pi install npm:pi-localgpt when you want the curated tool surface, Agent Skills, and vault workflows documented in this repo.

Quick start

  1. Start localgpt-gen interactively (Bevy window opens)
  2. Check relay: /localgpt:gen-status or localgpt_gen_status
  3. Build world: localgpt_gen_plan_from_roblox_trend (Roblox trend summary), localgpt_gen_plan_from_note (vault memo), or localgpt_gen_plan (short text) → localgpt_gen_blockoutlocalgpt_gen_populate
  4. Save design: localgpt_design_log_save

See skills/localgpt-gen/SKILL.md for the full workflow guide.

Vault design memos: docs/vault-note-plan-layout.md.

Roblox trend summaries: docs/roblox-trend-prototype.md.

Package contents

PathPurpose
extensions/Pi TypeScript extension entrypoints
lib/Shared TypeScript helpers (MCP client, gen tools)
skills/Agent Skills (localgpt-gen)
scripts/CI helpers (version bump check)
docs/Supporting docs (release, manual test checklist)

Tools

Status

ToolPurpose
localgpt_gen_statusBinary + relay check
localgpt_gen_callGeneric tool wrapper

Memory & Design Log

ToolPurpose
localgpt_design_log_search / _get / _save / _logDesign log search, read, durable save, daily append
localgpt_remember_worldgenSave design rationale linked to plan/evaluate/export/world artifacts

Scene

ToolPurpose
localgpt_gen_screenshotViewport screenshot
localgpt_gen_sceneScene hierarchy
localgpt_gen_entityEntity details
localgpt_gen_spawn / _batchSpawn primitives
localgpt_gen_modify / _deleteEntity changes
localgpt_gen_camera / _light / _environmentCamera & lighting
localgpt_gen_undo / _redo / _clearHistory & reset

Player & NPC

ToolPurpose
localgpt_gen_spawn_playerSpawn player character
localgpt_gen_add_npcCreate NPC
localgpt_gen_npc_dialogueConversation tree

Interactions

ToolPurpose
localgpt_gen_add_triggerProximity/click/area trigger
localgpt_gen_add_teleporterTeleporter portal
localgpt_gen_add_collectibleCollectible pickup
localgpt_gen_add_doorInteractive door

Physics

ToolPurpose
localgpt_gen_set_physicsPhysics body
localgpt_gen_add_colliderCollision shape
localgpt_gen_add_forceForce / impulse
localgpt_gen_set_gravityGravity preset

Terrain & Sky

ToolPurpose
localgpt_gen_add_terrainProcedural terrain
localgpt_gen_add_waterWater plane
localgpt_gen_add_foliageVegetation scatter
localgpt_gen_set_skySky & atmosphere

Audio

ToolPurpose
localgpt_gen_set_ambienceAmbient soundscape
localgpt_gen_audio_emitterPositional audio

WorldGen Pipeline

ToolPurpose
localgpt_gen_planText → layout plan
localgpt_gen_plan_from_noteVault markdown note → layout plan
localgpt_gen_plan_from_roblox_trendRoblox trend summary → layout plan
localgpt_gen_blockoutApply blockout
localgpt_gen_modify_blockoutEdit blockout
localgpt_gen_populateFill region
localgpt_gen_set_tier / _roleEntity tier/role
localgpt_gen_evaluateScene evaluation
localgpt_gen_refineAuto-improvement loop
localgpt_gen_navmeshWalkability grid
localgpt_gen_regenerateRefresh regions

Export & World Skills

ToolPurpose
localgpt_gen_export_screenshotScreenshot to file
localgpt_gen_export_gltfExport glTF
localgpt_gen_export_htmlExport HTML
localgpt_gen_save / _loadWorld skills

Commands

CommandPurpose
/localgpt:gen-statusCheck binary + relay
/localgpt:plan-from-note <path>Plan layout from vault markdown file
/localgpt:plan-from-roblox-trend <path>Plan layout from Roblox trend JSON file
/localgpt:remember-worldgenSave WorldGen design rationale (rationale only; use the tool to attach references)

Arguments are not required. Details are entered after the command runs.

Development

npm install
npm run ci

npm run ci runs typecheck, tests, and npm pack --dry-run (via pack:check) so the published tarball matches package.json files.

Before release, run the manual smoke checks in docs/manual-test-checklist.md (status, design-log search/save, platform notes).

Run the pack check alone:

npm run pack:check

Release

This package uses npm Trusted Publishing — no NPM_TOKEN required.

npm version patch
git push

See docs/release.md for setup details.

Security

Pi packages can execute code with your local permissions. Gen tools drive the Bevy 3D window via the --connect relay.

For vulnerability reporting, see SECURITY.md.

Links

License

MIT