<?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: Sushant Babbar</title>
    <description>The latest articles on DEV Community by Sushant Babbar (@sushant_babbar).</description>
    <link>https://dev.to/sushant_babbar</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%2F2858224%2F8c476ca2-a87f-4a3f-81a7-aea0ff6113b4.png</url>
      <title>DEV Community: Sushant Babbar</title>
      <link>https://dev.to/sushant_babbar</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/sushant_babbar"/>
    <language>en</language>
    <item>
      <title>Here are some load and cost reality checks for vibe-coded apps</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Mon, 09 Nov 2026 13:19:16 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/here-are-some-load-and-cost-reality-checks-for-vibe-coded-apps-20pj</link>
      <guid>https://dev.to/sushant_babbar/here-are-some-load-and-cost-reality-checks-for-vibe-coded-apps-20pj</guid>
      <description>&lt;p&gt;Vibe-coded apps look fine in a demo and then quietly become expensive or painfully slow once real data and schedules enter the picture. &lt;/p&gt;

&lt;p&gt;A retry loop on a tool error can burn more tokens than the rest of the day’s legitimate work. An N+1 query that was invisible with ten rows becomes a timeout with a thousand. The monthly invoice arrives after the damage is done...&lt;/p&gt;

&lt;p&gt;The checks below surface many of those problems while the feature is still under your control. They are small, mostly SQL and a few lines of instrumentation, and they fit the same constraint-first workflow used for the rest of the feature. They are not exhaustive; they are the measurements that are cheap to add early, and that catch the common failure modes before users or the bill notice.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Count queries per request as a heuristic
&lt;/h2&gt;

&lt;p&gt;AI agents readily generate the classic N+1 pattern: one query for a list, then one query per item inside a loop or &lt;code&gt;.map&lt;/code&gt;. With a handful of rows, the latency is fine. With real data, it is not.&lt;/p&gt;

&lt;p&gt;A lightweight client-side counter around &lt;code&gt;supabase.from()&lt;/code&gt; is a useful heuristic during development. It will not see every request. PostgREST may generate additional queries, RPCs take a different path, and auth or storage calls are invisible to a wrapper on &lt;code&gt;.from()&lt;/code&gt;. Treat a high count as a signal to investigate, not as complete coverage.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;queryCount&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;originalFrom&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;supabase&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;from&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;bind&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;supabase&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;supabase&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(...&lt;/span&gt;&lt;span class="nx"&gt;args&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;queryCount&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;originalFrom&lt;/span&gt;&lt;span class="p"&gt;(...&lt;/span&gt;&lt;span class="nx"&gt;args&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="c1"&gt;// after the request or agent turn&lt;/span&gt;
&lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;queryCount&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="mi"&gt;15&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;warn&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`High query count: &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;queryCount&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="c1"&gt;// or write to a log table&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A more durable version logs to a &lt;code&gt;request_metrics&lt;/code&gt; table (request_id, query_count, duration_ms, route). After a few real runs, sort by query_count. Anything that scales linearly with the number of rows is a candidate for an &lt;code&gt;IN&lt;/code&gt; clause, a join, or an RPC that returns the nested data in one round trip.&lt;/p&gt;

&lt;p&gt;Supabase projects already have &lt;code&gt;pg_stat_statements&lt;/code&gt; enabled. This query surfaces the same problem from the database side and catches paths the client wrapper misses:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sql"&gt;&lt;code&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;
  &lt;span class="n"&gt;calls&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;mean_exec_time&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;total_exec_time&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;query&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt; &lt;span class="n"&gt;pg_stat_statements&lt;/span&gt;
&lt;span class="k"&gt;WHERE&lt;/span&gt; &lt;span class="n"&gt;calls&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;
  &lt;span class="k"&gt;AND&lt;/span&gt; &lt;span class="n"&gt;mean_exec_time&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;
&lt;span class="k"&gt;ORDER&lt;/span&gt; &lt;span class="k"&gt;BY&lt;/span&gt; &lt;span class="n"&gt;total_exec_time&lt;/span&gt; &lt;span class="k"&gt;DESC&lt;/span&gt;
&lt;span class="k"&gt;LIMIT&lt;/span&gt; &lt;span class="mi"&gt;20&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Repeated near-identical statements with high call counts are the database’s view of an N+1. The Query Performance page in the Supabase dashboard ranks the same data and is usually the fastest place to look first.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Log slow statements and their plans (with care)
&lt;/h2&gt;

&lt;p&gt;A query that is acceptable at 50 rows is often unacceptable at 5 000. Slow-query logging is useful while investigating, but the settings need to be targeted.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sql"&gt;&lt;code&gt;&lt;span class="c1"&gt;-- Affects the postgres role for future connections only&lt;/span&gt;
&lt;span class="k"&gt;ALTER&lt;/span&gt; &lt;span class="k"&gt;ROLE&lt;/span&gt; &lt;span class="n"&gt;postgres&lt;/span&gt; &lt;span class="k"&gt;SET&lt;/span&gt; &lt;span class="n"&gt;log_min_duration_statement&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'500ms'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Supabase notes that Data API traffic (supabase-js, PostgREST) often uses other roles, so the change above can miss the queries you care about most. Prefer the Query Performance page and role-filtered views for app-generated traffic. For plans on Data API calls, the &lt;code&gt;.explain()&lt;/code&gt; modifier (once enabled with appropriate safeguards) is the supported path.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;auto_explain&lt;/code&gt; can log plans of slow statements, but it is not enabled with a simple &lt;code&gt;LOAD&lt;/code&gt; in a managed environment. Supabase documents role-level configuration. Broad, low-threshold plan logging adds overhead and log volume; raise the threshold or disable it again once the investigation is finished.&lt;/p&gt;

&lt;p&gt;Look for sequential scans on growing tables, missing indexes on foreign keys used in joins, and sorts that spill to disk. An index that the agent “forgot” is cheaper to add now than after a scheduled job starts timing out.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Put a tight budget on every agent run
&lt;/h2&gt;

&lt;p&gt;One of the more expensive failure modes is an agent that treats an error as “try again with more context.” Databricks documented tool-call bugs that silently cost hundreds of thousands of dollars a year because the agent retried instead of failing. Similar loops have produced five-figure bills in a single night. A runaway query or an external API outage can be equally costly; the common pattern is unbounded work that continues without a visible stop.&lt;/p&gt;

&lt;p&gt;Enforce the budget in ordinary code, not in the prompt. Before each model or tool call, check:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;token count (input + output) against a per-run ceiling&lt;/li&gt;
&lt;li&gt;tool-call count&lt;/li&gt;
&lt;li&gt;wall-clock time&lt;/li&gt;
&lt;li&gt;estimated dollar cost (see below)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Use inclusive checks so a run that hits the limit exactly still stops:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;BUDGET&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;maxTokens&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;30&lt;/span&gt;&lt;span class="nx"&gt;_000&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;maxToolCalls&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;12&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;maxMs&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;90&lt;/span&gt;&lt;span class="nx"&gt;_000&lt;/span&gt; &lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;checkBudget&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;tokens&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="nx"&gt;BUDGET&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;maxTokens&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt;
      &lt;span class="nx"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;toolCalls&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="nx"&gt;BUDGET&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;maxToolCalls&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt;
      &lt;span class="nx"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;elapsedMs&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="nx"&gt;BUDGET&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;maxMs&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;throw&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;BudgetExceededError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Catch the error, log it, and do not let the agent continue. Decide explicitly whether a failed run should be retried (and under what conditions), dead-lettered, or left for manual restart. Idempotency keys help when a partial run is resumed. Provider-side spend limits are a useful account-wide backstop, but they arrive too late to tell you which scheduled job went wrong. The per-run check tells you immediately.&lt;/p&gt;

&lt;p&gt;Token counts returned by the model API are reliable for accounting. Converting them to dollars is not. Prices differ by model, cached input tokens are cheaper than fresh ones, output tokens are priced separately, tool-use overhead varies, and rates change. Store the raw token counts and model name; calculate estimated cost only for alerting or dashboards, and treat the number as approximate.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Record metrics on every scheduled execution
&lt;/h2&gt;

&lt;p&gt;Once a job is scheduled, you no longer watch it. One practical way to notice drift is to write a metrics row on every run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sql"&gt;&lt;code&gt;&lt;span class="k"&gt;CREATE&lt;/span&gt; &lt;span class="k"&gt;TABLE&lt;/span&gt; &lt;span class="n"&gt;agent_runs&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="n"&gt;id&lt;/span&gt; &lt;span class="n"&gt;uuid&lt;/span&gt; &lt;span class="k"&gt;PRIMARY&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="k"&gt;DEFAULT&lt;/span&gt; &lt;span class="n"&gt;gen_random_uuid&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
  &lt;span class="n"&gt;agent_name&lt;/span&gt; &lt;span class="nb"&gt;text&lt;/span&gt; &lt;span class="k"&gt;NOT&lt;/span&gt; &lt;span class="k"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;started_at&lt;/span&gt; &lt;span class="n"&gt;timestamptz&lt;/span&gt; &lt;span class="k"&gt;DEFAULT&lt;/span&gt; &lt;span class="n"&gt;now&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
  &lt;span class="n"&gt;duration_ms&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;input_tokens&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;output_tokens&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;model&lt;/span&gt; &lt;span class="nb"&gt;text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;tool_calls&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;query_count&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;estimated_cost_usd&lt;/span&gt; &lt;span class="nb"&gt;numeric&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;6&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;  &lt;span class="c1"&gt;-- approximate only&lt;/span&gt;
  &lt;span class="n"&gt;status&lt;/span&gt; &lt;span class="nb"&gt;text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="c1"&gt;-- success | budget_exceeded | error | dead_lettered&lt;/span&gt;
  &lt;span class="n"&gt;error&lt;/span&gt; &lt;span class="nb"&gt;text&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Consider a retention policy. A high-frequency job will grow this table quickly; partition by time or prune older rows if storage cost matters.&lt;/p&gt;

&lt;p&gt;A short query then shows the outliers:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sql"&gt;&lt;code&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt; &lt;span class="n"&gt;agent_name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
       &lt;span class="n"&gt;percentile_cont&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="mi"&gt;95&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;WITHIN&lt;/span&gt; &lt;span class="k"&gt;GROUP&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;ORDER&lt;/span&gt; &lt;span class="k"&gt;BY&lt;/span&gt; &lt;span class="n"&gt;estimated_cost_usd&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;AS&lt;/span&gt; &lt;span class="n"&gt;p95_cost&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
       &lt;span class="k"&gt;max&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;estimated_cost_usd&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;AS&lt;/span&gt; &lt;span class="n"&gt;max_cost&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
       &lt;span class="k"&gt;count&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;*&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;FILTER&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;WHERE&lt;/span&gt; &lt;span class="n"&gt;status&lt;/span&gt; &lt;span class="o"&gt;!=&lt;/span&gt; &lt;span class="s1"&gt;'success'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;AS&lt;/span&gt; &lt;span class="n"&gt;failures&lt;/span&gt;
&lt;span class="k"&gt;FROM&lt;/span&gt; &lt;span class="n"&gt;agent_runs&lt;/span&gt;
&lt;span class="k"&gt;WHERE&lt;/span&gt; &lt;span class="n"&gt;started_at&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;now&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="n"&gt;interval&lt;/span&gt; &lt;span class="s1"&gt;'7 days'&lt;/span&gt;
&lt;span class="k"&gt;GROUP&lt;/span&gt; &lt;span class="k"&gt;BY&lt;/span&gt; &lt;span class="n"&gt;agent_name&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Anything whose p95 is several times the median, or whose failure rate is rising, is worth opening. Route alerts to a place a human will actually see (Slack channel, email, or the same destination the successful run uses). A circuit breaker that pauses the schedule after repeated budget or error statuses prevents a bad run from repeating until someone looks.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Watch for context and tool-catalog bloat
&lt;/h2&gt;

&lt;p&gt;Every extra tool definition and every previous turn that stays in the context is paid on every subsequent call. Agents that append the full history or register every available MCP tool quickly inflate input tokens. Two simple checks catch this early:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Log input token count per turn. A steady climb across turns of the same job usually means history or tool results are being re-sent unnecessarily.&lt;/li&gt;
&lt;li&gt;Compare the tool list actually sent with the tools the spec says are required. Trim to the minimum set before the run starts.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Sliding windows, summarizing older turns, and loading tools only for the current intent are standard mitigations; the measurement makes it obvious when you need them.&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Test with realistic volume before you schedule
&lt;/h2&gt;

&lt;p&gt;N+1 and missing indexes stay hidden until the table grows. Before turning a job into a schedule, run it against a copy of production-like data (or a seeded table with thousands of rows). Measure:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;query count&lt;/li&gt;
&lt;li&gt;p95 latency&lt;/li&gt;
&lt;li&gt;token usage&lt;/li&gt;
&lt;li&gt;whether the budget limits fire&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If the numbers are acceptable only because the table is small, fix the query or add the index first. The same measurement harness used in development becomes the baseline the production metrics are compared against.&lt;/p&gt;

&lt;h2&gt;
  
  
  Putting the checks in the spec
&lt;/h2&gt;

&lt;p&gt;These measurements belong in the same Markdown spec that already constrains the feature:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;Performance &amp;amp; cost:
&lt;span class="p"&gt;-&lt;/span&gt; Query count per run ≥ 15 is a signal to investigate (client counter is a heuristic)
&lt;span class="p"&gt;-&lt;/span&gt; p95 duration ≤ 8s on 5k-row fixture
&lt;span class="p"&gt;-&lt;/span&gt; Per-run budget: 30k tokens, 12 tool calls, 90s (inclusive)
&lt;span class="p"&gt;-&lt;/span&gt; Write every run to agent_runs (with retention policy)
&lt;span class="p"&gt;-&lt;/span&gt; Alert on budget_exceeded, repeated errors, or p95 cost &amp;gt; 3× median
&lt;span class="p"&gt;-&lt;/span&gt; On failure: dead-letter or pause schedule; do not auto-retry unbounded
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Because the spec is read by both the interactive agent and the scheduled agent, the limits travel with the code. When a later change introduces a new loop or a wider tool list, the existing checks surface it on the next run instead of on the next invoice.&lt;/p&gt;

&lt;p&gt;The tools and model prices will keep changing. The underlying failure modes—unbounded retries, linear query growth, invisible token accumulation—do not. Measuring them with a few counters, targeted slow-query logging, a per-run budget enforced in code, and a simple metrics table is enough to catch many of the expensive cases while the feature is still small enough to fix.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>vibecoding</category>
      <category>api</category>
      <category>productivity</category>
    </item>
    <item>
      <title>6 AI Coding Tips That Sound Wrong (But Actually Work)</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Sat, 07 Nov 2026 13:31:52 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/6-ai-coding-tips-that-sound-wrong-but-actually-work-m23</link>
      <guid>https://dev.to/sushant_babbar/6-ai-coding-tips-that-sound-wrong-but-actually-work-m23</guid>
      <description>&lt;p&gt;Most advice regarding coding with AI optimizes for the first demo. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Write clearer prompts. Generate more code. Iterate fast.&lt;/strong&gt; &lt;em&gt;Those tips now feel like bottom-of-the-barrel advice.&lt;/em&gt; &lt;/p&gt;

&lt;p&gt;The tips that have produced features I can still open and trust weeks later do the opposite: they constrain the agent earlier, force smaller outputs, and treat the natural-language instructions as part of the codebase.&lt;/p&gt;

&lt;p&gt;These are the ones that have held up for me:&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Write the constraints before you generate anything
&lt;/h2&gt;

&lt;p&gt;Opening the agent and describing the feature feels productive. Sessions that need less cleanup start with a short Markdown file the agent reads on every run.&lt;/p&gt;

&lt;p&gt;A usable spec answers four questions and stays under a few hundred words:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;Goal: Every Monday at 9:00, post a diff of three competitor pricing pages to #competitive.

Inputs:
&lt;span class="p"&gt;-&lt;/span&gt; Firecrawl results for the exact URLs listed in urls.txt
&lt;span class="p"&gt;-&lt;/span&gt; Previous run stored in Supabase table &lt;span class="sb"&gt;`competitor_snapshots`&lt;/span&gt;

Constraints:
&lt;span class="p"&gt;-&lt;/span&gt; Only those three URLs
&lt;span class="p"&gt;-&lt;/span&gt; No price inference or external search
&lt;span class="p"&gt;-&lt;/span&gt; Slack message ≤ 800 characters
&lt;span class="p"&gt;-&lt;/span&gt; If scrape returns empty or errors, post the error and stop (max 1 retry)

Done when:
&lt;span class="p"&gt;-&lt;/span&gt; Message appears in the channel
&lt;span class="p"&gt;-&lt;/span&gt; Snapshot row is written with timestamp and raw markdown
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Because the file lives in the repo, later sessions and scheduled agents inherit the same boundaries. When the agent suggests adding a dashboard or scraping extra pages, the constraint is already explicit. Updating the spec is usually faster than editing generated code that drifted.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Build the thinnest version that can run end-to-end once
&lt;/h2&gt;

&lt;p&gt;Agents expand scope by default. The practical counter is to make the first version satisfy the spec and nothing else, then run it yourself.&lt;/p&gt;

&lt;p&gt;For the competitor brief, that means: one script or agent turn that fetches the three URLs, diffs against the last Supabase row, formats a message, and posts it. No auth, no history UI, no email. Once that path has executed under supervision and the Slack message matches the spec, the feature has proven it can exist. Additional surface area is added only after that proof.&lt;/p&gt;

&lt;p&gt;In &lt;a href="https://www.tryfriday.ai/code" rel="noopener noreferrer"&gt;Friday Code&lt;/a&gt;, this usually looks like pointing the agent at the spec file plus the existing project folder, letting it use the already-connected Supabase and Slack MCPs, then opening the resulting files in your normal editor to run and verify. The code is not trapped in the chat.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Treat the first working output as disposable scaffolding
&lt;/h2&gt;

&lt;p&gt;The moment something runs, the instinct is to keep it. A more reliable pattern is to treat the first successful generation as proof-of-concept scaffolding that you are free to delete.&lt;/p&gt;

&lt;p&gt;Because the project is a normal local folder (exportable, git-trackable), you can discard half the generated files if a simpler approach appears. I have repeatedly replaced multi-file agent output with a shorter script once the data flow was clear. The time saved comes from not defending the structure the agent invented before the constraints were tight.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Put explicit failure behavior in the spec
&lt;/h2&gt;

&lt;p&gt;Happy-path prompts are cheap. Silent failures are expensive, especially once a job is scheduled.&lt;/p&gt;

&lt;p&gt;Add the failure cases while the feature is still manual:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Empty scrape → post “No data from [urls]” and exit&lt;/li&gt;
&lt;li&gt;Rate-limit or 5xx → log to Supabase &lt;code&gt;agent_runs&lt;/code&gt; table, retry once, then alert&lt;/li&gt;
&lt;li&gt;Message length &amp;gt; 800 → truncate with “…” and note the truncation&lt;/li&gt;
&lt;li&gt;Missing previous snapshot → treat as first run and say so&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These lines feel pessimistic. They also become the instructions the scheduled agent follows. When a site structure changes, the failure is visible in Slack or the log table instead of disappearing. The fix is usually a one-line spec or prompt update plus a small code adjustment, committed together.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Schedule only the slice that has already succeeded manually
&lt;/h2&gt;

&lt;p&gt;Scheduling an ambitious agent the moment the demo looks good is how you get jobs that drift or fail quietly. The sequence that lasts is:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Run the narrow job manually at least twice while watching the real output (Slack message, GitHub issue, Supabase row).&lt;/li&gt;
&lt;li&gt;Confirm it matches the spec, including the failure path.&lt;/li&gt;
&lt;li&gt;Create a scheduled agent whose only responsibility is to re-execute that same verified logic on the cadence you want.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The scheduled agent does not receive permission to invent new features. Its prompt references the same spec file and the same constraints. In Friday Code this is a second, purpose-built agent that calls the existing code or prompts rather than a single ever-growing conversation. When credentials expire or a page layout shifts, the blast radius stays small.&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Keep the spec, agent instructions, and code in one repository
&lt;/h2&gt;

&lt;p&gt;Chat transcripts are not a source of truth. Model updates and new sessions discard context. The features that still run months later store three things side-by-side:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;SPEC.md&lt;/code&gt; (the constraints and done criteria)&lt;/li&gt;
&lt;li&gt;The implementation (scripts, Supabase migrations, prompt fragments)&lt;/li&gt;
&lt;li&gt;The scheduled-agent instructions (or a &lt;code&gt;schedule.md&lt;/code&gt; that the agent reads)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A change to a competitor’s markup updates the scraper, the spec’s expected selectors or parsing notes, and the failure message in one commit. A channel rename is a one-line edit visible in git history. This is ordinary software hygiene applied to agent-built work. It is also what makes the feature maintainable by someone who was not in the original chat—including future you.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why these reduce support load and improve the product
&lt;/h2&gt;

&lt;p&gt;Each tip lowers the chance that a user builds something that works once in a demo and then breaks or requires constant re-prompting. That directly affects the friction points that show up in community conversations: “it worked yesterday,” “the agent added things I didn’t ask for,” “I can’t find the code,” “the scheduled job stopped, and I don’t know why.”&lt;/p&gt;

&lt;p&gt;Writing constraints first and keeping them next to the code makes those failures legible. Scheduling only verified slices makes ownership obvious. Treating early output as disposable encourages the export-and-edit path instead of prompt dependency. These are the patterns worth reinforcing in docs, examples, and office hours because they produce features people can actually keep.&lt;/p&gt;

&lt;p&gt;The tools will keep changing. The habits that have produced agent-built features still running without daily prompting have stayed consistent: constrain early, ship thin and owned, make failure explicit, and only then let the repeating part run unattended.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>aiops</category>
      <category>coding</category>
    </item>
    <item>
      <title>How to Build Features That Run Autonomously</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Tue, 03 Nov 2026 09:06:58 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/how-to-build-features-that-run-autonomously-3c37</link>
      <guid>https://dev.to/sushant_babbar/how-to-build-features-that-run-autonomously-3c37</guid>
      <description>&lt;p&gt;Most AI coding sessions end the same way. You describe what you want, the agent generates a fair amount of working code, and for a few hours it feels like you’ve solved the problem. Then you close the laptop…&lt;/p&gt;

&lt;p&gt;The next day, the feature still needs you to open the chat, paste context, and tell it what to do next. The code exists, but it doesn’t run on its own.&lt;/p&gt;

&lt;p&gt;After building and shipping several small products, the pattern that actually stuck was different. The features that kept being useful were the ones I treated as three separate jobs: write a clear spec, ship a thin working version you own, and then deliberately turn the recurring part into something that runs without you.&lt;/p&gt;

&lt;p&gt;The tools matter less than the order you do those jobs in. Here’s how you build features that work without you.&lt;/p&gt;

&lt;h2&gt;
  
  
  Start with a task you already do
&lt;/h2&gt;

&lt;p&gt;The features that stalled all began as “it would be valuable if the app could…” The ones that kept running started with a task someone (usually me) was already doing by hand.&lt;/p&gt;

&lt;p&gt;Write down the actual job first:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Who does it?&lt;/li&gt;
&lt;li&gt;How often does it happen?&lt;/li&gt;
&lt;li&gt;What do they currently do?&lt;/li&gt;
&lt;li&gt;Which part is annoying enough that they sometimes skip it?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Then define the smallest end-to-end version that would remove the annoyance. Everything else is out of scope until that version has run on its own at least once.&lt;/p&gt;

&lt;p&gt;This sounds obvious. In practice, it is the step most people skip because describing a full feature feels more productive than deciding what the feature should refuse to do.&lt;/p&gt;

&lt;p&gt;A competitive brief that only summarizes three specific pages and posts to one Slack channel is more likely to keep running than a “full competitive intelligence system.”&lt;/p&gt;

&lt;p&gt;A support triage flow that only classifies messages and creates GitHub issues for the ones that match two patterns is more likely to keep running than an agent that tries to draft perfect replies.&lt;/p&gt;

&lt;h2&gt;
  
  
  Write the spec before you open the agent
&lt;/h2&gt;

&lt;p&gt;Once the job is clear, write a short specification. Not a product requirements document. A few hundred words that answer four questions:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;What outcome should be true when this finishes?&lt;/li&gt;
&lt;li&gt;What inputs does it need, and where do they come from?&lt;/li&gt;
&lt;li&gt;What must it never do?&lt;/li&gt;
&lt;li&gt;How will you know it worked?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I keep these in a plain Markdown file in the project. The agent can read it. I can edit it. Later sessions start from the same file instead of from my memory of the last chat.&lt;/p&gt;

&lt;p&gt;When something goes wrong, the first fix is usually to the spec, not to the code.&lt;/p&gt;

&lt;p&gt;A usable spec for a weekly competitive brief looks roughly like this:&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%2Fai5hi66j0494hpzuwiud.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%2Fai5hi66j0494hpzuwiud.png" alt=" " width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is short enough that you will actually write it. It is specific enough that the agent has less room to invent a different product.&lt;/p&gt;

&lt;h2&gt;
  
  
  Ship a version you can open in your own editor
&lt;/h2&gt;

&lt;p&gt;With the spec written, use the agent to build the thinnest version that satisfies it.&lt;/p&gt;

&lt;p&gt;In Friday Code, this usually means pointing it at the spec file and asking it to implement the feature with the integrations you already have connected (Supabase for anything that needs to remember state, Vercel for the deploy, Slack or GitHub for the output). For reference, here are some integrations that come built-in with Friday Code:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fki3tb8izronqsj08d5va.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fki3tb8izronqsj08d5va.gif" alt=" " width="800" height="451"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The important part is that the result lives in a real project folder on your machine. You can open it in your normal editor, run the tests yourself, and export or push the code whenever you want.&lt;/p&gt;

&lt;p&gt;If the agent suggests adding a user dashboard, email digests, and three extra integrations, you can reject those changes because they are not in the spec. The code is not locked inside the chat.&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%2F505648gfgri7362bes9i.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%2F505648gfgri7362bes9i.png" alt=" " width="800" height="624"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I treat the first working version as disposable scaffolding. It has to run end-to-end once, under my supervision, and produce the outcome the spec described. After that, I can delete half of it if a simpler approach appears.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The goal is not elegant code.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The goal is a feature that has already done the job once without me typing the next prompt.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Turn the recurring part into a scheduled agent
&lt;/h2&gt;

&lt;p&gt;This is the step that separates “I generated some code” from “the feature runs autonomously.”&lt;/p&gt;

&lt;p&gt;Most useful work isn't a one-time build. It is the same small job repeating: check the pages, compare them to last time, and post the summary; or read new messages, classify them, and open the issues.&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%2F4fce1nqz1wf80m2uw149.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%2F4fce1nqz1wf80m2uw149.png" alt=" " width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Friday Code’s scheduled agents are built for this. Once the feature works manually, you create a second agent whose only job is to run the existing code or prompts on a schedule.&lt;/p&gt;

&lt;p&gt;You give it the same constraints from the spec, tell it where to put the output, and set the cadence. Then you close the laptop.&lt;/p&gt;

&lt;p&gt;The first few runs will still need attention. The agent might miss a formatting detail or hit a rate limit. You fix those in the scheduled agent’s instructions or in the underlying code, then let it run again.&lt;/p&gt;

&lt;p&gt;After a handful of cycles, the failure rate drops and the feature becomes something you check rather than something you operate.&lt;/p&gt;

&lt;p&gt;I have found that scheduled agents stay reliable longer when their job is narrow.&lt;/p&gt;

&lt;p&gt;“Summarize these three pages and post the diff” survives more model updates and website changes than “monitor the competitive landscape and alert me to anything important.”&lt;/p&gt;

&lt;h2&gt;
  
  
  Check the output yourself before you trust the schedule
&lt;/h2&gt;

&lt;p&gt;Before you leave a feature running unattended, run it a few times while you are still watching. Compare the output to what the spec said should happen.&lt;/p&gt;

&lt;p&gt;Look at the actual Slack message or GitHub issue, not just the agent’s summary of what it did.&lt;/p&gt;

&lt;p&gt;This is the same habit that mattered when I was turning ideas into products: check the flow yourself before you show it to anyone else. With autonomous features, the “anyone else” is future-you who is not in the chat.&lt;/p&gt;

&lt;p&gt;If the message is too long, the classification is wrong, or the agent quietly skipped a constraint, you will only notice after it has already run a dozen times.&lt;/p&gt;

&lt;p&gt;A short checklist helps:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Did it use only the inputs listed in the spec?&lt;/li&gt;
&lt;li&gt;Did it stay inside the constraints?&lt;/li&gt;
&lt;li&gt;Is the output in the exact place and format you expected?&lt;/li&gt;
&lt;li&gt;What happens if one of the external services is down?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Fix anything that fails while you are still in the session. Then schedule it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Keep the spec and the schedule in the same place as the code
&lt;/h2&gt;

&lt;p&gt;The features that kept working months later were the ones where the specification, the scheduled agent instructions, and the code all lived in the same repository.&lt;/p&gt;

&lt;p&gt;When a competitor changed their page structure, I updated the spec and the agent prompt in the same commit that adjusted the scraper. When I needed to change the Slack channel, the change was visible next to the rest of the project.&lt;/p&gt;

&lt;p&gt;This is ordinary software practice applied to agent-built features. The difference is that the “code” now includes the natural-language instructions the scheduled agent follows.&lt;/p&gt;

&lt;p&gt;Treating those instructions as part of the project, instead of as chat history, is what lets the feature survive across sessions, model changes, and time.&lt;/p&gt;

&lt;h2&gt;
  
  
  What this looks like in practice
&lt;/h2&gt;

&lt;p&gt;One feature I still use started as a manual habit: every Monday I would open three competitor sites, note anything that looked different, and paste a summary into Slack.&lt;/p&gt;

&lt;p&gt;After writing the four-line spec above, I had Friday Code build a small script that used Firecrawl on those exact URLs, compared the results to a previous run stored in Supabase, and formatted a message.&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%2Fnlgr1lsdkuf2jc5jworb.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%2Fnlgr1lsdkuf2jc5jworb.png" alt=" " width="800" height="300"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I ran it myself twice, fixed the formatting, then turned the same logic into a scheduled agent that posts at 9 am.&lt;/p&gt;

&lt;p&gt;The scheduled version has missed a couple of runs when a site blocked the scraper. Each time, the fix was a small change to the agent’s instructions or a fallback in the code.&lt;/p&gt;

&lt;p&gt;The feature has otherwise continued without me opening the project. The time I spend on it now is occasional maintenance, not the original weekly task.&lt;/p&gt;

&lt;p&gt;The same shape works for other recurring jobs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Triaging a Slack channel into GitHub issues&lt;/li&gt;
&lt;li&gt;Generating a short internal changelog from merged pull requests&lt;/li&gt;
&lt;li&gt;Checking that a set of pages still return the expected status&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The common pieces are a narrow spec, a version you can open and edit yourself, and a scheduled agent that only does the repeating part.&lt;/p&gt;

&lt;h2&gt;
  
  
  Handle failures before they become silent
&lt;/h2&gt;

&lt;p&gt;Autonomous features fail. Sites change their markup, rate limits hit, credentials expire, and the scheduled agent returns something that no longer matches the spec.&lt;/p&gt;

&lt;p&gt;The difference between a feature that keeps running and one that quietly stops is how early and how visibly those failures surface.&lt;/p&gt;

&lt;p&gt;Here’s a useful diagram:&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%2Fje4gqejd4fo8bkjx5q52.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%2Fje4gqejd4fo8bkjx5q52.png" alt=" " width="800" height="500"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Before you leave a feature unattended, decide what “failed” looks like and where you’ll see it. In practice, this usually means one of three things:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;The agent posts a short failure message to the same Slack channel (or creates a GitHub issue) instead of staying silent.&lt;/li&gt;
&lt;li&gt;It writes a log or status row you can check.&lt;/li&gt;
&lt;li&gt;It stops and waits rather than guessing.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Keep the failure path as narrow as the happy path.&lt;/p&gt;

&lt;p&gt;“If the scraper returns nothing, post ‘No data from the three URLs’ and stop” is more useful than an agent that tries to improvise.&lt;/p&gt;

&lt;p&gt;Update the spec with the failure case so later sessions inherit the same rule.&lt;/p&gt;

&lt;p&gt;The first few scheduled runs will still surface problems. Treat those as expected. Fix the instruction or the code, then let it run again.&lt;/p&gt;

&lt;p&gt;Features that survive months are usually the ones whose failures were made obvious early, not the ones that never failed.&lt;/p&gt;

&lt;h2&gt;
  
  
  The parts that still need you
&lt;/h2&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%2Fshnt69b73e701tccepw0.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%2Fshnt69b73e701tccepw0.png" alt=" " width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Autonomous features do not remove judgment. You still decide which job is worth automating, what “done” means, and when the output is no longer useful enough to keep running.&lt;/p&gt;

&lt;p&gt;You still review the first several runs. You still own the code and the instructions, which means you can turn the schedule off or change the constraints when the world shifts.&lt;/p&gt;

&lt;p&gt;This approach means you don’t have to be in the chat every time the job runs. For tasks that are frequent, well-defined, and already annoying, that difference is large.&lt;/p&gt;

&lt;p&gt;Tools change. The sequence that lasts does not: start with a real task, write the constraints first, ship something you own, then schedule the part that repeats.&lt;/p&gt;

&lt;p&gt;Features that still run months later followed this order.&lt;/p&gt;

</description>
      <category>automation</category>
      <category>ai</category>
      <category>webdev</category>
      <category>programming</category>
    </item>
    <item>
      <title>I Spent 20 Hours Turning Ideas into Real Products with AI. Here's What Actually Worked.</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Tue, 20 Oct 2026 10:46:23 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/i-spent-20-hours-turning-ideas-into-real-products-with-ai-heres-what-actually-worked-1fa0</link>
      <guid>https://dev.to/sushant_babbar/i-spent-20-hours-turning-ideas-into-real-products-with-ai-heres-what-actually-worked-1fa0</guid>
      <description>&lt;p&gt;Most people treat AI coding tools like a faster way to follow tutorials. They generate a lot of code, feel productive for a while, and then realize nobody is using what they built.&lt;/p&gt;

&lt;p&gt;After spending roughly 20 hours deliberately trying to turn ideas into things people could actually try, a few patterns became clear. The tools matter less than how you use them. Here is what consistently worked.&lt;/p&gt;

&lt;h2&gt;
  
  
  Start with a user and a job, not a feature list
&lt;/h2&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%2Fv3p0o8ok0nhp81fg7mmz.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%2Fv3p0o8ok0nhp81fg7mmz.jpg" alt="needs decide the use" width="799" height="501"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The ideas that stalled all began the same way: a list of things the product should do. The ones that moved forward started with one person and one job they were already trying to get done.&lt;/p&gt;

&lt;p&gt;Write down who has the problem, what they currently do, and what makes that method annoying. Then define the smallest end-to-end task that would make their life better. Everything else is out of scope until that task works.&lt;/p&gt;

&lt;p&gt;This sounds obvious. In practice it is the step most people skip because generating features feels more productive than deciding what not to build.&lt;/p&gt;

&lt;h2&gt;
  
  
  Make the first version thinner than feels reasonable
&lt;/h2&gt;

&lt;p&gt;AI makes it easy to keep adding. The useful constraint is the opposite: force the first version to do one thing and stop.&lt;/p&gt;

&lt;p&gt;Before you start generating code, write a one-sentence finish line for the current cycle. Then list three things that are explicitly out of scope. When the agent suggests extra screens or settings, you can point back to that list.&lt;/p&gt;

&lt;p&gt;A thin version that someone can actually try is more valuable than a broader version that stays on your machine.&lt;/p&gt;

&lt;h2&gt;
  
  
  Check the flow yourself before you show it
&lt;/h2&gt;

&lt;p&gt;A generated interface can look finished while the data never saves, the error states are missing, or the happy path is the only path that works.&lt;/p&gt;

&lt;p&gt;Walk through the product as a user. Try the obvious inputs, then the wrong ones. Look at whatever data or output the product is supposed to produce. Note what breaks. Fix the blockers before you ask anyone else to look at it.&lt;/p&gt;

&lt;p&gt;This step feels slow. It is also the difference between getting real feedback and getting confused reactions to a broken flow.&lt;/p&gt;

&lt;h2&gt;
  
  
  Show it to someone without coaching them
&lt;/h2&gt;

&lt;p&gt;Once the core path works for you, put it in front of a relevant person and stay quiet. Do not explain what to do. Watch where they hesitate, what they expect to happen, and what they say when it does not.&lt;/p&gt;

&lt;p&gt;The feedback that matters usually shows up in the first few minutes. Most of it will be about the flow or the missing piece that seemed obvious to you. Treat that as the next change to make, not as a reason to redesign everything.&lt;/p&gt;

&lt;h2&gt;
  
  
  Keep cycles short and evidence-based
&lt;/h2&gt;

&lt;p&gt;The projects that progressed used the same loop:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Pick one user and one job.&lt;/li&gt;
&lt;li&gt;Set a small finish line and write down what is out of scope.&lt;/li&gt;
&lt;li&gt;Build only the essential path.&lt;/li&gt;
&lt;li&gt;Check it yourself with real and invalid inputs.&lt;/li&gt;
&lt;li&gt;Show it to someone relevant without coaching.&lt;/li&gt;
&lt;li&gt;Choose one next change based on what you saw.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Repeating this took less time overall than the projects where I kept expanding the idea before anyone used it. It also produced clearer decisions about what was worth building next.&lt;/p&gt;

&lt;h2&gt;
  
  
  Treat verification and ownership as part of the work
&lt;/h2&gt;

&lt;p&gt;AI can produce code quickly. It does not automatically know whether that code is safe, correct, or something you can maintain.&lt;/p&gt;

&lt;p&gt;A few habits helped:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Review the plan before large or risky changes.&lt;/li&gt;
&lt;li&gt;Keep edits small enough that you can still understand what changed.&lt;/li&gt;
&lt;li&gt;Ask the tool what it changed and how it checked the change.&lt;/li&gt;
&lt;li&gt;Keep secrets out of prompts and screenshots.&lt;/li&gt;
&lt;li&gt;Export and keep a copy of the code you care about.&lt;/li&gt;
&lt;li&gt;Know what any connected service can access before you connect it.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These steps are not exciting. They are the reason some of the projects remained usable after the initial excitement faded.&lt;/p&gt;

&lt;p&gt;The rest of the 20 hours went into a structured course that applies exactly this loop across different types of products. It is called Friday Code Bootcamp.&lt;/p&gt;

&lt;p&gt;You can find it here: &lt;a href="https://friday-code-bootcamp.vercel.app/" rel="noopener noreferrer"&gt;Friday Code Bootcamp&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What the bootcamp actually covers
&lt;/h2&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%2Feusrhdzin9lmmzrya5z7.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%2Feusrhdzin9lmmzrya5z7.png" alt="Friday Code Bootcamp" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The course is 10 modules and takes 20 to 24 hours if you work through the projects. It is built for people who want to ship useful software without first becoming professional engineers. That includes indie hackers, founders, students, career switchers, and anyone with ideas that have not left their notes app.&lt;/p&gt;

&lt;p&gt;The modules move from shipping something small to building systems that continue after you stop prompting:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Ship your first product&lt;/li&gt;
&lt;li&gt;Build a web app&lt;/li&gt;
&lt;li&gt;Build a mobile app&lt;/li&gt;
&lt;li&gt;Find a problem&lt;/li&gt;
&lt;li&gt;Find your first users&lt;/li&gt;
&lt;li&gt;Make a product video&lt;/li&gt;
&lt;li&gt;Automate a workflow&lt;/li&gt;
&lt;li&gt;Build an agent&lt;/li&gt;
&lt;li&gt;Launch and monetize&lt;/li&gt;
&lt;li&gt;Build your product system&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Later modules can build on earlier projects, but they do not have to. A small tool that solves one problem for a few people is treated as more useful than a large idea that never reaches anyone.&lt;/p&gt;

&lt;p&gt;Each module ends with an "invent" challenge: propose a use case the module did not list, make a small prototype, and state what evidence would show it is useful. There are also weekly "Ship Something" challenges that emphasize honest feedback over visual polish.&lt;/p&gt;

&lt;h2&gt;
  
  
  How the course treats Friday Code
&lt;/h2&gt;

&lt;p&gt;Friday Code is positioned as a desktop app for research, design, coding, integrations, content, and recurring tasks. The course focuses on durable habits rather than specific buttons or current model names, because those details change.&lt;/p&gt;

&lt;p&gt;It is explicit that the agent can accelerate work but does not remove the need to verify. A screen that looks finished does not prove data is saved, a payment is recorded, or an automation behaves safely. You still decide what matters, what data is safe to share, how much to spend, and whether something is ready for real people.&lt;/p&gt;

&lt;p&gt;The material also covers practical ownership: treating API keys as secrets, starting with test environments for payments and integrations, exporting your code, using version control where possible, and knowing what each connected service can access. You do not need to subscribe to every model or tool mentioned. The advice is to pick the smallest set that supports the current project.&lt;/p&gt;

&lt;h2&gt;
  
  
  What finishing looks like
&lt;/h2&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%2Fyqepsh0du5kbfbl59llq.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%2Fyqepsh0du5kbfbl59llq.png" alt="Friday Code" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The course defines success as a working product that solves a stated problem for someone, plus a clear account of what you learned. A small tool with a tested flow, sensible errors, measured costs, and honest limits is better than a long feature list with no verified users.&lt;/p&gt;

&lt;p&gt;It is clear that completing the modules does not guarantee revenue, adoption, or app store success. Those depend on the problem, the execution, and the market. The point is to leave with evidence instead of assumptions.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to start
&lt;/h2&gt;

&lt;p&gt;Download Friday Code from &lt;a href="https://www.tryfriday.ai/code" rel="noopener noreferrer"&gt;tryfriday.ai/code&lt;/a&gt;. It runs on Mac and Windows. Once it is installed, open the bootcamp and start with the introduction.&lt;/p&gt;

&lt;p&gt;The course is at &lt;a href="https://friday-code-bootcamp.vercel.app/" rel="noopener noreferrer"&gt;friday-code-bootcamp.vercel.app&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;If you have ideas that keep sitting in notes and you want a structured way to turn a few of them into things people can actually try, the first two or three modules are enough to get something live. The rest of the course builds from the same loop that worked in the 20 hours: pick a small job, build the thin version, check it, show it to someone, and decide the next change from what you saw.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>coding</category>
      <category>programming</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Gemini 4 Argon vs GPT-6.1 Sol: Which is better for coding?</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Tue, 20 Oct 2026 09:58:05 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/gemini-4-argon-vs-gpt-61-sol-which-is-better-for-coding-bfm</link>
      <guid>https://dev.to/sushant_babbar/gemini-4-argon-vs-gpt-61-sol-which-is-better-for-coding-bfm</guid>
      <description>&lt;p&gt;Google's Gemini 4 Argon pairs a 1M-token output limit with DeepSWE 77.9% and a $2/$10 API launch price. Here's what its staged rollout means for coding and enterprise teams.&lt;/p&gt;

&lt;p&gt;Google announced Gemini 4 Argon on September 30, 2026, positioning it as a frontier model for complex software engineering, knowledge work, and defensive cybersecurity. The most striking spec is not a leaderboard score: Argon can generate up to 1 million output tokens, an unusually large runway for multi-step work in a single trajectory. Google says it will expand access gradually, beginning with trusted cyber defenders and testers; broad developer, enterprise, and consumer access is not yet live.&lt;/p&gt;

&lt;p&gt;That makes the comparison with OpenAI's GPT-6.1 Sol less about declaring a winner and more about evaluating two different promises: Argon's very long execution horizon and low announced introductory token rates versus Sol's established coding-oriented position. Model cards, identical benchmark runs, and public API availability will matter before teams can make a confident migration decision.&lt;/p&gt;

&lt;h2&gt;
  
  
  Gemini 4 Argon vs GPT-6.1 Sol at a glance
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Specification&lt;/th&gt;
&lt;th&gt;Gemini 4 Argon&lt;/th&gt;
&lt;th&gt;GPT-6.1 Sol&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Publisher&lt;/td&gt;
&lt;td&gt;Google DeepMind&lt;/td&gt;
&lt;td&gt;OpenAI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Announced&lt;/td&gt;
&lt;td&gt;September 30, 2026&lt;/td&gt;
&lt;td&gt;See OpenAI's official model documentation for current release details&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Availability&lt;/td&gt;
&lt;td&gt;Rolling out to trusted cyber defenders and testers; broader access planned&lt;/td&gt;
&lt;td&gt;Check OpenAI's API documentation and account availability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Output capacity&lt;/td&gt;
&lt;td&gt;Up to 1 million tokens, per Google&lt;/td&gt;
&lt;td&gt;Not asserted here; verify current model documentation&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Announced API price&lt;/td&gt;
&lt;td&gt;Introductory $2 / 1M input tokens; $10 / 1M output tokens; cached input discounted 95%&lt;/td&gt;
&lt;td&gt;Not directly compared here; price depends on the current model/API SKU&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Public coding evidence&lt;/td&gt;
&lt;td&gt;DeepSWE v1.1: 77.9%, reported by Google&lt;/td&gt;
&lt;td&gt;Not a same-run comparison; consult OpenAI's published results&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Other highlighted evaluations&lt;/td&gt;
&lt;td&gt;Vals Index leadership; AutomationBench 51.3%; LVBench 91.7%; CWE-bench v1 68%&lt;/td&gt;
&lt;td&gt;Evaluation sets and test conditions differ; no direct ranking inferred&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Modalities and limits&lt;/td&gt;
&lt;td&gt;Multimodal capabilities described; input/context details not fully specified&lt;/td&gt;
&lt;td&gt;Verify current model card for modalities and limits&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Benchmark caveat:&lt;/strong&gt; these are publisher-reported results, not a controlled head-to-head. Benchmarks can differ by harness, prompting, tool access, sample selection, and scoring. DeepSWE v1.1 and CWE-bench v1 are different from SWE-bench Verified and CWE-bench v0; their percentages should not be treated as interchangeable.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why Argon's million-token output matters
&lt;/h2&gt;

&lt;p&gt;Most model comparisons focus on input context: how much material a model can read. Google is emphasizing output capacity, raising Argon's output limit from 64K to 1M tokens. In principle, that gives an agent much more room to reason, draft, inspect intermediate work, or produce a long multi-step result without stopping to hand off state.&lt;/p&gt;

&lt;p&gt;The practical question is whether teams should actually ask a model to produce a million tokens. Usually not. Long generations can increase elapsed time, cost, and the surface area for errors. For production, developers should set explicit budgets, stream partial results, checkpoint agent state, and require tests or human review before applying code changes. Argon's expanded ceiling is most compelling when the task genuinely benefits from one continuous trajectory—not as a default generation target.&lt;/p&gt;

&lt;p&gt;The launch article does not specify a generally available API, complete input-context limit, rate limits, latency, or the exact model identifier. Treat those as unanswered questions rather than assuming that the announced output ceiling is already usable in a production integration.&lt;/p&gt;

&lt;h2&gt;
  
  
  Coding performance: a promising result, not a universal verdict
&lt;/h2&gt;

&lt;p&gt;Google reports 77.9% on DeepSWE v1.1, describing Argon as state of the art on this long-horizon software engineering evaluation. The company also recounts internal work on code migrations and optimization, including an Argon-assisted Rust rewrite of 32,000 lines of SIMD code in libgav1. Google says the resulting safe Rust decoder ran 2.7× faster than the existing Rust port with identical video output. This is a Google-reported internal case study, not an independently reproduced result or a guarantee for arbitrary repositories.&lt;/p&gt;

&lt;p&gt;For developers, long-horizon competence can help with multi-file changes, debugging chains of failures, and migrations that need repeated profiling and verification. But a benchmark score alone does not tell you whether the agent will preserve repository conventions, avoid risky edits, or recover cleanly from a failed test. Evaluate it on your own issues and require branch isolation, test execution, diffs, and approval gates.&lt;/p&gt;

&lt;p&gt;GPT-6.1 Sol and Argon should be tested using the same repository tasks, tool permissions, time budget, and acceptance criteria. Until a reliable public apples-to-apples evaluation exists, don't infer that either DeepSWE's score or a result from a different coding benchmark settles the comparison.&lt;/p&gt;

&lt;h2&gt;
  
  
  Beyond code: business work, vision, and cyber defense
&lt;/h2&gt;

&lt;p&gt;Google says Argon leads the Vals Index, an economic-impact-weighted evaluation spanning finance, coding, legal, and tax; reports 51.3% on AutomationBench; and cites 91.7% on LVBench for long-video understanding. It also describes results on Vals Finance Agent v2 and Harvey's Legal Agent Benchmark without publishing scores in the launch post. These claims suggest broader enterprise ambitions, but the announcement does not provide enough matching GPT-6.1 Sol results to make a fair numerical comparison.&lt;/p&gt;

&lt;p&gt;Cybersecurity is a particular focus. Google reports a 68% tie for first place on CWE-bench v1, and says Argon can find, validate, and patch vulnerabilities. The release also describes a phased access program for trusted defenders and extensive safeguards, including misuse protections, prompt-injection testing, misalignment monitoring, and hardened evaluation environments. This is high-impact capability: security teams should use isolated, authorized test environments, review every proposed patch, and never provide production credentials to an unvetted agent.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pricing and access: attractive announced rates, unavailable broadly—for now
&lt;/h2&gt;

&lt;p&gt;Google lists introductory pricing of $2 per million input tokens and $10 per million output tokens, with cached input tokens at a 95% discount from the input price. That is a useful initial signal, but not a complete cost comparison: Argon's long output ceiling can make output consumption substantial, and end-to-end agent costs also include retries, tools, and verification.&lt;/p&gt;

&lt;p&gt;The release says Argon is rolling out to trusted cyber defenders through the Fairwind Program and that wider availability will follow, starting with paid API customers and Google AI Ultra subscribers. No public launch date, rate limits, or complete usage terms are specified in the announcement. For now, the pricing is announced rather than a guarantee that every developer can provision the model today.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where Friday fits
&lt;/h2&gt;

&lt;p&gt;Friday is the workflow layer around models: teams can evaluate models against actual tasks, keep human approval in the loop, and route work through the tools and processes they already use. Argon's long output budget could be useful for substantial repository analysis or multi-stage knowledge work once access opens; its cybersecurity strengths call for especially clear permissions and audit trails.&lt;/p&gt;

&lt;p&gt;A sensible evaluation plan is to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Select representative coding, research, and document tasks from your own backlog.&lt;/li&gt;
&lt;li&gt;Run Argon and your current model with equivalent prompts, context, tool access, and time/cost ceilings.&lt;/li&gt;
&lt;li&gt;Measure accepted task completion, test pass rates, review effort, latency, and total tokens—not just benchmark scores.&lt;/li&gt;
&lt;li&gt;Keep writes and deployments behind explicit review until the model has earned broader autonomy.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Verdict: watch the rollout; test before switching
&lt;/h2&gt;

&lt;p&gt;Gemini 4 Argon is a consequential announcement: a reported 77.9% DeepSWE v1.1 result, a 1M-token output limit, broad knowledge-work claims, and focused cyber capabilities make it worth evaluating. Its announced input/output rates look straightforward, although long generations mean teams must control output budgets.&lt;/p&gt;

&lt;p&gt;The biggest near-term limitation is access. Argon is still in a phased rollout, and important details such as public API identifiers, rate limits, latency, and independently comparable results remain unavailable in the cited announcement. GPT-6.1 Sol remains a useful incumbent to benchmark rather than a straw opponent. Keep your current production setup, build a matched evaluation, and revisit the decision when Argon access and documentation are concrete.&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Want to try GPT-6 and 300+ other models today?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Run GPT-6.1 Sol, Gemini, Claude, and hundreds of other frontier models side-by-side in Friday Code — with real agent workflows, local execution, and full control over your data.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.tryfriday.ai/code" rel="noopener noreferrer"&gt;Try Friday Code →&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Frequently asked questions
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Is Gemini 4 Argon available to developers now?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Not generally, according to Google's September 30 announcement. It is rolling out first to trusted cyber defenders and testers, with broader availability planned later, starting with paid API customers and Google AI Ultra subscribers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is Gemini 4 Argon's context window?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Google highlights a 1 million-token output limit. The launch announcement does not fully specify the input context limit; do not conflate output capacity with context window.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How much does Gemini 4 Argon cost?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Google announced introductory pricing of $2 per million input tokens and $10 per million output tokens, with cached input priced 95% below the input rate. Availability and final billing details should be confirmed in official API documentation when access opens.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is Argon's coding benchmark score?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Google reports 77.9% on DeepSWE v1.1. This is a publisher-reported result and should not be compared directly with differently configured SWE-bench tests.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Is Argon better than GPT-6.1 Sol?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;There is not enough directly comparable evidence in the cited launch materials to conclude that. Evaluate both against the same tasks, tools, budgets, and quality checks.&lt;/p&gt;

&lt;h2&gt;
  
  
  Sources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Google: Gemini 4 Argon announcement, September 30, 2026&lt;/li&gt;
&lt;li&gt;Google DeepMind: Gemini 4 Argon evaluations and methodology&lt;/li&gt;
&lt;li&gt;Vals Index benchmark&lt;/li&gt;
&lt;li&gt;CWE-bench&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>ai</category>
      <category>chatgpt</category>
      <category>coding</category>
    </item>
    <item>
      <title>How to Route LLM Requests: Building a Cost-Optimized Fallback Chain</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Tue, 20 Oct 2026 09:27:01 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/how-to-route-llm-requests-building-a-cost-optimized-fallback-chain-283f</link>
      <guid>https://dev.to/sushant_babbar/how-to-route-llm-requests-building-a-cost-optimized-fallback-chain-283f</guid>
      <description>&lt;p&gt;I got paged twice in the last two months because a single model dependency went down. One was a Copilot billing spike after a silent pricing change on a reasoning-heavy endpoint. The other was Anthropic’s Claude Fable 5 and Mythos 5, getting suspended on June 12, 2026, to comply with U.S. Department of Commerce export controls, &lt;a href="https://blog.getbind.co/fable-5-is-back-the-19-day-ai-shutdown-that-changed-how-governments-control-ai/" rel="noopener noreferrer"&gt;only to be restored on July 1 once the controls were lifted&lt;/a&gt;. Nineteen days of an unavailable model, zero warning, and any app hardcoded to that one model string was dead in the water until Anthropic’s team flipped the switch back on (&lt;a href="https://www.anthropic.com/news/fable-mythos-access" rel="noopener noreferrer"&gt;official statement&lt;/a&gt;).&lt;/p&gt;

&lt;p&gt;That’s the whole argument for this post. If your app calls one model, one provider, one endpoint, you don’t have an LLM integration; you have a single point of failure with a chat interface bolted on. This is a code-first tutorial on building a router that treats models like a pool of interchangeable workers: try the cheapest one that can do the job, fail over cleanly when it errors out or times out, and logs what it costs you. No frameworks you have to trust blindly, no hand-waving. Just Python that you can read in one sitting.&lt;/p&gt;

&lt;h2&gt;
  
  
  The problem with “just call the API”
&lt;/h2&gt;

&lt;p&gt;Most tutorials show you this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;openai&lt;/span&gt;

&lt;span class="n"&gt;client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;openai&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;OpenAI&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="n"&gt;response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;chat&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;completions&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;create&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="n"&gt;model&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt-5.5&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;[{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;role&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;user&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Summarize this contract.&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;}]&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That’s fine for a demo. It’s not fine for production, because it fails on four separate axes:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Provider outage&lt;/strong&gt; — OpenAI or Anthropic has a bad five minutes, and your whole app goes down with it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rate limits&lt;/strong&gt; — you get 429’d during a traffic spike and have no plan B.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cost drift&lt;/strong&gt; — you’re paying frontier-model prices for a task that a cheaper model handles fine.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Model deprecation or access changes&lt;/strong&gt; — a model gets deprecated, paused for compliance reasons, or moved behind a waitlist, like what happened with Fable 5.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A fallback chain fixes all four at once. The idea: define an ordered list of models, cheapest-and-fastest first, and walk down the list on any failure until one succeeds.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 1: Define your model chain as data, not code
&lt;/h3&gt;

&lt;p&gt;Don’t hardcode &lt;code&gt;if openai_fails: try_anthropic()&lt;/code&gt;. Model the chain as a config so you can reorder, add, or pull a model without touching your call logic.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;dataclasses&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;dataclass&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;enum&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Enum&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;Provider&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Enum&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="n"&gt;OPENAI&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;openai&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
    &lt;span class="n"&gt;ANTHROPIC&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;anthropic&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;

&lt;span class="nd"&gt;@dataclass&lt;/span&gt;
&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="n"&gt;provider&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Provider&lt;/span&gt;
    &lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;
    &lt;span class="n"&gt;input_cost_per_mtok&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt;   &lt;span class="c1"&gt;# USD per million input tokens
&lt;/span&gt;    &lt;span class="n"&gt;output_cost_per_mtok&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt;  &lt;span class="c1"&gt;# USD per million output tokens
&lt;/span&gt;    &lt;span class="n"&gt;max_retries&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;
    &lt;span class="n"&gt;timeout_s&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mf"&gt;30.0&lt;/span&gt;

&lt;span class="c1"&gt;# Ordered cheapest-capable-first. Reorder this list, don't rewrite your router.
&lt;/span&gt;&lt;span class="n"&gt;FALLBACK_CHAIN&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="nc"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Provider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ANTHROPIC&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;claude-sonnet-5&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mf"&gt;2.00&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mf"&gt;10.00&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;   &lt;span class="c1"&gt;# intro pricing through Aug 31, 2026
&lt;/span&gt;    &lt;span class="nc"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Provider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;OPENAI&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt-5.5&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mf"&gt;5.00&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mf"&gt;30.00&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="nc"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;Provider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ANTHROPIC&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;claude-haiku-4-5-20251001&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mf"&gt;1.00&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mf"&gt;5.00&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
&lt;span class="p"&gt;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A note on the pricing numbers: Claude Sonnet 5 launched at an introductory rate of $2/$10 per million input/output tokens through August 31, 2026, moving to $3/$15 after that. GPT-5.5 runs $5/$30 per million tokens. If you’re on the trusted-partner preview for OpenAI’s GPT-5.6 family (Sol, Terra, Luna), Sol prices at $5/$30, Terra at $2.50/$15, and Luna at $1/$6 — but as of this writing GPT-5.6 is still limited-preview only, not self-serve API access, so don’t build a production chain that depends on it being generally available yet. Build the chain so swapping &lt;code&gt;gpt-5.5&lt;/code&gt; for &lt;code&gt;gpt-5.6-sol&lt;/code&gt; later is a one-line config change, not a rewrite.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 2: Write one adapter per provider, same interface out
&lt;/h3&gt;

&lt;p&gt;The point of the router is that call sites never know which provider actually answered. Wrap each SDK behind an identical function signature.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;openai&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;anthropic&lt;/span&gt;

&lt;span class="n"&gt;openai_client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;openai&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;OpenAI&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="n"&gt;anthropic_client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;anthropic&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Anthropic&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;ModelError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;Exception&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Raised on any failure we want the router to catch and fail over on.&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;pass&lt;/span&gt;

&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;call_openai&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;list&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;tuple&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;]:&lt;/span&gt;
    &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;resp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;openai_client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;chat&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;completions&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;create&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;model&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;timeout&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timeout_s&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;text&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;choices&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="n"&gt;message&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;content&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompt_tokens&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;completion_tokens&lt;/span&gt;
    &lt;span class="nf"&gt;except &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;openai&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;APIStatusError&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;openai&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;APITimeoutError&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;openai&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;RateLimitError&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;ModelError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;OpenAI &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s"&gt; failed: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;

&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;call_anthropic&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;list&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;tuple&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;]:&lt;/span&gt;
    &lt;span class="c1"&gt;# Anthropic's SDK wants a separate system prompt and no "system" role in messages
&lt;/span&gt;    &lt;span class="n"&gt;system_msg&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;next&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="n"&gt;m&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;m&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;messages&lt;/span&gt; &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;m&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;role&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;system&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="n"&gt;user_msgs&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;m&lt;/span&gt; &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;m&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;messages&lt;/span&gt; &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;m&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;role&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;!=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;system&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;resp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;anthropic_client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;create&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;model&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;max_tokens&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;4096&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;system&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;system_msg&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;user_msgs&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;timeout&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timeout_s&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;text&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;content&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="n"&gt;text&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;input_tokens&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;usage&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;output_tokens&lt;/span&gt;
    &lt;span class="nf"&gt;except &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;anthropic&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;APIStatusError&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;anthropic&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;APITimeoutError&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;anthropic&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;RateLimitError&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;ModelError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Anthropic &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s"&gt; failed: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;

&lt;span class="n"&gt;DISPATCH&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;Provider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;OPENAI&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;call_openai&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;Provider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ANTHROPIC&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;call_anthropic&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Notice I’m only catching the exception types that mean “this provider had a problem,” not blanket &lt;code&gt;except Exception&lt;/code&gt;. If your prompt itself is malformed, you want that to blow up loudly, not silently retry three providers with the same broken request.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 3: The router — walk the chain, retry with backoff, track cost
&lt;/h3&gt;

&lt;p&gt;This is the core piece. It does three things every fallback router needs: retries within a model before giving up on it, moves to the next model on total failure, and returns cost data so you can actually see what happened.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;

&lt;span class="n"&gt;logger&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getLogger&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;llm_router&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;estimate_cost&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;input_tokens&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;output_tokens&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="nf"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
        &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;input_tokens&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;1_000_000&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;input_cost_per_mtok&lt;/span&gt;
        &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;output_tokens&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;1_000_000&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;output_cost_per_mtok&lt;/span&gt;
    &lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;route_request&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;list&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="n"&gt;chain&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;list&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;FALLBACK_CHAIN&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="n"&gt;errors&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[]&lt;/span&gt;

    &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;chain&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;fn&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;DISPATCH&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;provider&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;

        &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="nf"&gt;range&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;max_retries&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
            &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                &lt;span class="n"&gt;start&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;monotonic&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
                &lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;in_tok&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;out_tok&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                &lt;span class="n"&gt;latency&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;monotonic&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="n"&gt;start&lt;/span&gt;
                &lt;span class="n"&gt;cost&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;estimate_cost&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;in_tok&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;out_tok&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

                &lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;info&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;success model=%s attempt=%d latency=%.2fs cost=$%.5f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;latency&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;cost&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="p"&gt;)&lt;/span&gt;
                &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;text&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model_used&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;provider&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;provider&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;value&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;attempt&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;latency_s&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;round&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;latency&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;cost_usd&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;round&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;cost&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;6&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
                    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;fallback_depth&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;chain&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;index&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
                &lt;span class="p"&gt;}&lt;/span&gt;

            &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="n"&gt;ModelError&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                &lt;span class="n"&gt;errors&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;append&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
                &lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;warning&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;attempt %d/%d failed for %s: %s&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                                &lt;span class="n"&gt;attempt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;max_retries&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="n"&gt;spec&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;max_retries&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                    &lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sleep&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;min&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt; &lt;span class="o"&gt;**&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;8&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;  &lt;span class="c1"&gt;# exponential backoff, capped at 8s
&lt;/span&gt;
    &lt;span class="c1"&gt;# Every model in the chain failed
&lt;/span&gt;    &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;ModelError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;All models in chain exhausted. Errors: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;errors&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run it like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="n"&gt;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;route_request&lt;/span&gt;&lt;span class="p"&gt;([&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;role&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;system&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;You are a concise contract-review assistant.&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;role&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;user&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Flag any auto-renewal clauses in this text: ...&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;
&lt;span class="p"&gt;])&lt;/span&gt;

&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model_used&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;cost_usd&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;fallback_depth&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If Sonnet 5 answers on the first try, &lt;code&gt;fallback_depth&lt;/code&gt; is 0 and you paid Sonnet 5 rates. If Sonnet 5 is rate-limited and GPT-5.5 picks it up, &lt;code&gt;fallback_depth&lt;/code&gt; is 1 and you know exactly why your bill for that request looks different. That visibility is the whole point — you can’t optimize cost you can’t see.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 4: Don’t retry a provider that’s clearly dead — add a circuit breaker
&lt;/h3&gt;

&lt;p&gt;Retrying a model that’s mid-outage on every single request wastes time and money, and it can make an outage worse by hammering an already-struggling API. A circuit breaker tracks failure rate per model and skips it entirely for a cooldown period once it crosses a threshold.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;collections&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;deque&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;timedelta&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;CircuitBreaker&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;__init__&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;failure_threshold&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;window_s&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;cooldown_s&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;120&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;failure_threshold&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;failure_threshold&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;window&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;timedelta&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;seconds&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;window_s&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;cooldown&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;timedelta&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;seconds&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;cooldown_s&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;failures&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;deque&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{}&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tripped_until&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{}&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;is_open&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;bool&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;True means &lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;circuit open&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt; — skip this model.&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="n"&gt;until&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tripped_until&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;until&lt;/span&gt; &lt;span class="ow"&gt;and&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="n"&gt;until&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="bp"&gt;True&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="bp"&gt;False&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;record_failure&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;now&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
        &lt;span class="n"&gt;q&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;failures&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;setdefault&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nf"&gt;deque&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
        &lt;span class="n"&gt;q&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;append&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;now&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="n"&gt;q&lt;/span&gt; &lt;span class="ow"&gt;and&lt;/span&gt; &lt;span class="n"&gt;now&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="n"&gt;q&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;window&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;q&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;popleft&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="nf"&gt;len&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;q&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;failure_threshold&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tripped_until&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;now&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;cooldown&lt;/span&gt;
            &lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;circuit OPEN for %s until %s&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tripped_until&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;record_success&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;failures&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;pop&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tripped_until&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;pop&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;model_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="n"&gt;breaker&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;CircuitBreaker&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Wire it into &lt;code&gt;route_request&lt;/code&gt; by checking &lt;code&gt;breaker.is_open(spec.model_id)&lt;/code&gt; before you call &lt;code&gt;fn&lt;/code&gt;, and calling &lt;code&gt;breaker.record_failure&lt;/code&gt; / &lt;code&gt;breaker.record_success&lt;/code&gt; inside the try/except. Three failures inside 60 seconds and that model gets skipped for two minutes — long enough to ride out a transient blip, short enough that you’re back on the cheaper model the moment it recovers.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 5: Skip building your own SDK glue — know when to use LiteLLM
&lt;/h3&gt;

&lt;p&gt;Everything above is maybe 120 lines, and I’d argue you should understand it even if you don’t ship it. But if you want the multi-provider adapter layer without owning it, &lt;a href="https://github.com/BerriAI/litellm" rel="noopener noreferrer"&gt;LiteLLM&lt;/a&gt; is a real, actively maintained open-source library that gives you one OpenAI-compatible interface across 100+ providers, plus built-in retry and fallback config:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;litellm&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;completion&lt;/span&gt;

&lt;span class="n"&gt;response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;completion&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="n"&gt;model&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;claude-sonnet-5&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;messages&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;[{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;role&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;user&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Summarize this contract.&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;}],&lt;/span&gt;
    &lt;span class="n"&gt;fallbacks&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt-5.5&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;claude-haiku-4-5-20251001&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
    &lt;span class="n"&gt;num_retries&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That single call does most of Step 2 and Step 3 for you. What LiteLLM doesn’t hand you out of the box is the cost-aware ordering logic and the circuit breaker tuned to your own traffic patterns — that’s still on you to configure well. Use it when you want to move fast and trust a well-tested library; write your own router when you need tight control over ordering logic, custom cost accounting, or you’re operating in an environment where adding a dependency needs a security review.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 6: Route by task, not just by failure
&lt;/h3&gt;

&lt;p&gt;The chain above fails over reactively — only after something breaks. The bigger cost win is routing proactively: send simple tasks to cheap models by default, and only escalate to the expensive model when the task actually needs it.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;re&lt;/span&gt;

&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;pick_chain_for_task&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;base_chain&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;list&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;list&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;ModelSpec&lt;/span&gt;&lt;span class="p"&gt;]:&lt;/span&gt;
    &lt;span class="n"&gt;token_estimate&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;len&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;split&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
    &lt;span class="n"&gt;is_complex&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;bool&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;re&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;search&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;r&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;\b(analyze|architecture|refactor|multi-step|reason)\b&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;re&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;I&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;

    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;token_estimate&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;200&lt;/span&gt; &lt;span class="ow"&gt;and&lt;/span&gt; &lt;span class="ow"&gt;not&lt;/span&gt; &lt;span class="n"&gt;is_complex&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="c1"&gt;# cheap-first order, no need to touch the frontier model at all
&lt;/span&gt;        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;sorted&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;base_chain&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;key&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="k"&gt;lambda&lt;/span&gt; &lt;span class="n"&gt;s&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;s&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;input_cost_per_mtok&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;base_chain&lt;/span&gt;  &lt;span class="c1"&gt;# keep the default, capability-first order
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is the difference between a router that just survives outages and one that actually cuts your bill. A classification prompt, a short summarization job, a form-field extraction — none of that needs a $30/million-output-token model. Save the expensive model for the requests that genuinely need deep reasoning, long context, or agentic tool use.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 7: Log everything, then actually look at it
&lt;/h3&gt;

&lt;p&gt;The router above already returns &lt;code&gt;model_used&lt;/code&gt;, &lt;code&gt;cost_usd&lt;/code&gt;, &lt;code&gt;latency_s&lt;/code&gt;, and &lt;code&gt;fallback_depth&lt;/code&gt; per call. Pipe that into whatever you already use for logs — even a flat file with one JSON line per request is enough to start:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;

&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;log_request&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;llm_router.log&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="nf"&gt;open&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;a&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;write&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;dumps&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;&lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;ts&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;isoformat&lt;/span&gt;&lt;span class="p"&gt;()})&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;After a week of real traffic, run a quick pass over that log:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;pandas&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;pd&lt;/span&gt;

&lt;span class="n"&gt;df&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;pd&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;read_json&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;llm_router.log&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;lines&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="bp"&gt;True&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;df&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;groupby&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model_used&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;cost_usd&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nf"&gt;sum&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;df&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;groupby&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model_used&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;fallback_depth&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nf"&gt;mean&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="n"&gt;df&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;fallback_depth&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;mean&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;  &lt;span class="c1"&gt;# % of requests that needed a fallback at all
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If that last number is above a few percent, either your primary model has a real reliability problem worth escalating to the provider, or your primary choice in the chain is wrong for your traffic mix. Either way, you now have data instead of a hunch.&lt;/p&gt;

&lt;h2&gt;
  
  
  Things that will bite you if you skip them
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Token counting differs by tokenizer.&lt;/strong&gt; Sonnet 5 uses an updated tokenizer versus Sonnet 4.6 — the same prompt can produce noticeably more tokens on the new model. Don’t reuse an old token-count baseline to estimate cost on a new model; re-measure.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Streaming breaks naive fallback.&lt;/strong&gt; If you’re streaming tokens to a UI and the model fails mid-stream, you can’t just “retry the next model” cleanly — you’ll show a broken partial response. Buffer the first chunk before committing to a stream, or fail over before you start streaming at all.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Don’t fail over on content you disagree with.&lt;/strong&gt; A model returning an answer you don’t like isn’t a ModelError. Only fail over on actual transport/API failures — timeouts, rate limits, 5xx errors. Otherwise you’ll burn budget hunting for the answer you wanted instead of handling real outages.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rate limit errors need real backoff, not a fixed sleep.&lt;/strong&gt; Respect &lt;code&gt;Retry-After&lt;/code&gt; headers when providers send them instead of guessing your own backoff window.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Test the failure path, not just the happy path.&lt;/strong&gt; Point your primary model at a bad API key on purpose in staging and confirm the chain actually falls through. A fallback chain you’ve never seen fail is a fallback chain you don’t actually know works.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Bottom Line
&lt;/h2&gt;

&lt;p&gt;A fallback chain is not a nice-to-have resiliency pattern you get to later. It’s the difference between an outage or a compliance-driven pause taking your product down for nineteen days versus your users never noticing. Build it as data (the chain config), keep provider-specific code behind identical adapters, retry smart, circuit-break aggressively, route cheap-first when the task allows it, and log enough that “what did this cost us and why” is a query, not a guess.&lt;/p&gt;

&lt;p&gt;The code above is a complete, working starting point, not pseudocode. Copy it, swap in your own model chain, and you’ve got a router that survives the next model shutdown, price hike, or export-control surprise without a rewrite.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>llm</category>
      <category>webdev</category>
      <category>programming</category>
    </item>
    <item>
      <title>ChatGPT Go Subscription India Features, Pricing, and Alternatives</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Wed, 20 Aug 2025 15:30:55 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/chatgpt-go-subscription-india-features-pricing-and-alternatives-ae1</link>
      <guid>https://dev.to/sushant_babbar/chatgpt-go-subscription-india-features-pricing-and-alternatives-ae1</guid>
      <description>&lt;p&gt;OpenAI recently announced its ChatGPT Go subscription for the Indian audience. It's positioned as their most accessible paid offering so far, a bridge between ChatGPT's free tier and the premium subscription, if you must. Currently rolling out in India at ₹399/month (approximately $4.60–$5), it provides an entry-level upgrade for users who want more capability without committing to the higher-priced ChatGPT Plus at ₹1,999/month ($20). Let's have a look at ChatGPT Go Subscription's features, pricing, and &lt;a href="https://www.getbind.co/" rel="noopener noreferrer"&gt;alternatives&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What’s included in the ChatGPT Go Subscription?&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fnfzfea7wwl038lbm0iz0.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.amazonaws.com%2Fuploads%2Farticles%2Fnfzfea7wwl038lbm0iz0.png" alt=" " width="799" height="350"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;OpenAI has bundled several upgrades into the Go plan to make it feel like a meaningful step up from free access.&lt;br&gt;
&lt;em&gt;1. GPT-5 Access&lt;/em&gt;&lt;br&gt;
Subscribers get access to GPT-5, OpenAI’s flagship model. Free users are restricted to lighter models, but Go ensures access to a more advanced and reliable version of ChatGPT.&lt;br&gt;
&lt;em&gt;2. Expanded Usage Limits&lt;/em&gt;&lt;br&gt;
Go increases the number of prompts users can send, as well as how frequently they can use premium features such as image generation and advanced data analysis. This allows for heavier day-to-day use without running into limitations too quickly.&lt;br&gt;
&lt;em&gt;3. Extended access to Image Generation&lt;/em&gt;&lt;br&gt;
Go subscribers can generate significantly more AI images than free users. This is valuable for students, designers, or anyone looking to quickly visualize ideas.&lt;br&gt;
&lt;em&gt;4. File Uploads and Analysis&lt;/em&gt;&lt;br&gt;
The plan allows larger and more frequent file uploads—documents, spreadsheets, and presentations can be submitted for analysis. This makes ChatGPT more practical as a productivity assistant.&lt;br&gt;
&lt;em&gt;5. Advanced Data Analysis (ADA)&lt;/em&gt;&lt;br&gt;
ChatGPT Go grants more frequent access to ADA, a tool powered by Python that allows code execution, chart generation, and problem-solving beyond basic conversation.&lt;br&gt;
&lt;em&gt;6. Memory Improvements&lt;/em&gt;&lt;br&gt;
ChatGPT Go provides double the memory of the free plan, which helps the AI maintain better context across conversations.&lt;br&gt;
&lt;em&gt;7. Convenient Payment Options&lt;/em&gt;&lt;br&gt;
In India, subscriptions can be purchased through UPI or credit cards, making the service accessible to a wide audience.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ChatGPT Go Limitations&lt;/strong&gt;&lt;br&gt;
Despite its advantages, ChatGPT Go remains an entry-level plan. Several advanced features are still locked behind higher tiers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;No legacy model access (e.g., GPT-4o).&lt;/li&gt;
&lt;li&gt;No access to advanced tools such as Sora for video creation, Agents, or Connectors.&lt;/li&gt;
&lt;li&gt;Limited regional availability—currently only available in India, with expansion expected in the future.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For many casual users, these restrictions may not be a concern. But for professionals and developers who rely on broader tools, ChatGPT Go feels limited. Comparatively, Bind AI offers open access to multiple advanced models, seamless integration with GitHub, and a more advanced variation of custom GPTs. More on it later in the article.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ChatGPT Go Alternatives for high value&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fdy05aolk8a9wrtinn9ok.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.amazonaws.com%2Fuploads%2Farticles%2Fdy05aolk8a9wrtinn9ok.png" alt=" " width="800" height="474"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;While OpenAI fine-tunes its subscription offerings, Bind AI has positioned itself as a comprehensive alternative—especially attractive for developers, creators, and teams.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Why Bind AI?&lt;/em&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2F0tnlcaflw4qvw3x26s41.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.amazonaws.com%2Fuploads%2Farticles%2F0tnlcaflw4qvw3x26s41.png" alt=" " width="800" height="398"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Unlike ChatGPT Go, which focuses on affordability, Bind AI emphasizes flexibility, customization, and integration. It’s not just a chatbot; it’s a productivity platform designed for power users.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bind AI Features&lt;/em&gt;&lt;br&gt;
Multi-Model Access&lt;br&gt;
Unlike ChatGPT Go, which only grants access to GPT-5, Bind AI integrates multiple leading models—Claude, Gemini, GPT variants, and Llama—all in one platform.&lt;br&gt;
Built-in IDE&lt;br&gt;
Bind AI comes with an integrated development environment supporting over 70 programming languages. Users can write, execute, and preview code directly, making it far more powerful for developers.&lt;br&gt;
GitHub Integration&lt;br&gt;
Teams can sync projects directly with GitHub, manage repositories, and collaborate seamlessly within Bind AI.&lt;br&gt;
Custom GPT Agents&lt;br&gt;
Users can create personalized AI agents tailored to specific workflows, a feature not available in ChatGPT Go.&lt;br&gt;
Bring-Your-Own-Key&lt;br&gt;
For advanced users, Bind AI supports BYOK, allowing integration with existing OpenAI or Anthropic API keys—making usage limits effectively expandable.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bind AI Pricing and Plans&lt;/em&gt;&lt;br&gt;
Bind AI offers a tiered pricing model that scales with user needs:&lt;br&gt;
&lt;strong&gt;Free Plan:&lt;/strong&gt; Access to models like GPT-4o mini and Claude 3.5 Haiku. Basic file uploads and a lightweight coding environment are included.&lt;br&gt;
&lt;strong&gt;Premium Plan ($18/month):&lt;/strong&gt; Access to IDE, Claude 4, GPT-4.1, Gemini 2.5 Pro, DeepSeek R1, and other advanced models. It includes up to 1 million compute points per month, support for custom GPT agents, and Bring-Your-Own-Key (BYOK) options for near-unlimited use.&lt;br&gt;
&lt;strong&gt;Scale Plan ($39/month):&lt;/strong&gt; Features everything included in the Premium Plan, but with extended limits. &lt;/p&gt;

&lt;p&gt;For businesses, Bind AI also provides team and enterprise plans with collaboration features and higher usage allowances.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ChatGPT Go vs. Bind AI - Direct Comparison&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fpjqq4bl3qx5l8i58w039.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.amazonaws.com%2Fuploads%2Farticles%2Fpjqq4bl3qx5l8i58w039.png" alt=" " width="800" height="484"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The table above provides a side-by-side comparison between ChatGPT Go and Bind AI. While ChatGPT Go offers affordability and basic access to GPT-5, Bind AI delivers a much richer toolset, supporting multiple models, advanced coding integrations, and custom AI agents. For professionals and teams, Bind AI stands out as the more powerful and scalable choice.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;FAQ&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;Q: Is ChatGPT Go worth it for casual users?&lt;/em&gt;&lt;br&gt;
Yes. If you primarily want access to GPT-5 and enhanced limits without paying for ChatGPT Plus, Go is excellent value.&lt;br&gt;
&lt;em&gt;Q: Who should choose Bind AI instead?&lt;/em&gt;&lt;br&gt;
Bind AI is better for developers, teams, and power users who need advanced tools, multiple AI models, or integration with coding workflows.&lt;br&gt;
&lt;em&gt;Q: Which is more affordable?&lt;/em&gt;&lt;br&gt;
ChatGPT Go is cheaper upfront. However, Bind AI offers more features per dollar for those who need advanced capabilities.&lt;br&gt;
&lt;em&gt;Q: Does Bind AI support enterprise use?&lt;/em&gt;&lt;br&gt;
Yes. Bind AI’s higher tiers support team collaboration, multi-agent workflows, and deployment pipelines—capabilities missing in ChatGPT Go.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The Bottom Line&lt;/strong&gt;&lt;br&gt;
ChatGPT Go is a smart move by OpenAI. At ₹399 per month, it opens the door to GPT-5, image generation, and enhanced productivity features at a fraction of the cost of ChatGPT Plus or Pro. For students, hobbyists, and everyday users, it’s a compelling upgrade from the free tier.&lt;/p&gt;

&lt;p&gt;However, Bind AI offers much more power and flexibility. Its integration of multiple AI models, built-in IDE, GitHub support, and custom agent creation make it a stronger long-term investment for professionals. While it costs more ($18–39/month), the additional tools and scalability justify the difference.&lt;/p&gt;

&lt;p&gt;In short:&lt;/p&gt;

&lt;p&gt;Choose ChatGPT Go if you want affordable access to GPT-5 for daily tasks.&lt;br&gt;
Choose Bind AI if you want a professional-grade AI platform that grows with your projects and ambitions.&lt;/p&gt;

&lt;p&gt;For anyone beyond casual use, Bind AI is the smarter deal - &lt;a href="https://app.getbind.co/" rel="noopener noreferrer"&gt;get it here&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>openai</category>
      <category>chatgpt</category>
      <category>vibecoding</category>
    </item>
    <item>
      <title>GPT-5 vs GPT-4: A very detailed coding comparison 🤖</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Sun, 10 Aug 2025 12:44:33 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/gpt-5-vs-gpt-4-a-very-detailed-coding-comparison-5dni</link>
      <guid>https://dev.to/sushant_babbar/gpt-5-vs-gpt-4-a-very-detailed-coding-comparison-5dni</guid>
      <description>&lt;p&gt;It’s safe to say that the GPT-5 release has been less than stellar. Yes, the model isn’t enormously costly. Yes, it delivers and stands above the competition. Yes, it’s a welcome addition to the GPT model family. But maybe just maybe it has fallen short of many people’s expectations. Still, analysis is warranted. &lt;a href="https://blog.getbind.co/2025/08/04/openai-gpt-5-vs-claude-4-feature-comparison/" rel="noopener noreferrer"&gt;We’ve already compared GPT-5 with the Claude 4 model family&lt;/a&gt;, and now it’s GPT-4o’s turn. Here’s a detailed GPT-5 vs GPT-4 analysis focusing on how each performs in coding. Let’s get started.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GPT-5 Model Family Overview and Comparison with GPT-4o&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;OpenAI is marketing GPT-5 as a family of models and an intelligent router that picks the right variant for each request. It ships with “general” and “thinking” variants and claims significant gains on reasoning and coding benchmarks compared to GPT-4. Official documentation highlights improved scores on math, coding, and multimodal tasks, expectedly.&lt;/p&gt;

&lt;p&gt;Compared to GPT-4o, GPT-5 improves upon reasoning, coding accuracy, and handling multimodal inputs like text, images, and more. Official tests show higher scores in math, programming, and cross-modal problem-solving. For people who depend on AI not just to be creative, but also to be consistently right, GPT-5 offers a blend of adaptability, precision, and speed that makes it feel less like a tool and more like a capable partner.&lt;/p&gt;

&lt;p&gt;You can try &lt;a href="https://app.getbind.co/chat/bind-ai?model=advanced" rel="noopener noreferrer"&gt;GPT-4o here&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GPT-5 Benchmarks and Empirical Performance&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Feuka5w5pbdsq1v8vohds.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.amazonaws.com%2Fuploads%2Farticles%2Feuka5w5pbdsq1v8vohds.png" alt=" " width="800" height="585"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Benchmarks matter. OpenAI reports that GPT-5 scores 74.9% on SWE-bench Verified and 88% on Aider Polyglot for coding tasks. Independent benchmarks and developer reviews broadly confirm a meaningful uplift in many real-world coding scenarios, although not uniformly across every workload. Some community tests show exceptional gains when “thinking”/chain-of-thought settings are enabled; others find edge-cases and style regressions compared to specialized competitors. GPT-4 remains strong at many day-to-day tasks, but GPT-5 pulls ahead on cross-file reasoning and multimodal cues in the tests publicized so far.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;What feels different while coding?&lt;/em&gt;&lt;br&gt;
Speed and responsiveness: GPT-5 is designed to be faster for common tasks. For many small, iterative queries—refactors, short bug fixes, or writing unit tests—responses are snappy. In practice, that reduces friction during pair-programming sessions and keeps context alive across interactions.&lt;/p&gt;

&lt;p&gt;Quality of generated code: Code from GPT-5 tends to be more idiomatic and better at multi-file reasoning. Where GPT-4 sometimes produced plausible but brittle code, GPT-5 reduces hallucinated APIs and mismatched types in typical stacks. That said, reviewers report variability: for UI-heavy tasks or detailed UX implementations, GPT-5 can still produce thin skeletons that need human polish.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Debugging and reasoning about complex codebases&lt;/em&gt;&lt;br&gt;
This is where GPT-5 shines relative to GPT-4. The “thinking” mode and improved context handling help with tracing bugs across files, suggesting fixes that respect hidden invariants, and summarizing long diffs with fewer follow-ups. For code review and PR summarization, third-party benchmarks and internal tests show higher quality on typical enterprise PR tasks. However, the gains are not a magic wand: GPT-5 still approximates likely fixes and can miss domain-specific intentions. Use it to triage and propose patches faster, but keep the human in the loop for domain validation.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Multi-modal help: reading screenshots, diagrams, and docs&lt;/em&gt;&lt;br&gt;
GPT-5’s multimodal abilities are better than GPT-4’s older capabilities. That means it handles screenshots of stack traces, diagrams, and mixed text+image PRs more reliably. For frontend developers, feeding a screenshot of a broken component plus the associated CSS file gets more accurate diagnoses than GPT-4 did in similar tests. This matters for debugging UI regressions and rapidly understanding legacy code.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Tooling and API changes that matter to devs&lt;/em&gt;&lt;br&gt;
OpenAI shipped developer-focused pages describing GPT-5 for developers and integrations across platforms (GitHub Models, API variants). The router that automatically selects a model variant means less manual experimentation but more need to understand pricing and rate limits for each variant. GitHub Models support makes it easier to use GPT-5 directly in code hosts, improving workflows like autocompletion, PR generation, and in-CI checks. &lt;/p&gt;

&lt;p&gt;If you build on OpenAI’s API, the new model family and thinking variants give you knobs—faster, cheaper “mini” models and a higher-latency “thinking” model that does heavier reasoning.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GPT-5 vs GPT-4 Pricing Comparison&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fb47r2we8vd0z84vjprne.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.amazonaws.com%2Fuploads%2Farticles%2Fb47r2we8vd0z84vjprne.png" alt=" " width="800" height="465"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;GPT-5 introduces more flexible pricing than GPT-4, especially for developers and large-scale applications. Its standard API rates are half the cost for input tokens compared to GPT-4, while the output token cost matches the previous generation. And the introduction of Mini and Nano tiers makes GPT-5 incredibly cost-effective for ultra-high-volume or highly cost-sensitive uses, with input and output costs dropping by up to 25 times relative to GPT-4.&lt;/p&gt;

&lt;p&gt;For individual users and small teams, subscription plan limits remain similar between versions, with both offering constrained free usage and paid options starting at $20 per month. That said, GPT-5’s higher response speed, improved reasoning, and lower hallucination rates add clear practical value, while enterprise users benefit most from the vastly cheaper and more granular pricing introduced with GPT-5’s new tiers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GPT-5 vs GPT-4: Security, Hallucinations, and Safety&lt;/strong&gt;&lt;br&gt;
GPT-5 reduces some hallucination classes compared to GPT-4, particularly around API usage and type errors, but it does not eliminate them. The model’s improved confidence calibration helps, yet you must still rely on tests, static analyzers, and linters. For security-sensitive code (auth, crypto, cryptographic protocols), treat outputs as draft proposals — never deploy without rigorous review. Organizations with compliance needs should audit the model’s outputs and establish guardrails.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Developer workflows that change&lt;/em&gt;&lt;br&gt;
Pair programming: GPT-5 works better as a real-time pair, making suggestions that fit the current codebase and catching more subtle mistakes.&lt;/p&gt;

&lt;p&gt;Code review: Use GPT-5 to generate first-draft PR descriptions, summarize diffs, and propose focused test cases. It accelerates reviewers by pointing out likely edge cases.&lt;/p&gt;

&lt;p&gt;Refactoring: Larger-scope refactors are easier because GPT-5 holds more context and reasons across files.&lt;/p&gt;

&lt;p&gt;Prototyping: Rapid prototypes and scaffolding are faster, but you’ll still hand-polish complex UIs.&lt;/p&gt;

&lt;p&gt;CI integration: Treat GPT-5 as an advisory check (generate tests, flag risky changes) rather than an authoritative gate; combine with existing test suites.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Reddit Perception&lt;/strong&gt;&lt;br&gt;
Reddit reactions are split and nuanced. Pockets of excitement celebrate GPT-5’s code review chops and PR summarization; others note that for complex product design, the model still needs tight prompts and lots of iteration. Some threads claim GPT-5 outperforms Anthropic’s Opus or Sonnet in certain tasks, while others show the opposite for specific workloads. A consistent theme: GPT-5 often speeds the mechanical parts of development, but product judgment and final architectural choices remain human.&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.amazonaws.com%2Fuploads%2Farticles%2Ffjpf9po1aib8cdnnksws.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.amazonaws.com%2Fuploads%2Farticles%2Ffjpf9po1aib8cdnnksws.png" alt=" " width="800" height="601"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;“Fast and good at fixing” — A user reporting strong bugfix and iteration performance but needing additional refinement.&lt;br&gt;
“Quality is spotty for UI” — frontend devs reporting skeletal outputs that require polishing.&lt;br&gt;
“Benchmarks show gains, but real projects vary” — devs pointing to SWE-bench and PR benchmarks yet cautioning about edge cases.&lt;br&gt;
Concrete examples: prompts and outcomes&lt;br&gt;
To make this less abstract, here are three real-world mini-scenarios where GPT-5 shows clear advantage over GPT-4.&lt;/p&gt;

&lt;p&gt;Cross-file bug trace: Give GPT-5 the failing test, the stack trace screenshot, and the two implicated files. GPT-5’s multimodal understanding and “thinking” variant can propose a focused patch that changes a handful of lines in the right file and proposes a unit test. GPT-4 would often require more back-and-forth to locate the root cause.&lt;br&gt;
PR summarization at scale: For a 500-line diff touching services and frontend components, GPT-5 generates a prioritized bullet list of functional changes, possible regressions, and suggested test cases—useful for busy reviewers. GPT-4 gave plausible summaries but tended to miss cross-service side effects more frequently.&lt;br&gt;
Generating integration tests: Feed GPT-5 a public API spec and corresponding DB migration. It can scaffold integration tests with setup/teardown and common failure cases. GPT-4 was capable but generated more brittle fixtures that needed human hardening.&lt;br&gt;
Prompt templates that work well&lt;br&gt;
Context first, ask second: start with the repo link (or pasted code), then the failing test or desired behavior, then the exact deliverable (“Write a pytest that demonstrates the bug and a minimal fix”).&lt;br&gt;
Limit scope: when requesting refactors, ask for changes only in specific modules to avoid sprawling edits.&lt;br&gt;
Safety net: always append “include unit tests and run with pytest; mark assumptions explicitly” to force testable output.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GPT-5 vs GPT-4 Cost-benefit Math&lt;/strong&gt;&lt;br&gt;
Assume a mid-sized team spends 4 engineer-hours/week on PR triage and repetitive slog. If GPT-5 saves 25% of that time, that’s 1 hour/week per engineer. Multiply by a 10-engineer team and a $60/hr fully-loaded cost, you save $600/week or roughly $31K/year. If GPT-5 costs an extra $2,000/month for API integrations and higher-tier variants, the net win is positive. Your mileage varies; do the pilot and instrument.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Human + AI roles&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Humans retain strategic authority: architecture, product decisions, security tradeoffs.&lt;/li&gt;
&lt;li&gt;AI handles routine cognitive load: boilerplate, tests, code comments.&lt;/li&gt;
&lt;li&gt;Humans enforce correctness: tests, manual review, and domain validation.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;GPT-5 vs GPT-4 Prompts to Try&lt;/strong&gt;&lt;br&gt;
Try these complex coding and general-purpose prompts to compare both models:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/chat/code-generation?query=Given+this+Python+function+that+calculates+the+nth+Fibonacci+number+using+recursion%2C+rewrite+it+using+memoization+and+explain+the+time+complexity+improvement" rel="noopener noreferrer"&gt;Given this Python function that calculates the nth Fibonacci number using recursion, rewrite it using memoization and explain the time complexity improvement.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/chat/code-generation?query=A+train+leaves+City+A+at+60+km/h+and+another+leaves+City+B+%28300+km+away%29+at+40+km/h+at+the+same+time+heading+toward+each+other%3B+calculate+when+and+where+they+meet" rel="noopener noreferrer"&gt;A train leaves City A at 60 km/h and another leaves City B (300 km away) at 40 km/h at the same time heading toward each other; calculate when and where they meet.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/chat/code-generation?query=Create+a+RESTful+API+in+Node.js+using+Express+that+allows+users+to+register%2C+log+in%2C+and+retrieve+their+profile+data+securely+with+JWT+authentication" rel="noopener noreferrer"&gt;Create a RESTful API in Node.js using Express that allows users to register, log in, and retrieve their profile data securely with JWT authentication.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/chat/code-generation?query=Given+a+CSV+of+daily+stock+prices%2C+write+a+Python+script+using+Pandas+and+Matplotlib+to+calculate+and+plot+the+7-day+moving+average%2C+then+highlight+the+days+with+the+highest+trading+volume" rel="noopener noreferrer"&gt;Given a CSV of daily stock prices, write a Python script using Pandas and Matplotlib to calculate and plot the 7-day moving average, then highlight the days with the highest trading volume.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/chat/code-generation?query=Explain+how+a+hash+table+works+internally+and+describe+a+scenario+where+using+a+hash+table+would+be+a+poor+choice+compared+to+a+binary+search+tree" rel="noopener noreferrer"&gt;Explain how a hash table works internally and describe a scenario where using a hash table would be a poor choice compared to a binary search tree.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/chat/code-generation?query=Write+a+Python+function+that+takes+a+paragraph+of+text%2C+extracts+all+named+entities+using+spaCy%2C+and+stores+them+in+a+normalized+SQL+database+schema" rel="noopener noreferrer"&gt;Write a Python function that takes a paragraph of text, extracts all named entities using spaCy, and stores them in a normalized SQL database schema.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;The Bottom Line&lt;/strong&gt;&lt;br&gt;
Upgrade if you: run large codebases, need better PR triage, frequently debug tricky cross-file bugs, or want the fastest gains in developer productivity and are prepared to pay more. &lt;/p&gt;

&lt;p&gt;Hold off if you: are a hobbyist, have very tight budgets, or your primary workload is pixel-perfect UI design where model outputs require heavy human polishing.&lt;/p&gt;

&lt;p&gt;Try a targeted pilot. Measure time saved and error rates. If GPT-5’s improvements map to your pain points—especially PR work, complex bug triage, and multi-file refactors—upgrade. If your needs are cheaper autocompletion or occasional brainstorming, &lt;a href="https://app.getbind.co/chat/bind-ai?model=advanced" rel="noopener noreferrer"&gt;GPT-4 still serves very well&lt;/a&gt;. &lt;/p&gt;

&lt;p&gt;And… if you’re wondering if it’s possible to use older (allegedly discontinued) OpenAI models, &lt;a href="https://app.getbind.co/chat/bind-ai?model=ultra" rel="noopener noreferrer"&gt;the answer is yes.&lt;/a&gt; You can try them on &lt;a href="https://app.getbind.co/chat/bind-ai?model=advanced" rel="noopener noreferrer"&gt;Bind AI here&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>openai</category>
      <category>coding</category>
      <category>chatgpt</category>
      <category>ai</category>
    </item>
    <item>
      <title>OpenAI ChatGPT Agent vs. Perplexity Comet: Is there a comparison?</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Thu, 24 Jul 2025 06:28:41 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/openai-chatgpt-agent-vs-perplexity-comet-is-there-a-comparison-16m7</link>
      <guid>https://dev.to/sushant_babbar/openai-chatgpt-agent-vs-perplexity-comet-is-there-a-comparison-16m7</guid>
      <description>&lt;p&gt;We can decisively say that AI in 2025 has shifted from mere conversation and search to the heart of action and workflow. &lt;a href="https://getbind.co/ide" rel="noopener noreferrer"&gt;AI-powered IDEs&lt;/a&gt;, autonomous AI agents, and more, you name it, and there’s an AI-powered solution for that. The recent ambitious projects driving this change are OpenAI’s ChatGPT Agent and Perplexity’s Comet. Both systems enhance user interaction significantly with agentic capabilities. AI will now not only answer questions but also autonomously complete tasks. That said, ChatGPT Agent and Comet differ dramatically in their design philosophy, architectures, and real-world applications. This ChatGPT Agent vs Perplexity Comet blog covers everything you need to know about them and how they compare to one another.&lt;/p&gt;

&lt;p&gt;Let’s get started.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What Is Agentic AI?&lt;/strong&gt;&lt;br&gt;
“Agentic AI” refers to AI endowed not just with reasoning or information-retrieval skills, but with automated action-taking: the ability to chain multi-step decisions, take consequences into account, and effect change in the digital world autonomously. For example, an AI agent might plan and book a trip, triage emails, manage reports, or even initiate financial transactions, all from a single instruction. Of course, it can get a lot more complicated than this based on what we’re talking about, but what’s described above serves as a decent base.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;OpenAI’s ChatGPT Agent: The Unified Research and Action Platform&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2F7k8e9vr3tu2hvz6pfwe8.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.amazonaws.com%2Fuploads%2Farticles%2F7k8e9vr3tu2hvz6pfwe8.png" alt=" " width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;ChatGPT Agent, &lt;a href="https://cdn.openai.com/pdf/839e66fc-602c-48bf-81d3-b21eacc3459d/chatgpt_agent_system_card.pdf" rel="noopener noreferrer"&gt;as described in OpenAI’s 2025 system card&lt;/a&gt;, is built atop the experience of three OpenAI product lines:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Deep Research – Multi-step, reference-backed research and report generation&lt;/li&gt;
&lt;li&gt;Operator – Visual browser automation and web interaction&lt;/li&gt;
&lt;li&gt;Terminal Tool – Sandboxed code execution with only limited network access&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These forces combine into a single “agent” entity capable of:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Automated browsing and form-filling&lt;/li&gt;
&lt;li&gt;Code execution and data analysis&lt;/li&gt;
&lt;li&gt;Slide, spreadsheet, and report generation&lt;/li&gt;
&lt;li&gt;Connecting to external data sources (Google Drive, APIs)&lt;/li&gt;
&lt;li&gt;Maintaining context across a conversation&lt;/li&gt;
&lt;li&gt;Multistep, tool-based workflows&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Agentic tasks are supervised by a unified interface in ChatGPT and governed by both immediate user input and a sophisticated confirmation system: every action deemed consequential (e.g., sending an email, finalizing a purchase) triggers a confirmation before execution, ensuring the user remains in ultimate control.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;How OpenAI’s Agent Thinks and Acts&lt;/em&gt;&lt;br&gt;
The key innovation with ChatGPT Agent isn’t just tool access but intelligent orchestration:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Dynamic tool selection: Agent uses different tools (browser, terminal, spreadsheet, code, connectors) based on context.&lt;/li&gt;
&lt;li&gt;Chain-of-thought planning: Tasks are decomposed into sub-steps and executed in series or parallel.&lt;/li&gt;
&lt;li&gt;Action narration: The agent describes its reasoning, current action, and lets the user observe or interrupt every step.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Safety, Security, and Trust&lt;/em&gt;&lt;br&gt;
OpenAI’s central design principle is preventing harm before it occurs—especially as agents gain access to more user data and online actions. Key mechanisms include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Safety Training: Specialized instruction to avoid harms from content generation, privacy breaches, or interacting with dangerous or sensitive web content.&lt;/li&gt;
&lt;li&gt;Automated Monitors and Filters: System-level fail-safes that can block inputs, outputs, and actions based on ongoing risk analysis or emerging attack patterns.&lt;/li&gt;
&lt;li&gt;User Confirmations: Before sending emails, transacting, or editing in sensitive contexts, the system demands explicit user permission.&lt;/li&gt;
&lt;li&gt;“Watch Mode”: In contexts requiring elevated sensitivity (e.g., banking, health records), the Agent pauses if the user stops supervising the process.&lt;/li&gt;
&lt;li&gt;Terminal Network Restrictions &amp;amp; Memory Isolation: Code execution is sandboxed; agent memory is disabled to prevent data exfiltration across sessions.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;OpenAI’s preparedness framework even applies biological and cybersecurity risks to its agents, activating “high capability” safeguards if a model could theoretically assist with severe risks, even if practical evidence is lacking.&lt;/p&gt;

&lt;p&gt;Besides, OpenAI offers the most transparent set of benchmarks published to date for its Agent:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Content Policy Compliance: Nearly perfect refusal rates (99%+) for disallowed content and privacy risks.&lt;/li&gt;
&lt;li&gt;Robustness to Jailbreaks: Cutting-edge resilience to adversarial prompts or “prompt injections.”&lt;/li&gt;
&lt;li&gt;Hallucination Rates: Slightly higher than recent GPT models on some factual QA sets, due in part to seeking multiple sources and surfacing ambiguities.&lt;/li&gt;
&lt;li&gt;User Confirmation Recall: 91%+ recall for requested confirmations before risky actions; 100% on the most critical actions (financial, editing permissions).&lt;/li&gt;
&lt;li&gt;Bias and Fairness: Net-bias metrics (gender, race, etc.) among the lowest ever measured, enhanced by stricter grading.&lt;/li&gt;
&lt;li&gt;Expert Evaluations: Independently tested for chemistry, biology, and cybersecurity risk, with an emphasis on never enabling “novice uplift” for high-stakes dangers.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;ChatGPT Agent Limitations&lt;/em&gt;&lt;br&gt;
OpenAI’s Agent is tightly coupled to the ChatGPT ecosystem, meaning:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Customization is limited to OpenAI-sanctioned APIs and connectors&lt;/li&gt;
&lt;li&gt;Workflow logic, though powerful, is constrained to available tools and chained prompt flows&lt;/li&gt;
&lt;li&gt;Some users report over-cautious refusals, prioritizing safety over flexibility (e.g., not answering disambiguated questions even when policy allows
).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Perplexity Comet: The Agentic Browser Reimagined&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fw4upvntk55c6cpebv6gp.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.amazonaws.com%2Fuploads%2Farticles%2Fw4upvntk55c6cpebv6gp.png" alt=" " width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Perplexity designed Comet from first principles as not just an assistant, but an AI-first browser. The hypothesis: if agency is all about context, why not put the agent where context originates—inside the browser?&lt;/p&gt;

&lt;p&gt;At its foundation, Comet combines:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Chromium Base: A full-featured browser—tabs, navigation, extensions, and bookmarks—providing compatibility for almost any workflow.&lt;/li&gt;
&lt;li&gt;Sidebar-based Comet Assistant: An integrated agent that sees everything you see. It can summarize, recommend, shop, fill forms, or multitask directly within any site or set of tabs.&lt;/li&gt;
&lt;li&gt;Real-Time Web Search: Perplexity’s answer engine cross-indexes the web in real time, integrating recent data and citations from across sources, including its proprietary model Sonar and external LLMs (GPT-4.5, Claude 4.0 Sonnet, etc.).&lt;/li&gt;
&lt;li&gt;Seamless Task Automation: Execute actions like scheduling, shopping, briefings, or knowledge extraction without ever leaving the browser, and without pasting information between windows.&lt;/li&gt;
&lt;li&gt;Personalized Memory: Comet learns user workflows, preferences, and frequently performed actions, organizing research and tasks proactively.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Architecture for Extensibility and Developer Control&lt;/em&gt;&lt;br&gt;
Comet stands out for its modular, chain-of-thought architecture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Prompt Chains: Each notebook-like “cell” performs a function—API call, web search, code execution, summary, etc.—and can be chained together for composable, multi-step workflows.&lt;/li&gt;
&lt;li&gt;Native API Support: Developers can integrate custom APIs and SQL data sources directly. Unlike OpenAI’s ecosystem, where tool access is limited to what OpenAI allows, Comet is geared for extensibility.&lt;/li&gt;
&lt;li&gt;Universal Context Window: The AI agent has continuous access to all open tabs, live data, and user actions, enabling contextual reasoning beyond traditional chat interfaces.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Perplexity Comet Use Cases in Practice&lt;/em&gt;&lt;br&gt;
Comet redefines what users can delegate to AI. Common examples include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Chart Analysis: Identify support/resistance zones on trading charts, with real-time annotation and direct execution in trading platforms or spreadsheets.&lt;/li&gt;
&lt;li&gt;Automated Email Unsubscription: Use natural language (“Unsubscribe me from any emails I ignored for three months”) and Comet acts across webmail autonomously.&lt;/li&gt;
&lt;li&gt;Travel Planning: From instruction (“Plan my Barcelona trip, €1,000 budget”) to final itinerary, all steps—search, compare, book—are handled inside the browser.&lt;/li&gt;
&lt;li&gt;Research Synthesis: Open a dozen tabs on a topic, and Comet will synthesize key points, generate decision summaries, and suggest next steps—cross-referencing live web data.&lt;/li&gt;
&lt;li&gt;In-tab Multi-modal Operation: Summarize YouTube tutorials while watching, link supporting docs, and even act on other tabs while video plays.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Perplexity Comet Safety and User Control&lt;/em&gt;&lt;br&gt;
Perplexity’s approach to safety and user oversight is practical and evolving:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Explicit Permissions: Users can grant or restrict access to sensitive workflows, such as shopping, form submissions, or email automation.&lt;/li&gt;
&lt;li&gt;Built-in Audit Trails: All agent actions can be reviewed in real time, and users can pause or revise automated suggestions before accepting.&lt;/li&gt;
&lt;li&gt;Context-Awareness and Learning: By maintaining a local model of a user’s active tasks, Comet can avoid repetitive automation or accidental data exposures—though edge cases (like unexpected email sends) have been reported.&lt;/li&gt;
&lt;li&gt;Privacy Positioning: As context and orchestration occur locally within the browser, minimal personal data leaves the user’s machine, compared to cloud-dependent agent frameworks.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Perplexity Comet Limitations&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Subscription Gating: As of July 2025, Comet is limited to Perplexity Max subscribers ($200/month) or early invitees. Wider access is promised but not yet delivered.&lt;/li&gt;
&lt;li&gt;Potential for Over-Automation: Handling multi-step actions in context-rich tabs can lead to unexpected outputs if instructions are ambiguous or if the system makes assumptions based on erroneous context.&lt;/li&gt;
&lt;li&gt;New Paradigm Steep Learning Curve: For many users, the fusion of browser and agent may initially feel less transparent, as automation blends with ordinary browsing, raising the stakes for missteps or neglected oversight.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;ChatGPT Agent vs Perplexity Comet: Comparative Analysis&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fav2h1uqabbwxxifvfl4k.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.amazonaws.com%2Fuploads%2Farticles%2Fav2h1uqabbwxxifvfl4k.png" alt=" " width="799" height="298"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To summarize: ChatGPT’s agent is integrated within its app, using a sandboxed browser for context, with extensibility primarily through OpenAI-bound APIs. In contrast, Perplexity Comet operates as a standalone browser, offering persistent, unified context across all tabs and extensive extensibility via API, SQL, and plugin support. While ChatGPT uses stepwise, confirmation-based workflows, Comet employs fluid, event-driven routines, catering to different user needs from internal task automation to power-user research and development.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ChatGPT Agent vs Perplexity Comet: Use-cases &amp;amp; Scenarios&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;OpenAI ChatGPT Agent&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Creating high-quality research reports with integrated data analysis, visualizations, and structured slides&lt;/li&gt;
&lt;li&gt;Automating customer support or helpdesk triage with strict workflow gating&lt;/li&gt;
&lt;li&gt;Executing sandboxed code or managing cloud-stored datasets securely&lt;/li&gt;
&lt;li&gt;Acting on “closed world” tasks within a corporate ecosystem where compliance, audit, and confirmations are essential&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Perplexity Comet&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Summarizing and prioritizing the content of 10 or more browser tabs in one action&lt;/li&gt;
&lt;li&gt;Managing end-to-end ecommerce routines: comparing, buying, tracking, and summarizing receipts, all within browser&lt;/li&gt;
&lt;li&gt;Implementing developer-driven workflows with API, SQL, or multi-app chaining&lt;/li&gt;
&lt;li&gt;Research requiring synthesis across real-time sources, up-to-the-minute news, and cross-platform web context&lt;/li&gt;
&lt;li&gt;Handling mixed media and multi-modal data (video, charts, web forms) with screen-driven actions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;The Bottom Line&lt;/strong&gt;&lt;br&gt;
OpenAI’s ChatGPT Agent and Perplexity’s Comet offer two different approaches to AI assistance. OpenAI provides a safe and controlled agent that focuses on reliability and compliance, good for users and teams who want to manage risks. Perplexity Comet, on the other hand, utilizes the internet to help users work more efficiently and access a wider range of information, making it easier to delegate tasks.&lt;/p&gt;

&lt;p&gt;Choosing between them isn’t about which one is better; it’s about which approach—keeping control or empowering users to delegate—fits your needs, how much risk you want to take, and the workflows you want to improve. The growth of AI agents is not just a technical development; it’s a major change in how people work with digital tools and the information that drives their curiosity and tasks.&lt;/p&gt;

</description>
      <category>openai</category>
      <category>webdev</category>
      <category>ai</category>
    </item>
    <item>
      <title>Perplexity Labs vs ChatGPT - Which Is Better in 2025?</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Sat, 07 Jun 2025 05:50:41 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/perplexity-labs-vs-chatgpt-which-is-better-in-2025-4p0h</link>
      <guid>https://dev.to/sushant_babbar/perplexity-labs-vs-chatgpt-which-is-better-in-2025-4p0h</guid>
      <description>&lt;p&gt;Perplexity’s recent addition of ‘Perplexity Labs’ to its interface is quite interesting. Perplexity Labs goes a step further than the regular Perplexity ‘Search’ and &lt;a href="https://blog.getbind.co/2025/02/16/is-deep-research-useful-comparing-gemini-vs-chatgpt-vs-perplexity/" rel="noopener noreferrer"&gt;‘Research’ modes&lt;/a&gt; by creating entire projects with multiple components. Labs have access to advanced tools for generating files, presentations, images, mini-apps, and other interactive elements not available in Research mode. Interesting stuff, but the purpose of this article is to compare this new, updated Perplexity with ChatGPT. We focus on their respective features, strengths, weaknesses, and use cases to help you decide which tool best aligns with their goals.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is Perplexity Labs?&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fzyijtwp8j7ivern4ihv1.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.amazonaws.com%2Fuploads%2Farticles%2Fzyijtwp8j7ivern4ihv1.png" alt=" " width="800" height="290"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Perplexity Labs is a premium feature of Perplexity AI. It uses LLMs to deliver accurate, cited answers based on real-time web data. Launched on May 29, 2025, Perplexity Labs is available to Pro subscribers ($20/month) and lets users create complex projects like reports, spreadsheets, dashboards, and simple web applications. It uses tools such as deep web browsing, code execution, and chart creation to automate tasks that would typically take hours or days.&lt;/p&gt;

&lt;p&gt;TL;DR: it’s Perplexity’s answer to ChatGPT’s coding capabilities and Gemini’s Canvas feature.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Key Features of Perplexity Labs&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Project Creation: Generates reports, spreadsheets, dashboards, and web apps with minimal user input.&lt;/li&gt;
&lt;li&gt;Research and Analysis: Conducts extensive web research, providing cited, reliable outputs.&lt;/li&gt;
&lt;li&gt;Time Efficiency: Completes complex tasks in 10 minutes or more, saving significant manual effort.&lt;/li&gt;
&lt;li&gt;Model Diversity: Pro subscribers can choose from advanced models like GPT-4o, Claude 3.7 Sonnet (try it here), and others.&lt;/li&gt;
&lt;li&gt;Specialized Tools: Includes finance features (e.g., real-time stock quotes) and a shopping hub launched in November 2024.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Perplexity AI also offers a free version for basic searches and Deep Research for in-depth analysis, available to all users with limited queries for non-subscribers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ChatGPT in 2025&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fa1fw39inqzbcg0p8lgp5.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.amazonaws.com%2Fuploads%2Farticles%2Fa1fw39inqzbcg0p8lgp5.png" alt=" " width="800" height="359"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Known for its versatility and originality, ChatGPT handles dialogue, content generation, coding, and more. In 2025, it introduced advanced &lt;a href="https://blog.getbind.co/2025/04/15/gpt-4-1-comparison-with-claude-3-7-sonnet-and-gemini-2-5-pro/" rel="noopener noreferrer"&gt;models like GPT-4.1 and GPT-4.1 mini&lt;/a&gt;, enhancing coding and instruction-following capabilities. It also added deep research connectors for services like Dropbox and GitHub, making it a robust tool for various applications.&lt;/p&gt;

&lt;p&gt;In 2025, ChatGPT is just as good as it was in 2023 when it went viral, except with many added features for enhancing the experience even further.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Key Features of ChatGPT&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Conversational Versatility: Engages in dialogue, answers questions, and generates creative content.&lt;/li&gt;
&lt;li&gt;Advanced Models: GPT-4.1 (May 2025) excels in coding and problem-solving; GPT-4.1 mini replaces GPT-4o mini for efficiency.&lt;/li&gt;
&lt;li&gt;Deep Research Enhancements: Connectors for Dropbox, GitHub, Sharepoint, and OneDrive enable comprehensive research.&lt;/li&gt;
&lt;li&gt;Memory Features: Improved context retention for personalized responses.&lt;/li&gt;
&lt;li&gt;Image Library: Automatically saves generated images for easy access (April 2025).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;ChatGPT operates on a freemium model, with a free tier offering basic functionality and paid plans (Plus ($20/month), Pro($200/month), and Team) unlocking advanced features.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Perplexity Labs vs ChatGPT: Feature Comparison&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fnoybzdqva5um0bdze5yc.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.amazonaws.com%2Fuploads%2Farticles%2Fnoybzdqva5um0bdze5yc.png" alt=" " width="800" height="649"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;1. Core Functionality&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Perplexity Labs: Excels in delivering accurate, cited answers from web searches, ideal for users needing verifiable information. Its focus on research and project creation makes it a go-to for professional settings.&lt;/li&gt;
&lt;li&gt;ChatGPT: Offers a conversational interface for a wide range of tasks, from answering questions to generating creative content. It may not always provide citations, which could be a drawback for research-heavy tasks.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;2. Project Creation&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Perplexity Labs: Designed to automate complex project creation, such as generating a market analysis report or a financial dashboard with minimal input. It organizes outputs like charts and code files for easy access.&lt;/li&gt;
&lt;li&gt;ChatGPT: Can assist in project creation (e.g., writing code or drafting reports) but requires more user direction. It’s less streamlined for structured outputs compared to Perplexity Labs.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;3. Model Access and Performance&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Perplexity Labs: Pro users can select from various advanced models, offering flexibility for specific tasks. This diversity enhances its adaptability for different industries.&lt;/li&gt;
&lt;li&gt;ChatGPT: Relies on OpenAI’s models, with GPT-4.1 providing superior performance in coding and problem-solving. However, it lacks the model variety of Perplexity AI.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;4. User Experience&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Perplexity Labs: Provides a structured, research-oriented experience with citations, making it ideal for academic or business use where accuracy is critical.&lt;/li&gt;
&lt;li&gt;ChatGPT: Offers an interactive, conversational experience, better suited for brainstorming, creative writing, or casual queries.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;5. Specialized Features&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Perplexity Labs: Includes niche tools like real-time stock quotes, internal knowledge search for enterprise users, and a shopping hub, catering to specific industries.&lt;/li&gt;
&lt;li&gt;ChatGPT: Features like memory retention, deep research connectors, and an image library enhance its versatility across tasks, from education to content creation.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;6. Pricing and Accessibility&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Perplexity Labs: Requires a Pro subscription for full access, limiting its advanced features to paying users. The free version is restricted to basic searches.&lt;/li&gt;
&lt;li&gt;ChatGPT: Offers a robust free tier, with paid plans unlocking advanced models and features, making it more accessible for casual users.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Perplexity Labs vs ChatGPT: Use Cases&lt;/strong&gt;&lt;br&gt;
Perplexity Labs&lt;br&gt;
Business Research: Creating detailed market research reports or competitive analyses with cited sources.&lt;br&gt;
Project Management: Generating dashboards and spreadsheets to track key performance indicators (KPIs) or project progress.&lt;br&gt;
Web Development: Building simple web applications with automated code execution.&lt;br&gt;
ChatGPT&lt;br&gt;
Content Creation: Writing articles, blog posts, or social media content with creative flair.&lt;br&gt;
Education: Assisting with homework, explaining complex concepts, or generating study materials.&lt;br&gt;
Customer Support: Handling frequently asked questions or providing initial support responses.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Perplexity Labs vs ChatGPT: Strengths and Weaknesses&lt;/strong&gt;&lt;br&gt;
Perplexity Labs&lt;br&gt;
Strengths:&lt;br&gt;
Exceptional for research-heavy tasks requiring citations.&lt;br&gt;
Automates complex project creation, saving significant time.&lt;br&gt;
Offers specialized tools for finance and shopping.&lt;br&gt;
Weaknesses:&lt;br&gt;
Advanced features locked behind a paywall.&lt;br&gt;
Less versatile for creative or conversational tasks.&lt;br&gt;
ChatGPT&lt;br&gt;
Strengths:&lt;br&gt;
Highly versatile for a wide range of tasks, from coding to creative writing.&lt;br&gt;
Continuous updates with advanced models like GPT-4.1.&lt;br&gt;
Free tier accessible for basic use.&lt;br&gt;
Weaknesses:&lt;br&gt;
May not always provide citations, potentially affecting reliability for research.&lt;br&gt;
Requires more user input for complex project creation.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Do Your Testing&lt;/strong&gt;&lt;br&gt;
Try these prompts with both Perplexity and ChatGPT to see how they perform:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Build+a+Twitter+clone+with+a+responsive+timeline,+tweet+composition+box,+like+and+retweet+functionality,+and+user+profiles.+Include+a+dark+mode+toggle.&amp;amp;demoPromptId=PROMPT-20250326122828&amp;amp;thread=new" rel="noopener noreferrer"&gt;Build a Twitter clone with a responsive timeline, tweet composition box, like and retweet functionality, and user profiles. Include a dark mode toggle.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Build+a+Spotify-like+music+streaming+web+app+with+a+responsive+sidebar+navigation,+featured+playlists+section,+music+player+with+controls,+and+the+ability+to+create+and+save+playlists.+Include+a+search+function+for+finding+tracks+and+artists.&amp;amp;demoPromptId=PROMPT-20250327082553%20%20%20%20&amp;amp;thread=new" rel="noopener noreferrer"&gt;Build a Spotify-like music streaming web app with a responsive sidebar navigation, featured playlists section, music player with controls, and the ability to create and save playlists. Include a search function for finding tracks and artists.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Build+an+Instagram-inspired+photo+sharing+app+with+a+responsive+grid+layout+for+photos,+like+and+comment+functionality,+user+profiles,+and+a+photo+upload+feature.+Include+story+circles+at+the+top+and+an+explore+page.&amp;amp;demoPromptId=PROMPT-20250327071154&amp;amp;thread=new" rel="noopener noreferrer"&gt;Build an Instagram-inspired photo sharing app with a responsive grid layout for photos, like and comment functionality, user profiles, and a photo upload feature. Include story circles at the top and an explore page.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;The Bottom Line&lt;/strong&gt;&lt;br&gt;
Perplexity Labs and ChatGPT are powerful AI tools with different strengths. Perplexity Labs is ideal for research-driven tasks and accurate, cited outputs, while ChatGPT excels in creative and conversational contexts. Your choice depends on whether you need structured reliability (Perplexity Labs) or flexibility (ChatGPT). Both platforms are evolving to enhance AI interactions and serve diverse needs. That said, if coding is your focus, consider dedicated options like &lt;a href="https://www.getbind.co/ide" rel="noopener noreferrer"&gt;Bind AI IDE&lt;/a&gt; for more advanced solutions. Based on Claude 4, Bind AI IDE lets you create custom Front-end and Back-end applications and deploy them directly.&lt;/p&gt;

&lt;p&gt;So, if that’s something your business wants, get &lt;a href="https://app.getbind.co/ide?thread=new" rel="noopener noreferrer"&gt;Bind today&lt;/a&gt;!&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>ai</category>
      <category>programming</category>
      <category>chatgpt</category>
    </item>
    <item>
      <title>Claude 4 vs Claude 3.7 Sonnet vs Gemini 2.5 Pro Coding Comparison</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Fri, 23 May 2025 11:45:34 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/claude-4-vs-claude-37-sonnet-vs-gemini-25-pro-coding-comparison-59ap</link>
      <guid>https://dev.to/sushant_babbar/claude-4-vs-claude-37-sonnet-vs-gemini-25-pro-coding-comparison-59ap</guid>
      <description>&lt;p&gt;In one of the major AI announcements of the year, Anthropic has officially released Claude 4, bringing Claude Opus 4 and Claude Sonnet 4 to everyone. The news is noteworthy, but we have a different agenda. Today’s models can handle entire development workflows, from architectural planning to complex debugging. But with Anthropic’s new Claude 4 series, the established &lt;a href="https://app.getbind.co/chat/bind-ai?model=ultra" rel="noopener noreferrer"&gt;Claude 3.7 Sonnet&lt;/a&gt;, and Google’s &lt;a href="https://blog.getbind.co/2025/05/22/is-gemini-diffusion-better-than-chatgpt-heres-what-we-know/" rel="noopener noreferrer"&gt;Gemini 2.5 Pro&lt;/a&gt; all claiming coding supremacy, which one &lt;em&gt;actually&lt;/em&gt; performs the best? Which one’s the fastest? Which one offers the most efficient pricing?&lt;/p&gt;

&lt;p&gt;After analyzing benchmarks, developer feedback, and practical considerations, here’s what you need to know. Here’s a detailed Claude 4 vs. Claude 3.7 Sonnet vs. Gemini 2.5 Pro coding comparison.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Claude 4 vs Claude 3.7 Sonnet vs Gemini 2.5 Pro – Overview&lt;/strong&gt;&lt;br&gt;
Claude Opus 4 is Anthropic’s new flagship model. It’s designed for complex, multi-step engineering tasks that traditionally take days to complete. Think large-scale refactoring, architectural changes, and autonomous coding workflows.&lt;/p&gt;

&lt;p&gt;Claude Sonnet 4 is the practical workhorse—upgraded capabilities at the same price as its predecessor, optimized for everyday development tasks like code reviews and bug fixes.&lt;/p&gt;

&lt;p&gt;Claude 3.7 Sonnet pioneered the “thinking mode” approach in February 2025. While superseded, it’s still capable and often praised for code reliability and design sense.&lt;/p&gt;

&lt;p&gt;Gemini 2.5 Pro is Google’s answer, featuring a massive 1-million-token context window and true multimodal capabilities. It can process text, images, audio, and video simultaneously—imagine debugging by showing it error screenshots or generating code from UI mockups.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Claude 4 vs Claude 3.7 Sonnet vs Gemini 2.5 Pro Performance: Where Each Model Shines&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;Real-World Software Engineering&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.amazonaws.com%2Fuploads%2Farticles%2F5goh64ol4slcsrxm31pm.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.amazonaws.com%2Fuploads%2Farticles%2F5goh64ol4slcsrxm31pm.png" alt=" " width="800" height="480"&gt;&lt;/a&gt;&lt;br&gt;
Anthropic&lt;/p&gt;

&lt;p&gt;On SWE-bench (solving actual GitHub issues), Claude 4 models dominate:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Claude Opus 4: 72.5%&lt;/li&gt;
&lt;li&gt;Claude Sonnet 4: 72.7%&lt;/li&gt;
&lt;li&gt;Claude 3.7 Sonnet: 70.3%&lt;/li&gt;
&lt;li&gt;Gemini 2.5 Pro: 63.2%&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This isn’t just academic—it means Claude 4 models are genuinely better at understanding complex codebases and implementing fixes that actually work.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Algorithmic and Mathematical Coding&lt;/em&gt;&lt;br&gt;
Gemini 2.5 Pro takes the lead here:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AIME 2024 (advanced math): Gemini 92%, Claude 3.7 80%&lt;/li&gt;
&lt;li&gt;LiveCodeBench (competitive programming): Gemini 75.6%&lt;/li&gt;
&lt;li&gt;Creative PyTorch coding: Gemini leads&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you’re doing data science, algorithm development, or mathematical simulations, Gemini has a clear edge.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;UI and Frontend Development&lt;/em&gt;&lt;br&gt;
User experiences reveal interesting patterns. Developers consistently praise &lt;a href="https://apidog.com/blog/claude-3-7-sonnet-vs-gemini-2-5-pro/" rel="noopener noreferrer"&gt;Gemini 2.5 Pro&lt;/a&gt; as the “new UI king,” noting it “nailed the UI design almost perfectly” when matching reference images. One developer observed that Claude is “very good at visuals, front-end making things look really pretty, adding animations,” while Gemini is “substantially better at underlying code and making things more functional.”&lt;/p&gt;

&lt;p&gt;Claude 3.7 Sonnet gets mixed reviews—praised for “sophisticated frontends with remarkable design quality” but criticized for stumbling on details like colors and missing input boxes. Claude 4 will likely address these issues and give users the best Claude coding experience to date.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The Game-Changing Differences&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;Context: Size Matters&lt;/em&gt;&lt;br&gt;
This is where Gemini 2.5 Pro becomes genuinely transformative. Its 1-million-token context window (expanding to 2 million) means you can feed it entire codebases—around 30,000 lines—in a single conversation.&lt;/p&gt;

&lt;p&gt;Claude models are limited to 200K tokens. That’s still substantial, but for massive enterprise codebases, Gemini’s context window eliminates the need for chunking code or complex workarounds.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Multimodal Magic&lt;/em&gt;&lt;br&gt;
Gemini 2.5 Pro’s native multimodality isn’t just a feature—it’s a workflow revolution. You can:&lt;/p&gt;

&lt;p&gt;Debug by uploading error screenshots&lt;br&gt;
Generate code from architectural diagrams&lt;br&gt;
Analyze UI mockups alongside requirements&lt;br&gt;
Get insights from video walkthroughs&lt;br&gt;
Claude models handle text and images well, but Gemini’s true multimodal understanding feels more natural and comprehensive.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Thinking vs. Speed&lt;/em&gt;&lt;br&gt;
All models now feature “thinking” modes—they pause to reason through complex problems rather than immediately generating responses. But there are differences:&lt;/p&gt;

&lt;p&gt;Claude’s “extended thinking” can be controlled with “thinking budgets,” letting you balance speed vs. depth. Claude Opus 4 scored an impressive 98.43% on graduate-level physics reasoning.&lt;/p&gt;

&lt;p&gt;Gemini 2.5 Pro’s experimental “Deep Think” mode considers multiple hypotheses before responding. Developers consistently praise its speed, with “very quick” responses enabling “rapid iterative cycles.”&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Claude 4 vs Claude 3.7 Sonnet vs Gemini 2.5 Pro – Real Developer Experiences&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;Code Quality and Reliability&lt;/em&gt;&lt;br&gt;
Early reviews noted that Claude Opus 4 is the “first model that boosts code quality during editing and debugging… without sacrificing performance or reliability.” Cursor describes it as “state-of-the-art for coding and a leap forward in complex codebase understanding.”&lt;/p&gt;

&lt;p&gt;However, one developer reported Claude 4 “still went into his own vibe and did everything except what was told in the prompt,”—suggesting it sometimes needs more precise guidance.&lt;/p&gt;

&lt;p&gt;Claude 3.7 Sonnet gets praised for “complete production-grade code with genuine design taste” but criticized as an “extremely creative try hard that happens to have an over-engineering problem.”&lt;/p&gt;

&lt;p&gt;Gemini 2.5 Pro is described as having “fewer bugs in the code” but being “TOO defensive coding at times.”&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Speed and Iteration&lt;/em&gt;&lt;br&gt;
Gemini 2.5 Pro consistently wins on speed. Developers love its quick responses for rapid debugging cycles. One user noted it rewrote 180,000 tokens of code in about 75 seconds of thinking time.&lt;/p&gt;

&lt;p&gt;Claude models offer both instant responses and deep thinking modes, but Claude 3.7 Sonnet is notably slower at 75.3 tokens per second with higher latency.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Integration and Ecosystem&lt;/em&gt;&lt;br&gt;
Platform Availability&lt;br&gt;
Claude models integrate with GitHub Copilot, VS Code, JetBrains, and Amazon Bedrock. Claude Code offers a dedicated terminal tool with GitHub Actions integration.&lt;/p&gt;

&lt;p&gt;Gemini 2.5 Pro deeply integrates with Google Cloud, Vertex AI, BigQuery ML, Android Studio, and the full Google ecosystem.&lt;/p&gt;

&lt;p&gt;Your existing tech stack might determine your choice. Heavy Google Cloud users will find Gemini seamless. GitHub-centric teams might prefer Claude’s direct integrations.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;API Pricing Models&lt;/em&gt;&lt;br&gt;
Claude Opus 4 Pricing&lt;br&gt;
The pricing for Claude Opus 4 is $15 per million input tokens and $75 per million output tokens. Anthropic offers potential cost savings of up to 90% with prompt caching and 50% with batch processing.&lt;/p&gt;

&lt;p&gt;Claude Sonnet 4 &amp;amp; Claude 3.7 Sonnet Pricing&lt;br&gt;
Both Claude Sonnet 4 and Claude 3.7 Sonnet share the same pricing structure: $3 per million input tokens and $15 per million output tokens. Similar to Opus 4, they also offer up to 90% cost savings with prompt caching and 50% with batch processing.&lt;/p&gt;

&lt;p&gt;Gemini 2.5 Pro Pricing&lt;br&gt;
Gemini 2.5 Pro employs a tiered pricing model based on token count:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Input: $1.25 per million tokens for prompts up to 200,000 tokens, and $2.50 per million tokens for prompts exceeding 200,000 tokens.&lt;/li&gt;
&lt;li&gt;Output (including thinking tokens): $10.00 per million tokens for prompts up to 200,000 tokens, and $15.00 per million tokens for prompts exceeding 200,000 tokens. Notably, there is no additional charge for “thinking” tokens.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Claude 4 vs Claude 3.7 Sonnet vs Gemini 2.5 Pro – Features &amp;amp; Cost Comparison Table&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Here’s a snapshot of the main features and pricing details of each model;&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.amazonaws.com%2Fuploads%2Farticles%2Fxse52j2n2q6hml0w0m2n.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.amazonaws.com%2Fuploads%2Farticles%2Fxse52j2n2q6hml0w0m2n.png" alt=" " width="800" height="364"&gt;&lt;/a&gt;&lt;br&gt;
Bind AI&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Try These Coding Prompts&lt;/strong&gt;&lt;br&gt;
Try Claude 4 models and others, &lt;a href="https://app.getbind.co/chat/bind-ai?model=ultra" rel="noopener noreferrer"&gt;such as Claude 3.7 Sonnet and Gemini 2.5 Pro&lt;/a&gt;, here to see how they perform in these coding tasks:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://copilot.getbind.co/chat/code-generation?query=Write+a+Python+script+that+integrates+a+machine+learning+model+for+sentiment+analysis+with+a+Flask+API%2C+allowing+users+to+submit+text+and+receive+predictions+via+a+POST+request" rel="noopener noreferrer"&gt;Write a Python script that integrates a machine learning model for sentiment analysis with a Flask API, allowing users to submit text and receive predictions via a POST request.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://copilot.getbind.co/chat/code-generation?query=Create+a+responsive+webpage+layout+using+Flexbox+that+displays+three+cards+in+a+row+on+a+desktop+and+stacks+them+vertically+on+mobile%2C+including+hover+effects+and+smooth+transitions" rel="noopener noreferrer"&gt;Create a responsive webpage layout using Flexbox that displays three cards in a row on a desktop and stacks them vertically on mobile, including hover effects and smooth transitions.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://copilot.getbind.co/chat/code-generation?query=Write+a+JavaScript+function+that+takes+a+string+of+text+and+returns+the+longest+substring+without+repeating+characters%2C+using+the+sliding+window+technique" rel="noopener noreferrer"&gt;Write a JavaScript function that takes a string of text and returns the longest substring without repeating characters, using the sliding window technique.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://copilot.getbind.co/chat/code-generation?query=Design+an+SQL+query+that+returns+the+top+5+most+frequent+products+sold+in+the+last+30+days%2C+considering+data+from+%27orders%27+and+%27products%27+tables+with+a+join+operation" rel="noopener noreferrer"&gt;Design an SQL query that returns the top 5 most frequent products sold in the last 30 days, considering data from ‘orders’ and ‘products’ tables with a join operation.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://copilot.getbind.co/chat/code-generation?query=Create+a+React+component+that+fetches+and+displays+a+list+of+users+from+an+API%2C+and+allows+for+search+filtering+by+username+or+email%2C+with+the+results+updating+live" rel="noopener noreferrer"&gt;Create a React component that fetches and displays a list of users from an API, and allows for search filtering by username or email, with the results updating live.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://copilot.getbind.co/chat/code-generation?query=Write+a+Python+script+that+calls+a+public+weather+API%2C+parses+the+JSON+response%2C+and+prints+the+current+temperature+and+forecast+for+the+next+7+days+in+a+user-friendly+format" rel="noopener noreferrer"&gt;Write a Python script that calls a public weather API, parses the JSON response, and prints the current temperature and forecast for the next 7 days in a user-friendly format.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;The Bottom Line&lt;/strong&gt;&lt;br&gt;
Claude 4, particularly Sonnet 4, appears to be the best for coding due to its superior SWE-bench scores (72.7% without extended thinking, 80.2% with high compute). Opus 4 is nearly as good (72.5%, 79.4%) and excels in long-running tasks. Gemini 2.5 Pro, with a 63.8% SWE-bench score, is a strong contender, especially for large codebases, due to its 1-million-token context window and lower cost ($1.25/$10 per million tokens). Claude 3.7 Sonnet, at 62.3%, is solid but outdated compared to newer models.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bind AI’s Recommendation:&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Choose Claude 4 for top coding performance. Sonnet 4 is cost-effective for general tasks, while Opus 4 suits complex, sustained projects.&lt;/li&gt;
&lt;li&gt;Choose Gemini 2.5 Pro for large codebases or budget constraints, offering great value and versatility. [&lt;a href="https://app.getbind.co/chat/bind-ai?model=ultra" rel="noopener noreferrer"&gt;Try here&lt;/a&gt;]&lt;/li&gt;
&lt;li&gt;Consider Claude 3.7 Sonnet only if you’re already using it and can’t upgrade yet. [&lt;a href="https://app.getbind.co/chat/bind-ai?model=ultra" rel="noopener noreferrer"&gt;Try here&lt;/a&gt;]&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Your choice depends on project needs, budget, and whether you prioritize raw performance or large-scale processing.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>coding</category>
      <category>ai</category>
      <category>programming</category>
    </item>
    <item>
      <title>Bolt.new Alternatives: Which AI App Builder is Right for You?</title>
      <dc:creator>Sushant Babbar</dc:creator>
      <pubDate>Wed, 30 Apr 2025 13:01:10 +0000</pubDate>
      <link>https://dev.to/sushant_babbar/boltnew-alternatives-which-ai-app-builder-is-right-for-you-3bmf</link>
      <guid>https://dev.to/sushant_babbar/boltnew-alternatives-which-ai-app-builder-is-right-for-you-3bmf</guid>
      <description>&lt;p&gt;Bolt.new is &lt;a href="https://blog.getbind.co/2025/03/14/best-ai-ides-full-stack-development-2025/" rel="noopener noreferrer"&gt;one of the best AI coding IDEs in 2025&lt;/a&gt;. It stands out for its compelling feature set and capabilities that make AI code generation easier and more accessible than ever. That said, alternatives are plenty. Many options can help you develop web applications with ease. But which one is the best Bolt.new alternative? Let’s find that out in this detailed blog.&lt;/p&gt;

&lt;p&gt;Here, we compare Bolt.new with &lt;a href="https://www.getbind.co/ide" rel="noopener noreferrer"&gt;Bind AI IDE&lt;/a&gt; for their AI code generation and full-stack development capabilities, integrations, code editing functionality, and web deployment features to see which AI assistant stands tall as the best AI code generation platform. Let’s start with a basic overview of each.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Bolt.new Overview – An advanced coding assistant for web development&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fj9u20f47zrlndd6lchu5.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.amazonaws.com%2Fuploads%2Farticles%2Fj9u20f47zrlndd6lchu5.png" alt=" " width="800" height="360"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Bolt is StackBlitz’s AI coding assistant—specifically designed for coding web applications and other web development tasks. It’s a great coding assistant for building and deploying full-stack web applications directly within a browser environment. Besides, it’s also fairly effective for generating basic boilerplate code snippets. For more complex tasks, Bolt(.new) supports popular frameworks like React and Vue and offers features such as running Node.js servers and installing npm packages.&lt;/p&gt;

&lt;p&gt;Overall, Bolt makes a solid case for itself and stands out.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bolt.new Available Models&lt;/em&gt;&lt;br&gt;
Bolt(.new) hasn’t disclosed what models it uses for generating outputs. Rest assured, the quality is there. However, the lack of options might be a downside to some.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bolt.new Pricing&lt;/em&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fbwrp3s2uhdzgvmkvc11d.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.amazonaws.com%2Fuploads%2Farticles%2Fbwrp3s2uhdzgvmkvc11d.png" alt=" " width="798" height="240"&gt;&lt;/a&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.amazonaws.com%2Fuploads%2Farticles%2Fqo2be0toutlwwi0bs3d3.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.amazonaws.com%2Fuploads%2Farticles%2Fqo2be0toutlwwi0bs3d3.png" alt=" " width="800" height="307"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Bolt does something interesting when it comes to its pricing. For its paid plans, it only offers a ‘Pro’ plan, but that pro plan comes in variants. There’s the regular Pro with 10M tokens at $20/month, Pro 50 with 26M tokens at $50/month, Pro 100 with 55M tokens at $100/month, and finally the Pro 200 with 120M tokens at $200/month.&lt;/p&gt;

&lt;p&gt;There are also various ‘Team’ plans, as you can see in the above screenshot.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Best Bolt.new Alternative: Bind AI IDE – ideal for code-generation in multiple languages (JavaScript, Python, C#)&lt;/strong&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fo4oeyuje7tpcawd0vbnj.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.amazonaws.com%2Fuploads%2Farticles%2Fo4oeyuje7tpcawd0vbnj.png" alt=" " width="800" height="443"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Bind AI IDE is designed for beginners, junior developers, and experts. Featuring many advanced models such as &lt;a href="https://app.getbind.co/chat/bind-ai?model=ultra" rel="noopener noreferrer"&gt;Claude 3.7 Sonnet&lt;/a&gt;, OpenAI o3-mini, DeepSeek R1, and more, it offers the best possible options in the LLM department. But besides the models, there’s much more that makes Bind AI stand out. It offers advanced integrations such as GitHub (native), the ability to run and test code instantly, and custom GPT agents for those who want specific functionalities.&lt;/p&gt;

&lt;p&gt;Plus, everything is presented in a clean user interface with minimum clutter, and you also get support tickets for any queries. So, whether you’re a game designer, bug fixer, or web app developer, Bind AI has something to offer. Here’s a &lt;a href="https://www.youtube.com/watch?v=mJ-1TXcTD5w" rel="noopener noreferrer"&gt;video demo showing how to build front-end applications with Bind AI&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bind AI IDE Available Models&lt;/em&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Frikwek9m5qmbuuza82t4.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.amazonaws.com%2Fuploads%2Farticles%2Frikwek9m5qmbuuza82t4.png" alt=" " width="800" height="500"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Bind AI offers numerous models—premium and freemium—new and old. Claude 3.7 Sonnet and 3.5 Sonnet, GPT-4o and o3-mini, DeepSeek R1, Gemini 2.5 Flash, Qwen 2.5, to name a few.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bind AI IDE Pricing&lt;/em&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fau1dkbcx0yguzli4rg01.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.amazonaws.com%2Fuploads%2Farticles%2Fau1dkbcx0yguzli4rg01.png" alt=" " width="799" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Besides the free tier, Bind AI gives you a Premium and Scale plan with extended features and queries. You can get the Premium plan at $18/month, and the Scale plan, which features 3x the limits for advanced and ultra models, multiple GitHub repos, and unlimited custom GPTs at $39/month.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Bind AI IDE vs Bolt.new: Web Application Case Study&lt;/strong&gt;&lt;br&gt;
We compared Bind AI IDE and Bolt(.new) for creating a fully functional web chess, using the same prompt. While the results were slightly different, one wasn’t necessarily better than the other.&lt;/p&gt;

&lt;p&gt;This is the prompt we used: &lt;a href="https://copilot.getbind.co/chat/code-generation?query=Generate+an+interactive+chess+game+where+the+user+plays+as+White+and+the+CPU+plays+as+Black.+The+CPU+should+use+an+advanced+strategy%2C+evaluating+moves+based+on+common+chess+AI+techniques+like+minimax+or+alpha-beta+pruning%2C+to+make+intelligent+decisions.+Each+move+should+be+presented+in+standard+algebraic+notation%2C+and+after+the+user%27s+move%2C+the+CPU+should+respond+with+its+best+calculated+move.+The+game+should+continue+until+a+checkmate%2C+stalemate%2C+or+draw+is+reached%2C+with+the+final+result+clearly+displayed+at+the+end+of+the+game" rel="noopener noreferrer"&gt;Generate an interactive chess game where the user plays as White and the CPU plays as Black. The CPU should use an advanced strategy, evaluating moves based on common chess AI techniques like minimax or alpha-beta pruning, to make intelligent decisions. Each move should be presented in standard algebraic notation, and after the user’s move, the CPU should respond with its best calculated move. The game should continue until a checkmate, stalemate, or draw is reached, with the final result clearly displayed at the end of the game.&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bind AI’s result:&lt;/em&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2F24lni6s8tytnzdxm3744.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.amazonaws.com%2Fuploads%2Farticles%2F24lni6s8tytnzdxm3744.png" alt=" " width="800" height="370"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Bind AI produced a functional chess game that adhered closely to the prompt’s requirements. Visually, the interface presented a more traditional or classic chess board appearance. The focus was clearly on delivering the core game logic and interaction as specified, resulting in a straightforward and usable application.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Bolt.new’s result:&lt;/em&gt;&lt;br&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.amazonaws.com%2Fuploads%2Farticles%2Fnxjwy7nhc4xse6sz7f9v.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.amazonaws.com%2Fuploads%2Farticles%2Fnxjwy7nhc4xse6sz7f9v.png" alt=" " width="800" height="382"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Bolt(.new) also successfully generated the interactive chess game with the requested AI opponent. However, its output featured a distinctly more modern aesthetic. The user interface elements, board design, and overall presentation felt more contemporary and visually polished compared to the Bind AI version.&lt;/p&gt;

&lt;p&gt;Both Bind AI IDE and Bolt(.new) showed they were up to the task of generating a complex web application – in this case, a chess game with an AI opponent – from a single, detailed prompt. While both successfully delivered the essential functionality, Bolt(.new’s) result felt more refined and visually modern. But it’s not a big difference, all things considered, and would take one more prompt to change the look of it. Deployment, however, is where Bolt(.new) offers a real edge.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Test Examples&lt;/strong&gt;&lt;br&gt;
Here are some prompts you can try to test both Bind AI and Bolt(.new):&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Build+a+Twitter+clone+with+a+responsive+timeline,+tweet+composition+box,+like+and+retweet+functionality,+and+user+profiles.+Include+a+dark+mode+toggle.&amp;amp;demoPromptId=PROMPT-20250326122828&amp;amp;thread=new" rel="noopener noreferrer"&gt;Build a Twitter clone with a responsive timeline, tweet composition box, like and retweet functionality, and user profiles. Include a dark mode toggle.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Create+an+Airbnb-style+property+rental+website+with+a+visual+property+grid,+search+functionality+with+filters+for+dates,+location,+and+price.+Include+property+detail+pages+with+booking+calendar+and+review+system.&amp;amp;demoPromptId=PROMPT-20250326134719&amp;amp;thread=new" rel="noopener noreferrer"&gt;Create an Airbnb-style property rental website with a visual property grid, search functionality with filters for dates, location, and price. Include property detail pages with booking calendar and review system.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Build+a+Spotify-like+music+streaming+web+app+with+a+responsive+sidebar+navigation,+featured+playlists+section,+music+player+with+controls,+and+the+ability+to+create+and+save+playlists.+Include+a+search+function+for+finding+tracks+and+artists.&amp;amp;demoPromptId=PROMPT-20250327082553%20%20%20%20&amp;amp;thread=new" rel="noopener noreferrer"&gt;Build a Spotify-like music streaming web app with a responsive sidebar navigation, featured playlists section, music player with controls, and the ability to create and save playlists. Include a search function for finding tracks and artists.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Build+an+Instagram-inspired+photo+sharing+app+with+a+responsive+grid+layout+for+photos,+like+and+comment+functionality,+user+profiles,+and+a+photo+upload+feature.+Include+story+circles+at+the+top+and+an+explore+page.&amp;amp;demoPromptId=PROMPT-20250327071154&amp;amp;thread=new" rel="noopener noreferrer"&gt;Build an Instagram-inspired photo sharing app with a responsive grid layout for photos, like and comment functionality, user profiles, and a photo upload feature. Include story circles at the top and an explore page.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://app.getbind.co/ide?query=Create+a+Trello-style+kanban+board+with+draggable+task+cards,+multiple+columns+for+different+stages+(To+Do,+In+Progress,+Done),+card+creation+with+titles+and+descriptions,+and+the+ability+to+add+labels+and+due+dates+to+cards.&amp;amp;demoPromptId=PROMPT-20250327070252&amp;amp;thread=new" rel="noopener noreferrer"&gt;Create a Trello-style kanban board with draggable task cards, multiple columns for different stages (To Do, In Progress, Done), card creation with titles and descriptions, and the ability to add labels and due dates to cards.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;The Bottom Line&lt;/strong&gt;&lt;br&gt;
When considering alternatives to Bolt.new, Bind AI is an impressive option, offering code generation across 72 programming languages. Its seamless integration into development environments enhances efficiency, allowing for quick code generation and troubleshooting.&lt;/p&gt;

&lt;p&gt;Bind AI also provides a versatile toolkit for diverse programming tasks, making it ideal for developers seeking a robust AI code generator. In contrast, Bolt.new simplifies web development, enabling users to build full-stack applications in the browser without coding experience. Ultimately, the choice depends on whether you need an all-around code generator or a specialized web development assistant.&lt;/p&gt;

&lt;p&gt;Try &lt;a href="https://www.getbind.co/ide" rel="noopener noreferrer"&gt;Bind AI IDE&lt;/a&gt; now.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>ai</category>
      <category>programming</category>
      <category>coding</category>
    </item>
  </channel>
</rss>
