OptFor.AI Consulting / Transformation / Development

Case Study · AI-Native Web Engineering

OptFor.AI: A Reference AI-Native Architecture for Landing Pages

Author Marcin Mroczkowski CTO & Founder OptFor.AI

OptFor.AI homepage showing a chart of AI adoption impact on software teams

Baseline before publication

68.4 s

complete local release gate

The August 4, 2026 npm run check:ci measurement under Node.js 22.

101

automated tests

The baseline integration and Chromium suite run against a temporary static build.

20.28 kB

compressed homepage HTML

Generated gzipped HTML kept within a 21 kB budget.

01 · System

A reference architecture with production proof

Owner
OptFor.AI
Use case
Landing pages and static expert websites
Surface
A bilingual website in Polish and English
Technology
Astro, TypeScript, Playwright, GitHub Actions, Vercel
Status
Reference implementation running in production

02 · Problem

Limits of a builder-based workflow

WordPress with a substantial visual builder makes it quick to arrange views, but it spreads website state across a database, plugin configuration, an administration panel, and code. That makes it harder to see the complete change, restore an earlier version, and verify the result with one test suite.

We needed landing pages that could be developed with AI in the same way as code: through a small diff, automated verification, review, and rollback. The repository therefore became the source of truth, and the production version is created as a static build.

03 · Delivery

Code, Git, and one release process

Astro generates the static website. Git stores its components, page data, routes, and deployment configuration, so an interface change and the rule that verifies it can live in the same pull request.

The npm run check:ci command runs static checks, builds the production version, and tests a temporary copy of the website. GitHub Actions repeats the process in three jobs, and deployment waits for their result.

A new contributor or automation tool can inspect the types, run the tests, and trace earlier decisions in Git history. Working instructions are versioned with the code, so context does not have to be reconstructed from conversations or visual-editor states.

04 · Quality control

Checks before deployment

  • 14 static checks run concurrently, covering types, dependencies, formatting, CSS, architecture, routes, and unused code.
  • 13 repository-specific check-* implementations are covered by a wiring gate that rejects any local check not connected to CI.
  • Validation of every generated route, internal link, Schema.org record, URL policy, and the boundary between private files and public output.
  • 101 integration and browser tests run against a fresh temporary build.
  • WCAG 2.1 AA checks, interface regression coverage from 320 to 1280 pixels, and a compressed HTML budget for the homepage.

In the August 4, 2026 measurement, the complete gate passed under Node.js 22 in 68.4 seconds. Type checking reported no errors, warnings, or hints, and the dependency audit found no known vulnerabilities. An invalid change produces a specific failure before deployment instead of leaving the team to locate the difference in production.

05 · Discoverability

Generated entry points for AI systems

OptFor.AI publishes llms.txt, two sitemaps, Schema.org data, canonical URLs, and reciprocal language alternates. robots.txt defines access rules for search engines and AI systems.

llms.txt is compiled from published case studies and knowledge-base entries. The same principle applies to the sitemaps. A new publication reaches the machine-readable entry points without a separate per-article list, while a test compares the generated result with the public collections. It also verifies that every entry appears once and that noindex content is excluded.

06 · Iteration

Redesigning the visual layer

The first version of the visual layer was too elaborate. On July 14, the redesign deleted 1,367 lines and added 227 across five files. A simpler, more coherent system was deployed later that day.

Both versions remained in Git history. The difference could be reviewed, the complete test suite rerun, and the previous commit restored if needed. A substantial interface change did not require cloned pages or a manual comparison of two configurations.

07 · Example

A language-switching regression

On July 30, the scroll-position mechanism exposed a defect on case-study pages. After a language change, the page could move the reader even when the switch began at the top.

A Playwright test opens the Polish case study with scrollY at zero, switches to the English URL, and checks the position again. The fix records an atPageStart flag before navigation and restores the top of the target document. The scenario remains in the regression suite.

Between June 26 and August 4, the project history recorded 425 commits, including 232 non-merge changes and 191 pull-request merges. Each iteration can be reviewed, verified, and reverted independently.

08 · Application

A foundation for further implementations

OptFor.AI runs in production as a bilingual static website with a custom interface. Its components, commands, and checks can provide the starting point for further landing pages and expert websites.

Astro alone does not make a system AI-native. The deciding factor is whether a change can be read, tested, and reverted unambiguously. The repository provides those conditions, allowing automation to accelerate delivery while the team retains control of publication.

Case study · Last updated:

OptFor.AI

Need a landing page your AI agents can safely evolve?

Let’s discuss a reference architecture, migration from a visual editor, and quality gates matched to your website.

Discuss your web architecture