WPKernel: the unfinished framework with a working engine

WPKernel is still very early alpha. But its pipeline already powers Geekist projects, while its PHP AST toolkit shows what happens when code generation…

What it is

There’s a peculiar moment in software development when the tool you’re building becomes less interesting than the machinery you invented to build it. WPKernel is having one of those moments.

We began with an ambitious idea: build modern WordPress products without constantly repeating the same intentions in PHP and JavaScript. Describe what a feature needs in TypeScript, let the tooling work out what belongs where, and use WordPress’s own capabilities wherever possible. Resources, actions, jobs, blocks and events would have a consistent place in that picture.

The complete WordPress framework is very early alpha and not working as a finished product. But two pieces developed a life of their own: the pipeline engine and the PHP AST toolkit. The pipeline has become part of every Geekist project. The framework may be unfinished, but the engineering beneath it is quite real.

What’s a pipeline? Picture preparing dinner. Sauce and meat can be prepared separately. Cooking has to wait for both. Serving has to wait for cooking. When someone burns the sauce, something has to decide what happens next. Our Hidden Machine Inside Modern Tooling article explores that exact idea with an interactive kitchen. It grew from the work behind WPKernel.

What’s new

The interesting progress has come from making the machinery useful in its own right, rather than polishing an unfinished WordPress framework.

A pipeline that understands dependencies. @wpkernel/pipeline reached version 2.0.0 in August 2026. Its original serial helper model evolved into a dataflow graph: a map of tasks and the results they depend on. Independent work can run together. A task that needs two earlier results waits for both, regardless of which finishes first.

It also knows how to handle failed work. The engine can prepare changes, commit them in a predictable order, and coordinate compensating actions backwards when something goes wrong. That is more disciplined than a chain of scripts hoping for the best. The engine manages a run inside one process; recovery across restarts belongs to whatever application hosts it.

PHP code without the string gymnastics. @wpkernel/php-json-ast works with an abstract syntax tree, or AST. Think of it as code broken into meaningful pieces: functions, conditions, arguments and return statements. Its typed TypeScript builders can assemble those pieces, while its PHP-Parser bridge supports reading, changing and printing PHP source. The low-level builders are established; the broader authoring surface is still evolving.

Neither package depends on the whole WPKernel vision coming together. That separation is precisely what makes them interesting.

What else is similar to it

If you want to create a WordPress block today, the official tool does exactly that. It creates a plugin with the necessary PHP, JavaScript and build tooling. It isn’t trying to provide WPKernel’s proposed application architecture.

10up WP Scaffold gives WordPress projects a ready-made starting structure for themes, plugins and assets. It solves the question of how to begin a project. WPKernel’s experiment asks how the moving pieces inside it might be described, generated and coordinated.

nikic/PHP-Parser is a foundation for the PHP AST work, not a rival. It turns PHP source into a tree that software can inspect or transform. WPKernel’s toolkit builds typed TypeScript tools around that representation.

The pipeline is different again. It’s framework-independent; you can use @wpkernel/pipeline in a TypeScript project that has never heard of WordPress. There’s no need to adopt an unfinished framework to benefit from its most mature engine.

Why it’s different

The idea behind WPKernel was to stop making developers express the same decision in several places. TypeScript knows what the application wants. PHP knows what WordPress expects. A dependable generation process could help them agree without leaving a trail of duplicated glue.

Two questions sit at the centre of that process. What has to happen before something else can happen? That’s the pipeline’s job. What does the PHP we’re generating actually mean? That’s where the AST comes in. It is the difference between assembling a working machine from understood parts and gluing strings together until they look like source code.

The pipeline has gone well beyond an architectural sketch: it now operates throughout Geekist’s projects. The PHP AST is still developing its public authoring layer, but already has typed constructors and machinery for parsing and transforming PHP. Those are different levels of readiness, and both are worth understanding on their own merits.

There’s a nice irony in all this. We set out to build a WordPress framework and ended up building an engine we use for things that have nothing to do with WordPress. Sometimes the best thing a project produces isn’t the thing on the label.

How to get started

  1. Start with the ideas, not an installation. Read The Hidden Machine Inside Modern Tooling and play with its interactive kitchen. You can see what runs in parallel, what has to wait and what happens when the sauce goes wrong.
  2. Want to explore the actual engine? You’ll need a little JavaScript or TypeScript and Node.js 20 or newer. The pipeline works in an ordinary project; a WordPress installation isn’t required.
  3. The PHP AST is a separate, more specialised experiment. Some familiarity with PHP will help. You can explore its basic building blocks without attempting to set up the entire WPKernel framework.
  1. In a small practice project, install @wpkernel/pipeline with npm install @wpkernel/pipeline. Open the package’s example. It creates a greeting and some punctuation separately, then combines them into one message.
  2. Follow the connections. The first two tasks can run independently. The final task needs both outputs. That’s a tiny dependency graph — and the same pattern powering the kitchen demonstration in Hidden Machinery.
  3. Curious about generating PHP? Install @wpkernel/php-json-ast in a TypeScript practice project and try the basic example: buildReturn(buildScalarString('Hello')). It describes a PHP return statement as structured data rather than a handwritten string.
  4. From there, browse the WPKernel source to see how the two ideas developed. The full framework is a work in progress; the standalone packages are the better place to experiment.
  1. Finding older pipeline examples? The original helper-based API isn’t the same as v2. For new code, import from @wpkernel/pipeline and use createPipeline() and runPipeline(). The older compatibility model lives under @wpkernel/pipeline/v1.
  2. Expecting rollback to undo everything everywhere? The pipeline coordinates compensation during a running process. It isn’t a durable job queue or a database transaction. Your application still decides how to recover after a restart.
  3. Getting stuck with PHP AST examples? Begin with the low-level typed builders from its README. Parsing, printing and transforming complete PHP files involve the PHP bridge and additional dependencies.
  4. Trying the full WPKernel starter? You’ll encounter unfinished framework behaviour. For now, explore the pipeline and AST independently rather than expecting a complete WordPress development environment.

Explore further: The Hidden Machine Inside Modern Tooling · WPKernel source · Pipeline engine · PHP AST toolkit.

Share your thoughts…?

    Get Geekist in your inbox

      Choose your newsletters. Confirm your email to subscribe.

      Choose your newsletters

      Read the privacy policy