
Minecraft AIBuilder plugin — AI Build with prompt (No-API-KEY) | Folia Paper supported 1.16 to 26.3
Build AI-designed JSON blueprints, animate construction, export your builds and keep persistent undo. Paper / Folia.
How to use
AIBuilder 1.0.3 by Peakim
========================
Target: Paper/Folia APIs from 1.20.2 / Java 17+. Plain Spigot is not supported.
In-game messages, the generation prompt and included setup notes are English.
INSTALL
Stop the server. Copy AIBuilder-1.0.3.jar to plugins/ and start the server.
Grant aibuilder.use to trusted builders (default: OP).
The plugin creates plugins/AIBuilder/plans and undo plus config and example files.
GENERATE A PLAN
Give AI_BUILD_PROMPT.txt and your building request to an external AI assistant.
Save its JSON response as UTF-8 without Markdown fences in plugins/AIBuilder/plans/.
No API key is required by this plugin. It does not make live AI requests.
OPTIONAL APARTMENT EXAMPLE
Copy plans/luxury_apartments.json from this bundle into plugins/AIBuilder/plans/.
This blueprint has decorative furniture. Real furniture is demonstrated separately
by furnished_room, which the plugin installs automatically.
BUILD
/aibuild pos look
/aibuild load furnished_room
/aibuild preview
Move outside the coloured box, then /aibuild confirm.
Preview shows bounds only, not all planned blocks.
The anchor is the minimum corner; +X east, +Y up, +Z south.
Choose an empty, loaded area. Use /aibuild pos x y z [world] for exact coordinates.
/aibuild rotate 0|90|180|270 changes orientation before preview.
CONTROL
/aibuild status /aibuild cancel /aibuild undo /aibuild forget
cancel stops construction and automatically restores blocks already placed.
undo during construction starts the same rollback; repeating it reports progress.
Automatic cancellation rollback uses normal bounded batches without cinematic delays.
Leave the build bounds so restoration can proceed safely. Check /aibuild status.
Undo after a completed build restores matching changes from its durable journal.
Neighbour-derived stair shapes, fence/pane/wall connections and leaf distances
are tolerated during undo; changed materials/orientations and edited containers
or signs remain protected. Original terrain is restored rather than simply erased.
forget removes your latest journal without changing the world.
Undo journals persist after restart. Modified blocks, populated/locked/named
chests and edited signs are protected from undo. Existing block entities are
never replaced. No entity, dropped-item or secondary physics restoration.
DETAILS
Real beds need both matching halves; chests are empty and type=single.
Signs are blank. Provide supporting blocks. No inventory/text/NBT JSON fields.
Other block entities and dangerous blocks remain restricted.
JSON supports only fill and set. See the prompt for the exact schema and limits.
LIMITS / PERFORMANCE
Default 150 blocks/tick, 4 ms loop budget, 50,000 final block positions,
128 per dimension, 4,096 operations, 64 loaded chunks and 2 MiB file size.
2 concurrent jobs, 5 completed undo journals per owner.
replace-existing defaults to false. Change config and restart for configuration.
There is no WorldGuard/claim integration. Limit access to trusted builders.
VERIFICATION
Parser, bounds, budgets, rotations, native 1.20.2 block states and simulated
construction/undo lifecycle checks passed. No live multiplayer gameplay test yet.
Newer server versions and plain Spigot are not verified/supported by this build.
SUPPORT
Contact Peakim on Spigot with exact server/plugin versions and relevant errors.
FOLIA SUPPORT (1.0.2)
The same JAR supports Paper and Folia; no config switch is needed.
Block scanning, construction and undo run on the region owning the next position.
A job keeps its normal total batch/time budget while handing off between regions.
Player previews and messages use the entity scheduler. File operations use the async scheduler.
Global callbacks do not read player positions or edit blocks on Folia.
Player occupancy is checked from entity-owned snapshots refreshed every tick;
a missing/stale snapshot pauses the job instead of reading another region's entity.
All build chunks must be loaded when starting. On Paper chunk tickets are retained as before.
On Folia the region scheduler owns each slice; a failed scheduling request or unloaded chunk
stops the job safely, preserving its durable undo history. Keep the build area loaded.
If /aibuild pos look would raytrace outside the current Folia region, use explicit coordinates.
The plugin declares folia-supported: true. Plain Spigot remains unsupported.
VERIFICATION
Local tests use actual Minecraft 1.20.2 block data and a strict simulated Folia scheduler.
They reject legacy scheduler use and off-region block/player access, including builds and
undo across four chunks, occupancy pauses, cancellation, shutdown and scheduling failure.
A live Folia server gameplay test has not been performed.
CINEMATIC BUILDER (1.0.3)
Enabled by default for builds and undo. An invisible, non-colliding armor stand
wearing a player head, colored leather armor and a pickaxe acts as the builder.
It is a cosmetic flying character, not a real player or an extra tab-list entry.
It glides in small steps, swings its tool and follows each changed position.
Distant blueprint jumps reposition the character. Cyan particles mark building;
purple particles mark undo, accompanied by block fragments and quiet sounds.
Cinematic builds follow rows from bottom to top; undo follows top to bottom.
/aibuild cinematic off - original fast batch mode for your next build or undo
/aibuild cinematic on - animated mode for your next build or undo
The command preference lasts until you disconnect. An active job keeps its mode.
The cinematic section is added to existing configs without replacing values:
cinematic:
enabled: true
interval-ticks: 4
blocks-per-step: 1
sounds: true
At 20 TPS this is up to 5 changed blocks/second per job. Use interval-ticks: 2
for about 10 blocks/second. More blocks-per-step is faster. Normal time budgets,
player collision pauses and Folia region hand-offs can slow these rates further.
Changing config settings requires a server restart. No blueprint edits are needed.
The character has no gravity, collision or item drops through player interaction;
it is not saved to disk. Completion, cancel and disconnect remove it on its owning
thread. Use a full server restart for Folia JAR replacement: live plugin unloading
cancels entity cleanup tasks, and Folia hot reload is not supported.
Local tests exercise the armor stand lifecycle, movement, arm animation, particles,
build/undo, cancellation and multi-region ownership. Visual appearance and skins
still require an in-game check; no live multiplayer video capture was performed.
DETAILED INTERIOR PROMPT (1.0.3)
The supplied AI_BUILD_PROMPT.txt includes room planning, supported patterned
carpets, floor inlays, furniture groupings, lighting and circulation checks.
Give the complete prompt to your external AI, then customize MY BUILD REQUEST.
The plugin executes JSON; it does not automatically decorate existing plans.
When updating an existing server, replace plugins/AIBuilder/AI_BUILD_PROMPT.txt
with the new supplied text yourself: existing prompt files are not overwritten.
EXPORT YOUR OWN BUILD (1.0.3)
Requires both aibuilder.use and aibuilder.export (default: OP).
Select two inclusive opposite corners around the finished build, including its
foundation, roof, paired beds, furniture and any air openings you want preserved:
/aibuild pos1 100 64 100
/aibuild pos2 120 85 124
Alternatively stand in a corner and use /aibuild pos1 or /aibuild pos2.
/aibuild pos1 look and /aibuild pos2 look select the actual targeted block,
not the block above it. Folia may require explicit coordinates near region edges.
Export selection is separate from the placement anchor /aibuild pos.
/aibuild selection
/aibuild export my_apartment
Writes plugins/AIBuilder/plans/my_apartment.json without overwriting a file.
Air is included by default to preserve interior openings. To omit all air cells:
/aibuild export my_apartment_noair noair
/aibuild status shows capture progress; /aibuild cancel cancels an export without
changing world blocks. Do not edit the selection while it is being scanned: the
capture is batched and is not an instantaneous snapshot.
Share only the exported JSON. The recipient copies it into their AIBuilder/plans
folder, then uses /aibuild load my_apartment, pos, preview and confirm normally.
No absolute coordinates or source world identifiers are stored in the JSON.
The minimum selected corner becomes local [0,0,0]; the footprint is inclusive.
Chests export empty and single, signs blank, beds unoccupied. Inventories, sign
text, entities, item frames, armor stands, paintings, NBT, biomes and ownership
are not exported. Unsupported/dangerous blocks cause a clear error, not omission.
Selections cutting through a bed are rejected; select both halves.
Capture reads only loaded chunks on their owning Folia regions and does not
place blocks, load chunks or use cinematic delays. Serialization runs async.
Existing configured limits apply, including air in the selection-volume budget:
by default 128 per axis, 50,000 cells, 256 palette states, 4,096 operations,
2 MiB JSON. Repeated cuboids compress to fills. Very irregular selections may
need to be split into smaller exports. No config changes are required.