PFor
$6.80 (Wireless-Tag store)A 180.9M-parameter MoE language model and agent on a $6.80 ESP32-P4.

By cyfrit
- Posted
- GitHub stars
- 8 (GitHub)
Build sheet
- Board
- WT9932P4-Tiny (ESP32-P4 v1.3, 32MB PSRAM, 16MB flash)
- AI model or service
- PFor: 12-layer MoE (29 experts, top-1) + PLE, 1.58-bit ternary weights, Qwen3.5-pruned vocab
- Difficulty
- Advanced
- Est. cost
- $6.80 (Wireless-Tag store)
Overview
Custom 180.9M-parameter MoE+PLE model quantized to W1.58A8 (~44 MiB across PSRAM and XIP flash) runs ChatML chat and a fixed-tool agent loop at ~9 tok/s on a WT9932P4-Tiny ESP32-P4 board using Espressif's XespV acceleration.
How it works
A 12-layer MoE with Per-Layer Embeddings and 1.58-bit weights lives across PSRAM and flash, running chat and a fixed-tool agent loop at about 9 tok/s.
Hardware
- WT9932P4-Tiny (ESP32-P4 v1.3, 32MB PSRAM, 16MB flash)
Like this build? Get the weekly builds
Get the best new AI hardware builds every Thursday. One email a week, free.
Built something? Submit a build
This page is a short summary written by HardwareLab. Build steps, code and photos belong to the creator; follow “View original” for the full project.
Featured? Add this badge
Built this? Paste the badge into your README. It links back to this page.
Markdown
[](https://hardwarelab.dev/projects/pfor-esp32-p4/?utm_source=badge&utm_medium=referral&utm_campaign=launch_2w)HTML
<a href="https://hardwarelab.dev/projects/pfor-esp32-p4/?utm_source=badge&utm_medium=referral&utm_campaign=launch_2w"><img src="https://hardwarelab.dev/badge.svg" alt="Featured on HardwareLab" width="188" height="20"></a>Related builds
All 22 in Local LLM Rigs & Edge Agents
28.9M-parameter LLM on an ESP32-S3
A 28.9M-parameter language model generating text on an ESP32-S3.
- ESP32-S3 N16R8
- OLED
Advanced4.5K
Muse Gadgets SDK
Meta’s open SDKs for connecting Muse to ESP32 and Raspberry Pi gadgets.
- ESP32 boards
- Raspberry Pi (3B+, 4, 5 or Zero 2 W) or another Linux computer with Bluetooth LE
Intermediate2.2K
ESP32 iPhone Agent
An ESP32-S3 board lets an AI model use a real iPhone: no computer at run time, no jailbreak.
- Seeed XIAO ESP32S3 (plain, 8MB PSRAM; any ESP32-S3 with native USB + PSRAM)
- iPhone on iOS 18+ with cellular data
- Lightning to USB Camera Adapter (Lightning iPhones only)
- +2 more
Intermediate2.4K