AI Post-Slicing GCODE Lowers FFF Material Use

By on May 19th, 2026 in news, research

Tags: , , , , , , ,

Normal (left) 3D printed drone body, and optimized (right) [Source: Journal of King Saud University – Engineering Sciences]

A new research paper shows AI and curvature-aware post-slicing can cut FFF material use by about a quarter without touching CAD or the slicer.

Most of us accept that slicers set the rules — layer heights, infill, speeds — and that post-processing GCODE usually means crude, global tweaks. Adaptive layers and non-planar paths are possible, but they force re-slicing and sometimes require special kinematics or firmware. The idea here is quite different: keep the slicer and hardware as is, then make the finished toolpath smarter.

The work is written up in the Journal of King Saud University – Engineering Sciences. Their concept is pretty straightforward: operate directly on slicer-generated GCODE while preserving printer safety and backward compatibility. In other words, improve what the machine does without changing what the slicer thinks it told it to do.

A New Take On GCODE: Local Intelligence Without Re-slicing

Their framework adds three modules to finished toolpaths: curvature-aware adaptive layering, function-specific reinforcement, and unsupervised AI weak-zone detection. It also smooths feedrates in sharp turns to reduce jerk and ringing. Critically, it enforces physically correct incremental extrusion by converting to relative mode (M83) and applying changes to delta-E, while copying all retractions verbatim. That keeps pressure management, retractions and firmware limits intact.

Practically, the system reconstructs the modal state of each G1 move, computes local curvature along XY paths, and varies layer usage within the existing Z schedule — thinner in tight geometry for fidelity, thicker where curvature is low to save material. Reinforcement rules add material in function-critical regions, demonstrated on drone motor arms in their testing. An AI clustering pass flags likely weak spots by combining curvature, extrusion gradient and spatial context, then adds local strengthening where the model predicts vulnerability.

Validation was done on an Ender-3 V2 with a 0.4 mm nozzle, Nylon (PA6-CF), and baseline GCODE from Cura 5.0. Three case studies — a quadcopter frame, an ASTM D638 tensile specimen and a complex bracket — all showed about 22–25 percent less extrusion with only a seven to nine percent print time increase. Geometry stayed tight (RMS deviation under 0.05 mm), and surface finish improved in high-curvature areas thanks to thinner layers and speed smoothing.

On the quadcopter arms, mechanical tests reported a twelve percent higher peak load and nine percent higher stiffness after targeted reinforcement. That could be quite important for anyone trying to balance weight and durability in their projects. The researchers also show mass and flow checks to stay below volumetric limits and preserve retractions.

This sounds great, but generality is the big question. Could this work on arbitrary GCODE? The tests were on one printer class, one main material, and a single slicer profile. And while compute overhead is modest on desktop files, very large industrial jobs will be much more challenging to run.

If this really works, service bureaus might drop material costs on high volume jobs without the need to retrain staff or tweak print parameters. Design teams could harden specific features on functional parts without rebuilding process templates. For desktop users looking for reliability, curvature-aware speeds and layer usage could push print quality from acceptable to consistent.

For slicing software producers, this is a reminder that the GCODE itself is a possible optimization domain. A post-slicing pass — whether as a plugin or a cloud service — could complement adaptive layers and pressure advance, especially when the slicer cannot see functional context. The benefit is obvious: lower material use without forcing users to switch slicers or fiddle with parameters.

Could we see this concept implmeneted in an open, vendor-agnostic plugin for Cura or PrusaSlicer? Let’s make the GCODE smarter!

Via Journal of King Saud University – Engineering Sciences

By Kerry Stevenson

Kerry Stevenson, aka "General Fabb" has written over 8,000 stories on 3D printing at Fabbaloo since he launched the venture in 2007, with an intention to promote and grow the incredible technology of 3D printing across the world. So far, it seems to be working!