<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Evanchen</title>
    <description>The latest articles on DEV Community by Evanchen (@yevanchen).</description>
    <link>https://dev.to/yevanchen</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4056459%2F3da824bf-4c4f-4d3e-9499-03ce0dd89425.jpg</url>
      <title>DEV Community: Evanchen</title>
      <link>https://dev.to/yevanchen</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/yevanchen"/>
    <language>en</language>
    <item>
      <title>Two kinds of agents: Pet and Cattle</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Tue, 11 Aug 2026 13:12:37 +0000</pubDate>
      <link>https://dev.to/yevanchen/two-kinds-of-agents-pet-and-cattle-55g3</link>
      <guid>https://dev.to/yevanchen/two-kinds-of-agents-pet-and-cattle-55g3</guid>
      <description>&lt;p&gt;I increasingly believe that agents will split into two camps.&lt;/p&gt;

&lt;p&gt;They are not lighter and heavier versions of the same product, nor do they sit at different points on a scale of autonomy. People expect them to become entirely different things: one is expected to become “someone”; the other only needs to finish a certain kind of work.&lt;/p&gt;

&lt;p&gt;mosoo calls these two kinds of agents &lt;strong&gt;Pet&lt;/strong&gt; and &lt;strong&gt;Cattle&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where these terms came from
&lt;/h2&gt;

&lt;p&gt;Anthropic did not invent Pet and Cattle. The terms come from an old infrastructure analogy. We encountered them again in Anthropic’s 2026 article, &lt;a href="https://www.anthropic.com/engineering/managed-agents" rel="noopener noreferrer"&gt;Scaling Managed Agents: Decoupling the brain from the hands&lt;/a&gt;: a pet is a named individual that needs special care and cannot be easily lost, while cattle are interchangeable.&lt;/p&gt;

&lt;p&gt;Anthropic’s article is about agent infrastructure. Its conclusion is to separate the brain, hands, and session so that containers and harnesses can be replaced, rather than binding all state to a machine that has to be nursed back to health.&lt;/p&gt;

&lt;p&gt;mosoo borrowed the terms but pushed the question up to the product layer. We are not asking how servers should be managed. We are asking what people expect an agent to become.&lt;/p&gt;

&lt;p&gt;Anthropic’s earlier &lt;a href="https://www.anthropic.com/engineering/building-effective-agents" rel="noopener noreferrer"&gt;Building effective agents&lt;/a&gt; also distinguishes workflows from agents. A workflow sends LLMs and tools down paths written in advance; an agent decides for itself how to proceed and which tools to use. This distinction matters because Cattle is not just a traditional workflow with a new name. It is still an agent.&lt;/p&gt;

&lt;h2&gt;
  
  
  Type one: Pet, an agent you cultivate
&lt;/h2&gt;

&lt;p&gt;The clearest example of this kind of agent is &lt;a href="https://openclaw.ai/" rel="noopener noreferrer"&gt;OpenClaw&lt;/a&gt;, which broke out in early 2026. People expect it to feel more like Jarvis: a personal assistant with an identity.&lt;/p&gt;

&lt;p&gt;It has its own special memory. Interacting with it is, in practice, a process of cultivating it. People often compare the experience to mentoring an intern, and they naturally start to see the agent as a digital employee.&lt;/p&gt;

&lt;p&gt;This kind of agent carries heavy state. It is often already a proxy for a computer—or, more directly, the proxy for a machine. A large amount of external state is preserved through tools and memory. MCP and skills extend its capabilities. Memory in the filesystem becomes part of the agent itself.&lt;/p&gt;

&lt;p&gt;Users do not treat it as an instance that can be freely generalized or replaced. A two-year-old MacBook Pro is usually more useful to you than one you just bought. The hardware did not become better; it accumulated your software, sign-ins, files, habits, and way of working. That is why computers and phones need cloning, migration, and restore. Pet agents will need the same things.&lt;/p&gt;

&lt;p&gt;We have long believed that this kind of agent should be delivered—or distributed—across channels. You can talk to it in GitHub, move to Linear, Email, Slack, or Discord, and it should still know what happened before. A channel is an entry point; the agent behind those entry points should remain the same.&lt;/p&gt;

&lt;p&gt;Take an FAQ support agent. The customer problems it solved in Discord, the issues it handled on GitHub, and the work it recorded in Zendesk or Slack should all shape how it responds next. This is not one bot per channel. It is one agent, with one identity and memory, distributed to many places.&lt;/p&gt;

&lt;p&gt;This agent may also receive permissions that resemble those of a natural person or social citizen. A user may give it a dedicated email address and its own credentials, then let it access payments, email, calendars, or internal systems. It may hold only a subset of that person’s permissions, or something close to the full set.&lt;/p&gt;

&lt;p&gt;Pet users therefore care about token spend and whether subscriptions can lower the cost of long-term use. They care whether memory can be migrated, whether credentials are safe, and whether the agent remains “the same one” after moving to another machine. These are not deployment details. They are the core product experience.&lt;/p&gt;

&lt;h2&gt;
  
  
  Type two: Cattle, an agent pipeline that replaces a workflow
&lt;/h2&gt;

&lt;p&gt;To understand Cattle, start with the workflow.&lt;/p&gt;

&lt;p&gt;A workflow is a process pipeline. A person defines the procedure for a recurring problem in advance and specifies what should happen at each node. It often begins as the method of an experienced operator, then gets assembled in a low-code tool such as n8n or Dify. A few LLM nodes may handle steps that need reasoning, but the whole thing remains a fixed process.&lt;/p&gt;

&lt;p&gt;Cattle is meant to replace that earlier generation of workflows.&lt;/p&gt;

&lt;p&gt;It is a stateless agent. “Stateless” does not mean a task has no context. It means the agent does not depend on an irreplaceable, long-lived identity. The jobs it consumes, their type, and their input are highly consistent. Its required tools are fixed, and it works inside a controlled problem domain. When one run ends, a fresh instance can handle the next job of the same kind.&lt;/p&gt;

&lt;p&gt;It behaves like a more flexible and free processing pipeline, with more room for reasoning and less dependence on a fixed path. PR audits, ticket triage, and refund requests are typical examples. We can constrain the permissions, input, and expected outcome without enumerating every step the agent must take.&lt;/p&gt;

&lt;p&gt;Its mental model is closer to the imagined end state of autonomous driving: instead of continuing to encode “stop on red, go on green” as a growing set of if-else rules, an end-to-end system built around a vision model drives within a defined boundary. This analogy does not mean agents need no guardrails. It means the core capability shifts from “a person wrote the full path” to “the model chooses a path inside a controlled domain.”&lt;/p&gt;

&lt;p&gt;Cattle users do not want to cultivate the agent, and they do not care which instance completed a particular job. They care about throughput, repeatable outcomes, whether failures can be rerun, whether permissions stay narrow, and how much each job costs. Its natural consumption model is an API token, with the agent embedded as a processing step inside another system.&lt;/p&gt;

&lt;h2&gt;
  
  
  The same support agent can be two entirely different products
&lt;/h2&gt;

&lt;p&gt;Pet and Cattle are not determined by the industry, the model, or the name of the task. They are determined by the continuity users expect and the permissions the system is prepared to grant.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;Pet&lt;/th&gt;
&lt;th&gt;Cattle&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;User relationship&lt;/td&gt;
&lt;td&gt;I am cultivating “it” over time&lt;/td&gt;
&lt;td&gt;I am repeatedly invoking a capability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;State&lt;/td&gt;
&lt;td&gt;Identity, memory, and environment accumulate&lt;/td&gt;
&lt;td&gt;Each job starts from controlled input&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Distribution&lt;/td&gt;
&lt;td&gt;The same agent appears in many channels&lt;/td&gt;
&lt;td&gt;A pipeline embedded at one system boundary&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Permissions&lt;/td&gt;
&lt;td&gt;Delegated personal permissions, potentially broad&lt;/td&gt;
&lt;td&gt;The minimum permissions for one class of work&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cost model&lt;/td&gt;
&lt;td&gt;Tokens, subscriptions, and long-term ownership&lt;/td&gt;
&lt;td&gt;API usage and cost per job or outcome&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Failure recovery&lt;/td&gt;
&lt;td&gt;Clone, migrate, and restore “the same one”&lt;/td&gt;
&lt;td&gt;Discard the instance and rerun the job&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The FAQ agent above is a Pet if it needs to remember its long-running work across Discord, GitHub, Slack, and Zendesk. An execution unit that processes a single refund from an order, a policy, and a customer request is closer to Cattle. Both may be called a “support agent,” but they are not the same product.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why mosoo implements both Agent Types
&lt;/h2&gt;

&lt;p&gt;mosoo currently implements them as two Agent Types: &lt;strong&gt;Assistant Agent (Pet)&lt;/strong&gt; and &lt;strong&gt;Task Agent (Cattle)&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Pet keeps a stable working environment so that state can accumulate across sessions. Cattle creates a clean working environment for every run and releases it when the job ends. The current boundary is documented in the &lt;a href="https://github.com/langgenius/mosoo/blob/main/docs/prd/agent-type.md" rel="noopener noreferrer"&gt;mosoo Agent Type PRD&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I also know that putting both choices in a single Agent Type selector will not be the final, correct product design. They serve two different kinds of users, with different buying, authorization, deployment, and cost models. mosoo has implemented the runtime boundary first. We will keep clarifying the product boundary over time.&lt;/p&gt;

&lt;h2&gt;
  
  
  This will become a dividing line across the agent industry
&lt;/h2&gt;

&lt;p&gt;I believe the industry will explore this question repeatedly throughout 2026, and the distinction will gradually become clearer.&lt;/p&gt;

&lt;p&gt;It will create two camps in investment maps. It will create two camps in agent infrastructure, and two camps in agent-native apps.&lt;/p&gt;

&lt;p&gt;Companies building for Pets need to solve identity, long-term memory, delegated credentials, cross-channel distribution, backup and cloning, and the trust that gradually accumulates between a person and an agent. They are delivering something closer to a digital employee.&lt;/p&gt;

&lt;p&gt;Companies building for Cattle need to solve isolation, evals, reproducible execution, concurrency, APIs, least privilege, auditing, and unit economics per task. They are providing a new kind of computation and processing capacity.&lt;/p&gt;

&lt;p&gt;Neither path is more “agentic” than the other. The value of a Pet accumulates with time and use. The value of Cattle comes from being replaceable again and again while its outcomes remain reliable.&lt;/p&gt;

&lt;p&gt;The next time we evaluate an agent product, perhaps we should not ask only what it can do. We should first ask: do users expect it to become someone, or do they only expect it to complete something?&lt;/p&gt;




&lt;p&gt;Originally published on &lt;a href="https://mosoo.ai/blog/two-kinds-of-agents-pet-and-cattle" rel="noopener noreferrer"&gt;mosoo&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>agents</category>
      <category>product</category>
      <category>architecture</category>
    </item>
    <item>
      <title>How ghfind turns a Mosoo Agent into a project evaluation feature</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Mon, 10 Aug 2026 09:58:13 +0000</pubDate>
      <link>https://dev.to/yevanchen/how-ghfind-turns-a-mosoo-agent-into-a-project-evaluation-feature-2gil</link>
      <guid>https://dev.to/yevanchen/how-ghfind-turns-a-mosoo-agent-into-a-project-evaluation-feature-2gil</guid>
      <description>&lt;p&gt;&lt;a href="https://ghfind.com" rel="noopener noreferrer"&gt;ghfind&lt;/a&gt; does not hand its entire product to an Agent. It delegates one feature that genuinely needs open-ended research—the deep evaluation of public GitHub repositories—to a published Mosoo Agent. GitHub account scoring, job orchestration, result validation, and the product interface remain ghfind's responsibility.&lt;/p&gt;

&lt;p&gt;That boundary answers the most important question in Agent adoption: Mosoo does not rebuild the application's business logic. It lets the application call an Agent with tools, a sandbox, and a managed lifecycle as a backend capability.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is ghfind?
&lt;/h2&gt;

&lt;p&gt;ghfind is an open-source product for scoring the value and trustworthiness of GitHub developers. The homepage roast calculates a reproducible account score from public GitHub data. It does not use an Agent.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fio0uh4akod3ck2y6sfjs.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fio0uh4akod3ck2y6sfjs.png" alt="The GitHub account scoring entry point on the ghfind homepage" width="800" height="584"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;ghfind also evaluates projects. A user submits a public repository and, optionally, a branch, tag, or commit. ghfind returns a structured judgment across real demand, effectiveness, onboarding experience, and value density. That work requires reading source code, documentation, and project history—and sometimes verifying installation, builds, and core flows—so it is a better fit for an Agent.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fenf03dg2kksypizf9tuh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fenf03dg2kksypizf9tuh.png" alt="The ghfind project evaluation entry point, labeled Powered by mosoo" width="800" height="584"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What does Mosoo do here?
&lt;/h2&gt;

&lt;p&gt;ghfind publishes a cattle Agent carrying its project-evaluation Skill on Mosoo. Mosoo supplies the reusable runtime capabilities: an isolated sandbox, Agent harness, tool execution, Run lifecycle, public events, and output files. ghfind does not need to maintain its own model loop, tool runner, or sandbox scheduler.&lt;/p&gt;

&lt;p&gt;The real path for one evaluation is:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;The browser submits a repository URL to ghfind.&lt;/li&gt;
&lt;li&gt;ghfind's Go worker calls &lt;code&gt;POST /agents/{agentId}/threads&lt;/code&gt; with a stable idempotency key and persists the Thread and Run IDs.&lt;/li&gt;
&lt;li&gt;Mosoo starts the published Agent in an isolated sandbox. The Agent inspects the repository against ghfind's rubric while emitting Run and tool events.&lt;/li&gt;
&lt;li&gt;The Agent commits three files: analysis JSON, evidence JSON, and a Markdown report.&lt;/li&gt;
&lt;li&gt;ghfind downloads the files, validates them against its business schema, persists the result, and renders a native result page.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The Mosoo token stays in the ghfind backend. The browser sees ghfind's validated product result, not Mosoo's internal runtime data.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fba7wyknwmo50ybzb4tx2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fba7wyknwmo50ybzb4tx2.png" alt="A project evaluation produced by a Mosoo Agent and rendered by ghfind" width="800" height="584"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The boundary between Agent and application
&lt;/h2&gt;

&lt;p&gt;In this design, Mosoo owns the reusable Agent runtime. ghfind owns the product definition.&lt;/p&gt;

&lt;p&gt;The responsibilities that should stay in ghfind include the project rubric, repository submission and authorization, durable RabbitMQ jobs and concurrency, business retry policy, artifact size limits, result schema, leaderboards, and UI. Its headline account score is especially important: it is a deterministic scoring core locked down by unit tests and has nothing to do with the Mosoo Agent.&lt;/p&gt;

&lt;p&gt;The responsibilities Mosoo should absorb are the protocol glue every Agent App would otherwise repeat: Thread, Run, event, and file types; authentication and error envelopes; idempotent requests; a resumable Run watcher; and a stable association between a Run and its output artifacts.&lt;/p&gt;

&lt;h2&gt;
  
  
  The current integration cost
&lt;/h2&gt;

&lt;p&gt;ghfind's implementation also reveals what Mosoo still needs to provide. At &lt;a href="https://github.com/hikariming/ghfind/tree/b7eee13f547807c0be36f9f3c0c4c4457b699fdd" rel="noopener noreferrer"&gt;&lt;code&gt;b7eee13&lt;/code&gt;&lt;/a&gt;, the production Go backend maintains a &lt;a href="https://github.com/hikariming/ghfind/blob/b7eee13f547807c0be36f9f3c0c4c4457b699fdd/internal/backend/mosoo.go" rel="noopener noreferrer"&gt;564-line handwritten Public Thread client&lt;/a&gt;. The file explicitly says it mirrors a separate &lt;a href="https://github.com/hikariming/ghfind/blob/b7eee13f547807c0be36f9f3c0c4c4457b699fdd/src/lib/mosoo-project-analysis.ts" rel="noopener noreferrer"&gt;427-line TypeScript implementation&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Three workarounds stand out:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The client fetches only the latest 100 events. It parses &lt;code&gt;truncated&lt;/code&gt; but neither pages older history nor surfaces truncation to the caller.&lt;/li&gt;
&lt;li&gt;The worker polls the Thread, detects terminal states, schedules backoff, and restores a Run after queue redelivery.&lt;/li&gt;
&lt;li&gt;After completion, the client scans the full Thread file list and finds results by three agreed filenames; it cannot obtain structured artifact IDs directly from the Run.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These observations are now recorded in Mosoo &lt;a href="https://github.com/langgenius/mosoo/issues/489" rel="noopener noreferrer"&gt;#489&lt;/a&gt;, which tracks publishing and extending the existing Public Thread client instead of creating a second SDK. The stable Run-to-artifact association is tracked separately in &lt;a href="https://github.com/langgenius/mosoo/issues/505" rel="noopener noreferrer"&gt;#505&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  The reusable lesson
&lt;/h2&gt;

&lt;p&gt;The safest way to add an Agent to a product is not to let the Agent take over the whole application. Find the feature that actually requires open-ended reasoning, tool use, and isolated execution, then put that work in a published Mosoo Agent. Keep user identity, business state, deterministic rules, and final presentation in the application.&lt;/p&gt;

&lt;p&gt;ghfind's project evaluation demonstrates that boundary: Mosoo makes the Agent runnable, observable, and able to deliver files; ghfind turns those capabilities into a product feature users can understand and choose to use.&lt;/p&gt;




&lt;p&gt;Originally published at &lt;a href="https://mosoo.ai/blog/ghfind-mosoo-project-evaluation" rel="noopener noreferrer"&gt;mosoo.ai&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>opensource</category>
      <category>webdev</category>
    </item>
    <item>
      <title>From model calls to agent tasks</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Sat, 01 Aug 2026 08:31:15 +0000</pubDate>
      <link>https://dev.to/yevanchen/from-model-calls-to-agent-tasks-2bh8</link>
      <guid>https://dev.to/yevanchen/from-model-calls-to-agent-tasks-2bh8</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F017nm9wb85h3o5nhesm4.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F017nm9wb85h3o5nhesm4.jpg" alt="A collage of green paper squares and wild plants climbing upward on a pale field, like sessions stacking into a living system." width="799" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Every generation of AI API gives developers a new primitive. Completions returned text. Chat APIs added structured messages. Tool calling let models request actions.&lt;/p&gt;

&lt;p&gt;Each step moved more intelligence behind the API. But the application still owned the loop around it: tools, permissions, environment, state, retries, and the product experience.&lt;/p&gt;

&lt;p&gt;Modern model APIs now include hosted tools, stored state, and background execution. They are useful building blocks. They still do not run your product-specific agent with its own environment, credentials, files, and lifecycle.&lt;/p&gt;

&lt;h2&gt;
  
  
  Local agents proved the runtime
&lt;/h2&gt;

&lt;p&gt;Claude Code and Codex changed the experience because the model was no longer alone. It had a filesystem, shell, git, skills, and tools inside a real working environment.&lt;/p&gt;

&lt;p&gt;That makes a familiar prototype possible. Point a coding agent at a repository, let it pull data and run an analysis, then feed the result into your own web page. The workflow can come together in one sitting.&lt;/p&gt;

&lt;p&gt;The next request arrives naturally: move it to the cloud, run it on a schedule, run jobs concurrently, or turn it into a feature for teammates and customers.&lt;/p&gt;

&lt;h2&gt;
  
  
  Productizing agents exposes the runtime gap
&lt;/h2&gt;

&lt;p&gt;When the workflow leaves the laptop, model intelligence is not the missing piece. Runtime is.&lt;/p&gt;

&lt;p&gt;A production integration needs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a sandboxed environment where the agent can run commands and work with files;&lt;/li&gt;
&lt;li&gt;execution that can outlive one HTTP request;&lt;/li&gt;
&lt;li&gt;durable Thread state and explicit file storage;&lt;/li&gt;
&lt;li&gt;events that expose progress without leaking private runtime data;&lt;/li&gt;
&lt;li&gt;permission gates, interruption, retries, concurrency, and usage controls;&lt;/li&gt;
&lt;li&gt;secure custody for model keys and integration credentials.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These are not model capabilities. They are runtime and product responsibilities. If every team rebuilds them, an agent feature becomes an agent platform project.&lt;/p&gt;

&lt;h2&gt;
  
  
  The unit of work is a task
&lt;/h2&gt;

&lt;p&gt;We should not call this a new unit of compute. One agent task may contain many model calls, tool calls, retries, and files. It is a unit of work.&lt;/p&gt;

&lt;p&gt;Your product hands a task to a purpose-built cloud agent. A managed runtime executes it in a configured sandbox, while your product remains the user interface.&lt;/p&gt;

&lt;p&gt;This is serverless as a consumption model: you invoke the agent without operating its execution infrastructure. It does not mean the task is a short-lived function.&lt;/p&gt;

&lt;h2&gt;
  
  
  A managed agent runtime, exposed as an API
&lt;/h2&gt;

&lt;p&gt;That is the abstraction mosoo provides. Publish an Agent, call it from your backend, and mosoo handles execution, Threads, and files.&lt;/p&gt;

&lt;p&gt;Create a Thread with an initial message. Follow its run status through the Thread, observe progress through Events, and exchange attachments and recorded artifacts through Files.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; POST &lt;span class="s2"&gt;"https://cloud.mosoo.ai/api/v1/agents/&lt;/span&gt;&lt;span class="nv"&gt;$AGENT_ID&lt;/span&gt;&lt;span class="s2"&gt;/threads"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Authorization: Bearer &lt;/span&gt;&lt;span class="nv"&gt;$MOSOO_API_TOKEN&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{
    "input": {
      "type": "user.message",
      "content": [
        { "type": "text", "text": "Analyze the commits from last week." }
      ]
    }
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Poll &lt;code&gt;GET /threads/{threadId}/events&lt;/code&gt;, or use &lt;code&gt;/events/stream&lt;/code&gt; for Server-Sent Events. Your product can show progress, tool activity, results, and downloadable artifacts in its own interface.&lt;/p&gt;

&lt;p&gt;API tokens are backend secrets. Your app remains responsible for end-user authentication, authorization, and mapping its users to mosoo Threads.&lt;/p&gt;

&lt;h2&gt;
  
  
  From local prototype to product
&lt;/h2&gt;

&lt;p&gt;Every published Agent includes a copyable &lt;strong&gt;Instruction for LLM&lt;/strong&gt;. It gives a coding agent the generated identifiers, endpoints, environment variables, and integration contract for that Agent.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7w9p3j1a1dcrevl1q2ol.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7w9p3j1a1dcrevl1q2ol.png" alt="mosoo console showing a published agent with the " width="800" height="524"&gt;&lt;/a&gt;&lt;br&gt;
  &lt;em&gt;Publish an Agent, copy its Instruction for LLM, and give your coding agent the exact contract it needs to integrate with mosoo.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Paste the instruction into Claude Code or Codex and let it wire the API into your backend. You still review authentication, data access, and the user experience like any production integration.&lt;/p&gt;

&lt;p&gt;Local agents proved the value of giving models a real runtime. The next step is not a larger model call. It is a managed agent task that your product can start, observe, and continue through an API.&lt;/p&gt;

&lt;p&gt;Try it at &lt;a href="https://cloud.mosoo.ai" rel="noopener noreferrer"&gt;cloud.mosoo.ai&lt;/a&gt;, or read the code on GitHub: &lt;a href="https://github.com/langgenius/mosoo" rel="noopener noreferrer"&gt;langgenius/mosoo&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;Originally published on &lt;a href="https://mosoo.ai/blog/why-we-need-a-headless-agent-api-in-the-cloud" rel="noopener noreferrer"&gt;Mosoo Blog&lt;/a&gt;. &lt;a href="https://mosoo.ai" rel="noopener noreferrer"&gt;Mosoo&lt;/a&gt; is an open-source managed agent runtime for deploying sandboxed agents behind an API.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>programming</category>
      <category>productivity</category>
    </item>
    <item>
      <title>The journey begins with an Imagine If.</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Sat, 01 Aug 2026 08:25:25 +0000</pubDate>
      <link>https://dev.to/yevanchen/the-journey-begins-with-an-imagine-if-ine</link>
      <guid>https://dev.to/yevanchen/the-journey-begins-with-an-imagine-if-ine</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fh0gr3is4utbdz928hguk.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fh0gr3is4utbdz928hguk.jpg" alt="A textured green spray-paint field with the mosoo asterisk emerging at the lower right, the bamboo shoot rising through paper." width="799" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Follow the notes upon the journey. At first sight marks one's destiny. Return lies within the hasty keys.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;A few months ago, I was moving between customer sites, talking through our New Agent Design in Workflow.&lt;/p&gt;

&lt;p&gt;The questions kept repeating: why not OpenClaw? How is this different from Hermes Agent?&lt;/p&gt;

&lt;p&gt;It was not the first time I felt a little lost.&lt;/p&gt;

&lt;p&gt;Eventually I realized the confusion was not about one tool. It was about a boundary we had not named clearly enough: when is Agent Work just a delivery, and when should it become part of a production system?&lt;/p&gt;

&lt;p&gt;For many consumer scenarios, building a component library ahead of time is too expensive.&lt;/p&gt;

&lt;p&gt;If the need is one-off, and you are not sure the same problem will appear again in three months, Claude Code or Codex is often enough. You do not need to abstract first. You do not need to build an app before delivering the result.&lt;/p&gt;

&lt;p&gt;Sometimes I tell customers to make the problem smaller.&lt;/p&gt;

&lt;p&gt;"This does not need to be so complicated. Claude Code can solve it. If the problem comes back, write a skill. That may be the smallest useful investment."&lt;/p&gt;

&lt;p&gt;I still believe that.&lt;/p&gt;

&lt;p&gt;But another thing slowly became visible: countless personal PCs started growing fragmented Agent solutions.&lt;/p&gt;

&lt;p&gt;They were experiments, but also artifacts. They depended on local environments, Session History, context, file copies, MCP tools, and skills.&lt;/p&gt;

&lt;p&gt;I can finish the task on my computer. If your environment matches mine, you can replay my experiment.&lt;/p&gt;

&lt;p&gt;But if this is how Agent artifacts move, what are they? Fast-moving goods? A local performance that only works on one stage?&lt;/p&gt;

&lt;p&gt;That was the real turn in our journey.&lt;/p&gt;

&lt;p&gt;We are not trying to platform every piece of Agent Work. Quite the opposite: we want to respect the threshold.&lt;/p&gt;

&lt;p&gt;In an image, grayscale describes how bright or dark a pixel is. Usually 0 is pure black, and 255 is pure white.&lt;/p&gt;

&lt;p&gt;Agent Apps have a similar threshold.&lt;/p&gt;

&lt;p&gt;Below it, the right answer is a one-off app, a skill, a local delivery, a place where you should avoid unnecessary complexity.&lt;/p&gt;

&lt;p&gt;Above it, the work becomes building, evaluation, deployment, A/B testing, and production feedback. It needs a lifecycle.&lt;/p&gt;

&lt;p&gt;Once you cross that line, the tools become scattered.&lt;/p&gt;

&lt;p&gt;Developers have to stitch together point solutions: sandboxes, Eval Harnesses, deploy scripts, logs, permissions, context, UI, and functions where most of the real behavior still lives inside Prompt strings.&lt;/p&gt;

&lt;p&gt;At that point, you are no longer using Codex or Claude Code to solve your own problem.&lt;/p&gt;

&lt;p&gt;You are using them to build a production solution for your customer.&lt;/p&gt;

&lt;p&gt;You live inside harnesses and dependencies. You open terminals, worktrees, or a new ADE, trying to keep the work moving.&lt;/p&gt;

&lt;p&gt;That is when I kept asking myself: why is there no framework-agnostic "Supabase" for this?&lt;/p&gt;

&lt;p&gt;Not to replace builders, but to remove repeated Agent Runtime hosting, deployment, isolation, and evaluation from every app.&lt;/p&gt;

&lt;p&gt;Before cloud computing, building software felt like buying land, building a house, and running the property yourself.&lt;/p&gt;

&lt;p&gt;You bought servers, switches, and storage. You put them into a machine room or IDC before you could talk about the application.&lt;/p&gt;

&lt;p&gt;Agent App development is beginning the same journey.&lt;/p&gt;

&lt;p&gt;We used to wrap tokens into LLM API Calls and treat them as the smallest compute unit.&lt;/p&gt;

&lt;p&gt;Now we are wrapping tokens into requests against a Cloud Agent.&lt;/p&gt;

&lt;p&gt;Local consumer demand represented by tools like Hermes or OpenClaw will continue. But more complex production demand will move toward Cloud Agents in Sandboxes.&lt;/p&gt;

&lt;p&gt;It needs higher concurrency, longer-running jobs, stronger isolation, and background tasks that can be created, paused, resumed, evaluated, and deployed.&lt;/p&gt;

&lt;p&gt;We are re-abstracting cloud machine resources into a Cloud Agent Session Lifecycle API that developers can call directly.&lt;/p&gt;

&lt;p&gt;That is what we are building.&lt;/p&gt;

&lt;p&gt;Not another Agent Demo.&lt;/p&gt;

&lt;p&gt;Not another Prompt Wrapper.&lt;/p&gt;

&lt;p&gt;It is a value judgment: once Agent Work crosses the threshold, it should be hosted, isolated, observed, and reused like a cloud resource.&lt;/p&gt;

&lt;p&gt;We call it &lt;strong&gt;mosoo&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The first piece of that work is now open source: mosoo Agent Driver.&lt;/p&gt;

&lt;p&gt;It is the driver layer we use to make OpenClaw, Hermes Agent, Claude Code, and Codex speak a compatible Agent Session API.&lt;/p&gt;




&lt;p&gt;Originally published on &lt;a href="https://mosoo.ai/blog/the-journey-begins-with-an-imagine-if" rel="noopener noreferrer"&gt;Mosoo Blog&lt;/a&gt;. &lt;a href="https://mosoo.ai" rel="noopener noreferrer"&gt;Mosoo&lt;/a&gt; is an open-source managed agent runtime for deploying sandboxed agents behind an API.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>opensource</category>
      <category>cloud</category>
      <category>startup</category>
    </item>
    <item>
      <title>From responses to agents: the API becomes a runtime</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Sat, 01 Aug 2026 08:24:45 +0000</pubDate>
      <link>https://dev.to/yevanchen/from-responses-to-agents-the-api-becomes-a-runtime-263k</link>
      <guid>https://dev.to/yevanchen/from-responses-to-agents-the-api-becomes-a-runtime-263k</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7y3i6bcb2blags6jl6ao.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7y3i6bcb2blags6jl6ao.webp" alt="Abstract green scan-line blocks assembling across a landscape with the words From responses to agents." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;By the GPT-5.6 era, the direction of OpenAI's API platform is difficult to miss. The model endpoint is no longer shaped only around generating the next piece of text. It can keep state, operate tools, compact a growing context, and coordinate parallel work.&lt;/p&gt;

&lt;p&gt;One correction matters at the start: &lt;strong&gt;Chat Completions is not deprecated&lt;/strong&gt;. OpenAI says it remains supported, while recommending the &lt;a href="https://developers.openai.com/api/docs/guides/migrate-to-responses" rel="noopener noreferrer"&gt;Responses API for new projects&lt;/a&gt;. The dividing line is architectural, not a shutdown date.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The important change is not a new endpoint. It is how much of the agent loop can now live inside the model runtime.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  One flow instead of a text-shaped exchange
&lt;/h2&gt;

&lt;p&gt;The &lt;a href="https://developers.openai.com/api/reference/responses/overview" rel="noopener noreferrer"&gt;Responses API&lt;/a&gt; works with typed items rather than treating every turn as another chat message. Messages, reasoning items, function calls, function outputs, and hosted-tool activity can participate in the same response flow.&lt;/p&gt;

&lt;p&gt;That changes the integration model. A response can include an agentic loop in which the model uses multiple tools before returning its answer. The application still defines permissions and handles client-owned functions, but it no longer has to flatten every intermediate step into a transcript-shaped protocol.&lt;/p&gt;

&lt;h2&gt;
  
  
  State becomes a platform primitive
&lt;/h2&gt;

&lt;p&gt;There are two server-side state patterns, and they solve different problems.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;previous_response_id&lt;/code&gt; chains a new response to the previous one. It is the lightweight option for nearby turns: the client sends the new input instead of reconstructing and resending the complete history.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://developers.openai.com/api/docs/guides/conversation-state#using-the-conversations-api" rel="noopener noreferrer"&gt;Conversations API&lt;/a&gt; creates a durable object with its own ID. The same conversation can continue across sessions, devices, or background jobs. Its items can include messages, tool calls, tool outputs, and other structured conversation data.&lt;/p&gt;

&lt;p&gt;The retention distinction is useful. Ordinary Response objects are stored for 30 days by default. Conversation objects and their items are not subject to that 30-day TTL. This is durable conversation state, not merely a connection-local cache.&lt;/p&gt;

&lt;p&gt;It is also not an exposed log of private chain-of-thought. Applications should reason about the structured items the API returns, including supported reasoning summaries or encrypted items, rather than promise a replay of hidden internal reasoning.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fhogrtiifvan9w4pvxil7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fhogrtiifvan9w4pvxil7.png" alt="A three-turn context window showing inputs and outputs accumulating until the final output is truncated" width="800" height="849"&gt;&lt;/a&gt;&lt;br&gt;
  &lt;em&gt;As turns accumulate, useful context competes for a finite window. Source: &lt;a href="https://developers.openai.com/api/docs/guides/conversation-state" rel="noopener noreferrer"&gt;OpenAI's conversation state guide&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  WebSocket mode removes continuation overhead
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://developers.openai.com/api/docs/guides/websocket-mode" rel="noopener noreferrer"&gt;Responses WebSocket mode&lt;/a&gt; keeps a persistent connection to &lt;code&gt;wss://api.openai.com/v1/responses&lt;/code&gt;. Each continuation can send only new input items plus &lt;code&gt;previous_response_id&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;This is designed for long-running, tool-heavy loops such as coding or orchestration. OpenAI reports that rollouts with more than 20 tool calls have seen &lt;strong&gt;up to roughly 40% faster&lt;/strong&gt; end-to-end execution. That is an observed upper bound, not a latency guarantee.&lt;/p&gt;

&lt;p&gt;The connection can also be warmed with &lt;code&gt;response.create&lt;/code&gt; and &lt;code&gt;generate: false&lt;/code&gt;. A warmup prepares known tools, instructions, or custom messages without generating model output, then returns a response ID for the next turn to continue from.&lt;/p&gt;

&lt;p&gt;WebSocket mode does not turn the API into an unlimited process. Connections have documented limits, and an application still needs reconnection, error recovery, and durable job ownership.&lt;/p&gt;

&lt;h2&gt;
  
  
  Compaction carries the useful state forward
&lt;/h2&gt;

&lt;p&gt;Long conversations create a simple systems problem: more history means more tokens, more latency, and more competition inside the context window.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://developers.openai.com/api/docs/guides/compaction" rel="noopener noreferrer"&gt;Server-side compaction&lt;/a&gt; can be enabled with &lt;code&gt;context_management&lt;/code&gt; and &lt;code&gt;compact_threshold&lt;/code&gt;. When the rendered token count crosses the threshold, the server emits an encrypted compaction item. That item carries key prior state and reasoning into the next window using fewer tokens.&lt;/p&gt;

&lt;p&gt;The compaction item is opaque and not intended to be human-readable. It should not be described as a conventional summary or as a literal dump of a model's “latent understanding.” Its contract is narrower and more useful: preserve the state needed to continue while reducing context pressure.&lt;/p&gt;

&lt;p&gt;For stateless input-array chaining, items before the latest compaction item can be dropped after the new window is assembled. When using &lt;code&gt;previous_response_id&lt;/code&gt;, the service manages the chain and the client should not manually prune it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Tools can be coordinated as a program
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://developers.openai.com/api/docs/guides/tools-programmatic-tool-calling" rel="noopener noreferrer"&gt;Programmatic Tool Calling&lt;/a&gt; lets the model write JavaScript that coordinates eligible tools. The program can use loops, conditions, parallel calls, and local transformations while keeping intermediate results inside the hosted execution step.&lt;/p&gt;

&lt;p&gt;This is useful when control flow is predictable: query several sources, filter and rank the results, then return a smaller structure to the model. It can reduce unnecessary model decisions, repeated API continuations, and the movement of large intermediate payloads.&lt;/p&gt;

&lt;p&gt;The runtime boundary is intentionally strict. Each program runs in a fresh isolated V8 environment with top-level &lt;code&gt;await&lt;/code&gt;, but without Node.js, package installation, direct network access, a general-purpose filesystem, subprocesses, a console, or persistent JavaScript state. External effects are possible only through the tools enabled for that request.&lt;/p&gt;

&lt;p&gt;Client-owned function calls still return to the application for execution. Programmatic Tool Calling compresses a class of orchestration; it does not move every integration into OpenAI's sandbox.&lt;/p&gt;

&lt;h2&gt;
  
  
  Multi-agent coordination reaches the API layer
&lt;/h2&gt;

&lt;p&gt;The &lt;a href="https://developers.openai.com/api/docs/guides/responses-multi-agent" rel="noopener noreferrer"&gt;Responses Multi-agent feature&lt;/a&gt; is available in beta across GPT-5.6 models. A root agent can create subagents, give them bounded work, communicate with them, wait for results, and synthesize the final response.&lt;/p&gt;

&lt;p&gt;HTTP and WebSocket expose the same capability, but their coordination behavior differs when client functions are involved.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fo8h2sqnyblwfnszw9tfi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fo8h2sqnyblwfnszw9tfi.png" alt="HTTP function call execution across an application, a Responses API root agent, and three subagents" width="800" height="593"&gt;&lt;/a&gt;&lt;br&gt;
  &lt;em&gt;With HTTP, blocked subagents resume after the active response completes and the application submits outstanding function outputs in a new request. Source: &lt;a href="https://developers.openai.com/api/docs/guides/responses-multi-agent#http-vs-websocket-performance" rel="noopener noreferrer"&gt;OpenAI's Multi-agent guide&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F610175q8z0t35569u29r.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F610175q8z0t35569u29r.png" alt="WebSocket function call execution across an application, a Responses API root agent, and three subagents" width="800" height="454"&gt;&lt;/a&gt;&lt;br&gt;
  &lt;em&gt;With WebSocket, each function output can be injected as soon as it is ready, so one subagent can resume while others continue. Source: &lt;a href="https://developers.openai.com/api/docs/guides/responses-multi-agent#http-vs-websocket-performance" rel="noopener noreferrer"&gt;OpenAI's Multi-agent guide&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://developers.openai.com/api/docs/guides/agents#compare-the-responses-api-and-agents-sdk" rel="noopener noreferrer"&gt;Agents SDK&lt;/a&gt; sits at a different level. It adds a reusable agent loop, sessions, guardrails, tracing, and two common ownership patterns: handoffs, where a specialist takes over the conversation, and agents-as-tools, where a manager retains control of the final answer.&lt;/p&gt;

&lt;h2&gt;
  
  
  The model runtime is not the whole product runtime
&lt;/h2&gt;

&lt;p&gt;Together, these features move the API from a text-generation primitive toward an &lt;strong&gt;agent runtime substrate&lt;/strong&gt;. State, context maintenance, tool execution, continuation, and delegation are becoming native platform concepts.&lt;/p&gt;

&lt;p&gt;But the boundary still matters. The Responses API runs model-centric work. A production product may still need its own sandbox, files, credentials, authorization, durable job lifecycle, approvals, retries, observability, and customer-facing state.&lt;/p&gt;

&lt;p&gt;That distinction is central to mosoo's view of the stack. Better model runtimes reduce the amount every team has to rebuild inside the inference loop. A managed agent runtime turns the remaining product-specific work into a deployable Agent with an environment, lifecycle, and API.&lt;/p&gt;

&lt;p&gt;The paradigm shift is real, but it is not “one endpoint replaces the application.” It is a cleaner division of labor: the model platform owns more of the agent loop, while the product runtime owns the durable system around it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Developer resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/reference/responses/overview" rel="noopener noreferrer"&gt;Responses API overview&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/docs/guides/migrate-to-responses" rel="noopener noreferrer"&gt;Migrate to the Responses API&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/docs/guides/conversation-state" rel="noopener noreferrer"&gt;Conversation state&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/reference/resources/conversations/methods/create" rel="noopener noreferrer"&gt;Create a conversation&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/reference/resources/conversations/subresources/items/methods/list" rel="noopener noreferrer"&gt;List conversation items&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/docs/guides/websocket-mode" rel="noopener noreferrer"&gt;Responses WebSocket mode&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/docs/guides/compaction" rel="noopener noreferrer"&gt;Compaction&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/docs/guides/tools-programmatic-tool-calling" rel="noopener noreferrer"&gt;Programmatic Tool Calling&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/docs/guides/responses-multi-agent" rel="noopener noreferrer"&gt;Responses Multi-agent&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.openai.com/api/docs/guides/agents#compare-the-responses-api-and-agents-sdk" rel="noopener noreferrer"&gt;Agents SDK and Responses API&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;Originally published on &lt;a href="https://mosoo.ai/blog/from-responses-to-agents" rel="noopener noreferrer"&gt;Mosoo Blog&lt;/a&gt;. &lt;a href="https://mosoo.ai" rel="noopener noreferrer"&gt;Mosoo&lt;/a&gt; is an open-source managed agent runtime for deploying sandboxed agents behind an API.&lt;/p&gt;

</description>
      <category>openai</category>
      <category>ai</category>
      <category>api</category>
      <category>webdev</category>
    </item>
    <item>
      <title>From API to CLI + Skill: a new software development paradigm</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Sat, 01 Aug 2026 08:10:09 +0000</pubDate>
      <link>https://dev.to/yevanchen/from-api-to-cli-skill-a-new-software-development-paradigm-1o84</link>
      <guid>https://dev.to/yevanchen/from-api-to-cli-skill-a-new-software-development-paradigm-1o84</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fyna9esxct7v2y5303ged.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fyna9esxct7v2y5303ged.webp" alt="A CLI-first development loop flows from API to specification, through a central CLI with Catalog and Skill modules, into Workflow and E2E testing, then back to the API." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;While building mosoo, we originally followed a familiar sequence: build the API first, close the loop on the product's core capabilities, and only then create a CLI to make those capabilities easier for coding agents to use.&lt;/p&gt;

&lt;p&gt;That sequence turned out to be backwards—or, at least, incomplete.&lt;/p&gt;

&lt;h2&gt;
  
  
  What we observed
&lt;/h2&gt;

&lt;p&gt;Without a first-class CLI, coding agents usually tested individual API endpoints with &lt;code&gt;curl&lt;/code&gt;, browser automation, or scripts written on the fly. Each approach created avoidable friction.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;A raw &lt;code&gt;curl&lt;/code&gt; response is often a large block of HTML or JSON containing fields that do not matter to the test at hand. The response itself does not explain field semantics, constraints, discovery, or the stable way to call the operation. Without sustained pressure from a CLI, SDK, or maintained tests, an API specification is also more likely to become incomplete, stale, or inconsistent with the implementation. The agent has to infer types, required fields, and constraints from source code, errors, and surrounding context. That consumes more tokens and more time.&lt;/li&gt;
&lt;li&gt;Browser automation is expensive in tokens, slow, prone to stalls, and awkward for the person waiting on it.&lt;/li&gt;
&lt;li&gt;Temporary test scripts multiply quickly. They become long, structurally inconsistent, and difficult to maintain. Reading them consumes yet more context.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;These methods are especially weak for orchestrating integration tests. The agent repeatedly produces piles of nearly unreadable scripts; once the test itself is unreadable, its result becomes difficult to explain or trust.&lt;/p&gt;

&lt;p&gt;After getting used to vibe coding, someone may still glance at the business logic. Test code often receives even less attention. &lt;strong&gt;Code nobody reads has almost no value.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This problem followed mosoo throughout development. The turning point came when we used &lt;a href="https://github.com/lathe-cli/lathe" rel="noopener noreferrer"&gt;Lathe&lt;/a&gt;, an open-source API-to-CLI generator, to generate a complete CLI for mosoo.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Lathe provides
&lt;/h2&gt;

&lt;p&gt;Lathe is designed for teams whose APIs must serve both people and AI agents. It turns Swagger 2.0, OpenAPI 3, or Protobuf APIs with &lt;code&gt;google.api.http&lt;/code&gt; annotations into a production-grade Cobra CLI.&lt;/p&gt;

&lt;p&gt;The generated CLI includes a machine-readable command catalog, intent search, per-command detail JSON, authentication metadata, request-body builders, structured output, and a repository-local &lt;code&gt;skills/&amp;lt;cli-name&amp;gt;/&lt;/code&gt; directory.&lt;/p&gt;

&lt;p&gt;That combination matters. The result is not merely a set of shell commands. It is a discoverable interface an agent can inspect before deciding what to run.&lt;/p&gt;

&lt;h2&gt;
  
  
  A new discovery—and a new problem
&lt;/h2&gt;

&lt;p&gt;After generating the CLI, I built skills, workflows, and instructions around it. End-to-end testing and load testing in mosoo became dramatically simpler and faster.&lt;/p&gt;

&lt;p&gt;I could sketch a batch of cases and hand them to a coding agent. The agent could implement the cases, run them, and collect the results. Skills, the CLI, and prompt-based workflows supported the entire path.&lt;/p&gt;

&lt;p&gt;More importantly, I could readily believe—or challenge—the agent's conclusion because the testing process was readable and explainable. It also felt far less token-intensive than the previous approach, although we did not run a controlled benchmark.&lt;/p&gt;

&lt;p&gt;But generation alone did not solve everything.&lt;/p&gt;

&lt;p&gt;Lathe converts every API in a project into CLI commands and generates a skill around that surface. It does not know which APIs are central to the product, which should remain internal, which operations form a complete business workflow, or when a particular command should be used.&lt;/p&gt;

&lt;p&gt;The first generated CLI was therefore difficult for an agent to use. It did not know which command to choose or when not to use one. At the time, the generated catalog exposed 127 commands, including hidden commands. The volume of operations also created naming and governance problems.&lt;/p&gt;

&lt;p&gt;We had to apply our understanding of mosoo's business domain. We reorganized the skill, exercised a large set of CLI-driven cases, and incorporated agent feedback. From generating the first mosoo CLI to making it genuinely usable by coding agents took about a month of intermittent work.&lt;/p&gt;

&lt;h2&gt;
  
  
  What if the CLI started on day one?
&lt;/h2&gt;

&lt;p&gt;What would happen if, from the first API on day one, we:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;generated its CLI surface;&lt;/li&gt;
&lt;li&gt;deliberately selected which APIs should and should not become commands;&lt;/li&gt;
&lt;li&gt;identified which commands compose into workflows;&lt;/li&gt;
&lt;li&gt;documented the business situations in which each command applies; and&lt;/li&gt;
&lt;li&gt;wrote the corresponding &lt;code&gt;SKILL.md&lt;/code&gt; by hand?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The mosoo CLI would likely have been smaller and more agent-friendly. Command names could have been shorter and easier for people to read. The overall development loop might have moved faster and consumed less context.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why did we not build the CLI first?
&lt;/h2&gt;

&lt;p&gt;By June, I was already advocating for a CLI even before the API was complete. Dogfooding cases without one had become painful. The first mosoo CLI did not ship until July, two weeks after Lathe was introduced to the team.&lt;/p&gt;

&lt;p&gt;Two assumptions held us back.&lt;/p&gt;

&lt;p&gt;First, we had not adapted to how software is consumed in the coding-agent era: less dependence on UI, and a CLI-first operational surface. During the first two months, API development was driven largely through mosoo's frontend. We judged the system with our eyes instead of its inputs and outputs. That made it easy to spend too much attention on naming debates and visual polish while leaving less attention for the product's underlying behavior.&lt;/p&gt;

&lt;p&gt;Second, we assumed introducing a CLI early would add complexity. We imagined that every API change would require manual regeneration and distribution. With a generator and a stable workflow, however, that maintenance cost approaches zero. The CLI instead creates healthy pressure to keep the API specification accurate, which also improves the API documentation.&lt;/p&gt;

&lt;h2&gt;
  
  
  The development loop
&lt;/h2&gt;

&lt;p&gt;My current view is that software development in the coding-agent era should follow this loop:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Develop or modify an API.&lt;/li&gt;
&lt;li&gt;Update or export its API specification, such as OpenAPI or Swagger.&lt;/li&gt;
&lt;li&gt;Generate or refresh the CLI, command catalog, and skill.&lt;/li&gt;
&lt;li&gt;Validate every API operation through the CLI.&lt;/li&gt;
&lt;li&gt;Compose CLI commands into workflows.&lt;/li&gt;
&lt;li&gt;Run integration and end-to-end tests.&lt;/li&gt;
&lt;li&gt;When a problem appears, return to the API, generated interface, or workflow layer that owns it.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Then repeat.&lt;/p&gt;

&lt;p&gt;The important part is for this loop to become an &lt;strong&gt;invisible project contract&lt;/strong&gt;. A user should not have to remind a coding agent to generate the CLI or test through it.&lt;/p&gt;

&lt;p&gt;That suggests a project template similar to what an IDE offers when creating a new project—but designed for coding agents. It would include CLI and skill generation from the beginning, along with an &lt;code&gt;AGENTS.md&lt;/code&gt; that makes the workflow explicit.&lt;/p&gt;

&lt;p&gt;I have not yet surveyed whether a complete template like this already exists. Lathe may be close to providing one.&lt;/p&gt;




&lt;p&gt;Originally published on &lt;a href="https://mosoo.ai/blog/api-cli-skill-development-paradigm" rel="noopener noreferrer"&gt;Mosoo Blog&lt;/a&gt;. &lt;a href="https://mosoo.ai" rel="noopener noreferrer"&gt;Mosoo&lt;/a&gt; is an open-source managed agent runtime for deploying sandboxed agents behind an API.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>cli</category>
      <category>programming</category>
    </item>
    <item>
      <title>An agent's state is not its process</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Sat, 01 Aug 2026 08:08:22 +0000</pubDate>
      <link>https://dev.to/yevanchen/an-agents-state-is-not-its-process-43cg</link>
      <guid>https://dev.to/yevanchen/an-agents-state-is-not-its-process-43cg</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fvu79li2q6s23pfpy2g3p.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fvu79li2q6s23pfpy2g3p.webp" alt="A hand-drawn three-part agent architecture connecting durable facts, a control plane, and replaceable execution environments across a cut line." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Two recent discussions about cloud agents exposed a real architectural disagreement.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://x.com/arkuy99/status/2077676218321956925" rel="noopener noreferrer"&gt;The first discussion&lt;/a&gt; offered two choices: run agent loops centrally and send only tool calls to sandboxes, or give every user a complete isolated agent runtime. Its replies did not converge. Some favored centralized control; others argued that coding harnesses such as Codex and Claude Code already bind the loop, tools, and workspace tightly enough that a complete runtime is the more natural boundary.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://x.com/QuantumTransf/status/2078586634183065867" rel="noopener noreferrer"&gt;The second discussion&lt;/a&gt; moved the question forward: perhaps a system should persist the data model needed for interaction, not the agent process itself. Its author later acknowledged that existing coding harnesses are difficult to split cleanly into a central loop and sandboxed tools. The post's “30-second cold start” claim has no public reproducible measurement conditions, so we do not treat it as evidence here.&lt;/p&gt;

&lt;p&gt;These threads are more useful as a question set than as market consensus. Our answer is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Define user-visible continuity and acceptable loss first. Then decide where the loop and sandbox belong. The deployment unit should follow the durability contract, not define it.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  Draw the failure boundary before choosing a deployment unit
&lt;/h2&gt;

&lt;p&gt;“Agent state” contains at least three things with very different lifetimes:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Product facts&lt;/strong&gt;: the agent configuration version, Session and Run state, accepted events, explicit uploads, and produced artifacts.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Control state&lt;/strong&gt;: authorization, scheduling, command delivery, event acknowledgement, and the runtime currently serving a subject.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Execution state&lt;/strong&gt;: the provider-native session, working directory, caches, login state, temporary files, and live processes.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmosoo.ai%2Fblog%2Fblog%2Fagent-state-is-not-process-state%2Farchitecture.svg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmosoo.ai%2Fblog%2Fblog%2Fagent-state-is-not-process-state%2Farchitecture.svg" alt="Agent state separated into durable product facts, a control plane, and sandbox execution state" width="1672" height="941"&gt;&lt;/a&gt;&lt;br&gt;
  &lt;em&gt;A useful boundary is not “cloud versus local.” It is “what remains part of the product promise after a process disappears.” The diagram describes mosoo's current responsibility split; it is not a multi-cloud or zero-loss claim.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;If the execution environment on the right disappears, can the durable side still explain what the user saw, what work completed, and which files should exist? If not, “recoverable” only means that a process has not died yet. The system does not have recovery semantics.&lt;/p&gt;

&lt;h2&gt;
  
  
  How mosoo draws the boundary
&lt;/h2&gt;

&lt;p&gt;mosoo does not implement another universal model planner. When it creates a Session, it freezes an execution snapshot: the Agent's prompt, model, runtime, tools, Skills, MCP bindings, and Environment revision are bound to that Session. This is a traceable behavior configuration, &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/apps/api/src/modules/runtime/application/session-runs/create-agent-session.service.ts#L149-L251" rel="noopener noreferrer"&gt;not a full machine image&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The control plane manages execution through a narrow set of operations such as prepare, dispatch, terminal, reset, recreate, and stop. The current code has &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/apps/api/src/modules/runtime/infrastructure/execution-plane/sandbox-execution-plane-adapter.ts#L96-L245" rel="noopener noreferrer"&gt;one execution adapter, Cloudflare Sandbox&lt;/a&gt;, so we do not describe this as a completed multi-cloud abstraction.&lt;/p&gt;

&lt;p&gt;At boot, the runtime writes a private payload to a one-time file. The Driver reads and removes it, then actively dials an authenticated WebSocket to the control plane. The implication is simple: a sandbox may execute work without becoming the sole source of truth for credentials, Session ownership, or durable facts. &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/docs/architecture.md#L145-L153" rel="noopener noreferrer"&gt;The architecture document makes this chain explicit&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Inside the sandbox, Agent Driver keeps each provider's native loop. Its current registry integrates OpenAI app-server, Claude Agent SDK, and ACP. It normalizes start, input, cancel, and stop, plus host ports for events, permissions, MCP, Skills, and files; it &lt;a href="https://github.com/langgenius/mosoo-agent-driver/blob/0db020ac5c6c40cc2231dfb650cabff38467956c/src/runtimes/provider-registry.ts#L24-L79" rel="noopener noreferrer"&gt;does not pretend the provider runtimes are one internal implementation&lt;/a&gt;. Capability differences remain explicit.&lt;/p&gt;

&lt;p&gt;That boundary accommodates both sides of the original debate. A coding harness can remain whole inside the sandbox, while product control, identity, and durable facts do not have to be trapped in the same process.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pet and Cattle are continuity contracts
&lt;/h2&gt;

&lt;p&gt;mosoo does not assume that every Agent needs the same runtime lifetime. &lt;code&gt;kind&lt;/code&gt; becomes two observable policies:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;Pet&lt;/th&gt;
&lt;th&gt;Cattle&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Runtime subject&lt;/td&gt;
&lt;td&gt;Stable &lt;code&gt;agent:{agentId}&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Session-scoped &lt;code&gt;session:{sessionId}&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;After a Run becomes terminal&lt;/td&gt;
&lt;td&gt;Not closed only because the Run ended&lt;/td&gt;
&lt;td&gt;Sandbox is closed and recycled immediately&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Preserved across rebuild&lt;/td&gt;
&lt;td&gt;Only &lt;code&gt;/workspace/memory&lt;/code&gt; and eligible Session workspaces&lt;/td&gt;
&lt;td&gt;No checkpoint&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Not promised&lt;/td&gt;
&lt;td&gt;Login state, caches, provider-native state, and other container files after rebuild&lt;/td&gt;
&lt;td&gt;Temporary files, caches, login state, and native runtime state&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;These are not naming preferences. They are &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/apps/api/src/modules/runtime/domain/runtime-kind-policy.ts#L84-L139" rel="noopener noreferrer"&gt;runtime policies in code&lt;/a&gt;. The complete persistence matrix is also published in the &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/docs/architecture.md#L236-L261" rel="noopener noreferrer"&gt;architecture document&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;“Continue the same Session” therefore does not have to mean “revive the same process.” A later Cattle Run gets a fresh sandbox; product history remains readable, but the old workspace and provider-native state are not presented as if they still existed. Pet offers stronger continuity, but it is still a bounded checkpoint policy rather than an immortal container.&lt;/p&gt;

&lt;h2&gt;
  
  
  Reaching a WebSocket is not becoming a fact
&lt;/h2&gt;

&lt;p&gt;Streaming and durability are another pair of concepts that are often collapsed.&lt;/p&gt;

&lt;p&gt;mosoo's event ingress filters replays, projects and persists canonical events, delivers committed events to viewers, and only then returns an accepted receipt. &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/apps/api/src/modules/runtime/infrastructure/driver-instance/rpc-event-ingestion-controller.ts#L118-L201" rel="noopener noreferrer"&gt;The source explains why&lt;/a&gt;: acknowledging fragments buffered only inside a hibernatable process could confirm text that a fresh instance cannot reconstruct.&lt;/p&gt;

&lt;p&gt;The current Agent Driver &lt;code&gt;main&lt;/code&gt; goes further by separating lossless and best-effort events. Lossless events retain source IDs, drain partial receipts, and retry unconfirmed work; best-effort events may be dropped on transport or receipt failure. &lt;a href="https://github.com/langgenius/mosoo-agent-driver/blob/0db020ac5c6c40cc2231dfb650cabff38467956c/src/runtimes/driver-event-publisher.ts#L440-L520" rel="noopener noreferrer"&gt;The queue implements the distinction explicitly&lt;/a&gt;. OpenAI text deltas are marked &lt;a href="https://github.com/langgenius/mosoo-agent-driver/blob/0db020ac5c6c40cc2231dfb650cabff38467956c/src/runtimes/openai/app-server-item-events.ts#L84-L95" rel="noopener noreferrer"&gt;best-effort&lt;/a&gt;; a final item snapshot arbitrates the complete message.&lt;/p&gt;

&lt;p&gt;One version boundary matters: the mosoo commit linked in this article still pins an earlier Driver revision. The new queue semantics are the current implementation direction on Agent Driver &lt;code&gt;main&lt;/code&gt;, not a blanket promise that every stream in an existing mosoo deployment is lossless. The more accurate principle is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Incremental streams serve the experience. Persisted events and terminal snapshots serve the facts.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  The market needs falsifiable evidence
&lt;/h2&gt;

&lt;p&gt;“Central loop,” “complete runtime,” and “durable agent” can all become labels. Publishing evidence that others can reproduce—and disprove when it fails—contributes more than choosing a camp.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Capability being claimed&lt;/th&gt;
&lt;th&gt;Minimum evidence&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;The Agent can resume&lt;/td&gt;
&lt;td&gt;Kill the connection, Driver, and sandbox separately; record which messages, files, and native sessions return and which do not&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Startup is fast enough&lt;/td&gt;
&lt;td&gt;Publish the workload, image, region, warming and pooling conditions, and P50/P95/P99 cold and warm distributions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Events are not duplicated or lost&lt;/td&gt;
&lt;td&gt;Replay the same source ID after disconnect; verify deduplication, partial acknowledgement, and the persistence boundary&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Sandbox isolation is effective&lt;/td&gt;
&lt;td&gt;Name the identity, credential, network, file, and tenant boundaries, then publish failure tests instead of only a container-shaped API&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cancellation completed&lt;/td&gt;
&lt;td&gt;State which cooperation stopped and which tool side effects cannot be rolled back&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;mosoo also has gaps worth stating plainly: there is only one execution adapter; &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/apps/api/src/modules/runtime/infrastructure/driver-instance/terminal-run-release.ts#L123-L161" rel="noopener noreferrer"&gt;automatic crash requeue is unfinished&lt;/a&gt;; &lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/docs/architecture.md#L163-L169" rel="noopener noreferrer"&gt;some network policy is saved intent rather than enforced policy&lt;/a&gt;; Cattle does not persist native resume state. Publishing those non-goals next to implementation links helps other teams judge fit better than calling a direction “mainstream.”&lt;/p&gt;

&lt;h2&gt;
  
  
  A long-term judgment
&lt;/h2&gt;

&lt;p&gt;We treat runtime state as a cache until the product explicitly promises continuity. We separate semantic resume from process resume. And we see per-user runtimes and sandbox-as-tool as product modes, not mutually exclusive beliefs.&lt;/p&gt;

&lt;p&gt;A durable abstraction is not one that keeps a process alive for as long as possible. It is one that can still answer three questions after that process disappears: what happened, what the user still owns, and where the next execution begins.&lt;/p&gt;

&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://x.com/arkuy99/status/2077676218321956925" rel="noopener noreferrer"&gt;Original discussion about the loop and sandbox boundary&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://x.com/QuantumTransf/status/2078586634183065867" rel="noopener noreferrer"&gt;Original discussion about durable data and runtime state&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/docs/architecture.md#L236-L261" rel="noopener noreferrer"&gt;mosoo Agent sandbox and persistence layers&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/langgenius/mosoo/blob/169441995325f0b7c6846d9ac8969b12437343e9/apps/api/src/modules/runtime/domain/runtime-kind-policy.ts#L84-L139" rel="noopener noreferrer"&gt;mosoo runtime kind policy&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/langgenius/mosoo-agent-driver/blob/0db020ac5c6c40cc2231dfb650cabff38467956c/src/runtimes/provider-registry.ts#L24-L79" rel="noopener noreferrer"&gt;mosoo Agent Driver provider registry&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;Originally published on &lt;a href="https://mosoo.ai/blog/agent-state-is-not-process-state" rel="noopener noreferrer"&gt;Mosoo Blog&lt;/a&gt;. &lt;a href="https://mosoo.ai" rel="noopener noreferrer"&gt;Mosoo&lt;/a&gt; is an open-source managed agent runtime for deploying sandboxed agents behind an API.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>ai</category>
      <category>architecture</category>
      <category>cloud</category>
    </item>
    <item>
      <title>The Model Is Streaming. Why Is the Text Still Jumping?</title>
      <dc:creator>Evanchen</dc:creator>
      <pubDate>Fri, 31 Jul 2026 10:45:58 +0000</pubDate>
      <link>https://dev.to/yevanchen/the-model-is-streaming-why-is-the-text-still-jumping-280m</link>
      <guid>https://dev.to/yevanchen/the-model-is-streaming-why-is-the-text-still-jumping-280m</guid>
      <description>&lt;p&gt;This post shares what we learned while improving Mosoo's streaming output. The model already streams native deltas; the Web UI's job is to turn bursty delivery into perceptually continuous text without adding enough work to erase the benefit.&lt;/p&gt;

&lt;p&gt;The model may be streaming, but the text on screen does not necessarily look like it is.&lt;/p&gt;

&lt;p&gt;A model can keep returning native deltas, yet those deltas pass through a provider, an Agent Runtime, event buffering, and WebSocket delivery before they reach the browser. By then, the browser often receives them in batches. If the Web UI inserts each entire batch into React as soon as it arrives, users see a repeating pattern: nothing, then a jump of text, then nothing again.&lt;/p&gt;

&lt;p&gt;That does not mean the model stopped generating. It does not necessarily mean the network slowed down either. The problem is that we treated two different clocks as one.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Streaming output has two clocks: when events arrive, and when text enters the next screen paint.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  &lt;code&gt;requestAnimationFrame&lt;/code&gt; is not the same as smoothing
&lt;/h2&gt;

&lt;p&gt;mosoo's server does not send a separate WebSocket message for every tiny delta. Viewer events are compressed and merged for up to 150ms. The buffer flushes early when it reaches 4KB or 64 events, and also for the first delta or a terminal Run event. &lt;a href="https://github.com/langgenius/mosoo/blob/0fd94741bfea328cec194e99b1f4832412db7e15/apps/api/src/modules/runtime/infrastructure/driver-instance/session-viewer-event-delivery-buffer.ts#L16-L18" rel="noopener noreferrer"&gt;Those limits live directly in the delivery buffer&lt;/a&gt;, while the fast paths for the first delta and terminal events have &lt;a href="https://github.com/langgenius/mosoo/blob/0fd94741bfea328cec194e99b1f4832412db7e15/apps/api/src/modules/runtime/infrastructure/driver-instance/session-viewer-event-delivery-buffer.ts#L86-L108" rel="noopener noreferrer"&gt;their own explicit conditions&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;This is a necessary systems tradeoff. Batching reduces message count, serialization work, and downstream state updates. The cost is that the browser's input rhythm no longer matches the model's generation rhythm.&lt;/p&gt;

&lt;p&gt;The old implementation already used &lt;code&gt;requestAnimationFrame&lt;/code&gt; to combine rendering work, but it delivered the entire queued batch on the next frame. &lt;code&gt;rAF&lt;/code&gt; answers &lt;em&gt;when&lt;/em&gt; to commit. It does not answer &lt;em&gt;how much&lt;/em&gt; to commit in that frame. If one WebSocket message already contains roughly 150ms of output, delivering all of it on the next frame still produces a jump.&lt;/p&gt;

&lt;h2&gt;
  
  
  The control variable is pending backlog, not a fixed typing speed
&lt;/h2&gt;

&lt;p&gt;The obvious solution is a typewriter: reveal one character every few milliseconds. A fixed speed, however, cannot adapt to slow models, fast models, short tails, and sudden large batches at the same time.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Too slow, and the model finishes while the user is still watching text from seconds ago.&lt;/li&gt;
&lt;li&gt;Too fast, and transport batches remain visible as jumps.&lt;/li&gt;
&lt;li&gt;One timer per character also creates a large number of callbacks and state updates.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;mosoo uses a different control variable: &lt;strong&gt;the number of graphemes already received but not yet rendered&lt;/strong&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;pending = received - rendered
rate = clamp(pending / 0.25s, 20, 800)
budget += rate * elapsedSeconds
emit = floor(budget)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The larger the backlog, the faster the next frame catches up. The smaller the backlog, the gentler the pace. A time constant of &lt;code&gt;τ = 250ms&lt;/code&gt; keeps a transport batch of roughly 150ms in flight until the next batch is likely to arrive, turning adjacent steps into a continuous stream. The 20–800 graphemes-per-second bounds prevent a short tail from dragging on forever and prevent the animation from becoming too fast to read.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmosoo.ai%2Fblog%2Fblog%2Fsmoothing-native-model-output%2Fpacing-model.svg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fmosoo.ai%2Fblog%2Fblog%2Fsmoothing-native-model-output%2Fpacing-model.svg" alt="A blue staircase shows the cumulative text received by the browser, while a continuous green curve shows cumulative rendered text. The larger the gap, the faster the green curve catches up; the terminal event closes the gap immediately." width="1600" height="900"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;The browser does not replay every model token. It uses a second clock to follow the first. Each frame's budget is driven by backlog, not by a fixed typing speed.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;The budget uses the actual elapsed time &lt;code&gt;Δt&lt;/code&gt; instead of assuming that every frame lasts exactly 16ms. A 60Hz display, a 120Hz display, and a throttled page therefore produce similar visible progress over the same wall-clock interval. A budget smaller than one grapheme is not discarded; its fractional remainder carries into the next frame. &lt;a href="https://github.com/langgenius/mosoo/blob/0fd94741bfea328cec194e99b1f4832412db7e15/apps/web/src/domains/runtime/session-stream/session-stream-render-scheduler.ts#L293-L406" rel="noopener noreferrer"&gt;The complete budget calculation and queue slicing live in one Scheduler&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  The unit of slicing is a grapheme, not a UTF-16 index
&lt;/h2&gt;

&lt;p&gt;Slicing by JavaScript string index can split a surrogate pair, combining character, or ZWJ emoji. For a moment, the UI may render &lt;code&gt;�&lt;/code&gt; or half an emoji.&lt;/p&gt;

&lt;p&gt;When an event enters the queue, mosoo uses &lt;code&gt;Intl.Segmenter&lt;/code&gt; to split it into grapheme clusters in advance, with code-point iteration as the fallback. &lt;a href="https://github.com/langgenius/mosoo/blob/0fd94741bfea328cec194e99b1f4832412db7e15/apps/web/src/domains/runtime/session-stream/session-stream-render-scheduler.ts#L55-L82" rel="noopener noreferrer"&gt;That work happens once, and the per-frame budget reuses the result&lt;/a&gt;. This preserves text correctness without rescanning the same string on every frame.&lt;/p&gt;

&lt;h2&gt;
  
  
  Smoothing must know when to stop
&lt;/h2&gt;

&lt;p&gt;A Scheduler that only knows how to “show text slowly” is incomplete. Animation must yield to event semantics.&lt;/p&gt;

&lt;p&gt;When the queue contains Message End, Reasoning End, a terminal Run event, or a State / Messages Snapshot after reconnection, mosoo immediately delivers the preceding backlog. The server has already established that the segment is complete, so there is no reason to keep playing stale animation. &lt;a href="https://github.com/langgenius/mosoo/blob/0fd94741bfea328cec194e99b1f4832412db7e15/apps/web/src/domains/runtime/session-stream/session-stream-render-scheduler.ts#L85-L113" rel="noopener noreferrer"&gt;These events are explicit pacing barriers in the code&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Likewise, when the backlog exceeds 4,096 graphemes, the Scheduler delivers the whole batch immediately. Continuing at the maximum animation rate could still leave the screen seconds behind the real state. &lt;strong&gt;Stopping the polish under overload is part of the performance strategy.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fi4097qhlm2x5qpqvq23e.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fi4097qhlm2x5qpqvq23e.jpg" alt="Pending text enters a per-frame budgeter. An active stream stays smooth, an END event flushes immediately, backlog over 4,096 is delivered as a batch, and a 50ms timer takes over when requestAnimationFrame is paused." width="799" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Smoothing exists only while generation is active and backlog is under control. Correctness, terminal state, and freshness take priority.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Several other boundaries matter:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Every event stays in strict FIFO order. A later tool or state event cannot overtake text that is still being revealed.&lt;/li&gt;
&lt;li&gt;At most 512 events are delivered in one frame, preventing a pathological event storm from creating one enormous React commit.&lt;/li&gt;
&lt;li&gt;When a hidden page pauses &lt;code&gt;requestAnimationFrame&lt;/code&gt;, a 50ms timer continues draining the queue.&lt;/li&gt;
&lt;li&gt;When the socket closes, the active Session calls &lt;code&gt;flushNow&lt;/code&gt;. Queues for inactive Sessions are cleared so content cannot leak into another Session.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;After a WebSocket event arrives, the Scheduler submits at most one batch to Live State per frame. Closing the connection triggers an explicit flush. &lt;a href="https://github.com/langgenius/mosoo/blob/0fd94741bfea328cec194e99b1f4832412db7e15/apps/web/src/domains/runtime/session-stream/session-stream-socket.ts#L94-L145" rel="noopener noreferrer"&gt;That integration boundary stays inside the Session Stream Socket&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Low overhead is not a magic number
&lt;/h2&gt;

&lt;p&gt;This change adds no animation library and creates no timer per character. It reuses the browser's frame clock and handles budgeting, slicing, and batched state updates in one queue:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Graphemes are segmented once, when they enter the queue.&lt;/li&gt;
&lt;li&gt;Each frame computes an integer budget from actual elapsed time.&lt;/li&gt;
&lt;li&gt;A frame triggers at most one batched state update.&lt;/li&gt;
&lt;li&gt;Only user-visible text deltas are paced; structural events do not receive a character-by-character animation.&lt;/li&gt;
&lt;li&gt;Terminal state and excessive backlog both have direct exit paths.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;These are structural constraints for keeping overhead low, not an unmeasured performance promise. PR #450 focuses its verification on timing semantics: controlled clocks cover 60Hz / 120Hz consistency, emoji boundaries, terminal flushing, reconnection snapshots, strict ordering, hidden-page fallback, and excessive backlog. &lt;a href="https://github.com/langgenius/mosoo/blob/0fd94741bfea328cec194e99b1f4832412db7e15/apps/web/tests/session-stream-render-scheduler.test.ts#L117-L395" rel="noopener noreferrer"&gt;Each case is visible in the test file&lt;/a&gt;. We did not run production CPU or long-task benchmarks for this change, so we do not turn “smoother” into an unsupported claim that it is “measurably faster.”&lt;/p&gt;

&lt;h2&gt;
  
  
  A reusable principle
&lt;/h2&gt;

&lt;p&gt;If you are building a Web UI on top of native model output, start with four rules:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Let the first delta bypass transport buffering to protect time to first text.&lt;/li&gt;
&lt;li&gt;During generation, adjust the per-frame rate from backlog instead of using a fixed typing speed.&lt;/li&gt;
&lt;li&gt;Flush terminal events and snapshots immediately; explicitly flush or clear the queue when the connection closes or the active Session changes.&lt;/li&gt;
&lt;li&gt;Stop animating when backlog escapes control. Freshness matters more than smoothness.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The transport layer reduces system overhead. The rendering layer maintains perceptual continuity. Event semantics decide when both must yield.&lt;/p&gt;

&lt;p&gt;That is the core of &lt;a href="https://github.com/langgenius/mosoo/pull/450" rel="noopener noreferrer"&gt;mosoo PR #450&lt;/a&gt;: we did not change how the model produces output or fabricate more tokens. We gave the browser a bounded display clock, with explicit exit paths, that faithfully catches up with the model's native stream.&lt;/p&gt;

&lt;h2&gt;
  
  
  About Mosoo
&lt;/h2&gt;

&lt;p&gt;Mosoo is an open-source, Cloudflare-native agent runtime for Codex, Claude Agent SDK, and OpenCode—with API endpoints, isolated sandboxes, durable Threads, and inspectable Runs.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://mosoo.ai" rel="noopener noreferrer"&gt;Explore Mosoo&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://cloud.mosoo.ai" rel="noopener noreferrer"&gt;Try Mosoo&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/langgenius/mosoo" rel="noopener noreferrer"&gt;Star Mosoo on GitHub&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Originally published on the &lt;a href="https://mosoo.ai/blog/smoothing-native-model-output" rel="noopener noreferrer"&gt;Mosoo engineering blog&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>javascript</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
