[{"data":1,"prerenderedAt":3826},["ShallowReactive",2],{"/blog/forward-deployed-engineer-tech-stack":3,"related-/blog/forward-deployed-engineer-tech-stack":611},{"id":4,"title":5,"authorId":6,"body":7,"category":562,"created":563,"description":564,"extension":565,"faqs":566,"featurePriority":582,"head":583,"hideCta":584,"landingPath":583,"meta":585,"navigation":599,"ogImage":583,"path":600,"robots":583,"schemaOrg":583,"seo":601,"sitemap":602,"stem":603,"tags":604,"__hash__":610},"blog/blog/1059.forward-deployed-engineer-tech-stack.md","The Forward Deployed Engineer Tech Stack: 10 Tools for Live Deployments","salome-koshadze",{"type":8,"value":9,"toc":531},"minimark",[10,19,30,33,38,41,115,123,127,130,138,142,145,150,156,165,171,177,181,187,196,199,204,209,213,216,220,226,229,238,244,249,254,258,264,267,272,277,281,284,288,294,297,302,307,311,316,324,329,334,338,345,349,355,358,363,368,372,378,382,387,390,395,400,404,409,412,417,422,426,429,433,438,441,446,451,455,458,480,492,496],[11,12,13,14,18],"p",{},"A forward deployed engineer (FDE) rarely gets to keep one stack. Each customer brings its own cloud, its own data platform, and its own rules about what software may touch production. ",[15,16,17],"strong",{},"In 843 FDE job postings we analyzed, the cloud requirement splits almost evenly: AWS 28.5%, Azure 25.6%, GCP 23.6%."," The job is to work inside whatever the customer already runs.",[11,20,21,22,29],{},"This guide picks 10 tools across six deployment phases and shows how often FDE postings name each one. Counts come from 843 postings by 225 companies in the ",[23,24,28],"a",{"href":25,"rel":26},"https://topfdejobs.com",[27],"nofollow","topfdejobs.com"," database (16 October 2026 snapshot).",[11,31,32],{},"Discovery tools (interview and meeting capture) are left out. No tool in that category shows real backing in the postings.",[34,35,37],"h2",{"id":36},"why-the-fde-stack-differs-from-a-product-engineers","Why the FDE stack differs from a product engineer's",[11,39,40],{},"A product engineer builds once for many customers on infrastructure their company controls. An FDE builds for one customer at a time, inside systems someone else owns. Four parts of the stack change:",[42,43,44,59],"table",{},[45,46,47],"thead",{},[48,49,50,53,56],"tr",{},[51,52],"th",{},[51,54,55],{},"Product engineer",[51,57,58],{},"Forward deployed engineer",[60,61,62,76,89,102],"tbody",{},[48,63,64,70,73],{},[65,66,67],"td",{},[15,68,69],{},"Deploy target",[65,71,72],{},"The company's own cloud account",[65,74,75],{},"The customer's cloud, VPC, or on-prem servers",[48,77,78,83,86],{},[65,79,80],{},[15,81,82],{},"Quality check",[65,84,85],{},"QA against a product spec",[65,87,88],{},"Evals against the customer's real data and queries",[48,90,91,96,99],{},[65,92,93],{},[15,94,95],{},"Monitoring",[65,97,98],{},"The team's shared dashboards",[65,100,101],{},"The tool the customer's on-call team already watches",[48,103,104,109,112],{},[65,105,106],{},[15,107,108],{},"Who owns the environment",[65,110,111],{},"An internal platform team",[65,113,114],{},"The customer's IT and security teams",[11,116,117,118,122],{},"The last row drives most choices below. For daily work, see ",[23,119,121],{"href":120},"/blog/forward-deployed-engineer-vs-software-engineer","FDE vs software engineer",".",[34,124,126],{"id":125},"the-10-tools-at-a-glance","The 10 tools at a glance",[11,128,129],{},"The 10 tools cover six phases of a live deployment, from reaching the customer's systems to keeping the agent healthy after go-live. Each section below shows the share of the 843 postings that name the tool.",[131,132],"video-frame",{":autoplay":133,":controls":133,":loop":133,":muted":133,"caption":134,"poster":135,"src":136,"srcMp4":137},"true","The 10 tools of the forward deployed engineer stack, grouped by deployment phase.","/blog/forward-deployed-engineer-tech-stack/fde-tech-stack-poster.jpg","/blog/forward-deployed-engineer-tech-stack/fde-tech-stack.webm","/blog/forward-deployed-engineer-tech-stack/fde-tech-stack.mp4",[34,139,141],{"id":140},"connect-reach-the-customers-systems","Connect: reach the customer's systems",[11,143,144],{},"An agent is only as useful as the systems it can reach. These two tools cover two ways in: APIs, and the web apps people already use.",[146,147,149],"h3",{"id":148},"mcp-expose-customer-systems-as-agent-tools","MCP: expose customer systems as agent tools",[11,151,152,155],{},[15,153,154],{},"Named in 10.7% of FDE postings",", more than Docker (8.3%).",[11,157,158,159,164],{},"The ",[23,160,163],{"href":161,"rel":162},"https://modelcontextprotocol.io/docs/getting-started/intro",[27],"Model Context Protocol"," is an open-source standard for connecting AI applications to data sources and tools. FDEs use it to wrap a customer's ticketing API or claims database as a small set of tools any MCP-capable agent can call. Start with a read-only server so security can approve lookups before any tool writes data.",[11,166,167,170],{},[15,168,169],{},"Watch out for:"," each MCP server is a new entry point. Tool output can carry prompt injection, so scope permissions per tool and log every call.",[11,172,173,176],{},[15,174,175],{},"Use instead if:"," you need one integration for one customer. Plain REST calls and webhooks are less to build and less to review.",[146,178,180],{"id":179},"webfuse-work-inside-the-customers-web-app","Webfuse: work inside the customer's web app",[11,182,183,186],{},[15,184,185],{},"Live sessions (co-browsing or screen sharing) named in 1 posting."," Disclosure: Webfuse is our product.",[11,188,189,190,195],{},"Access is the problem here, more than the tool. In ",[23,191,194],{"href":192,"rel":193},"https://usetandem.ai/blog/fde-stack-2026",[27],"Tandem's interviews with nine FDEs",", engineers called access \"the single biggest frustration of the job,\" with waits of \"weeks to months.\"",[11,197,198],{},"Webfuse is a programmable web proxy. A session opens the customer's web app from a link, with nothing for the customer to install, and several people can share that live session and pass control. The Session MCP Server lets an MCP-compatible agent open URLs, read the page, and fill in forms in the same session. Admins can limit which hosts a session reaches and mask sensitive inputs from the agent.",[11,200,201,203],{},[15,202,169],{}," it reaches the web UI only. The customer's security team still has to approve traffic through a proxy.",[11,205,206,208],{},[15,207,175],{}," you need backend access to databases or servers. A VPN or VDI account is the standard route.",[34,210,212],{"id":211},"build-write-the-agent","Build: write the agent",[11,214,215],{},"These two tools split the build work. One writes code, the other structures agent logic.",[146,217,219],{"id":218},"claude-code-write-and-refactor-in-unfamiliar-repos","Claude Code: write and refactor in unfamiliar repos",[11,221,222,225],{},[15,223,224],{},"Named in 4.4% of FDE postings",", spread across companies (Deloitte 5, others 2 to 3 each).",[11,227,228],{},"FDEs open a new customer repo every few weeks. Claude Code reads the codebase, runs commands, and edits files from the terminal, which shortens the time to a first working change. It comes with Claude's Pro plan ($20/month) and higher tiers.",[11,230,231,232,237],{},"Krishna Chheta, a self-described FDE, ",[23,233,236],{"href":234,"rel":235},"https://x.com/k_d_patel007/status/2112066109512069468",[27],"summed up the mix on X"," on 19 October 2026:",[239,240,241],"blockquote",{},[11,242,243],{},"\"codex is great for focused diffs, messy repos still need a human pass. cursor + claude code + tests is how i survive both client work and my own apps\"",[11,245,246,248],{},[15,247,169],{}," some customers ban AI coding tools on their code. Ask before the first session, not after.",[11,250,251,253],{},[15,252,175],{}," you prefer an editor. Cursor appears in 5.5% of postings, though 18 of those 46 are Cognition postings naming a rival. Codex sits at 4.9%, with 23 of 41 from OpenAI's own postings.",[146,255,257],{"id":256},"langgraph-structure-multi-step-agent-logic","LangGraph: structure multi-step agent logic",[11,259,260,263],{},[15,261,262],{},"Named in 6.5% of FDE postings",", with LangChain at 8.8%.",[11,265,266],{},"LangGraph (MIT) models an agent as a graph with explicit state, so cycles, branches, and approval steps are visible in code. That helps when a claims agent must pause for a supervisor's sign-off and resume hours later.",[11,268,269,271],{},[15,270,169],{}," dependencies. The customer's security team will ask about every package you ship, and a framework adds many.",[11,273,274,276],{},[15,275,175],{}," the agent is a simple loop. The model provider's plain SDK is easier to debug in someone else's environment. For jobs that run for hours, Temporal (MIT-licensed) handles retries and durable state.",[34,278,280],{"id":279},"data-work-where-the-customers-data-lives","Data: work where the customer's data lives",[11,282,283],{},"FDEs rarely get to move data. These tools query and search it where it sits.",[146,285,287],{"id":286},"databricks-query-the-customers-lakehouse-in-place","Databricks: query the customer's lakehouse in place",[11,289,290,293],{},[15,291,292],{},"Named in 12.0% of FDE postings",", the most-named data platform in our set.",[11,295,296],{},"Many enterprise customers already keep their data in Databricks. Running pipelines and batch evals inside the customer's workspace keeps data in their account, which shortens the security conversation.",[11,298,299,301],{},[15,300,169],{}," compute runs on the customer's bill. A forgotten scheduled job or idle cluster becomes your problem at the next review.",[11,303,304,306],{},[15,305,175],{}," the customer runs Snowflake (3.8% of postings). Match the platform they already pay for.",[146,308,310],{"id":309},"pgvector-add-vector-search-to-the-postgres-they-already-run","pgvector: add vector search to the Postgres they already run",[11,312,313],{},[15,314,315],{},"RAG named in 19.1% of postings; any vector database in 8.2%.",[11,317,318,323],{},[23,319,322],{"href":320,"rel":321},"https://github.com/pgvector/pgvector",[27],"pgvector"," is an open-source Postgres extension for vector similarity search. Most customers already run Postgres, so adding an extension means far less for security to review than a new database vendor. It supports HNSW and IVFFlat indexes, and vectors sit next to the rows they describe.",[11,325,326,328],{},[15,327,169],{}," scale limits. At very large vector counts, index builds get slow and memory-hungry.",[11,330,331,333],{},[15,332,175],{}," you need search over very large collections. Pinecone or Qdrant (Apache 2.0) are built for that load.",[34,335,337],{"id":336},"prove-show-the-agent-works","Prove: show the agent works",[11,339,340,341,344],{},"On FDE teams, evals do the job QA does for product teams. ",[15,342,343],{},"Evals appear in 22.2% of postings",", more than Kubernetes.",[146,346,348],{"id":347},"langsmith-run-evals-on-the-customers-real-queries","LangSmith: run evals on the customer's real queries",[11,350,351,354],{},[15,352,353],{},"Named in 3.7% of FDE postings",", the most-named eval tool in our data.",[11,356,357],{},"LangSmith traces agent runs, stores eval datasets, and scores outputs with LLM-as-judge metrics. Fits teams already on LangChain or LangGraph. The free Developer plan covers one seat, and Plus costs $39 per seat per month.",[11,359,360,362],{},[15,361,169],{}," self-hosting is limited to the Enterprise plan. Traces carry customer prompts and data.",[11,364,365,367],{},[15,366,175],{}," data must stay in the customer's VPC. Langfuse is self-hostable with an MIT-licensed core. Braintrust and Promptfoo (MIT) are other options.",[34,369,371],{"id":370},"ship-deploy-into-the-customers-environment","Ship: deploy into the customer's environment",[11,373,374,375],{},"This is where the customer's rules matter most. ",[15,376,377],{},"Regulated customers push toward self-managed clusters and infrastructure as code.",[146,379,381],{"id":380},"kubernetes-docker-run-the-same-build-in-any-customers-cluster","Kubernetes + Docker: run the same build in any customer's cluster",[11,383,384],{},[15,385,386],{},"Kubernetes named in 15.8% of FDE postings; Docker in 8.3%.",[11,388,389],{},"One container image runs in any cloud or a bank's own data center. Kubernetes appears almost twice as often as Docker, so employers expect FDEs to deploy into clusters, beyond packaging code. In many banks and insurers, the platform team hands you a namespace and a list of approved base images.",[11,391,392,394],{},[15,393,169],{}," overkill. A single agent service for an unregulated customer does not need a cluster you have to maintain.",[11,396,397,399],{},[15,398,175],{}," the customer has no compliance rules about hosting. Modal or a managed platform such as Cloud Run gets you live faster.",[146,401,403],{"id":402},"terraform-rebuild-the-customers-environment-from-code","Terraform: rebuild the customer's environment from code",[11,405,406],{},[15,407,408],{},"Named in 5.5% of FDE postings.",[11,410,411],{},"Terraform describes cloud resources as code, so an FDE can rebuild a whole customer environment from a repo. Separate state per customer keeps environments apart and leaves the customer something to run after you go. Since version 1.6, it uses the Business Source License.",[11,413,414,416],{},[15,415,169],{}," state files. They can hold secrets and must live in the customer's storage, not your laptop.",[11,418,419,421],{},[15,420,175],{}," licensing is a concern or the customer prefers a general-purpose language. OpenTofu (MPL 2.0) is the open fork. Pulumi or the customer's own IaC works too.",[34,423,425],{"id":424},"run-keep-it-healthy-after-go-live","Run: keep it healthy after go-live",[11,427,428],{},"After launch, the FDE is often the first person paged. The goal is to show up in the alerts the customer already watches.",[146,430,432],{"id":431},"datadog-monitor-through-the-customers-paging-tool","Datadog: monitor through the customer's paging tool",[11,434,435],{},[15,436,437],{},"Named in 2.3% of FDE postings.",[11,439,440],{},"Pick the tool the customer's on-call team already gets paged from. Datadog's LLM tracing records each agent request as spans and scores responses for quality and safety, with alerts landing in dashboards the team already reads.",[11,442,443,445],{},[15,444,169],{}," costs grow with data volume. Full prompt traces add up fast and may hold sensitive data, so redact before sending.",[11,447,448,450],{},[15,449,175],{}," the customer runs open-source monitoring. Grafana and Prometheus appear in 2.5% of postings.",[34,452,454],{"id":453},"how-to-pick-the-stack-for-your-next-customer","How to pick the stack for your next customer",[11,456,457],{},"Postings show what employers name. The customer decides what you can use, and three questions settle most choices:",[459,460,461,468,474],"ol",{},[462,463,464,467],"li",{},[15,465,466],{},"What does the customer allow?"," If AI coding tools are banned on their repo, drop Claude Code for that engagement. If no new vendors are allowed, pgvector beats a hosted vector database.",[462,469,470,473],{},[15,471,472],{},"What do they already run?"," Snowflake over Databricks, Grafana over Datadog, their IaC over Terraform. Matching their stack means their team can own it after you leave.",[462,475,476,479],{},[15,477,478],{},"Are they regulated?"," Banks and healthcare customers usually mean self-managed Kubernetes, self-hosted Langfuse over LangSmith, and Terraform in their account. Unregulated customers can take Modal and hosted tools.",[11,481,482,483,487,488,122],{},"Python and one of the three clouds cover the base. Everything above that changes per customer, so FDE teams keep two or three options per phase. For how the FDE role compares with adjacent jobs, see ",[23,484,486],{"href":485},"/compare/fde-vs-solutions-architect","FDE vs solutions architect"," and ",[23,489,491],{"href":490},"/compare/fde-vs-sales-engineer","FDE vs sales engineer",[34,493,495],{"id":494},"methodology-and-sources","Methodology and sources",[497,498,499,509,515,525],"ul",{},[462,500,501,504,505,508],{},[15,502,503],{},"Data:"," 843 published and expired FDE postings from 225 companies in the ",[23,506,28],{"href":25,"rel":507},[27]," database, local snapshot taken 16 October 2026. Shares are case-insensitive keyword matches in job descriptions. A match shows a tool is named, not that it is required.",[462,510,511,514],{},[15,512,513],{},"Vendor facts:"," licences, plans, and prices read on official sites or repositories on 22 October 2026.",[462,516,517,520,521,122],{},[15,518,519],{},"Interviews:"," access quotes come from ",[23,522,524],{"href":192,"rel":523},[27],"Tandem's FDE stack guide",[462,526,527,530],{},[15,528,529],{},"Disclosure:"," Webfuse is our product.",{"title":532,"searchDepth":533,"depth":533,"links":534},"",2,[535,536,537,542,546,550,553,557,560,561],{"id":36,"depth":533,"text":37},{"id":125,"depth":533,"text":126},{"id":140,"depth":533,"text":141,"children":538},[539,541],{"id":148,"depth":540,"text":149},3,{"id":179,"depth":540,"text":180},{"id":211,"depth":533,"text":212,"children":543},[544,545],{"id":218,"depth":540,"text":219},{"id":256,"depth":540,"text":257},{"id":279,"depth":533,"text":280,"children":547},[548,549],{"id":286,"depth":540,"text":287},{"id":309,"depth":540,"text":310},{"id":336,"depth":533,"text":337,"children":551},[552],{"id":347,"depth":540,"text":348},{"id":370,"depth":533,"text":371,"children":554},[555,556],{"id":380,"depth":540,"text":381},{"id":402,"depth":540,"text":403},{"id":424,"depth":533,"text":425,"children":558},[559],{"id":431,"depth":540,"text":432},{"id":453,"depth":533,"text":454},{"id":494,"depth":533,"text":495},"enterprise-ai","2026-10-22","The forward deployed engineer tech stack, built on hiring data: 10 tools grouped by deployment phase, with how often 843 FDE job postings from 225 companies name each one, what to watch out for, and what to use instead.","md",[567,570,573,576,579],{"question":568,"answer":569},"What tools do forward deployed engineers use most?","In 843 FDE job postings from 225 companies, Python is named in 66.8% and TypeScript in 35.7%. The three big clouds come next: AWS 28.5%, Azure 25.6%, and GCP 23.6%. Below them sit evals (22.2%), RAG (19.1%), CI/CD (19.0%), and Kubernetes (15.8%). No single AI framework or vendor tool reaches 15%.",{"question":571,"answer":572},"Do forward deployed engineers need to know Kubernetes?","Most should have working knowledge. Kubernetes appears in 15.8% of FDE postings, nearly twice the share for Docker (8.3%), and regulated customers often require deployment into a cluster they control. For unregulated customers, a managed platform is often enough.",{"question":574,"answer":575},"What is MCP used for in forward deployed engineering?","The Model Context Protocol is an open standard for connecting AI applications to data sources and tools. FDEs use it to wrap a customer's internal systems, such as a ticketing API or a database, as tools an agent can call. It appears in 10.7% of FDE postings, more than Docker.",{"question":577,"answer":578},"Which AI coding tool do forward deployed engineers use?","Postings split three ways: Cursor 5.5%, Codex 4.9%, and Claude Code 4.4%. The first two are skewed by vendors: 18 of the 46 Cursor mentions come from Cognition postings naming a rival product, and 23 of the 41 Codex mentions come from OpenAI's own postings. Claude Code mentions are spread across more companies. Check the customer's policy on AI coding tools before you pick.",{"question":580,"answer":581},"How do forward deployed engineers get access to customer systems?","Usually through the customer's own process: VPN accounts, virtual desktops, and security reviews. FDEs interviewed by Tandem called access the single biggest frustration of the job, with waits of weeks to months. Browser-based live sessions are one option for web apps, but only 1 of 843 postings mentions co-browsing or screen sharing, so most teams still rely on VPN and VDI.",0,null,false,{"shortTitle":586,"relatedLinks":587},"FDE Tech Stack",[588,592,595],{"text":589,"href":590,"description":591},"Forward Deployed Engineering (FDE): The Complete 2026 Guide","/blog/forward-deployed-engineering-fde-guide","The operating loop, the artifacts an FDE leaves behind, and how to tell a real engagement from a rebranded services contract.",{"text":593,"href":120,"description":594},"Forward Deployed Engineer vs Software Engineer (2026)","Pay, daily rhythm, customer time, and code ownership compared for FDEs and product engineers.",{"text":596,"href":597,"description":598},"Forward Deployed Engineer vs Technical Consultant","/blog/forward-deployed-engineer-vs-technical-consultant","Who pays for the engineer's hours, what each role is measured on, pay, and career paths.",true,"/blog/forward-deployed-engineer-tech-stack",{"title":5,"description":564},{"loc":600},"blog/1059.forward-deployed-engineer-tech-stack",[605,606,607,608,609],"forward-deployed-engineering","fde","ai-agents","mcp","careers","HGJ7AOemQpf3my9Iv8-hTjXD0Qsr79XgqmaDBxXXU0k",[612,3332],{"id":613,"title":614,"authorId":615,"body":616,"category":607,"created":3312,"description":3313,"extension":565,"faqs":583,"featurePriority":583,"head":583,"hideCta":599,"landingPath":583,"meta":3314,"navigation":599,"ogImage":583,"path":3322,"robots":583,"schemaOrg":583,"seo":3323,"sitemap":3324,"stem":3325,"tags":3326,"__hash__":3331},"blog/blog/1013.serialising-web-ui-state-for-llms-the-complete-guide.md","Serialising Web UI State for LLMs: The Complete Guide","thassilo-schiepanski",{"type":8,"value":617,"toc":3295},[618,624,647,652,655,659,662,665,674,679,683,690,709,713,716,719,723,730,734,739,742,759,763,781,785,797,811,815,828,832,835,839,857,860,864,874,879,953,956,959,964,1035,1040,1159,1164,1273,1277,1288,1293,1595,1600,1754,1763,1767,1778,1783,1787,1791,1794,1797,1800,1907,1912,1915,1919,1922,1925,1930,2154,2159,2411,2416,2492,2497,2504,2513,2517,2520,2523,2526,2531,2540,2544,2884,2904,2957,2961,2964,2996,3145,3149,3152,3155,3159,3170,3173,3184,3190,3291],[11,619,620,621,122],{},"LLMs have become a core component of AI web browsing agents. Previously, automating a web journey required formal models of both web browsing and web-based user interfaces (UIs). An LLM can serve as a plug-in reasoning backend: given serialised web UI state, it is expected to suggest input actions that progress a specified web browsing task. Serialised UI state is, more ergonomically, referred to as a ",[15,622,623],{},"snapshot",[11,625,626,627,632,633,638,639,632,643,646],{},"Snapshots and action suggestions are the two key artefacts along the agent loop. Action suggestions are elicited from the web agent LLM backend. Suggestions can be acted out via automated web browser environments, such as ",[23,628,631],{"href":629,"rel":630},"https://playwright.dev",[27],"Playwright"," or ",[23,634,637],{"href":635,"rel":636},"https://www.webfuse.com",[27],"Webfuse",", for example, ",[640,641,642],"em",{},"clicking",[640,644,645],{},"typing",". The snapshot, on the other hand, is an artefact created by the agent harness, that is, the individual application component between the LLM and the web browser.",[648,649],"nuxt-picture",{"src":650,":alt":651},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/1.svg","{\"Figurative depiction of two key artefacts along the agent loop\":\"the snapshot towards the LLM and the input action towards the browser\",\"provider\":\"none\",\"loading\":\"lazy\",\"width\":460}",[11,653,654],{},"Creating snapshots for LLMs is a central challenge of developing efficient web agents. It is a trade-off between representation utility – how well models can interpret the such encoded UI – and LLM token costs. Snapshots are the major cost factor of an agentic web journey, accumulated over multiple rounds of the loop.",[34,656,658],{"id":657},"gui-snapshots","GUI Snapshots",[11,660,661],{},"Screenshots, i.e., GUI snapshots, resemble what humans see when viewing a web page at a given point in time. Early LLM-based web agents were primarily premised on GUI snapshots because of this evident equivalence. By design, the GUI surfaces only the UI context designated to be visible to the user.",[11,663,664],{},"The document object model (DOM) is a web browser's model of a web application UI's runtime state. With few exceptions, the DOM is the single source of truth regarding the UI. Most snapshot representations are thus, technically speaking, derivatives of a raw DOM snapshot. For the cases not reflected in the DOM, GUI snapshots are a first-class base representation.",[11,666,667,668,673],{},"Rendering a GUI snapshot from the DOM is, moreover, non-trivial; no client-side library manages to create GUI snapshots in reasonable quality or time – ",[23,669,672],{"href":670,"rel":671},"https://html2canvas.hertzen.com",[27],"HTML2Canvas"," demonstrates the limits.",[648,675],{"src":676,"alt":677,"loading":678},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/2.png","The same web-based user interface serialised via browser-native screenshot API and the client-side library HTML2Canvas showing significant geometric differences","lazy",[146,680,682],{"id":681},"vision-based-targeting","Vision-Based Targeting",[11,684,685,686,689],{},"The snapshot representation dictates how elements can be targeted in the live UI. Unambiguous targeting based on a visual representation must be either geometric (absolute), e.g., via point coordinates, or semantic (relative), e.g., via cues, such as ",[640,687,688],{},"\"Button with Text 'Shop'\"",". On its own, semantic targeting introduces a circular problem: which element has this text?",[11,691,692,693,696,697,700,701,704,705,122],{},"Consider the web browsing task: ",[640,694,695],{},"\"Navigate to the Apple online shop\"",". In combination with an action, in this case ",[640,698,699],{},"click",", the agent could target the ",[640,702,703],{},"Shop"," button via a point coordinate, e.g., ",[706,707,708],"code",{},"(725, 750)",[648,710],{"src":711,"alt":712,"loading":678},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/3.png","A GUI snapshot (screenshot) visualising point coordinate targeting",[11,714,715],{},"When the UI shifts between snapshot and action time, geometric targeting suggestions might have become obsolete.",[11,717,718],{},"Depending on the web browser environment, screenshots might be constrained to the GUI viewport. Scrolling is a secondary task that is imperative with viewport-contrained GUI snapshots.",[146,720,722],{"id":721},"the-problem-with-gui-snapshots","The Problem with GUI Snapshots",[11,724,725,726,729],{},"Image data is downsampled to make it economically viable as input to LLMs. It reduces LLM input tokens to a few thousand for real-world-representative full-page screenshots. A common downsampling approach is averaging ",[640,727,728],{},"n×n","-tiles of pixels, as known from image downscaling. Side effects are: pixel-precise targeting does not map back to the live UI, and small geometric features are not preserved (e.g., small labels). Downsampling effects can be accounted for under certain circumstances, e.g., by providing a snapshot format that downsamples to its identity. However, GUI aspect ratio and detail might be beyond the agent's control.",[648,731],{"src":732,"alt":733,"loading":678},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/4.png","A GUI snapshot (screenshot) compared to its figuratively downsampled counterpart",[735,736,738],"h4",{"id":737},"grounded-gui-snapshots","Grounded GUI Snapshots",[11,740,741],{},"Geometric targeting remains unreliable with certain models and responsive UIs. To rely on semantic targeting instead, the agent must link relevant elements in the live UI to semantics in the screenshot. Relevance usually equates with actionability, but ultimately depends on the snapshot's purpose.",[11,743,744,747,748,758],{},[640,745,746],{},"Set-of-Mark"," prompting is the go-to technique to create grounded GUI snapshots",[749,750,751],"sup",{},[23,752,757],{"href":753,"ariaDescribedBy":754,"dataFootnoteRef":532,"id":756},"#user-content-fn-1",[755],"footnote-label","user-content-fnref-1","1",". In this context, relevant elements are parsed from the live DOM and indexed with a unique numeric identifier. Each indexed element in the live UI is then enhanced with a coloured bounding box associated with the respective identifier.",[648,760],{"src":761,"alt":762,"loading":678},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/5.png","A GUI snapshot (screenshot) visualising grounded cue targeting",[11,764,765,772,773,122],{},[23,766,769],{"href":767,"rel":768},"https://browser-use.com",[27],[640,770,771],{},"Browser Use"," agents implement Set-of-Mark-grounded GUI snapshots",[749,774,775],{},[23,776,780],{"href":777,"ariaDescribedBy":778,"dataFootnoteRef":532,"id":779},"#user-content-fn-2",[755],"user-content-fnref-2","2",[34,782,784],{"id":783},"dom-snapshots","DOM Snapshots",[11,786,787,788,796],{},"The DOM is parsed from HTML. In its latest state it can be serialised back to HTML – including all runtime mutations. Research has supported LLMs' capabilities to interpret HTML, and even to navigate such encoded UIs",[749,789,790],{},[23,791,795],{"href":792,"ariaDescribedBy":793,"dataFootnoteRef":532,"id":794},"#user-content-fn-3",[755],"user-content-fnref-3","3",". For that reason, DOM snapshots are a compelling alternative to GUI snapshots. LLMs excel at code generation and review, so these capabilities are no surprise.",[11,798,799,800,803,804,807,808,810],{},"Cross-origin ",[706,801,802],{},"iframe"," elements and ",[706,805,806],{},"canvas"," elements are exceptions to the DOM-is-source-of-truth assumption: ",[706,809,806],{},"-drawn GUI is not reflected in the DOM, nor are external, self-contained DOM subtrees if no explicit policy allows it. Structurally, both are leaves in the serialisable DOM tree.",[146,812,814],{"id":813},"dom-based-targeting","DOM-Based Targeting",[11,816,817,818,487,821,824,825,122],{},"Programmatically, DOM elements can be targeted by different relative means. CSS selectors abstract targeting with a standalone language. Whilst CSS selectors can resolve to more than one element in the DOM – compare semantics of the HTML ",[706,819,820],{},"class",[706,822,823],{},"id"," attributes – every element has at least one unique CSS selector, constructed from nth-child node paths, e.g., ",[706,826,827],{},"main .section:nth-child(2) > .row:nth-of-type(5) > form button",[648,829],{"src":830,"alt":831,"loading":678},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/6.png","A DOM snapshot (HTML) visualising CSS selector targeting",[11,833,834],{},"A raw DOM snapshot is complete, beyond the GUI that renders in the spatially limited browser viewport. For a human-like visual browsing experience, scrolling can be abstracted by an indirect scroll-target-into-view mechanism.",[146,836,838],{"id":837},"the-problem-with-dom-snapshots","The Problem with DOM Snapshots",[11,840,841,842,847,848,856],{},"DOM snapshots of real-world web pages may come at a size of several megabytes, which converts to millions of LLM input tokens – we estimate a raw snapshot of ",[23,843,846],{"href":844,"rel":845},"https://edition.cnn.com",[27],"cnn.com"," at around 1.5M tokens. At this size, DOM snapshots over-utilise the context window of many LLMs, or even exceed it (such as of ",[23,849,852,855],{"href":850,"rel":851},"https://openai.com/index/gpt-4o-system-card/",[27],[640,853,854],{},"GPT-4o"," (OpenAI)","). Ultimately, raw DOM snapshots out-cost GUI snapshots.",[11,858,859],{},"Using DOM snapshots with LLM-based web agents requires size-reducing transformations, similar to image downsampling implemented behind LLM APIs.",[735,861,863],{"id":862},"extracted-dom-snapshots","Extracted DOM Snapshots",[11,865,866,867,870,871,873],{},"The naïve approach to use information from the DOM as a snapshot is element extraction: relevant elements are copied from the live DOM to an initially empty virtual DOM. For small top-",[640,868,869],{},"k"," extractions – the ",[640,872,869],{}," highest-scoring elements – a snapshot of the virtual DOM comes at a fraction of the original DOM's size.",[11,875,876],{},[15,877,878],{},"Top-3 DOM Snapshot:",[880,881,885],"pre",{"className":882,"code":883,"language":884,"meta":532,"style":532},"language-html shiki shiki-themes github-dark github-dark","\u003Cbutton type=\"submit\">Submit\u003C/button>\n\u003Cbutton>More\u003C/button>\n\u003Ca href=\"/more\">Find out more\u003C/a>\n","html",[706,886,887,919,932],{"__ignoreMap":532},[888,889,892,896,900,904,907,911,914,916],"span",{"class":890,"line":891},"line",1,[888,893,895],{"class":894},"suv1-","\u003C",[888,897,899],{"class":898},"sxg3X","button",[888,901,903],{"class":902},"sFR8T"," type",[888,905,906],{"class":894},"=",[888,908,910],{"class":909},"s4wv1","\"submit\"",[888,912,913],{"class":894},">Submit\u003C/",[888,915,899],{"class":898},[888,917,918],{"class":894},">\n",[888,920,921,923,925,928,930],{"class":890,"line":533},[888,922,895],{"class":894},[888,924,899],{"class":898},[888,926,927],{"class":894},">More\u003C/",[888,929,899],{"class":898},[888,931,918],{"class":894},[888,933,934,936,938,941,943,946,949,951],{"class":890,"line":540},[888,935,895],{"class":894},[888,937,23],{"class":898},[888,939,940],{"class":902}," href",[888,942,906],{"class":894},[888,944,945],{"class":909},"\"/more\"",[888,947,948],{"class":894},">Find out more\u003C/",[888,950,23],{"class":898},[888,952,918],{"class":894},[11,954,955],{},"If done manually, element extraction presupposes correct assumptions about which elements and element properties count as relevant. Alternatively, element relevance scoring can be outsourced to an LLM, at the cost of another inference step.",[11,957,958],{},"Extraction disposes of deep DOM hierarchy, which might be salient to the web agent LLM backend. From the below extracted DOM snapshot alone, the original content relationship is lost:",[11,960,961],{},[15,962,963],{},"Extracted DOM Snapshot:",[880,965,967],{"className":882,"code":966,"language":884,"meta":532,"style":532},"\u003Cstrong>MacBook Air\u003C/strong>\n\u003Cbutton>Add to cart\u003C/button>\n\u003Cp>Out of stock\u003C/p>\n\u003Ch2>MacBook Pro\u003C/h2>\n\u003Cbutton>Add to cart\u003C/button>\n",[706,968,969,982,995,1008,1022],{"__ignoreMap":532},[888,970,971,973,975,978,980],{"class":890,"line":891},[888,972,895],{"class":894},[888,974,15],{"class":898},[888,976,977],{"class":894},">MacBook Air\u003C/",[888,979,15],{"class":898},[888,981,918],{"class":894},[888,983,984,986,988,991,993],{"class":890,"line":533},[888,985,895],{"class":894},[888,987,899],{"class":898},[888,989,990],{"class":894},">Add to cart\u003C/",[888,992,899],{"class":898},[888,994,918],{"class":894},[888,996,997,999,1001,1004,1006],{"class":890,"line":540},[888,998,895],{"class":894},[888,1000,11],{"class":898},[888,1002,1003],{"class":894},">Out of stock\u003C/",[888,1005,11],{"class":898},[888,1007,918],{"class":894},[888,1009,1011,1013,1015,1018,1020],{"class":890,"line":1010},4,[888,1012,895],{"class":894},[888,1014,34],{"class":898},[888,1016,1017],{"class":894},">MacBook Pro\u003C/",[888,1019,34],{"class":898},[888,1021,918],{"class":894},[888,1023,1025,1027,1029,1031,1033],{"class":890,"line":1024},5,[888,1026,895],{"class":894},[888,1028,899],{"class":898},[888,1030,990],{"class":894},[888,1032,899],{"class":898},[888,1034,918],{"class":894},[11,1036,1037],{},[15,1038,1039],{},"Original DOM Snapshot – Candidate A:",[880,1041,1043],{"className":882,"code":1042,"language":884,"meta":532,"style":532},"\u003Csection class=\"product\">\n  \u003Cstrong>MacBook Air\u003C/strong>\n  \u003Cbutton>Add to cart\u003C/button>\n  \u003Cp>Out of stock\u003C/p>  👈\n\u003C/section>\n\u003Csection class=\"product\">\n  \u003Cstrong>MacBook Pro\u003C/strong>\n  \u003Cbutton>Add to cart\u003C/button>\n\u003C/section>\n",[706,1044,1045,1062,1075,1087,1100,1109,1124,1137,1150],{"__ignoreMap":532},[888,1046,1047,1049,1052,1055,1057,1060],{"class":890,"line":891},[888,1048,895],{"class":894},[888,1050,1051],{"class":898},"section",[888,1053,1054],{"class":902}," class",[888,1056,906],{"class":894},[888,1058,1059],{"class":909},"\"product\"",[888,1061,918],{"class":894},[888,1063,1064,1067,1069,1071,1073],{"class":890,"line":533},[888,1065,1066],{"class":894},"  \u003C",[888,1068,15],{"class":898},[888,1070,977],{"class":894},[888,1072,15],{"class":898},[888,1074,918],{"class":894},[888,1076,1077,1079,1081,1083,1085],{"class":890,"line":540},[888,1078,1066],{"class":894},[888,1080,899],{"class":898},[888,1082,990],{"class":894},[888,1084,899],{"class":898},[888,1086,918],{"class":894},[888,1088,1089,1091,1093,1095,1097],{"class":890,"line":1010},[888,1090,1066],{"class":894},[888,1092,11],{"class":898},[888,1094,1003],{"class":894},[888,1096,11],{"class":898},[888,1098,1099],{"class":894},">  👈\n",[888,1101,1102,1105,1107],{"class":890,"line":1024},[888,1103,1104],{"class":894},"\u003C/",[888,1106,1051],{"class":898},[888,1108,918],{"class":894},[888,1110,1112,1114,1116,1118,1120,1122],{"class":890,"line":1111},6,[888,1113,895],{"class":894},[888,1115,1051],{"class":898},[888,1117,1054],{"class":902},[888,1119,906],{"class":894},[888,1121,1059],{"class":909},[888,1123,918],{"class":894},[888,1125,1127,1129,1131,1133,1135],{"class":890,"line":1126},7,[888,1128,1066],{"class":894},[888,1130,15],{"class":898},[888,1132,1017],{"class":894},[888,1134,15],{"class":898},[888,1136,918],{"class":894},[888,1138,1140,1142,1144,1146,1148],{"class":890,"line":1139},8,[888,1141,1066],{"class":894},[888,1143,899],{"class":898},[888,1145,990],{"class":894},[888,1147,899],{"class":898},[888,1149,918],{"class":894},[888,1151,1153,1155,1157],{"class":890,"line":1152},9,[888,1154,1104],{"class":894},[888,1156,1051],{"class":898},[888,1158,918],{"class":894},[11,1160,1161],{},[15,1162,1163],{},"Original DOM Snapshot – Candidate B:",[880,1165,1167],{"className":882,"code":1166,"language":884,"meta":532,"style":532},"\u003Csection class=\"product\">\n  \u003Cstrong>MacBook Air\u003C/strong>\n  \u003Cbutton>Add to cart\u003C/button>\n\u003C/section>\n\u003Csection class=\"product\">\n  \u003Cp>Out of stock\u003C/p>  👈\n  \u003Cstrong>MacBook Pro\u003C/strong>\n  \u003Cbutton>Add to cart\u003C/button>\n\u003C/section>\n",[706,1168,1169,1183,1195,1207,1215,1229,1241,1253,1265],{"__ignoreMap":532},[888,1170,1171,1173,1175,1177,1179,1181],{"class":890,"line":891},[888,1172,895],{"class":894},[888,1174,1051],{"class":898},[888,1176,1054],{"class":902},[888,1178,906],{"class":894},[888,1180,1059],{"class":909},[888,1182,918],{"class":894},[888,1184,1185,1187,1189,1191,1193],{"class":890,"line":533},[888,1186,1066],{"class":894},[888,1188,15],{"class":898},[888,1190,977],{"class":894},[888,1192,15],{"class":898},[888,1194,918],{"class":894},[888,1196,1197,1199,1201,1203,1205],{"class":890,"line":540},[888,1198,1066],{"class":894},[888,1200,899],{"class":898},[888,1202,990],{"class":894},[888,1204,899],{"class":898},[888,1206,918],{"class":894},[888,1208,1209,1211,1213],{"class":890,"line":1010},[888,1210,1104],{"class":894},[888,1212,1051],{"class":898},[888,1214,918],{"class":894},[888,1216,1217,1219,1221,1223,1225,1227],{"class":890,"line":1024},[888,1218,895],{"class":894},[888,1220,1051],{"class":898},[888,1222,1054],{"class":902},[888,1224,906],{"class":894},[888,1226,1059],{"class":909},[888,1228,918],{"class":894},[888,1230,1231,1233,1235,1237,1239],{"class":890,"line":1111},[888,1232,1066],{"class":894},[888,1234,11],{"class":898},[888,1236,1003],{"class":894},[888,1238,11],{"class":898},[888,1240,1099],{"class":894},[888,1242,1243,1245,1247,1249,1251],{"class":890,"line":1126},[888,1244,1066],{"class":894},[888,1246,15],{"class":898},[888,1248,1017],{"class":894},[888,1250,15],{"class":898},[888,1252,918],{"class":894},[888,1254,1255,1257,1259,1261,1263],{"class":890,"line":1139},[888,1256,1066],{"class":894},[888,1258,899],{"class":898},[888,1260,990],{"class":894},[888,1262,899],{"class":898},[888,1264,918],{"class":894},[888,1266,1267,1269,1271],{"class":890,"line":1152},[888,1268,1104],{"class":894},[888,1270,1051],{"class":898},[888,1272,918],{"class":894},[735,1274,1276],{"id":1275},"downsampled-dom-snapshots","Downsampled DOM Snapshots",[11,1278,1279,1280,122],{},"Downsampling means reducing data point count whilst preserving the overall data shape and most of the relevant features. Picture an image being downsized: the depicted object remains recognisable to a large degree. The concept of image downsampling can be transferred to the DOM by locally 'averaging' DOM subtrees – trading fidelity for size",[749,1281,1282],{},[23,1283,1287],{"href":1284,"ariaDescribedBy":1285,"dataFootnoteRef":532,"id":1286},"#user-content-fn-4",[755],"user-content-fnref-4","4",[11,1289,1290],{},[15,1291,1292],{},"Original DOM Snapshot:",[880,1294,1296],{"className":882,"code":1295,"language":884,"meta":532,"style":532},"\u003Csection class=\"container\" tabindex=\"3\" required=\"true\" type=\"example\">\n  \u003Cdiv class=\"mx-auto\" data-topic=\"products\" required=\"false\">\n    \u003Ch1>Our Pizza\u003C/h1>\n    \u003Cdiv>\n      \u003Cdiv class=\"shadow-lg\">\n        \u003Ch2>Margherita\u003C/h2>\n        \u003Cp>\n         A simple classic: mozzarella, tomatoes and basil.\n         An everyday choice!\n        \u003C/p>\n        \u003Cbutton type=\"button\">Add\u003C/button>\n      \u003C/div>\n      \u003Cdiv class=\"shadow-lg\">\n        \u003Ch2>Capricciosa\u003C/h2>\n        \u003Cp>\n          A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\n          A true favourite!\n        \u003C/p>\n        \u003Cbutton type=\"button\">Add\u003C/button>\n      \u003C/div>\n    \u003C/div>\n  \u003C/div>\n\u003C/section>\n",[706,1297,1298,1336,1367,1382,1390,1406,1420,1428,1433,1438,1448,1469,1479,1494,1508,1517,1523,1529,1538,1557,1566,1576,1586],{"__ignoreMap":532},[888,1299,1300,1302,1304,1306,1308,1311,1314,1316,1319,1322,1324,1327,1329,1331,1334],{"class":890,"line":891},[888,1301,895],{"class":894},[888,1303,1051],{"class":898},[888,1305,1054],{"class":902},[888,1307,906],{"class":894},[888,1309,1310],{"class":909},"\"container\"",[888,1312,1313],{"class":902}," tabindex",[888,1315,906],{"class":894},[888,1317,1318],{"class":909},"\"3\"",[888,1320,1321],{"class":902}," required",[888,1323,906],{"class":894},[888,1325,1326],{"class":909},"\"true\"",[888,1328,903],{"class":902},[888,1330,906],{"class":894},[888,1332,1333],{"class":909},"\"example\"",[888,1335,918],{"class":894},[888,1337,1338,1340,1343,1345,1347,1350,1353,1355,1358,1360,1362,1365],{"class":890,"line":533},[888,1339,1066],{"class":894},[888,1341,1342],{"class":898},"div",[888,1344,1054],{"class":902},[888,1346,906],{"class":894},[888,1348,1349],{"class":909},"\"mx-auto\"",[888,1351,1352],{"class":902}," data-topic",[888,1354,906],{"class":894},[888,1356,1357],{"class":909},"\"products\"",[888,1359,1321],{"class":902},[888,1361,906],{"class":894},[888,1363,1364],{"class":909},"\"false\"",[888,1366,918],{"class":894},[888,1368,1369,1372,1375,1378,1380],{"class":890,"line":540},[888,1370,1371],{"class":894},"    \u003C",[888,1373,1374],{"class":898},"h1",[888,1376,1377],{"class":894},">Our Pizza\u003C/",[888,1379,1374],{"class":898},[888,1381,918],{"class":894},[888,1383,1384,1386,1388],{"class":890,"line":1010},[888,1385,1371],{"class":894},[888,1387,1342],{"class":898},[888,1389,918],{"class":894},[888,1391,1392,1395,1397,1399,1401,1404],{"class":890,"line":1024},[888,1393,1394],{"class":894},"      \u003C",[888,1396,1342],{"class":898},[888,1398,1054],{"class":902},[888,1400,906],{"class":894},[888,1402,1403],{"class":909},"\"shadow-lg\"",[888,1405,918],{"class":894},[888,1407,1408,1411,1413,1416,1418],{"class":890,"line":1111},[888,1409,1410],{"class":894},"        \u003C",[888,1412,34],{"class":898},[888,1414,1415],{"class":894},">Margherita\u003C/",[888,1417,34],{"class":898},[888,1419,918],{"class":894},[888,1421,1422,1424,1426],{"class":890,"line":1126},[888,1423,1410],{"class":894},[888,1425,11],{"class":898},[888,1427,918],{"class":894},[888,1429,1430],{"class":890,"line":1139},[888,1431,1432],{"class":894},"         A simple classic: mozzarella, tomatoes and basil.\n",[888,1434,1435],{"class":890,"line":1152},[888,1436,1437],{"class":894},"         An everyday choice!\n",[888,1439,1441,1444,1446],{"class":890,"line":1440},10,[888,1442,1443],{"class":894},"        \u003C/",[888,1445,11],{"class":898},[888,1447,918],{"class":894},[888,1449,1451,1453,1455,1457,1459,1462,1465,1467],{"class":890,"line":1450},11,[888,1452,1410],{"class":894},[888,1454,899],{"class":898},[888,1456,903],{"class":902},[888,1458,906],{"class":894},[888,1460,1461],{"class":909},"\"button\"",[888,1463,1464],{"class":894},">Add\u003C/",[888,1466,899],{"class":898},[888,1468,918],{"class":894},[888,1470,1472,1475,1477],{"class":890,"line":1471},12,[888,1473,1474],{"class":894},"      \u003C/",[888,1476,1342],{"class":898},[888,1478,918],{"class":894},[888,1480,1482,1484,1486,1488,1490,1492],{"class":890,"line":1481},13,[888,1483,1394],{"class":894},[888,1485,1342],{"class":898},[888,1487,1054],{"class":902},[888,1489,906],{"class":894},[888,1491,1403],{"class":909},[888,1493,918],{"class":894},[888,1495,1497,1499,1501,1504,1506],{"class":890,"line":1496},14,[888,1498,1410],{"class":894},[888,1500,34],{"class":898},[888,1502,1503],{"class":894},">Capricciosa\u003C/",[888,1505,34],{"class":898},[888,1507,918],{"class":894},[888,1509,1511,1513,1515],{"class":890,"line":1510},15,[888,1512,1410],{"class":894},[888,1514,11],{"class":898},[888,1516,918],{"class":894},[888,1518,1520],{"class":890,"line":1519},16,[888,1521,1522],{"class":894},"          A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\n",[888,1524,1526],{"class":890,"line":1525},17,[888,1527,1528],{"class":894},"          A true favourite!\n",[888,1530,1532,1534,1536],{"class":890,"line":1531},18,[888,1533,1443],{"class":894},[888,1535,11],{"class":898},[888,1537,918],{"class":894},[888,1539,1541,1543,1545,1547,1549,1551,1553,1555],{"class":890,"line":1540},19,[888,1542,1410],{"class":894},[888,1544,899],{"class":898},[888,1546,903],{"class":902},[888,1548,906],{"class":894},[888,1550,1461],{"class":909},[888,1552,1464],{"class":894},[888,1554,899],{"class":898},[888,1556,918],{"class":894},[888,1558,1560,1562,1564],{"class":890,"line":1559},20,[888,1561,1474],{"class":894},[888,1563,1342],{"class":898},[888,1565,918],{"class":894},[888,1567,1569,1572,1574],{"class":890,"line":1568},21,[888,1570,1571],{"class":894},"    \u003C/",[888,1573,1342],{"class":898},[888,1575,918],{"class":894},[888,1577,1579,1582,1584],{"class":890,"line":1578},22,[888,1580,1581],{"class":894},"  \u003C/",[888,1583,1342],{"class":898},[888,1585,918],{"class":894},[888,1587,1589,1591,1593],{"class":890,"line":1588},23,[888,1590,1104],{"class":894},[888,1592,1051],{"class":898},[888,1594,918],{"class":894},[11,1596,1597],{},[15,1598,1599],{},"Downsampled DOM Snapshot:",[880,1601,1603],{"className":882,"code":1602,"language":884,"meta":532,"style":532},"\u003Csection class=\"container\" required=\"true\" type=\"example\">\n  \u003Cdiv class=\"mx-auto\" required=\"false\">\n    Our Pizza\n    \u003Cdiv>\n      Margherita\n      A simple classic: mozzarella, tomatoes and basil.\n      An everyday choice!\n      \u003Cbutton type=\"button\">Add\u003C/button>\n      Capricciosa\n      A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\n      A true favourite!\n      \u003Cbutton type=\"button\">Add\u003C/button>\n    \u003C/div>\n  \u003C/div>\n\u003C/section>\n",[706,1604,1605,1631,1651,1656,1664,1669,1674,1679,1697,1702,1707,1712,1730,1738,1746],{"__ignoreMap":532},[888,1606,1607,1609,1611,1613,1615,1617,1619,1621,1623,1625,1627,1629],{"class":890,"line":891},[888,1608,895],{"class":894},[888,1610,1051],{"class":898},[888,1612,1054],{"class":902},[888,1614,906],{"class":894},[888,1616,1310],{"class":909},[888,1618,1321],{"class":902},[888,1620,906],{"class":894},[888,1622,1326],{"class":909},[888,1624,903],{"class":902},[888,1626,906],{"class":894},[888,1628,1333],{"class":909},[888,1630,918],{"class":894},[888,1632,1633,1635,1637,1639,1641,1643,1645,1647,1649],{"class":890,"line":533},[888,1634,1066],{"class":894},[888,1636,1342],{"class":898},[888,1638,1054],{"class":902},[888,1640,906],{"class":894},[888,1642,1349],{"class":909},[888,1644,1321],{"class":902},[888,1646,906],{"class":894},[888,1648,1364],{"class":909},[888,1650,918],{"class":894},[888,1652,1653],{"class":890,"line":540},[888,1654,1655],{"class":894},"    Our Pizza\n",[888,1657,1658,1660,1662],{"class":890,"line":1010},[888,1659,1371],{"class":894},[888,1661,1342],{"class":898},[888,1663,918],{"class":894},[888,1665,1666],{"class":890,"line":1024},[888,1667,1668],{"class":894},"      Margherita\n",[888,1670,1671],{"class":890,"line":1111},[888,1672,1673],{"class":894},"      A simple classic: mozzarella, tomatoes and basil.\n",[888,1675,1676],{"class":890,"line":1126},[888,1677,1678],{"class":894},"      An everyday choice!\n",[888,1680,1681,1683,1685,1687,1689,1691,1693,1695],{"class":890,"line":1139},[888,1682,1394],{"class":894},[888,1684,899],{"class":898},[888,1686,903],{"class":902},[888,1688,906],{"class":894},[888,1690,1461],{"class":909},[888,1692,1464],{"class":894},[888,1694,899],{"class":898},[888,1696,918],{"class":894},[888,1698,1699],{"class":890,"line":1152},[888,1700,1701],{"class":894},"      Capricciosa\n",[888,1703,1704],{"class":890,"line":1440},[888,1705,1706],{"class":894},"      A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\n",[888,1708,1709],{"class":890,"line":1450},[888,1710,1711],{"class":894},"      A true favourite!\n",[888,1713,1714,1716,1718,1720,1722,1724,1726,1728],{"class":890,"line":1471},[888,1715,1394],{"class":894},[888,1717,899],{"class":898},[888,1719,903],{"class":902},[888,1721,906],{"class":894},[888,1723,1461],{"class":909},[888,1725,1464],{"class":894},[888,1727,899],{"class":898},[888,1729,918],{"class":894},[888,1731,1732,1734,1736],{"class":890,"line":1481},[888,1733,1571],{"class":894},[888,1735,1342],{"class":898},[888,1737,918],{"class":894},[888,1739,1740,1742,1744],{"class":890,"line":1496},[888,1741,1581],{"class":894},[888,1743,1342],{"class":898},[888,1745,918],{"class":894},[888,1747,1748,1750,1752],{"class":890,"line":1510},[888,1749,1104],{"class":894},[888,1751,1051],{"class":898},[888,1753,918],{"class":894},[11,1755,1756,1757,122],{},"When downsampling is defined over different types of nodes – for instance, elements, attributes, and text – it becomes a powerful technique to control DOM size in a snapshot pipeline. Adaptive implementations can moreover produce snapshots that fall below a hard token limit. Our evaluation revealed that moderate downsampling ratios comfortably fit the mean DOM snapshot of real-world-representative web pages within GPT-4o's context window – leaving headroom for an agent system prompt and a trace of reasoning and action history",[749,1758,1759],{},[23,1760,1287],{"href":1284,"ariaDescribedBy":1761,"dataFootnoteRef":532,"id":1762},[755],"user-content-fnref-4-2",[146,1764,1766],{"id":1765},"the-problem-with-dom-based-targeting","The Problem with DOM-Based Targeting",[11,1768,1769,1770,1773,1774,1777],{},"When DOM snapshots are transformation artefacts, relative CSS selectors like nth-child paths might not map back to the live DOM. There are two straightforward ways to account for breaking CSS selectors: (1) assigning unique IDs to relevant elements in the live UI that persist transformations (e.g., via a unique attribute ",[706,1771,1772],{},"UNIQUE-ID=\"27\"",", which can be selected via ",[706,1775,1776],{},"[UNIQUE-ID=\"27\"]","), and (2) maintaining a source map between elements in the live DOM and the transformed DOM. The latter approach does favourably not affect the snapshot directly.",[11,1779,1780],{},[15,1781,1782],{},"DOM Snapshot with Inlined IDs:",[648,1784],{"src":1785,"alt":1786,"loading":678},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/7.png","A DOM snapshot (HTML) visualising unique ID (attribute) targeting",[146,1788,1790],{"id":1789},"the-dom-based-snapshot-pipeline","The DOM-Based Snapshot Pipeline",[11,1792,1793],{},"LLMs are able to reason over HTML. Yet, HTML carries noise, such as obfuscated scripts or hidden subtrees. DOM snapshots should for that reason be seen as a base representation, rather than a target representation.",[11,1795,1796],{},"The concept of DOM downsampling can be utilised as a universal size control in a snapshot pipeline – ideally exposed as quality, the inverse property of downsampling. Moreover, the DOM can be pre-transformed by deterministic techniques, such as pruning hidden subtrees to surface only the tangible UI – a characteristic that is natural with GUI snapshots.",[11,1798,1799],{},"The pipeline approach traceably goes from the raw DOM to an abstract snapshot representation. For example:",[459,1801,1802,1825,1831,1889,1895,1901],{},[462,1803,1804,1807,1808,1813,1814,1817,1818,487,1821,1824],{},[15,1805,1806],{},"Scope Subtree."," Scope in to a task-relevant subtree. An information retrieval task on ",[23,1809,1812],{"href":1810,"rel":1811},"https://www.wikipedia.org",[27],"wikipedia.org"," can scope into the ",[706,1815,1816],{},"main"," element – ",[706,1819,1820],{},"header",[706,1822,1823],{},"footer"," are irrelevant.",[462,1826,1827,1830],{},[15,1828,1829],{},"Clone."," Clone the live DOM.",[462,1832,1833,1836,1837],{},[15,1834,1835],{},"Filter."," Apply arbitrary filters to the cloned DOM (in memory). For example:\n",[497,1838,1839,1877,1883],{},[462,1840,1841,1844,1845],{},[15,1842,1843],{},"Prune Subtrees"," E.g.:\n",[497,1846,1847,1853,1859],{},[462,1848,1849,1852],{},[15,1850,1851],{},"Non-interactive Nodes",", e.g., hidden elements.",[462,1854,1855,1858],{},[15,1856,1857],{},"Irrelevant Nodes",", e.g., comment nodes.",[462,1860,1861,1864,1865,1867,1868,1870,1871,1874,1875,122],{},[15,1862,1863],{},"Redundant Nodes",", e.g., ",[706,1866,23],{}," in the ",[706,1869,1823],{}," that has a same-",[706,1872,1873],{},"href"," equivalent in the ",[706,1876,1820],{},[462,1878,1879,1882],{},[15,1880,1881],{},"Sanitise."," E.g., sensitive information from content-editables.",[462,1884,1885,1888],{},[15,1886,1887],{},"Clean."," E.g., remove stop words from text nodes.",[462,1890,1891,1894],{},[15,1892,1893],{},"Serialise."," Serialise the cloned DOM to HTML.",[462,1896,1897,1900],{},[15,1898,1899],{},"Downsample."," Downsample the HTML to control size.",[462,1902,1903,1906],{},[15,1904,1905],{},"Translate."," Translate the downsampled HTML to any DOM-based representation, e.g., the accessibility tree.",[648,1908],{"src":1909,"alt":1910,"loading":678,"provider":1911},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/8.svg","Example of a DOM snapshot pipeline","none",[11,1913,1914],{},"A filtered DOM drastically increases stability of repeatedly run web journeys: if only a single button routes to a target page, the agent perceives an unambiguous action target element. The rule of thumb is: the less actionable options a snapshot transcribes, the better – given all relevant options are covered.",[735,1916,1918],{"id":1917},"arbitrary-snapshot-representations","Arbitrary Snapshot Representations",[11,1920,1921],{},"Any text-based snapshot representation can be derived from the single-source-of-truth DOM. Which representation is best highly depends on the given web browsing task. A high-level distinction is between (A) navigation and (B) information retrieval tasks. Navigation tasks do not require extensive text, but  actionable elements – if a snapshot omits a relevant button, the LLM is not able to use the encoded UI. Information retrieval tasks, on the other hand, require text, as the text contains topical information, whilst actionable elements do not matter.",[11,1923,1924],{},"Compare the following snapshots representations for the same UI:",[11,1926,1927],{},[15,1928,1929],{},"DOM Snapshot:",[880,1931,1933],{"className":882,"code":1932,"language":884,"meta":532,"style":532},"\u003Csection class=\"container\" required=\"true\" type=\"example\">\n  \u003Cdiv class=\"mx-auto\" required=\"false\">\n    \u003Ch1>Our Pizza\u003C/h1>\n    \u003Cdiv>\n      \u003Ch2>Margherita\u003C/h2>\n      \u003Cp>\n        A simple classic: mozzarella, tomatoes and basil.\n        An everyday choice!\n      \u003C/p>\n      \u003Ca href=\"add?p=margherita\" data-uid=\"1\">Add\u003C/a>\n      \u003Ch2>Capricciosa\u003C/h2>\n      \u003Cp>\n        A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\n        A true favourite!\n      \u003C/p>\n      \u003Ca href=\"add?p=capricciosa\" data-uid=\"2\">Add\u003C/a>\n    \u003C/div>\n  \u003C/div>\n\u003C/section>\n",[706,1934,1935,1961,1981,1993,2001,2013,2021,2026,2031,2039,2066,2078,2086,2091,2096,2104,2130,2138,2146],{"__ignoreMap":532},[888,1936,1937,1939,1941,1943,1945,1947,1949,1951,1953,1955,1957,1959],{"class":890,"line":891},[888,1938,895],{"class":894},[888,1940,1051],{"class":898},[888,1942,1054],{"class":902},[888,1944,906],{"class":894},[888,1946,1310],{"class":909},[888,1948,1321],{"class":902},[888,1950,906],{"class":894},[888,1952,1326],{"class":909},[888,1954,903],{"class":902},[888,1956,906],{"class":894},[888,1958,1333],{"class":909},[888,1960,918],{"class":894},[888,1962,1963,1965,1967,1969,1971,1973,1975,1977,1979],{"class":890,"line":533},[888,1964,1066],{"class":894},[888,1966,1342],{"class":898},[888,1968,1054],{"class":902},[888,1970,906],{"class":894},[888,1972,1349],{"class":909},[888,1974,1321],{"class":902},[888,1976,906],{"class":894},[888,1978,1364],{"class":909},[888,1980,918],{"class":894},[888,1982,1983,1985,1987,1989,1991],{"class":890,"line":540},[888,1984,1371],{"class":894},[888,1986,1374],{"class":898},[888,1988,1377],{"class":894},[888,1990,1374],{"class":898},[888,1992,918],{"class":894},[888,1994,1995,1997,1999],{"class":890,"line":1010},[888,1996,1371],{"class":894},[888,1998,1342],{"class":898},[888,2000,918],{"class":894},[888,2002,2003,2005,2007,2009,2011],{"class":890,"line":1024},[888,2004,1394],{"class":894},[888,2006,34],{"class":898},[888,2008,1415],{"class":894},[888,2010,34],{"class":898},[888,2012,918],{"class":894},[888,2014,2015,2017,2019],{"class":890,"line":1111},[888,2016,1394],{"class":894},[888,2018,11],{"class":898},[888,2020,918],{"class":894},[888,2022,2023],{"class":890,"line":1126},[888,2024,2025],{"class":894},"        A simple classic: mozzarella, tomatoes and basil.\n",[888,2027,2028],{"class":890,"line":1139},[888,2029,2030],{"class":894},"        An everyday choice!\n",[888,2032,2033,2035,2037],{"class":890,"line":1152},[888,2034,1474],{"class":894},[888,2036,11],{"class":898},[888,2038,918],{"class":894},[888,2040,2041,2043,2045,2047,2049,2052,2055,2057,2060,2062,2064],{"class":890,"line":1440},[888,2042,1394],{"class":894},[888,2044,23],{"class":898},[888,2046,940],{"class":902},[888,2048,906],{"class":894},[888,2050,2051],{"class":909},"\"add?p=margherita\"",[888,2053,2054],{"class":902}," data-uid",[888,2056,906],{"class":894},[888,2058,2059],{"class":909},"\"1\"",[888,2061,1464],{"class":894},[888,2063,23],{"class":898},[888,2065,918],{"class":894},[888,2067,2068,2070,2072,2074,2076],{"class":890,"line":1450},[888,2069,1394],{"class":894},[888,2071,34],{"class":898},[888,2073,1503],{"class":894},[888,2075,34],{"class":898},[888,2077,918],{"class":894},[888,2079,2080,2082,2084],{"class":890,"line":1471},[888,2081,1394],{"class":894},[888,2083,11],{"class":898},[888,2085,918],{"class":894},[888,2087,2088],{"class":890,"line":1481},[888,2089,2090],{"class":894},"        A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\n",[888,2092,2093],{"class":890,"line":1496},[888,2094,2095],{"class":894},"        A true favourite!\n",[888,2097,2098,2100,2102],{"class":890,"line":1510},[888,2099,1474],{"class":894},[888,2101,11],{"class":898},[888,2103,918],{"class":894},[888,2105,2106,2108,2110,2112,2114,2117,2119,2121,2124,2126,2128],{"class":890,"line":1519},[888,2107,1394],{"class":894},[888,2109,23],{"class":898},[888,2111,940],{"class":902},[888,2113,906],{"class":894},[888,2115,2116],{"class":909},"\"add?p=capricciosa\"",[888,2118,2054],{"class":902},[888,2120,906],{"class":894},[888,2122,2123],{"class":909},"\"2\"",[888,2125,1464],{"class":894},[888,2127,23],{"class":898},[888,2129,918],{"class":894},[888,2131,2132,2134,2136],{"class":890,"line":1525},[888,2133,1571],{"class":894},[888,2135,1342],{"class":898},[888,2137,918],{"class":894},[888,2139,2140,2142,2144],{"class":890,"line":1531},[888,2141,1581],{"class":894},[888,2143,1342],{"class":898},[888,2145,918],{"class":894},[888,2147,2148,2150,2152],{"class":890,"line":1540},[888,2149,1104],{"class":894},[888,2151,1051],{"class":898},[888,2153,918],{"class":894},[11,2155,2156],{},[15,2157,2158],{},"Accessibility Tree Snapshot:",[880,2160,2164],{"className":2161,"code":2162,"language":2163,"meta":532,"style":532},"language-yaml shiki shiki-themes github-dark github-dark","- document:\n  children:\n    - section:\n      children:\n        - heading:\n          name: \"Our Pizza\"\n          level: 1\n        - heading:\n          name: \"Margherita\"\n          level: 2\n        - paragraph:\n          children:\n            - text: \"A simple classic: mozzarella, tomatoes and basil. An everyday choice!\"\n        - link:\n          name: \"Add\"\n          url: \"add?p=margherita\"\n          data-uid: 1\n        - heading:\n          name: \"Capricciosa\"\n          level: 2\n        - paragraph:\n          children:\n            - text: \"A rich taste: mozzarella, ham, mushrooms, artichokes and olives. A true favourite!\"\n        - link:\n          name: \"Add\"\n          url: \"add?p=capricciosa\"\n          data-uid: 2\n","yaml",[706,2165,2166,2177,2184,2193,2200,2210,2221,2232,2240,2249,2258,2267,2274,2287,2296,2305,2315,2324,2332,2341,2349,2357,2363,2374,2383,2392,2402],{"__ignoreMap":532},[888,2167,2168,2171,2174],{"class":890,"line":891},[888,2169,2170],{"class":894},"- ",[888,2172,2173],{"class":898},"document",[888,2175,2176],{"class":894},":\n",[888,2178,2179,2182],{"class":890,"line":533},[888,2180,2181],{"class":898},"  children",[888,2183,2176],{"class":894},[888,2185,2186,2189,2191],{"class":890,"line":540},[888,2187,2188],{"class":894},"    - ",[888,2190,1051],{"class":898},[888,2192,2176],{"class":894},[888,2194,2195,2198],{"class":890,"line":1010},[888,2196,2197],{"class":898},"      children",[888,2199,2176],{"class":894},[888,2201,2202,2205,2208],{"class":890,"line":1024},[888,2203,2204],{"class":894},"        - ",[888,2206,2207],{"class":898},"heading",[888,2209,2176],{"class":894},[888,2211,2212,2215,2218],{"class":890,"line":1111},[888,2213,2214],{"class":898},"          name",[888,2216,2217],{"class":894},": ",[888,2219,2220],{"class":909},"\"Our Pizza\"\n",[888,2222,2223,2226,2228],{"class":890,"line":1126},[888,2224,2225],{"class":898},"          level",[888,2227,2217],{"class":894},[888,2229,2231],{"class":2230},"s8ozJ","1\n",[888,2233,2234,2236,2238],{"class":890,"line":1139},[888,2235,2204],{"class":894},[888,2237,2207],{"class":898},[888,2239,2176],{"class":894},[888,2241,2242,2244,2246],{"class":890,"line":1152},[888,2243,2214],{"class":898},[888,2245,2217],{"class":894},[888,2247,2248],{"class":909},"\"Margherita\"\n",[888,2250,2251,2253,2255],{"class":890,"line":1440},[888,2252,2225],{"class":898},[888,2254,2217],{"class":894},[888,2256,2257],{"class":2230},"2\n",[888,2259,2260,2262,2265],{"class":890,"line":1450},[888,2261,2204],{"class":894},[888,2263,2264],{"class":898},"paragraph",[888,2266,2176],{"class":894},[888,2268,2269,2272],{"class":890,"line":1471},[888,2270,2271],{"class":898},"          children",[888,2273,2176],{"class":894},[888,2275,2276,2279,2282,2284],{"class":890,"line":1481},[888,2277,2278],{"class":894},"            - ",[888,2280,2281],{"class":898},"text",[888,2283,2217],{"class":894},[888,2285,2286],{"class":909},"\"A simple classic: mozzarella, tomatoes and basil. An everyday choice!\"\n",[888,2288,2289,2291,2294],{"class":890,"line":1496},[888,2290,2204],{"class":894},[888,2292,2293],{"class":898},"link",[888,2295,2176],{"class":894},[888,2297,2298,2300,2302],{"class":890,"line":1510},[888,2299,2214],{"class":898},[888,2301,2217],{"class":894},[888,2303,2304],{"class":909},"\"Add\"\n",[888,2306,2307,2310,2312],{"class":890,"line":1519},[888,2308,2309],{"class":898},"          url",[888,2311,2217],{"class":894},[888,2313,2314],{"class":909},"\"add?p=margherita\"\n",[888,2316,2317,2320,2322],{"class":890,"line":1525},[888,2318,2319],{"class":898},"          data-uid",[888,2321,2217],{"class":894},[888,2323,2231],{"class":2230},[888,2325,2326,2328,2330],{"class":890,"line":1531},[888,2327,2204],{"class":894},[888,2329,2207],{"class":898},[888,2331,2176],{"class":894},[888,2333,2334,2336,2338],{"class":890,"line":1540},[888,2335,2214],{"class":898},[888,2337,2217],{"class":894},[888,2339,2340],{"class":909},"\"Capricciosa\"\n",[888,2342,2343,2345,2347],{"class":890,"line":1559},[888,2344,2225],{"class":898},[888,2346,2217],{"class":894},[888,2348,2257],{"class":2230},[888,2350,2351,2353,2355],{"class":890,"line":1568},[888,2352,2204],{"class":894},[888,2354,2264],{"class":898},[888,2356,2176],{"class":894},[888,2358,2359,2361],{"class":890,"line":1578},[888,2360,2271],{"class":898},[888,2362,2176],{"class":894},[888,2364,2365,2367,2369,2371],{"class":890,"line":1588},[888,2366,2278],{"class":894},[888,2368,2281],{"class":898},[888,2370,2217],{"class":894},[888,2372,2373],{"class":909},"\"A rich taste: mozzarella, ham, mushrooms, artichokes and olives. A true favourite!\"\n",[888,2375,2377,2379,2381],{"class":890,"line":2376},24,[888,2378,2204],{"class":894},[888,2380,2293],{"class":898},[888,2382,2176],{"class":894},[888,2384,2386,2388,2390],{"class":890,"line":2385},25,[888,2387,2214],{"class":898},[888,2389,2217],{"class":894},[888,2391,2304],{"class":909},[888,2393,2395,2397,2399],{"class":890,"line":2394},26,[888,2396,2309],{"class":898},[888,2398,2217],{"class":894},[888,2400,2401],{"class":909},"\"add?p=capricciosa\"\n",[888,2403,2405,2407,2409],{"class":890,"line":2404},27,[888,2406,2319],{"class":898},[888,2408,2217],{"class":894},[888,2410,2257],{"class":2230},[11,2412,2413],{},[15,2414,2415],{},"Markdown Snapshot:",[880,2417,2420],{"className":2418,"code":2419,"language":565,"meta":532,"style":532},"language-md shiki shiki-themes github-dark github-dark","# Our Pizza\n\n## Margherita\n\nA simple classic: mozzarella, tomatoes and basil.\nAn everyday choice!\n\n[Add](add?p=margherita)\n\n## Capricciosa\n\nA rich taste: mozzarella, ham, mushrooms, artichokes and olives.\nA true favourite!\n\n[Add](add?p=capricciosa)\n",[706,2421,2422,2427,2432,2437,2441,2446,2451,2455,2460,2464,2469,2473,2478,2483,2487],{"__ignoreMap":532},[888,2423,2424],{"class":890,"line":891},[888,2425,2426],{},"# Our Pizza\n",[888,2428,2429],{"class":890,"line":533},[888,2430,2431],{"emptyLinePlaceholder":599},"\n",[888,2433,2434],{"class":890,"line":540},[888,2435,2436],{},"## Margherita\n",[888,2438,2439],{"class":890,"line":1010},[888,2440,2431],{"emptyLinePlaceholder":599},[888,2442,2443],{"class":890,"line":1024},[888,2444,2445],{},"A simple classic: mozzarella, tomatoes and basil.\n",[888,2447,2448],{"class":890,"line":1111},[888,2449,2450],{},"An everyday choice!\n",[888,2452,2453],{"class":890,"line":1126},[888,2454,2431],{"emptyLinePlaceholder":599},[888,2456,2457],{"class":890,"line":1139},[888,2458,2459],{},"[Add](add?p=margherita)\n",[888,2461,2462],{"class":890,"line":1152},[888,2463,2431],{"emptyLinePlaceholder":599},[888,2465,2466],{"class":890,"line":1440},[888,2467,2468],{},"## Capricciosa\n",[888,2470,2471],{"class":890,"line":1450},[888,2472,2431],{"emptyLinePlaceholder":599},[888,2474,2475],{"class":890,"line":1471},[888,2476,2477],{},"A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\n",[888,2479,2480],{"class":890,"line":1481},[888,2481,2482],{},"A true favourite!\n",[888,2484,2485],{"class":890,"line":1496},[888,2486,2431],{"emptyLinePlaceholder":599},[888,2488,2489],{"class":890,"line":1510},[888,2490,2491],{},"[Add](add?p=capricciosa)\n",[11,2493,2494],{},[15,2495,2496],{},"Custom Format Snapshot:",[880,2498,2502],{"className":2499,"code":2501,"language":2281},[2500],"language-text","[0] H1 \"Our Pizza\"\n[1] H2 \"Margherita\"\n[2] P \"A simple classic: mozzarella, tomatoes and basil.\\nAn everyday choice!\"\n[3] A \"Add\" \"add?p=margherita\"\n[4] H2 \"Capricciosa\"\n[5] P \"A rich taste: mozzarella, ham, mushrooms, artichokes and olives.\\nA true...\"\n[6] A \"Add\" \"add?p=capricciosa\"\n",[706,2503,2501],{"__ignoreMap":532},[11,2505,2506,2507,122],{},"Browser Use agents implement hybrid snapshots: the grounded GUI snapshot is a supplement to a custom-format indexed-list DOM snapshot, similar to the above example. Evaluations show that the indexed-list snapshot representation generally conveys most of the salient UI features for the web agent LLM backend",[749,2508,2509],{},[23,2510,1287],{"href":1284,"ariaDescribedBy":2511,"dataFootnoteRef":532,"id":2512},[755],"user-content-fnref-4-3",[34,2514,2516],{"id":2515},"non-idiomatic-application-designs","Non-Idiomatic Application Designs",[11,2518,2519],{},"An actionable element might lack affordance – not communicating its actionability through its bare appearance. That is bad UI/UX design practice. The concept extends to the DOM through HTML semantics, which communicate the general purpose of an element to web browsers and developers rather than users. Generalising to web agent LLM backends, the concept of affordance aligns between the GUI and the DOM – the model is a UI representation-agnostic user.",[11,2521,2522],{},"Missing affordances should be rectified in a snapshot wherever they can be discovered. Discoverability is another circular problem: what is an indirect affordance for actionability? Ideally, the underlying actionability is tracked, such as by checking for attached action event listeners. However, there is no browser API for this practice.",[11,2524,2525],{},"As an example for bad affordance in the GUI, imagine an overly subtle 'Shop' button. Bounding boxes in grounded GUI snapshots are a workaround – provided the element is discoverable as actionable in the DOM in the first place.",[648,2527],{"src":2528,"alt":2529,"loading":678,":width":2530},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/9.png","Example of a fictional UI/UX bad practice (overly subtle button)","480",[11,2532,2533,2534,2539],{},"As an example for bad affordance in the DOM, look at this datepicker from ",[23,2535,2538],{"href":2536,"rel":2537},"https://www.webmd.com",[27],"webmd.com",":",[648,2541],{"src":2542,"alt":2543,"loading":678,":width":2530},"/blog/serialising-web-ui-state-for-llms-the-complete-guide/10.png","Example of an HTML bad practice (ignoring tag name semantics)",[880,2545,2547],{"className":882,"code":2546,"language":884,"meta":532,"style":532},"\u003Cdiv>\n  \u003Cspan class=\"cell day-header\">Sun\u003C/span>\n  \u003Cspan class=\"cell day-header\">Mon\u003C/span>\n  \u003Cspan class=\"cell day-header\">Tue\u003C/span>\n  \u003Cspan class=\"cell day-header\">Wed\u003C/span>\n  \u003Cspan class=\"cell day-header\">Thu\u003C/span>\n  \u003Cspan class=\"cell day-header\">Fri\u003C/span>\n  \u003Cspan class=\"cell day-header\">Sat\u003C/span>\n  \u003C!-- [...] -->\n  \u003Cspan class=\"cell day blank\">\u003C/span>\n  \u003Cspan class=\"cell day blank\">\u003C/span>\n  \u003Cspan class=\"cell day\">\u003Cspan>1\u003C/span>\u003C/span>\n  \u003Cspan class=\"cell day\">\u003Cspan>2\u003C/span>\u003C/span>\n  \u003Cspan class=\"cell day\">\u003Cspan>3\u003C/span>\u003C/span>\n  \u003C!-- [...] -->\n  \u003Cspan class=\"cell day\">\u003Cspan>29\u003C/span>\u003C/span>\n  \u003Cspan class=\"cell day\">\u003Cspan>30\u003C/span>\u003C/span>\n\u003C/div>\n",[706,2548,2549,2557,2577,2596,2615,2634,2653,2672,2691,2697,2717,2735,2764,2791,2818,2822,2849,2876],{"__ignoreMap":532},[888,2550,2551,2553,2555],{"class":890,"line":891},[888,2552,895],{"class":894},[888,2554,1342],{"class":898},[888,2556,918],{"class":894},[888,2558,2559,2561,2563,2565,2567,2570,2573,2575],{"class":890,"line":533},[888,2560,1066],{"class":894},[888,2562,888],{"class":898},[888,2564,1054],{"class":902},[888,2566,906],{"class":894},[888,2568,2569],{"class":909},"\"cell day-header\"",[888,2571,2572],{"class":894},">Sun\u003C/",[888,2574,888],{"class":898},[888,2576,918],{"class":894},[888,2578,2579,2581,2583,2585,2587,2589,2592,2594],{"class":890,"line":540},[888,2580,1066],{"class":894},[888,2582,888],{"class":898},[888,2584,1054],{"class":902},[888,2586,906],{"class":894},[888,2588,2569],{"class":909},[888,2590,2591],{"class":894},">Mon\u003C/",[888,2593,888],{"class":898},[888,2595,918],{"class":894},[888,2597,2598,2600,2602,2604,2606,2608,2611,2613],{"class":890,"line":1010},[888,2599,1066],{"class":894},[888,2601,888],{"class":898},[888,2603,1054],{"class":902},[888,2605,906],{"class":894},[888,2607,2569],{"class":909},[888,2609,2610],{"class":894},">Tue\u003C/",[888,2612,888],{"class":898},[888,2614,918],{"class":894},[888,2616,2617,2619,2621,2623,2625,2627,2630,2632],{"class":890,"line":1024},[888,2618,1066],{"class":894},[888,2620,888],{"class":898},[888,2622,1054],{"class":902},[888,2624,906],{"class":894},[888,2626,2569],{"class":909},[888,2628,2629],{"class":894},">Wed\u003C/",[888,2631,888],{"class":898},[888,2633,918],{"class":894},[888,2635,2636,2638,2640,2642,2644,2646,2649,2651],{"class":890,"line":1111},[888,2637,1066],{"class":894},[888,2639,888],{"class":898},[888,2641,1054],{"class":902},[888,2643,906],{"class":894},[888,2645,2569],{"class":909},[888,2647,2648],{"class":894},">Thu\u003C/",[888,2650,888],{"class":898},[888,2652,918],{"class":894},[888,2654,2655,2657,2659,2661,2663,2665,2668,2670],{"class":890,"line":1126},[888,2656,1066],{"class":894},[888,2658,888],{"class":898},[888,2660,1054],{"class":902},[888,2662,906],{"class":894},[888,2664,2569],{"class":909},[888,2666,2667],{"class":894},">Fri\u003C/",[888,2669,888],{"class":898},[888,2671,918],{"class":894},[888,2673,2674,2676,2678,2680,2682,2684,2687,2689],{"class":890,"line":1139},[888,2675,1066],{"class":894},[888,2677,888],{"class":898},[888,2679,1054],{"class":902},[888,2681,906],{"class":894},[888,2683,2569],{"class":909},[888,2685,2686],{"class":894},">Sat\u003C/",[888,2688,888],{"class":898},[888,2690,918],{"class":894},[888,2692,2693],{"class":890,"line":1152},[888,2694,2696],{"class":2695},"sJ8bj","  \u003C!-- [...] -->\n",[888,2698,2699,2701,2703,2705,2707,2710,2713,2715],{"class":890,"line":1440},[888,2700,1066],{"class":894},[888,2702,888],{"class":898},[888,2704,1054],{"class":902},[888,2706,906],{"class":894},[888,2708,2709],{"class":909},"\"cell day blank\"",[888,2711,2712],{"class":894},">\u003C/",[888,2714,888],{"class":898},[888,2716,918],{"class":894},[888,2718,2719,2721,2723,2725,2727,2729,2731,2733],{"class":890,"line":1450},[888,2720,1066],{"class":894},[888,2722,888],{"class":898},[888,2724,1054],{"class":902},[888,2726,906],{"class":894},[888,2728,2709],{"class":909},[888,2730,2712],{"class":894},[888,2732,888],{"class":898},[888,2734,918],{"class":894},[888,2736,2737,2739,2741,2743,2745,2748,2751,2753,2756,2758,2760,2762],{"class":890,"line":1471},[888,2738,1066],{"class":894},[888,2740,888],{"class":898},[888,2742,1054],{"class":902},[888,2744,906],{"class":894},[888,2746,2747],{"class":909},"\"cell day\"",[888,2749,2750],{"class":894},">\u003C",[888,2752,888],{"class":898},[888,2754,2755],{"class":894},">1\u003C/",[888,2757,888],{"class":898},[888,2759,2712],{"class":894},[888,2761,888],{"class":898},[888,2763,918],{"class":894},[888,2765,2766,2768,2770,2772,2774,2776,2778,2780,2783,2785,2787,2789],{"class":890,"line":1481},[888,2767,1066],{"class":894},[888,2769,888],{"class":898},[888,2771,1054],{"class":902},[888,2773,906],{"class":894},[888,2775,2747],{"class":909},[888,2777,2750],{"class":894},[888,2779,888],{"class":898},[888,2781,2782],{"class":894},">2\u003C/",[888,2784,888],{"class":898},[888,2786,2712],{"class":894},[888,2788,888],{"class":898},[888,2790,918],{"class":894},[888,2792,2793,2795,2797,2799,2801,2803,2805,2807,2810,2812,2814,2816],{"class":890,"line":1496},[888,2794,1066],{"class":894},[888,2796,888],{"class":898},[888,2798,1054],{"class":902},[888,2800,906],{"class":894},[888,2802,2747],{"class":909},[888,2804,2750],{"class":894},[888,2806,888],{"class":898},[888,2808,2809],{"class":894},">3\u003C/",[888,2811,888],{"class":898},[888,2813,2712],{"class":894},[888,2815,888],{"class":898},[888,2817,918],{"class":894},[888,2819,2820],{"class":890,"line":1510},[888,2821,2696],{"class":2695},[888,2823,2824,2826,2828,2830,2832,2834,2836,2838,2841,2843,2845,2847],{"class":890,"line":1519},[888,2825,1066],{"class":894},[888,2827,888],{"class":898},[888,2829,1054],{"class":902},[888,2831,906],{"class":894},[888,2833,2747],{"class":909},[888,2835,2750],{"class":894},[888,2837,888],{"class":898},[888,2839,2840],{"class":894},">29\u003C/",[888,2842,888],{"class":898},[888,2844,2712],{"class":894},[888,2846,888],{"class":898},[888,2848,918],{"class":894},[888,2850,2851,2853,2855,2857,2859,2861,2863,2865,2868,2870,2872,2874],{"class":890,"line":1525},[888,2852,1066],{"class":894},[888,2854,888],{"class":898},[888,2856,1054],{"class":902},[888,2858,906],{"class":894},[888,2860,2747],{"class":909},[888,2862,2750],{"class":894},[888,2864,888],{"class":898},[888,2866,2867],{"class":894},">30\u003C/",[888,2869,888],{"class":898},[888,2871,2712],{"class":894},[888,2873,888],{"class":898},[888,2875,918],{"class":894},[888,2877,2878,2880,2882],{"class":890,"line":1531},[888,2879,1104],{"class":894},[888,2881,1342],{"class":898},[888,2883,918],{"class":894},[11,2885,2886,2887,2889,2890,2893,2894,2896,2897,2900,2901,2903],{},"The days wrapped in ",[706,2888,888],{}," (e.g., ",[706,2891,2892],{},"16",") are clickable, but the HTML communicates no such actionability. The idiomatic DOM equivalent would instead use ",[706,2895,899],{}," elements throughout, or at least assign suitable ",[706,2898,2899],{},"role"," attributes like ",[706,2902,899],{},". A DOM snapshot pipeline leaves space for solving this problem: rewrite the virtual DOM with idiomatic elements.",[880,2905,2907],{"className":882,"code":2906,"language":884,"meta":532,"style":532},"  \u003Cbutton class=\"cell day\">29\u003C/button>\n  \u003C!-- OR -->\n  \u003Cspan role=\"button\" class=\"cell day\">30\u003C/button>\n",[706,2908,2909,2927,2932],{"__ignoreMap":532},[888,2910,2911,2913,2915,2917,2919,2921,2923,2925],{"class":890,"line":891},[888,2912,1066],{"class":894},[888,2914,899],{"class":898},[888,2916,1054],{"class":902},[888,2918,906],{"class":894},[888,2920,2747],{"class":909},[888,2922,2840],{"class":894},[888,2924,899],{"class":898},[888,2926,918],{"class":894},[888,2928,2929],{"class":890,"line":533},[888,2930,2931],{"class":2695},"  \u003C!-- OR -->\n",[888,2933,2934,2936,2938,2941,2943,2945,2947,2949,2951,2953,2955],{"class":890,"line":540},[888,2935,1066],{"class":894},[888,2937,888],{"class":898},[888,2939,2940],{"class":902}," role",[888,2942,906],{"class":894},[888,2944,1461],{"class":909},[888,2946,1054],{"class":902},[888,2948,906],{"class":894},[888,2950,2747],{"class":909},[888,2952,2867],{"class":894},[888,2954,899],{"class":898},[888,2956,918],{"class":894},[34,2958,2960],{"id":2959},"choosing-between-snapshot-representations","Choosing Between Snapshot Representations",[11,2962,2963],{},"No snapshot representation fits all purposes; the two base representations alone – GUI and DOM (HTML) – come with markedly different advantages and limitations. A proper snapshot tool should therefore route and cascade:",[459,2965,2966,2978,2984,2990],{},[462,2967,2968,2971,2972,2974,2975,2977],{},[15,2969,2970],{},"Route Modality."," Fall back to GUI snapshots if the UI is based on ",[706,2973,806],{}," or cross-origin ",[706,2976,802],{}," elements; use DOM snapshots by default.",[462,2979,2980,2983],{},[15,2981,2982],{},"Route Representation."," Categorise task and translate DOM snapshot to the most suitable representation. Categorising the task can be done with increasing levels of machine learning – simple keyword matching, or deploying a language model.",[462,2985,2986,2989],{},[15,2987,2988],{},"Scope Escalation."," If elicited action suggestions are unusable, widen the snapshot scope and representation richness.",[462,2991,2992,2995],{},[15,2993,2994],{},"Cascade to Hybrid."," If elicited action suggestions are still unusable, augment the rich DOM snapshot with a GUI snapshot for maximum grounding.",[42,2997,2998,3017],{},[45,2999,3000],{},[48,3001,3002,3005,3008,3011,3014],{},[51,3003],{"align":3004},"left",[51,3006,3007],{},"GUI",[51,3009,3010],{},"grounded",[51,3012,3013],{},"DOM",[51,3015,3016],{},"transformed",[60,3018,3019,3041,3062,3085,3104,3125],{},[48,3020,3021,3024,3029,3033,3036],{},[65,3022,3023],{"align":3004},"LLM Input Tokens",[65,3025,3026],{},[15,3027,3028],{},"Low",[65,3030,3031],{},[15,3032,3028],{},[65,3034,3035],{},"High",[65,3037,3038,3040],{},[15,3039,3028],{}," to Moderate",[48,3042,3043,3046,3049,3054,3058],{},[65,3044,3045],{"align":3004},"Element Targeting",[65,3047,3048],{},"Absolute",[65,3050,3051],{},[15,3052,3053],{},"Relative",[65,3055,3056],{},[15,3057,3053],{},[65,3059,3060],{},[15,3061,3053],{},[48,3063,3064,3067,3073,3077,3081],{},[65,3065,3066],{"align":3004},"Snapshot Scope",[65,3068,3069,3072],{},[15,3070,3071],{},"Free","/Viewport",[65,3074,3075,3072],{},[15,3076,3071],{},[65,3078,3079],{},[15,3080,3071],{},[65,3082,3083],{},[15,3084,3071],{},[48,3086,3087,3090,3093,3095,3100],{},[65,3088,3089],{"align":3004},"Snapshot Context",[65,3091,3092],{},"UI",[65,3094,3092],{},[65,3096,3097],{},[15,3098,3099],{},"Full",[65,3101,3102],{},[15,3103,3099],{},[48,3105,3106,3111,3116,3120,3123],{},[65,3107,3108,3110],{"align":3004},[706,3109,802],{}," Context",[65,3112,3113],{},[15,3114,3115],{},"Viewport",[65,3117,3118],{},[15,3119,3115],{},[65,3121,3122],{},"Same-origin only",[65,3124,3122],{},[48,3126,3127,3131,3136,3140,3143],{},[65,3128,3129,3110],{"align":3004},[706,3130,806],{},[65,3132,3133],{},[15,3134,3135],{},"Yes",[65,3137,3138],{},[15,3139,3135],{},[65,3141,3142],{},"No",[65,3144,3142],{},[34,3146,3148],{"id":3147},"using-snapshots-in-the-model-context","Using Snapshots in the Model Context",[11,3150,3151],{},"Creating a snapshot is one thing. Using it as context to a model prompt is the other. Usually, conversational AI maintains a full trace of history as model context. Since a snapshot is time-sensitive, however, only the latest snapshot can be targeted with actions by an LLM.",[11,3153,3154],{},"Whether to keep a trace of previous actions and model reasoning is a question in its own right. If web browsing is modelled as a history-independent task, the snapshot-to-actions agent loop could even be separated from the persistent conversational loop as transient, one-shot model prompts.",[34,3156,3158],{"id":3157},"timing-snapshots-in-the-web-client","Timing Snapshots in the Web Client",[11,3160,3161,3162,122],{},"LLM-based web agents are much slower than humans in taking and processing snapshots. Not least for that reason, snapshot rounds should be kept to a minimum and timed so that a snapshot is taken as soon as the UI has reached a stable state. That implies a non-trivial challenge: defining what qualifies as a UI change, and at what intensity such a change counts as a state shift – beyond hard page transitions, e.g., in a single-page application",[749,3163,3164],{},[23,3165,3169],{"href":3166,"ariaDescribedBy":3167,"dataFootnoteRef":532,"id":3168},"#user-content-fn-5",[755],"user-content-fnref-5","5",[3171,3172],"hr",{},[11,3174,3175,3176,122],{},"The snapshot is the central artefact in a web agent harness. Its representation is among the most significant factors for agent success",[749,3177,3178],{},[23,3179,3183],{"href":3180,"ariaDescribedBy":3181,"dataFootnoteRef":532,"id":3182},"#user-content-fn-6",[755],"user-content-fnref-6","6",[11,3185,3186,3187,3189],{},"At Webfuse, we develop a platform for agentic browsing. A focus of our research is on efficient snapshot representations. The Automation API can be used to create next-level snapshots: timed, rectified, across ",[706,3188,802],{}," boundaries, etc.",[1051,3191,3194,3199],{"className":3192,"dataFootnotes":532},[3193],"footnotes",[34,3195,3198],{"className":3196,"id":755},[3197],"sr-only","Footnotes",[459,3200,3201,3216,3229,3241,3267,3279],{},[462,3202,3204,3208,3209],{"id":3203},"user-content-fn-1",[23,3205,3206],{"href":3206,"rel":3207},"https://arxiv.org/abs/2310.11441",[27]," ",[23,3210,3215],{"href":3211,"ariaLabel":3212,"className":3213,"dataFootnoteBackref":532},"#user-content-fnref-1","Back to reference 1",[3214],"data-footnote-backref","↩",[462,3217,3219,3220,3208,3224],{"id":3218},"user-content-fn-2","Our reimplementation of Browser Use's grounded GUI snapshots: ",[23,3221,3222],{"href":3222,"rel":3223},"https://github.com/webfuse-com/D2Snap/blob/main/snapshots/_bu.js",[27],[23,3225,3215],{"href":3226,"ariaLabel":3227,"className":3228,"dataFootnoteBackref":532},"#user-content-fnref-2","Back to reference 2",[3214],[462,3230,3232,3208,3236],{"id":3231},"user-content-fn-3",[23,3233,3234],{"href":3234,"rel":3235},"https://arxiv.org/abs/2210.03945",[27],[23,3237,3215],{"href":3238,"ariaLabel":3239,"className":3240,"dataFootnoteBackref":532},"#user-content-fnref-3","Back to reference 3",[3214],[462,3242,3244,3208,3248,3208,3253,3208,3260],{"id":3243},"user-content-fn-4",[23,3245,3246],{"href":3246,"rel":3247},"https://arxiv.org/abs/2508.04412",[27],[23,3249,3215],{"href":3250,"ariaLabel":3251,"className":3252,"dataFootnoteBackref":532},"#user-content-fnref-4","Back to reference 4",[3214],[23,3254,3215,3258],{"href":3255,"ariaLabel":3256,"className":3257,"dataFootnoteBackref":532},"#user-content-fnref-4-2","Back to reference 4-2",[3214],[749,3259,780],{},[23,3261,3215,3265],{"href":3262,"ariaLabel":3263,"className":3264,"dataFootnoteBackref":532},"#user-content-fnref-4-3","Back to reference 4-3",[3214],[749,3266,795],{},[462,3268,3270,3208,3274],{"id":3269},"user-content-fn-5",[23,3271,3272],{"href":3272,"rel":3273},"https://github.com/webfuse-com/DOMQuake",[27],[23,3275,3215],{"href":3276,"ariaLabel":3277,"className":3278,"dataFootnoteBackref":532},"#user-content-fnref-5","Back to reference 5",[3214],[462,3280,3282,3208,3286],{"id":3281},"user-content-fn-6",[23,3283,3284],{"href":3284,"rel":3285},"https://arxiv.org/abs/2504.01382",[27],[23,3287,3215],{"href":3288,"ariaLabel":3289,"className":3290,"dataFootnoteBackref":532},"#user-content-fnref-6","Back to reference 6",[3214],[3292,3293,3294],"style",{},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .suv1-, html code.shiki .suv1-{--shiki-default:#E1E4E8;--shiki-dark:#E1E4E8}html pre.shiki code .sxg3X, html code.shiki .sxg3X{--shiki-default:#85E89D;--shiki-dark:#85E89D}html pre.shiki code .sFR8T, html code.shiki .sFR8T{--shiki-default:#B392F0;--shiki-dark:#B392F0}html pre.shiki code .s4wv1, html code.shiki .s4wv1{--shiki-default:#9ECBFF;--shiki-dark:#9ECBFF}html pre.shiki code .s8ozJ, html code.shiki .s8ozJ{--shiki-default:#79B8FF;--shiki-dark:#79B8FF}html pre.shiki code .sJ8bj, html code.shiki .sJ8bj{--shiki-default:#6A737D;--shiki-dark:#6A737D}",{"title":532,"searchDepth":533,"depth":533,"links":3296},[3297,3301,3307,3308,3309,3310,3311],{"id":657,"depth":533,"text":658,"children":3298},[3299,3300],{"id":681,"depth":540,"text":682},{"id":721,"depth":540,"text":722},{"id":783,"depth":533,"text":784,"children":3302},[3303,3304,3305,3306],{"id":813,"depth":540,"text":814},{"id":837,"depth":540,"text":838},{"id":1765,"depth":540,"text":1766},{"id":1789,"depth":540,"text":1790},{"id":2515,"depth":533,"text":2516},{"id":2959,"depth":533,"text":2960},{"id":3147,"depth":533,"text":3148},{"id":3157,"depth":533,"text":3158},{"id":755,"depth":533,"text":3198},"2025-08-28","Understand how web-based user interfaces can be serialised for use with LLM-based web agents.",{"homepage":599,"relatedLinks":3315},[3316,3319],{"text":3317,"href":3318},"DOM Downsampling for LLM-Based Web Agents","/rnd/dom-downsampling-for-llm-based-web-agents",{"text":3320,"href":3321,"external":599},"Webfuse Automation API","https://dev.webfuse.com/automation-api/","/blog/serialising-web-ui-state-for-llms-the-complete-guide",{"title":614,"description":3313},{"loc":3322},"blog/1013.serialising-web-ui-state-for-llms-the-complete-guide",[607,3327,3328,3329,3330],"web-agents","web-automation","llms","snapshots","X7R93b2XjyDfLllTDaNgFoo_c8AvF9oBDGzv4yiISFA",{"id":3333,"title":3334,"authorId":615,"body":3335,"category":607,"created":3811,"description":3812,"extension":565,"faqs":583,"featurePriority":583,"head":583,"hideCta":599,"landingPath":583,"meta":3813,"navigation":599,"ogImage":583,"path":3819,"robots":583,"schemaOrg":583,"seo":3820,"sitemap":3821,"stem":3822,"tags":3823,"__hash__":3825},"blog/blog/1011.a-gentle-introduction-to-ai-agents-for-the-web.md","A Gentle Introduction to AI Agents for the Web",{"type":8,"value":3336,"toc":3792},[3337,3355,3359,3367,3372,3375,3379,3382,3402,3406,3415,3419,3435,3440,3443,3447,3458,3462,3465,3469,3476,3480,3503,3507,3511,3514,3517,3521,3542,3545,3549,3553,3562,3573,3578,3582,3591,3594,3598,3601,3604,3608,3621,3624,3628,3637,3640,3644,3648,3651,3655,3659,3662,3736,3738,3741,3755],[11,3338,3339,3344,3345,3344,3349,3354],{},[23,3340,3343],{"href":3341,"rel":3342},"https://openai.com/index/introducing-operator/",[27],"Operator",", ",[23,3346,771],{"href":3347,"rel":3348},"https://browser-use.com/",[27],[23,3350,3353],{"href":3351,"rel":3352},"https://www.skyvern.com/",[27],"Skyvern"," – we are currently witnessing an evolution of autonomous web browsing agents. The concept of agents is, in general, ubiquitous in the era of AI.",[34,3356,3358],{"id":3357},"what-is-an-agent","What is an Agent?",[11,3360,3361,3362,122],{},"An agent is an entity that acts on behalf of another entity – its principal. Robotic agents are modelled after humans: they perceive the world and act in it to achieve a specified goal. Whilst humans perceive through their senses, agents perceive through sensors; whilst humans act through motor systems (e.g., fingers), agents act through actuators. This terminology has been transferred from hard- to software agents, particularly those premised on artificial intelligence (AI). An agent's purpose, that is, its goal, is clearly defined; the principal interfaces with that goal by assigning the agent tasks",[749,3363,3364],{},[23,3365,757],{"href":753,"ariaDescribedBy":3366,"dataFootnoteRef":532,"id":756},[755],[648,3368],{"alt":3369,"loading":678,"src":3370,"provider":1911,":width":3371},"Figurative comparison of component equivalents between a human and an AI agent","/blog/a-gentle-introduction-to-ai-agents-for-the-web/1.svg","430",[11,3373,3374],{},"The analogy is more than decorative: an agent takes over the tool-use expertise, leaving the principal with only the domain expertise. Traditional software applications like Photoshop demand both.",[146,3376,3378],{"id":3377},"what-makes-an-agent-intelligent","What Makes an Agent Intelligent?",[11,3380,3381],{},"For acting on behalf of a human, developing an agent could be as simple as making it follow a hardcoded sequence of actions. This describes process automation, but not an artificially intelligent agent. Whilst definitions for AI differ, agent intelligence comes from making informed decisions that are not hardcoded. Here are common – not necessarily mutually exclusive – high-level approaches to induce intelligence:",[497,3383,3384,3390,3396],{},[462,3385,3386,3389],{},[15,3387,3388],{},"Search"," – the agent has a complete or heuristic model of the world and the action space to anticipate the effects of actions and search for a goal state.",[462,3391,3392,3395],{},[15,3393,3394],{},"Reinforcement learning"," – the agent has an initial action space and iteratively discovers the world and effects of actions, learning an optimal policy to act in order to reach a goal state.",[462,3397,3398,3401],{},[15,3399,3400],{},"Neural networks"," – the agent has no model, only examples: a network is fitted to task–solution instances and generalises to unseen, yet related tasks.",[146,3403,3405],{"id":3404},"a-quick-note-on-multi-agent-systems","A Quick Note on Multi-Agent Systems",[11,3407,3408,3409,3414],{},"Agent design gets an additional edge when other entities act in the same world as the agent. Such entities can be considered agents on their own. Their beliefs and goals might affect the agent: cooperative agents share the designed agent's goal, whilst adversarial agents have an opposite goal. In a zero-sum game, an adversarial agent maximises the exact inverse of the designed agent's utility. Knowing this, the designed agent needs to anticipate intelligent decisions by the adversary (e.g., by applying the ",[23,3410,3413],{"href":3411,"rel":3412},"https://cs.stanford.edu/people/eroberts/courses/soco/projects/2003-04/intelligent-search/minimax.html",[27],"Minimax algorithm","), as opposed to random world changes. That said, web browsing – modelled after humans – is not a typical multi-agent scenario.",[146,3416,3418],{"id":3417},"the-agent-loop","The Agent Loop",[11,3420,3421,3426,3427,3434],{},[23,3422,3425],{"href":3423,"rel":3424},"https://www.nngroup.com/people/don-norman/",[27],"Don Norman","'s ",[23,3428,3431],{"href":3429,"rel":3430},"https://jnd.org/books/the-design-of-everyday-things-revised-and-expanded-edition/",[27],[640,3432,3433],{},"Seven Stages of Action"," is a model of the human cognition cycle that generalises to an agent's lifecycle – the agent loop: with a (1) goal, (2) intent to act, (3) plan actions, (4) execute the action plan – this alters the world – then (5) perceive the new world state, (6) interpret the perception, and finally (7) evaluate the interpretation – report task success or an irrevocable failure; continue the cycle if the world state not yet reflects a goal state.",[648,3436],{"alt":3437,"loading":678,"src":3438,"provider":1911,":width":3439},"Don Norman's Seven Stages of Action – a model of human cognition","/blog/a-gentle-introduction-to-ai-agents-for-the-web/2.svg","500",[11,3441,3442],{},"Humans can run many of these cycles hierarchically, with increasing frequency the smaller the task. Take driving a car as an example: choosing a route runs on the order of minutes, choosing when to change lanes on seconds, and holding the car in its lane on fractions of a second. A cycle for holding the lane (1) is: intent to actively hold the lane (2), plan to keep the steering wheel straight, then watch the road (3), execute plan (4), observe the road (5), check whether the car is in the lane (6), if not, cycle again with an adjusted action plan (e.g., slightly rotate the steering wheel to the right) (7).",[146,3444,3446],{"id":3445},"errors-and-recovery","Errors and Recovery",[11,3448,3449,3450,3453,3454,3457],{},"Precisely speaking, \"to err is human\" means that errors are inevitable when heuristically navigating the world. Consequently, AI agents regularly run into errors, too. Norman's Seven Stages of Action make two error spaces apparent: when executing an action plan; the ",[640,3451,3452],{},"Gulf of Action (Execution)"," – how to act in the world? – and when perceiving world state; the ",[640,3455,3456],{},"Gulf of Perception (Evaluation)"," – how to understand the world?",[648,3459],{"alt":3460,"loading":678,"src":3461,"provider":1911,":width":3439},"The Gulf of Action (Execution) and  Perception (Evaluation) in Don Norman's Seven Stages of Action","/blog/a-gentle-introduction-to-ai-agents-for-the-web/3.svg",[11,3463,3464],{},"There are two notable kinds of errors within the Gulf of Action: mistakes and slips. A mistake occurs when the action plan is wrong, although executing this action plan might go right in itself. A slip occurs when the action plan is right, but the execution goes wrong. Here is an example: stopping a manual-shift car without pressing the clutch. This error describes a mistake if the driver did not know about the need to press the clutch, e.g., because they only knew how to operate automatic-drive cars. It is, in turn, a slip if they simply forgot to press the clutch because of fatigue. Since cognition cycles are hierarchic, most errors can be recovered within a cycle. Hearing a choking engine sound, the driver might adjust the action plan and press the clutch late. Errors that cannot be recovered – picture the car's engine dying – require adjusting the goal, which can be seen as moving on to a new cycle.",[34,3466,3468],{"id":3467},"web-browsing-agents","Web Browsing Agents",[11,3470,3471,3472,3475],{},"The advent of large language models (LLMs) has recently opened a new perspective on developing web agents – falling back on the neural networks approach to intelligence. An LLM can serve as a plug-in reasoning backend: given a task and somehow encoded UI state, it can suggest input actions – type and target, e.g., click at ",[706,3473,3474],{},"(200, 375)"," – that progress the given task. Moreover, it can decide whether a goal state has been reached. Providing a state-and-action history within context conveys to the model prior outcomes and contributes to in-context learning.",[146,3477,3479],{"id":3478},"web-browsing-is-all-about-the-journey","Web Browsing is All About the Journey",[11,3481,3482,3483,3486,3487,3492,3493,3498,3499,3502],{},"A web browsing task is any task that can be solved through a web-based user interface (UI). For instance: ",[640,3484,3485],{},"\"Book the cheapest flight from Amsterdam to New York tomorrow night\""," on ",[23,3488,3491],{"href":3489,"rel":3490},"https://www.klm.com",[27],"klm.com",". Application programming interfaces (APIs; e.g., ",[23,3494,3497],{"href":3495,"rel":3496},"https://www.ibm.com/think/topics/rest-apis",[27],"REST APIs",") are often restricted, incomplete, or unavailable. For that reason, web browsing agents today have to rely on human-facing web application UIs. Many agent use cases, such as for customer experience, even require a human in the loop. In this context, web browsing agents come at two levels: outcome-driven agents care only about reaching a goal state, which favours shortcuts like direct URL navigation or expert navigation like ",[706,3500,3501],{},"Ctrl + F",", whilst journey-driven agents are supposed to browse a web application in human fashion, via the application-native UI.",[648,3504],{"alt":3505,"loading":678,"src":3506},"A depiction of a web journey over three web application UI states","/blog/a-gentle-introduction-to-ai-agents-for-the-web/4.png",[146,3508,3510],{"id":3509},"a-formal-model-for-web-browsing","A Formal Model for Web Browsing",[11,3512,3513],{},"The world of web application UIs is hard to formalise; a complete model spans the union of every reachable UI state in every web application on the web. For that reason, conventional AI has failed to produce capable generalist web agents. From a web agent design perspective, however, an abstract model of web browsing is sufficient.",[11,3515,3516],{},"Web browsing might afford a model that is history-independent. A human could certainly pick up a partially completed browsing task. For example, completing the payment process on an airline website for an already selected flight – assuming prior actions were correct with respect to the specified task (e.g., the selected destination).",[648,3518],{"alt":3519,"loading":678,"src":3520},"Screenshot of the payment page on klm.com that reflects outcomes of prior actions and affords next actions","/blog/a-gentle-introduction-to-ai-agents-for-the-web/5.png",[11,3522,3523,3524,3529,3530,3535,3536,3541],{},"Yet, many web applications lack ",[23,3525,3528],{"href":3526,"rel":3527},"https://www.nngroup.com/articles/ten-usability-heuristics/#toc-1-visibility-of-system-status-1",[27],"visibility of system status"," – against ",[23,3531,3534],{"href":3532,"rel":3533},"https://www.nngroup.com/people/jakob-nielsen/",[27],"Jakob Nielsen","'s first heuristic for UI usability. Visibility of system status comprises reflecting both outcomes of prior actions and affordances for next actions in the UI. With this concept, web browsing is best described as a partially observable Markov decision process (POMDP)",[749,3537,3538],{},[23,3539,780],{"href":777,"ariaDescribedBy":3540,"dataFootnoteRef":532,"id":779},[755]," with, adapting to discovered UI states, where states can be tuples of UI state trajectories to contain history.",[11,3543,3544],{},"Reflex agents take actions that solely depend on the current world state. Planning agents, in turn, plan ahead. For most web browsing tasks, future UI states are roughly predictable, given that web journeys are similar across different web applications that help with similar tasks. In POMDP terms, the expected next UI state has a high probability, whilst unexpected states remain with a non-negligible probability. The further a web journey is progressed, the higher the probability of the next expected UI state gets: the flight selection step is likely followed by the passenger details step, which is even more likely followed by the payment step.",[648,3546],{"alt":3547,"loading":678,"src":3548},"Graph-based web journey representation of an unknown, adaptive, partially observable Markov decision process (POMDP)","/blog/a-gentle-introduction-to-ai-agents-for-the-web/6.png",[146,3550,3552],{"id":3551},"llm-sensors-actuators-agent","LLM + Sensors + Actuators = Agent",[11,3554,3555,3556,3561],{},"Conversationally satisfying simple information requests does not reasonably qualify an LLM as an agent – no more than it would a TF-IDF search system",[749,3557,3558],{},[23,3559,795],{"href":792,"ariaDescribedBy":3560,"dataFootnoteRef":532,"id":794},[755],", or a colleague telling you the time. The web agent LLM backend is metaphorically the brain of the agent. It abstracts the world model and state transition function, and can decide whether a goal state was reached.",[11,3563,3564,3565,3344,3567,3344,3569,3572],{},"Turning an LLM into a web agent means, at the core, connecting it with sensors and actuators, for example, the ability to take DOM snapshots and dispatch clicks via CSS selectors. This is a specialised architecture of LLM tool calling. The set of available input actions is known from human computer use: ",[640,3566,642],{},[640,3568,645],{},[640,3570,3571],{},"scrolling",", etc. The agent loop is then a continuous cycle of serialising UI state for the model to elicit action suggestions under a goal derived from the user-specified task.",[648,3574],{"alt":3575,"loading":678,"src":3576,"provider":1911,":width":3577},"Figurative depiction of components in the agent loop","/blog/a-gentle-introduction-to-ai-agents-for-the-web/7.svg","460",[146,3579,3581],{"id":3580},"snapshots-serialised-ui-state","Snapshots – Serialised UI State",[11,3583,3584,3585,3590],{},"There are plenty of ways to serialise the state of a web-based UI – referred to as a snapshot. A screenshot resembles what humans see when viewing a web page's graphical UI (GUI) at a given point in time. That said, a UI can be represented in versatile ways. LLMs have demonstrated the ability to interpret HTML and even navigate a UI encoded in this way",[749,3586,3587],{},[23,3588,1287],{"href":1284,"ariaDescribedBy":3589,"dataFootnoteRef":532,"id":1286},[755],". The document object model (DOM) is a web browser's runtime model of a web page. Serialised as HTML, to that effect, DOM snapshots represent a compelling alternative to GUI snapshots, offering certain advantages, such as processability (e.g., filtering). Filtering the DOM by pruning hidden, disabled, or redundant subtrees saves LLM communication costs and works towards more stable and predictable journeys.",[11,3592,3593],{},"Outcome-driven web agents have used UI-invasive snapshot measures, such as grounding LLMs with bounding boxes around actionable elements.",[648,3595],{"alt":3596,"loading":678,"src":3597},"Example of a screenshot (GUI snapshot) with coloured bounding boxes that visually ground an LLM","/blog/a-gentle-introduction-to-ai-agents-for-the-web/8.png",[11,3599,3600],{},"The ideal snapshot representation depends on the task. To get an idea, classify between navigation and information retrieval tasks: navigation tasks require snapshots to preserve actionable elements, whilst retrieval tasks require them to preserve text – both can be sourced from DOM snapshots. Accessibility tree snapshots are another DOM-sourced representation. Web UIs rarely afford merely a single task, so many of their components are noise in any given snapshot – which is not just a UI serialisation, but one scoped to the task at hand. GUI snapshots become a necessity when the target application is graphics-based, such as a canvas-based application like Google Maps.",[11,3602,3603],{},"A snapshot impacts the width of Norman's Gulf of Perception: if a relevant element is omitted or diffused, the model is hindered in identifying correct actions to progress a web browsing task. The Gulf of Action mostly grows when the snapshot-encoded UI state and the live UI state have irrecoverably drifted apart. The agent loop should be fast to prevent such drift. The Gulf of Perception is much wider by the nature of the problem: what snapshot representation can an LLM interpret, and which representation is best?",[146,3605,3607],{"id":3606},"targeting-action-suggestions","Targeting – Action Suggestions",[11,3609,3610,3611,3344,3613,3616,3617,3620],{},"An action is a user event, such as ",[640,3612,699],{},[640,3614,3615],{},"type",", or ",[640,3618,3619],{},"scroll",", targeting a specific element in the UI. The set of available actions thereby is defined by the accepted user input types which are generally derived and standardised over the mouse and keyboard devices.",[11,3622,3623],{},"The type of snapshot representation provided to an LLM dictates how an element can be targeted for an action. Vision-based, geometric targeting is indirect and absolute, i.e., by coordinates. DOM-based targeting is direct and relative, e.g., by CSS selectors or object references. Relative targeting remains valid if the UI shifts between snapshot and action time. A shift can happen due to many reasons, for instance, a lazy-loaded image.",[146,3625,3627],{"id":3626},"the-agent-harness","The Agent Harness",[11,3629,3630,3631,3636],{},"Any custom logic that sits between the LLM backend and the web page UI (problem world) is considered an agent harness – often linguistically equated with the agent in general. Common aspects of a harness include task decomposition, model routing, snapshot creation, history management, error recovery, and timeouts. ",[23,3632,3635],{"href":3633,"rel":3634},"https://www.anthropic.com/engineering/effective-context-engineering-for-ai-agents",[27],"System prompts"," are also part of the harness, instructing a general-purpose LLM to model a web agent for a specific domain – right in context.",[11,3638,3639],{},"Designing a harness is where the POMDP and Seven Stages of Action models come into play. The POMDP model helps with context engineering, for instance, how much history to provide to the LLM. The Seven Stages of Action set out problem components and artefacts, for example, the LLM or snapshots, respectively.",[648,3641],{"alt":3642,"loading":678,"src":3643,"provider":1911},"Don Norman's Seven Stages of Action mapped to the agentic web browsing problem","/blog/a-gentle-introduction-to-ai-agents-for-the-web/9.svg",[146,3645,3647],{"id":3646},"the-model-context-protocol","The Model Context Protocol",[11,3649,3650],{},"LLM providers commonly offer a structured output interface, which allows eliciting well-formed action suggestions from an LLM. A client can subsequently parse and drive these suggested actions in the live user interface. Through the model context protocol (MCP) – another web-based RPC standard – structured output can be bridged with tools that LLMs can call directly, without an extra client trip.",[648,3652],{"alt":3653,"loading":678,"src":3654,"provider":1911,":width":3439},"Figurative depiction of components in the agent loop using the model context protocol (MCP)","/blog/a-gentle-introduction-to-ai-agents-for-the-web/10.svg",[146,3656,3658],{"id":3657},"web-browser-environments","Web Browser Environments",[11,3660,3661],{},"When connected to web perception and actuation tools via MCP, an ordinary AI chat UI already qualifies as an agent UI; the MCP integration decides where the actual web browser runs. There are several types of browser runtime environment:",[497,3663,3664,3679,3692,3704],{},[462,3665,3666,3669,3670,3673,3674],{},[15,3667,3668],{},"Agentic browser"," – the agent's UI embeds a browser.",[3671,3672],"br",{},"\nExample: ",[23,3675,3678],{"href":3676,"rel":3677},"https://www.perplexity.ai/comet",[27],"Perplexity Comet",[462,3680,3681,3684,3685,3673,3687],{},[15,3682,3683],{},"Cloud browser"," – the agent spins up a browser in the cloud.",[3671,3686],{},[23,3688,3691],{"href":3689,"rel":3690},"https://www.browserbase.com",[27],"Browserbase",[462,3693,3694,3697,3698,3673,3700],{},[15,3695,3696],{},"Local browser (3rd-party browser)"," – the agent spins up an isolated browser locally.",[3671,3699],{},[23,3701,3703],{"href":629,"rel":3702},[27],"Chromium + Playwright",[462,3705,3706,3709,3710],{},[15,3707,3708],{},"Local browser (1st-party browser)"," – the agent is embedded within a web application running in a user's personal browser, e.g., in the form of a chatbot.\n",[497,3711,3712,3725],{},[462,3713,3714,3717,3718,3673,3720],{},[15,3715,3716],{},"Implemented (1st-party app)"," – served directly through the website.",[3671,3719],{},[23,3721,3724],{"href":3722,"rel":3723},"https://www.cognigy.com/platform/ai-agent-studio",[27],"Cognigy Studio",[462,3726,3727,3730,3731,3673,3733],{},[15,3728,3729],{},"Augmented (3rd-party app)"," – served indirectly through a website proxy.",[3671,3732],{},[23,3734,637],{"href":635,"rel":3735},[27],[3171,3737],{},[11,3739,3740],{},"Building AI agents has been approached from different angles. LLMs have opened up new perspectives on the design and development of AI agents, particularly web agents, which work in a problem domain that is hard to grasp with a formal model. Whilst higher-level agent methodology can borrow much from established research, LLMs have introduced new challenges, such as how to take UI state snapshots for eliciting input action suggestions from such models.",[11,3742,3743,3744,3749,3750,122],{},"At Webfuse, we research agentic web browsing and develop a platform for agentic browsing. Our web application reverse proxy allows LLMs to perceive and act on the live web. Use cases include connecting a chat UI like ",[23,3745,3748],{"href":3746,"rel":3747},"https://claude.com/",[27],"Claude",", or shipping ",[23,3751,3754],{"href":3752,"rel":3753},"https://github.com/webfuse-com/extension-elevenlabs-mcp",[27],"perceive-and-act-ready chatbots",[1051,3756,3758,3761],{"className":3757,"dataFootnotes":532},[3193],[34,3759,3198],{"className":3760,"id":755},[3197],[459,3762,3763,3772,3778,3784],{},[462,3764,3765,3208,3769],{"id":3203},[23,3766,3767],{"href":3767,"rel":3768},"https://inst.eecs.berkeley.edu/~cs188/textbook/textbook_full.pdf",[27],[23,3770,3215],{"href":3211,"ariaLabel":3212,"className":3771,"dataFootnoteBackref":532},[3214],[462,3773,3774,3775],{"id":3218},"A POMDP is a decision process in which the agent cannot see the exact world state, only partial observations of it, and so must choose actions against a probability distribution over the states it might be in. ",[23,3776,3215],{"href":3226,"ariaLabel":3227,"className":3777,"dataFootnoteBackref":532},[3214],[462,3779,3780,3781],{"id":3231},"TF-IDF (term frequency-inverse document frequency) is an information retrieval method that ranks documents by how often a query term occurs in each one, weighted down by how common that term is across the whole collection – so terms that are frequent here but rare elsewhere carry the most weight. ",[23,3782,3215],{"href":3238,"ariaLabel":3239,"className":3783,"dataFootnoteBackref":532},[3214],[462,3785,3786,3208,3789],{"id":3243},[23,3787,3234],{"href":3234,"rel":3788},[27],[23,3790,3215],{"href":3250,"ariaLabel":3251,"className":3791,"dataFootnoteBackref":532},[3214],{"title":532,"searchDepth":533,"depth":533,"links":3793},[3794,3800,3810],{"id":3357,"depth":533,"text":3358,"children":3795},[3796,3797,3798,3799],{"id":3377,"depth":540,"text":3378},{"id":3404,"depth":540,"text":3405},{"id":3417,"depth":540,"text":3418},{"id":3445,"depth":540,"text":3446},{"id":3467,"depth":533,"text":3468,"children":3801},[3802,3803,3804,3805,3806,3807,3808,3809],{"id":3478,"depth":540,"text":3479},{"id":3509,"depth":540,"text":3510},{"id":3551,"depth":540,"text":3552},{"id":3580,"depth":540,"text":3581},{"id":3606,"depth":540,"text":3607},{"id":3626,"depth":540,"text":3627},{"id":3646,"depth":540,"text":3647},{"id":3657,"depth":540,"text":3658},{"id":755,"depth":533,"text":3198},"2025-06-15","Get an idea of agents and how to build AI agents that browse the web: key concepts, terminology, and challenges.",{"homepage":599,"relatedLinks":3814},[3815,3817,3818],{"text":3816,"href":3322},"Serialising Web UI State for LLMs",{"text":3317,"href":3318},{"text":3320,"href":3321,"external":599},"/blog/a-gentle-introduction-to-ai-agents-for-the-web",{"title":3334,"description":3812},{"loc":3819},"blog/1011.a-gentle-introduction-to-ai-agents-for-the-web",[607,3824,3327,3328,3329],"browser-agents","65hAoQNete8P3AgO-H42P0eBhVfIkl5vIfZZAkvL-9o",1792660832157]