LLMPU
Large Language Model Processing Unit
Imagine a processing unit powered by LLM and infinite registers. Each register can store a string for prompts or codes. There is no fixed prompt. Instead, the contents of the first several registers are presented to the LLM. By generating code, the processing unit will be able to read and write any register, and directly execute the content of any register as Python code. Then the processing unit can be used as a general intelligent computing engine that potentially can improve itself by rewriting some of its own prompts or codes in registers.
Yes, this is a Turing machine powered by LLM.
Get Started
pip install llmpu
Configurations:
import llmpu
llmpu.config["api_key"] = ""
# full config with default values:
llmpu.config["V"] = 16 # visible register number
llmpu.config["L"] = 16000 # hard character number limit for register
llmpu.config["model"] = "gemini-flash-latest" # llm model
llmpu.config["llm_config"] = {} # llm config
# do NOT assign to llmpu.config!
Register operation:
# register operation
from llmpu import reg
reg[0x1A] = "print('hello')" # write into 0x1A
content = reg[0x1A] # read from 0x1A
reg[0x1A] = "" # clear 0x1A
Control functions:
# main cycle: generate instructions
code = llmpu.cycle()
# execute the code
exec(code, {})
# core dump
llmpu.dump("dump.json") # dump registers to a json file
llmpu.load("dump.json") # load registers from a json file
Server and UI:
Network server uses srpc protocol. It only allows localhost traffic for security reason. Exposing the interface allows arbitrary code execution!
llmpu.serve(port=22222)
Firmware
This is an example firmware that can be put in 0x0
You are a stateful processing unit executing across cycles. Generate executable Python code each cycle. Only registers persist across cycles. Registers 0x0 – 0xF are visible in prompt (never query in code; act directly on values seen in prompt; use string replace for small edits to save tokens).
## Register Operations
from llmpu import reg
Examples:
- Read (always get a string): content = reg[0xAA]
- Write: reg[0xBB] = content
- Clear: reg[0xCC] = ""
- Execute: exec(reg[0xDD], {})
> content: 10,000 chars max. Empty string for undefined registers.
## Register Purposes
- 0x1: Current task
- 0x2: Long-term goals
- 0x3: Catalog
## Installed Packages (update for new install)
- yaml, numpy
Metadata
Release files for llmpu 0.6.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| llmpu-0.6.2.tar.gz | 6.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| llmpu-0.6.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 14.0 kB
Release files / llmpu-0.6.2.tar.gz
| Download URL | llmpu-0.6.2.tar.gz |
|---|---|
| Size | 6.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
87552767ecd18aa3a2cc437bd391b0fc66569627f2c927a8db5b838b7e6d7f67
|
|
BLAKE2b-256 checksum How to use checksums |
599a0136564bed213d32e4d26f4b0058999f72af149212b3cfaa53c09e976724
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 11, 2026.
Transparency logRelease files / llmpu-0.6.2-py3-none-any.whl
| Download URL | llmpu-0.6.2-py3-none-any.whl |
|---|---|
| Size | 7.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
542953e6d4d1a69be6ccf49b20ee88fb989e4cd5944bf928cd877ffdd05b9c50
|
|
BLAKE2b-256 checksum How to use checksums |
f1340d2c860ec1e7615ab3ab036be539aa82cbcc352abc2bf9458f00cfc7b6ef
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 11, 2026.
Transparency log