Skip to content

OPEN-SOURCE PHP FRAMEWORK · HARNESS ENGINEERING

Build with AI agents. Keep your architecture.

Semitexa gives AI agents a map of your project before they edit and a verdict before they say done. Framework, UI platform and workspace, on PHP 8.4 and Swoole.

curl -fsSL https://semitexa.com/install.sh | bash -s my-app

Open source, MIT licensed. Only Docker needed. Runs semitexa.com.

Harness engineering
for PHP.

Agent = Model + Harness. The model you rent. Semitexa is the harness: it tells the agent how your project is built before it writes, and says no until the checks pass. What harness engineering means for PHP

A request in. A working feature out.LIVE
THE AGENT ✗ back to workClaude, Codex, Cursor
writing ContactPayload, ContactHandler, contact.html.twigwriting OrdersFeedPayload, OrdersFeedHandlerwriting OrderResource, OrderApiTest
Semitexaanswers with structure, the project graph and checks
  1. agent ›Add a contact form. Where does it go?
  2. semitexa ‹A request is a Payload DTO: #[AsPublicPayload(path: '/contact')], fields and rules on the class.ai:ask mechanisms
  3. semitexa ‹Logic lives in one #[AsPayloadHandler]. The page is an #[AsResource] with a Twig template.AGENTS.md
  4. semitexa ‹Graph: /contact is free, the site layout and nav are known, two tests cover the layout.project graph
  5. agent ›Done: the form saves and sends the mail.
  6. semitexa ‹✗ No. Not done. ContactTest fails: a message without an email gets through.ai:verify
  7. agent ›Fixed: email is required in ContactPayload. Checking again.
  8. semitexa ‹✓ pass lint, tests, module structure. Receipt written.ai:verify
  1. agent ›Show new orders live. How?
  2. semitexa ‹Extend AbstractSseCollectionFeedHandler. The grid subscribes to the feed by itself.ai:ask mechanisms
  3. semitexa ‹Declare the feed: #[AsPublicPayload(path: '/orders/feed')].AGENTS.md
  4. semitexa ‹Graph: the Order entity, the event that creates it, the orders grid on /orders.project graph
  5. agent ›Done: the grid polls /orders every 5 seconds.
  6. semitexa ‹✗ No. Not done. This feed must push: OrdersFeedTest waits for the new order on the stream.ai:verify
  7. agent ›Fixed: the handler streams OrderCreated. Checking again.
  8. semitexa ‹✓ pass lint, tests, module structure. Receipt written.ai:verify
  1. agent ›Expose an order as JSON.
  2. semitexa ‹Same Payload, one more line: produces: ['application/json'].ai:ask route
  3. semitexa ‹Shape it once in an #[AsResource]. HTML and JSON share it.AGENTS.md
  4. semitexa ‹Graph: the Order fields, the /orders/{id} route, OrderTest.project graph
  5. agent ›Done: total is returned as a float.
  6. semitexa ‹✗ No. Not done. OrderResource declares total as a string; OrderApiTest fails.ai:verify
  7. agent ›Fixed: total is a string again. Checking again.
  8. semitexa ‹✓ pass lint, tests, module structure. Receipt written.ai:verify
Contact us NameOlena Emailolena@example.com MessageCan we talk about the project next week? Send message
Orders LIVE
  • #1043Lviv€84.00new
  • #1042Kyiv€19.90paid
  • #1041Odesa€240.00paid
  • #1040Dnipro€56.10sent
GET /api/orders/1042 200 OK
{
  "id": 1042,
  "status": "paid",
  "total": "19.90",
  "currency": "EUR"
}
verified · receipt written being built… blocked by Semitexa
Requests in. Semitexa tells the agent how this project is built, then checks what it wrote. A working feature out.How agents see a project

01 EXPERIENCE LAYER

Semitexa OS

A workspace for
people and agents.

You say what should ship. Agents work on it in parallel, Semitexa holds them to the rules, and only the calls a check can’t make come to you. Semitexa OS is the workspace built for that seat.

Visit Semitexa OS site
09:41Semitexa OS
Ship the contact form, live orders and the order API.
Nothing needs you right now.3 features verified · 1 decision saved to the epic · receipts attached
Contact formClaude

queuedasking Semitexa · writing ContactHandler.php✗ Blocked by Semitexa: ContactTest failsneeds your call✓ verified · receipt

Live ordersCodex

queuedasking Semitexa · writing OrdersFeedHandler.php✗ Blocked by Semitexa: OrdersFeedTest failsneeds your call✓ verified · decision applied

Order APICursor

queuedasking Semitexa · writing OrderResource.php✗ Blocked by Semitexa: OrderApiTest failsneeds your call✓ verified · receipt

WORKSPACE CONCEPT

A concept preview of the OS. Agent presence, task memory, decisions and verification under it already run in the Semitexa dev environment.

02 INTERFACE LAYER

Semitexa Platform

One look,
as a contract.

Dashboards, forms and data views built from components that speak only in design tokens. An agent can restyle the whole product, but only through the contract: 45 tokens, generated CSS and a contrast check that can fail.

Visit Semitexa Platform site
One request. The look changes. The components don’t.LIVE

Make the orders page calmer and on-brand.

agent · attempt 1
.orders-grid {
  background: #ff0000;
  border-radius: 3px;
}

✗ No. Components speak only the 45 tokens of TokenContract, and tokens.css is generated from skin.json. A hand edit fails the lint. lint:skin-tokens

agent · attempt 2
$ bin/semitexa skins:generate \
    --prompt "calm, editorial, a little warm"

algorithm: balancedseed: #2f5e52light + dark

✓ contrast 16 / 16 gates · 0 components edited skins:contrast

The four Semitexa sites share this markup. Only the skin differs.

03 EXECUTION LAYER

Semitexa Framework

One way to build it.
Found on the first try.

This is the contact form from the harness above, as the agent wrote it. A route is a Payload, the logic is a Handler, the page is a Resource: one place for each, declared with attributes. So the agent finds it on the first try, and the checks know what to run.

Visit Semitexa Framework site
  • ai:ask route --path=/contactThe whole chain in one answer, because each part is an attribute on its class.
  • requireNotBlank()A rule lives in the Payload, so it runs before any handler can.
  • produces: ['application/json']The same Resource answers HTML or JSON. No second controller.
PHP 8.4 + SwooleAttributes, no routes fileHTML · JSON · SSE
The contact form from above, as the agent wrote it.{ }
01 / REQUESTContactPayload.php
// The request and its rules. One line changed after ContactTest failed.
#[AsPublicPayload(
    path: '/contact',
    methods: ['POST'],
    responseWith: ContactResource::class,
)]
final class ContactPayload
{
    use NotBlankValidationTrait;

    private string $email = '';

    public function setEmail(string $email): void
    {
-       $this->email = $email;
+       $this->email = $this->requireNotBlank('email', $email);
    }
}

POST /contact, email=""→ 422{"errors":{"email":["Must not be blank."]}}

PayloadHandlerResource
ONE PLACE FOR EACH THINGHTML · JSON · SSE

TRY IT

One command to a project
that answers back.

Only Docker needed: no PHP or Composer on your machine. The project comes with AGENTS.md, CLAUDE.md and ai:verify, so your agent knows the rules from its first task. The first start builds the runtime image and takes a few minutes; after that a start takes seconds.

curl -fsSL https://semitexa.com/install.sh | bash -s my-app
  1. [1/7] Checking prerequisites... Docker, Compose v2
  2. [2/7] Project name... my-app
  3. [3/7] Installing Semitexa Ultimate...
  4. [4/7] Environment setup...
  5. [5/7] Registering local app...
  6. [6/7] Local domain (optional)... skipped
  7. [7/7] Done! Installation complete.
  8. cd my-app && bin/semitexa server:start
  9. → http://localhost:9501 # the installer prints your port
  10. # your first page: generate it, edit its template, restart
  11. bin/semitexa make:page --module=Hello --name=About --path=/about --method=GET --access=public --write
  12. bin/semitexa server:restart
  13. # or give your agent its first task: it reads AGENTS.md and runs ai:verify before it says done
Have a product idea?One free MVP every month