<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Timothy on Medium]]></title>
        <description><![CDATA[Stories by Timothy on Medium]]></description>
        <link>https://medium.com/@timtech4u?source=rss-c6aa82026e26------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*nwqaZQmP3mjqo3RBumd8rA.jpeg</url>
            <title>Stories by Timothy on Medium</title>
            <link>https://medium.com/@timtech4u?source=rss-c6aa82026e26------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 16 Nov 2026 01:34:33 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@timtech4u/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[ADK Agent on Cloud Run]]></title>
            <link>https://timtech4u.medium.com/adk-agent-on-cloud-run-db7430c1f410?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/db7430c1f410</guid>
            <category><![CDATA[ai-agent]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <category><![CDATA[google-maps]]></category>
            <category><![CDATA[bigquery]]></category>
            <category><![CDATA[google-cloud-run]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Mon, 28 Sep 2026 09:38:10 GMT</pubDate>
            <atom:updated>2026-09-28T09:38:10.069Z</atom:updated>
            <content:encoded><![CDATA[<p>What “production-ready” actually meant for one small AI agent: a private service, a locked-down key, a guard on my data bill, and one line in the token count I did not see coming.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KKPbIs1WLgJ4gch3DYPlcQ.png" /></figure><p>Most agent demos end the moment the agent gives a good answer. That is exactly where the interesting part starts for me. Who is allowed to call it? Which keys does it hold? What happens to my bill if the model decides to scan a whole table? What breaks when six people ask at once?</p><p>Earlier this year I set out to build a production-minded agent with Google’s <a href="https://adk.dev/?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">Agent Development Kit (ADK)</a>, running on Cloud Run and connected to BigQuery and Google Maps, and then writing up what it really took, including the numbers. This is that write-up. Everything below comes from a real deployment I ran on 28 September 2026, and the full code is in a GitHub gist (link at the end).</p><h3>Meet Dock Scout</h3><p>I wanted a question that needs both <strong>history</strong> and <strong>the real world right now</strong>. London’s cycle hire scheme is perfect for that. BigQuery has a free public dataset with <strong>83 million bike hires</strong>, and Google Maps knows where you are standing, how long the walk is, and whether it is about to rain.</p><p>So Dock Scout answers questions like this:</p><blockquote>“I’m at King’s Cross station at 8am on a weekday. Which nearby dock usually has bikes leaving, how long is the walk, and do I need a jacket?”</blockquote><p>To answer, it has to find King’s Cross on a map, work out which docks are within a few hundred metres, look up how busy those docks usually are at 8am on weekdays, get a walking time, and check the weather. That is five steps across three services, and the agent decides the order itself.</p><h3>How it works, in plain words</h3><p>An ADK agent is three things: a <strong>model</strong> (I used Gemini 3.7 Flash), a set of <strong>tools</strong> it may call, and <strong>instructions</strong> that tell it how to behave. The model reads the question, picks a tool, looks at the result, and repeats until it can answer.</p><p>The tools come from <strong>MCP</strong> (Model Context Protocol), a standard way to plug tools into an agent. The nice surprise is that Google now runs MCP servers for you. There is one for <a href="https://cloud.google.com/bigquery/docs/use-bigquery-mcp?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">BigQuery</a> and one for Google Maps called <a href="https://developers.google.com/maps/ai/grounding-lite?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">Maps Grounding Lite</a> (places, walking routes and weather). I didn’t write or host a single tool server. My agent just points at two URLs.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pnmpAsmt3LPsIOkQrx29XQ.png" /></figure><p><em>Dock Scout on Cloud Run. Everything in the blue box scales to zero, and every arrow is authenticated.</em></p><p>This is roughly all it takes to give the agent Google Maps:</p><pre>maps_mcp = McpToolset(<br>    connection_params=StreamableHTTPConnectionParams(url=&quot;https://mapstools.googleapis.com/mcp&quot;),<br>    tool_filter=[&quot;search_places&quot;, &quot;compute_routes&quot;, &quot;lookup_weather&quot;],<br>    header_provider=lambda _: {&quot;X-Goog-Api-Key&quot;: os.environ[&quot;MAPS_API_KEY&quot;]},<br>)</pre><p>BigQuery looks almost the same, except it doesn’t use a key at all. It uses the identity of the service the agent runs as, and I only let it use one tool, execute_sql_readonly, so it can read but never change anything.</p><h3>The first thing that broke: I could read the data, but not copy it</h3><p>My plan was sensible. The raw bike table is about 10 GB and isn’t partitioned, so any question that touches it scans a couple of gigabytes. I’d summarise it once into a tiny table (“average departures per dock, per hour, weekday vs weekend”) and let the agent query that for pennies.</p><p>BigQuery said no.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BAmfwFOv0_QSbl5Tx5fXfw.png" /></figure><p><em>Reading the public dataset works. Copying query results into my own table is denied.</em></p><p>Reading the public data is fine. Saving results from it into a table in my own project is not. So the agent has to query the raw table, and a typical question scans 1.3 to 2.7 GB.</p><p>That turned a “nice to have” into a must-have: a <strong>cost guard</strong>. ADK lets you run your own code right before any tool call (a <a href="https://adk.dev/callbacks/?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">callback</a>). Mine does a free BigQuery “dry run” of every query the model writes and checks three things:</p><ul><li><strong>Who pays.</strong> It overwrites the billing project, so the model can never bill a query to someone else.</li><li><strong>What it touches.</strong> Only the London bicycles dataset is allowed.</li><li><strong>How big it is.</strong> Anything that would scan more than 3 GB is refused, and the model is told to use fewer columns.</li></ul><p>When a query is refused, the model gets a plain message back telling it to use fewer columns, so it can try again. Across my test runs the guard waved through 40 queries averaging 1.75 GB each. None hit the limit, which is exactly how a guard should look on a normal day.</p><h3>Locking it down</h3><p>This is the part demos skip. Here is what I actually set up:</p><p><strong>Its own identity with only the roles it needs.</strong> The agent runs as a dedicated service account with seven narrow roles: call Gemini, run BigQuery jobs, use Google’s MCP servers, and write logs, metrics and traces. Notice what is missing: no permission to read BigQuery datasets. Public datasets are readable by anyone signed in, so it didn’t need one.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nADwey3ZZsmjRxEk3zv7kA.png" /></figure><p><em>The runtime service account’s roles. Nothing project-wide beyond what it uses.</em></p><p><strong>A Maps key that can only do one thing.</strong> I created a new API key that can call Maps Grounding Lite and nothing else. It lives in Secret Manager, only the agent’s service account can read that secret, and Cloud Run hands it to the container as an environment variable. It isn’t in the code or the image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CpaKdMWXMhOEueT8epaCOA.png" /></figure><p><em>The key is restricted to one API, and only one identity can read the secret.</em></p><p><strong>A private front door.</strong> The Cloud Run service needs a Google identity token. Without one you get a 403 before my code even runs.</p><p><strong>Scale to zero.</strong> Minimum instances is 0, so when nobody is asking questions, nothing is running and nothing is billed. Maximum is 3, which also caps how much damage a runaway client could do.</p><p>Before deploying, I ran the agent on my own machine while <strong>impersonating that same service account</strong>. If a role was missing, I’d find out there rather than in production. It worked first time with just those seven roles:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hsa4LUnkV-TMglVpebMPUg.png" /></figure><p><em>A local run as the Cloud Run service account. The JSON lines are my own logs: tokens per model call, time per tool call, and bytes scanned.</em></p><p>Deploying is one Cloud Build and one gcloud run deploy. The flags carry most of the production decisions:</p><pre>gcloud run deploy adk-dock-scout --image &quot;$IMAGE&quot; --region europe-west1 \<br>  --service-account adk-dock-scout@$PROJECT_ID.iam.gserviceaccount.com \<br>  --no-allow-unauthenticated --min-instances 0 --max-instances 3 \<br>  --set-secrets MAPS_API_KEY=adk-maps-api-key:latest</pre><p>One small thing that cost me ten confused minutes: I gave the service a /healthz endpoint, and it always returned Google&#39;s 404 page. Cloud Run <a href="https://cloud.google.com/run/docs/known-issues?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">reserves URL paths ending in &quot;z&quot;</a>, so the request never reached my container. It&#39;s /health now.</p><p>Here’s the deployed service answering a question. No token: 403. With my token: a real answer, built from five tool calls, in about half a minute.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eQgesQ87aPDMCHxqMhH8HA.png" /></figure><p><em>The smoke test from the gist, run against the live Cloud Run URL. The agent found nearby docks with Maps, pulled Tuesday-morning demand from BigQuery, checked two walking routes and the weather, then credited Google Maps as its source.</em></p><h3>The surprise in the bill</h3><p>With everything deployed I ran a small load test: six different London questions, two at a time. Every answer was good. Then I looked at the numbers.</p><p>Each question was using about <strong>200,000 prompt tokens</strong> and costing about <strong>9 cents</strong> in Gemini alone. My instructions are only 658 tokens. Something else was filling the prompt.</p><p>So I counted, tool by tool, using Gemini’s token-counting API:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZHE1oISIixnbcHmMkVbc2w.png" /></figure><p><em>What each tool adds to every single model call, with and without its output schema.</em></p><p>Every MCP tool comes with a description of its inputs <strong>and</strong> a description of its outputs. ADK passes both to Gemini on every model call, and a question takes four or five calls. The BigQuery table-info tool alone added <strong>18,603 tokens</strong>, almost all of it the description of what it returns, and the agent never even called that tool.</p><p>The model only needs the inputs to call a tool. It sees the real output when the tool answers. So I added a second small callback that strips the output descriptions before each model call:</p><pre>def before_model(callback_context, llm_request):<br>    for tool in llm_request.config.tools or []:<br>        for fd in tool.function_declarations or []:<br>            fd.response_json_schema = None   # the model only needs the inputs</pre><p>I also dropped the table-info tool, since the table layout is already in the instructions. Same six questions, same service:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hewWuGcckSzPaehQeYdTQw.png" /></figure><p><em>Before: about 200k prompt tokens and $0.089 per question. After: about 45k tokens and $0.028.</em></p><p><strong>78% fewer prompt tokens, 69% cheaper per question</strong>, answers just as good, and a little faster too. If you build agents on MCP servers, count your tool tokens. It was the single biggest cost lever in this whole project, and it took five lines.</p><h3>When six people ask at once</h3><p>Next, a burst: twelve questions, six at a time. Two of them failed with an HTTP 500. The logs showed why: Gemini returned 429 RESOURCE_EXHAUSTED. On pay-as-you-go, Gemini runs on shared capacity, and short bursts can get pushed back.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Y4RC9ODO473iCjwy51p1pQ.png" /></figure><p><em>Top: no retries, 10 of 12 succeed. Bottom: with retries, 12 of 12, but slower.</em></p><p>The fix is to retry with a growing, slightly random wait, and ADK lets you set that on the model. After that, 12 out of 12 succeeded. The honest trade-off: the middle answer went from about 26 to 40 seconds, and the slowest took 72. Retries buy reliability, not speed. For steady heavy traffic, the real answer is <a href="https://cloud.google.com/vertex-ai/generative-ai/docs/error-code-429?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">reserved capacity</a>.</p><h3>Where the time goes</h3><p>Because ADK can send OpenTelemetry traces to Cloud Trace, I could see exactly where one request spent its time:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hf2n0527wY9mppgCcSO4IQ.png" /></figure><p><em>One request, summed by type. Almost all of it is the model.</em></p><p>About 95% of the time is Gemini thinking and writing. The Maps and BigQuery calls took between 0.04 and 1.2 seconds each. So if you want a faster agent, fewer model round trips will do more than faster tools. The trace also showed ADK re-fetching the tool list before every model call, so I switched on its tool-list cache.</p><h3>What it costs</h3><p>These are the numbers from my runs, using current list prices:</p><p>Per question:</p><ul><li>Gemini 3.7 Flash (after the fix): about $0.028</li><li>BigQuery (about 1.75 GB scanned): about $0.011, or free within the monthly free TB</li><li>Maps Grounding Lite (about 4 calls): free up to 10,000 calls a month, then $7 per 1,000</li><li>Cloud Run: a fraction of a cent, and $0 when idle</li></ul><p>So roughly <strong>4 cents a question</strong>, and nothing at all when nobody is using it. The whole build, including about 50 agent runs, the load tests and five deployments, came to roughly <strong>$2 to $3</strong>. One thing to plan for: Gemini 3.7 Flash is on <a href="https://cloud.google.com/gemini-enterprise-agent-platform/generative-ai/pricing?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">introductory pricing</a> until 31 December 2026, and the per-token price doubles after that.</p><h3>What I’d add before real users</h3><ul><li><strong>Memory across instances.</strong> Dock Scout keeps conversations in memory, which is fine for one-shot questions. For real multi-turn chat, store sessions in a managed session service or a database.</li><li><strong>A budget alert</strong> on the billing account, so a surprise shows up as an email and not an invoice.</li><li><strong>A proper front door</strong> (your app’s backend, API Gateway or IAP) instead of handing out identity tokens.</li><li><strong>An evaluation set.</strong> My six load-test questions should become an automated test so a prompt tweak can’t quietly make answers worse.</li><li><strong>Maps attribution in the UI.</strong> Grounding Lite requires Google Maps sources next to the answer. The agent already ends with a “Sources: Google Maps” line; a real app should show those links properly.</li></ul><h3>What I learned</h3><ul><li>Managed MCP servers make connecting an agent to BigQuery and Maps almost boring, in a good way. The hard parts are the same as for any service: identity, secrets, cost and failure.</li><li>Don’t trust the demo’s bill. Measure tokens per question on day one; mine were 80% tool descriptions.</li><li>Put guard-rails in code, not only in the prompt. The prompt asks the model to be careful; the callback makes sure.</li><li>Scale to zero plus a small max-instances is a great default for agents: cheap when idle, capped when busy.</li></ul><p>The code, deployment scripts, load test and a step-by-step README are in this GitHub gist: <a href="https://gist.github.com/Timtech4u/0d9df5e786b607d01291210e73467160"><strong>https://gist.github.com/Timtech4u/0d9df5e786b607d01291210e73467160</strong></a>. It deploys into your own project in about ten minutes, and there’s a teardown script for when you’re done.</p><p>If you build something with it, or find a bigger cost lever than the one I found, tell me. I’d love to see it.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=db7430c1f410" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My Agents Live Remotely]]></title>
            <link>https://timtech4u.medium.com/my-agents-live-remotely-a2f543b5f1ba?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/a2f543b5f1ba</guid>
            <category><![CDATA[remote-work]]></category>
            <category><![CDATA[gemini]]></category>
            <category><![CDATA[developer-tools]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <category><![CDATA[ai-agent]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Mon, 28 Sep 2026 09:22:57 GMT</pubDate>
            <atom:updated>2026-09-28T09:22:57.566Z</atom:updated>
            <content:encoded><![CDATA[<p>Gemini CLI on a small Google Cloud VM (and Codex and OpenClaw on another box), driven from my Mac over SSH and tmux.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FSgh1RpNno575fQ94LXsXA.png" /></figure><p>I like coding agents a lot more when they don’t live on my laptop. A long task keeps going when I close the lid. The heavy lifting happens on a machine that isn’t my Mac. And I can come back to the exact same session later, from wherever I am.</p><p>Last night I set this up with <strong>Codex CLI</strong> and <strong>OpenClaw</strong> on a Linux box, reached from my Mac over Tailscale SSH. It worked so well that this morning I did the same thing the Google way: <strong>Gemini CLI</strong> on a small <strong>Compute Engine</strong> VM, signed in to <strong>Vertex AI</strong> with the VM’s own service account, and reached through <strong>Identity-Aware Proxy (IAP)</strong>. No API key on the box, no SSH port open to the internet, and the whole thing costs pennies because I stop the VM when I’m done.</p><p>This post covers both, Google side first, and the parts that didn’t work the first time.</p><h3>The pattern</h3><p>The recipe is the same whichever agent you use:</p><ol><li><strong>A Linux box that stays on</strong> while you work, and costs little or nothing when you don’t.</li><li><strong>The agent CLI installed on that box</strong>, signed in without leaving long-lived keys around.</li><li><strong>A private way in.</strong> No public SSH port. I use Google’s IAP for the Gemini box and Tailscale SSH for the Codex box.</li><li><strong>tmux</strong>, so a session keeps running when my laptop sleeps or Wi-Fi drops.</li><li><strong>A way to stop paying</strong> when the box is idle.</li></ol><pre>My Mac<br> │<br> ├─ ssh gemini-box ── IAP ────────────▶ gemini-box (Google Cloud)<br> │                                       tmux → Gemini CLI → Vertex AI<br> │<br> └─ ssh grok-box ──── Tailscale SSH ──▶ grok-box (VM behind NAT)<br>                                         tmux → Codex CLI + OpenClaw</pre><p>The Mac is just the steering wheel. The boxes do the work.</p><h3>Part 1: Gemini CLI on Google Cloud</h3><p><a href="https://geminicli.com/docs/?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">Gemini CLI</a> is Google’s open-source coding agent for the terminal. It reads your code, edits files and runs commands, and it asks before it does anything risky. It’s a single npm package (@google/gemini-cli), which makes it easy to put on a server.</p><h3>A small VM, close to home</h3><p>I didn’t need anything big, because the model runs on Google’s side, not on the VM. The VM only runs the CLI, Node, git and my code. I went with an <strong>e2-medium</strong> (2 shared vCPUs, 4 GB RAM) on <strong>Debian 13</strong>, in <strong>africa-south1</strong> (Johannesburg), the closest Google Cloud region to me in Kigali, so typing in the terminal feels snappy.</p><p>Everything got the prefix gemini-box and a label purpose=gde-remote-box, so I can find (and clean up) all of it later.</p><p>Three things matter more than the machine size:</p><ul><li><strong>Its own service account</strong> (gemini-box-sa) with just one role: <strong>Vertex AI User</strong>. That&#39;s what lets Gemini CLI call Gemini on Vertex AI without any key file. More on that below.</li><li><strong>Its own little network</strong> with one firewall rule: SSH is only allowed from Google’s IAP range (35.235.240.0/20). Nothing else gets in.</li><li><strong>A label</strong>, so I can see exactly what I created.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1oKiUpPNhLv2EkJn-j5ekQ.png" /></figure><p><em>Creating the service account, the VM and the IAP-only firewall rule from my Mac with </em><em>gcloud (commands tidied up; the OS Login metadata is explained in the gotchas). The VM gets an ephemeral public IP only so it can reach npm and apt; nothing is allowed in on it.</em></p><h3>Getting in without opening a port</h3><p>On Google Cloud, the neat equivalent of Tailscale SSH is <a href="https://cloud.google.com/iap/docs/using-tcp-forwarding?utm_campaign=deveco_gdemembers&amp;utm_source=deveco"><strong>IAP TCP forwarding</strong></a>. gcloud opens a tunnel through Google, checks my Google identity and IAM permissions, and only then forwards me to port 22 on the VM. The VM&#39;s port 22 never talks to the open internet.</p><pre>gcloud compute ssh gemini-box --zone africa-south1-a --tunnel-through-iap</pre><p>I checked both sides: a direct connection to the VM’s public IP on port 22 gets no answer, while the IAP route works.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bkdGqvahjLV7whzmFXwMXg.png" /></figure><p><em>Port 22 doesn’t answer from the internet. </em><em>gcloud compute ssh --tunnel-through-iap gets in anyway, and on first use it adds my SSH key to the VM for me.</em></p><p>I don’t want to type that gcloud line every time, so I added a normal SSH alias on my Mac that uses IAP under the hood. After that it&#39;s just ssh gemini-box, like any other server, and tmux works exactly as you&#39;d expect:</p><pre>Host gemini-box<br>  User tim<br>  IdentityFile ~/.ssh/google_compute_engine<br>  ProxyCommand gcloud compute start-iap-tunnel %n 22 --listen-on-stdin --zone=africa-south1-a --verbosity=error<br>  ServerAliveInterval 30</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-_BP6lXQ3BP1mJyzVlubpQ.png" /></figure><p><em>My SSH alias, then the tmux flow: </em><em>tmux new -As gemini attaches to the session if it exists and creates it if it doesn&#39;t. I detach, log out, and the session is still there when I come back.</em></p><p>tmux new -As gemini is the one command I actually remember. I run Gemini CLI inside it, close the laptop, and later I ssh gemini-box and run the same command to land right back where I was.</p><h3>Installing Gemini CLI</h3><p>Gemini CLI needs Node.js 20 or newer. I used the official Node 24 LTS tarball (checked against its published checksums), same as on my Codex box, and then:</p><pre>sudo npm install -g @google/gemini-cli@latest</pre><p>That gave me Gemini CLI 0.61.0 on Node v24.21.0, plus tmux 3.5a from apt.</p><h3>Signing in with no API key</h3><p>This was the part I cared about most. There are a few ways to authenticate Gemini CLI: sign in with a Google account, a Gemini API key from AI Studio, or Vertex AI. On a VM, the cleanest option is <strong>Vertex AI with the VM’s service account</strong>.</p><p>A Compute Engine VM can get short-lived Google credentials for its attached service account from the <strong>metadata server</strong>. Gemini CLI uses those automatically (the <a href="https://geminicli.com/docs/get-started/authentication/?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">authentication docs</a> call this out). So there’s no key file, no GOOGLE_API_KEY and nothing secret in my dotfiles. My project doesn&#39;t even allow service account keys to be created, and with this setup I didn&#39;t need one.</p><p>All Gemini CLI needs is three settings in ~/.gemini/.env:</p><pre>GOOGLE_GENAI_USE_VERTEXAI=true<br>GOOGLE_CLOUD_PROJECT=&lt;your-project-id&gt;<br>GOOGLE_CLOUD_LOCATION=global</pre><p>I used global for the location, so I don&#39;t have to pick a region for the Gemini models (<a href="https://cloud.google.com/vertex-ai/generative-ai/docs/learn/locations?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">Vertex AI locations</a>). The first time I started gemini, it asked how I wanted to authenticate. I picked <strong>Vertex AI</strong>, and it saved that choice to ~/.gemini/settings.json.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qnrpT5iXrRYcAWn9IWC0iw.png" /></figure><p><em>The whole auth setup: three lines in </em><em>~/.gemini/.env, &quot;vertex-ai&quot; in settings, the VM&#39;s service account from the metadata server, and zero API-key variables in the environment.</em></p><h3>A real task, on the VM, from my Mac</h3><p>With that done, I asked Gemini CLI inside my tmux session to do something small but real: write a script that reports on the machine it’s running on, including the Compute Engine zone and machine type from the metadata server, then run it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*O-3ZlRFjACkSrc_rdnkkhg.png" /></figure><p><em>Gemini CLI writes </em><em>vm_report.py, waits for me to approve the file write and the shell command, then runs it on the VM: gemini-box, Debian 13, e2-medium in africa-south1-a. Condensed; the ⋮ marks lines I cut.</em></p><p>I like that it asks before writing files or running commands. I approved each step once, but there’s also “Allow for this session” when you trust what it’s doing.</p><p>/about confirms how it&#39;s signed in, and /model shows what &quot;Auto&quot; means here: Gemini CLI routes between <strong>gemini-3.1-pro-preview</strong> for harder work and <strong>gemini-3.8-flash</strong> for quicker tasks. In my session, the actual work ran on gemini-3.8-flash, with a small flash-lite model doing the routing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dmwq-cpfe-n598SBnH4_XA.png" /></figure><p><em>Auth method vertex-ai, and Auto model routing between gemini-3.1-pro-preview and gemini-3.8-flash.</em></p><h3>Headless mode, for scripts</h3><p>The same CLI runs without the interactive screen when you pass -p, and -o json gives you output you can parse. This is Gemini CLI&#39;s version of codex exec, and it&#39;s handy for small jobs you want to kick off from a script or over SSH.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kh7nDan_wGjK57jm5wUmOw.png" /></figure><p><em>gemini -p … -o json: Gemini read </em><em>vm_report.py with one tool call and explained where the zone comes from. The JSON also lists the models it used.</em></p><h3>Stop it when you’re done</h3><p>A running e2-medium in Johannesburg is about 4 US cents an hour (<a href="https://cloud.google.com/compute/vm-instance-pricing?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">pricing</a>). A stopped one costs nothing for compute. You only pay for the 20 GB disk, which is a couple of dollars a month, and the ephemeral public IP goes away until the next start. So when I’m done, I <a href="https://cloud.google.com/compute/docs/instances/stop-start-instance?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">stop it</a> rather than delete it:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*as_Z1QenPKUaWDhKZmA9ew.png" /></figure><p><em>gcloud compute instances stop. The VM keeps its disk, its setup and my files. </em><em>gcloud compute instances start brings it back, and because I go in through IAP, the new public IP after a restart doesn&#39;t matter.</em></p><p>The whole build and test this morning, about 20 minutes of VM time plus a handful of Gemini requests, came to cents. One thing to know: stopping the VM ends the tmux session too. After a start, I ssh gemini-box, run tmux new -As gemini, and start gemini again. Gemini CLI can resume earlier chats with --resume.</p><h3>Part 2: The same pattern with Codex CLI and OpenClaw</h3><p>The night before, I’d built the first version of this on a different kind of machine: a Debian 13 box with a <strong>private IP behind NAT</strong>, <strong>no inbound path at all</strong>, <strong>no sshd</strong> and <strong>no systemd</strong>. On that box I wanted <strong>Codex CLI</strong> and <strong>OpenClaw</strong>, billed to my <strong>ChatGPT Team</strong> plan instead of an API key. Here’s the short version.</p><h3>Getting in: Tailscale SSH</h3><p>With no inbound path, IAP-style tunnels weren’t an option, so I used <strong>Tailscale</strong>, which only makes outbound connections. I ran tailscaled in userspace networking mode (no systemd needed, and it doesn&#39;t touch the box&#39;s routing) and turned on <strong>Tailscale SSH</strong> with tailscale up --ssh. That means no sshd and no authorized_keys: my tailnet identity is the login. After I approved the node in my browser, grok-box showed up next to my Mac.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QU29s6flji87sjzfQ41TVw.png" /></figure><p><em>grok-box and my Mac on the same tailnet.</em></p><p>From there it’s exactly the same flow as on Google Cloud: ssh grok-box, tmux new -As codex, codex.</p><h3>Signing in: device code, on a subscription</h3><p>For Codex, codex login --device-auth is perfect on a headless box. It prints a short code, I approve it on my Mac, and the box is signed in to my ChatGPT account. One lesson: the box started out signed in to an old <strong>Free</strong> account, which in Codex tops out at gpt-6-luna. On my <strong>Team</strong> plan, gpt-6-astra is available, and that&#39;s what I set as the default.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dHgZ1xzKJtzrZxSHuJRPEA.png" /></figure><p><em>codex exec on gpt-6-astra, running real commands on grok-box, billed to my ChatGPT Team plan.</em></p><p><strong>OpenClaw</strong> didn’t need a second login. Its Codex harness can reuse the Codex sign-in on the same box, so both tools run on the one subscription.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IS7bGBAwMGh5P0fFXrStbA.png" /></figure><p><em>An OpenClaw agent turn answered by gpt-6-astra through the Codex harness.</em></p><p>There’s more to that box: the Codex Desktop app on my Mac connecting to it over SSH, a Codex app-server locked down with a capability token, and a tiny script that keeps everything running without systemd. The short version is that the pattern held up. Private way in, agent signed in on the box, tmux to keep it alive.</p><h3>Side by side</h3><p>Gemini boxCodex / OpenClaw boxWhereCompute Engine e2-medium, africa-south1Linux VM behind NATHow I get inssh gemini-box through IAP (Google identity)ssh grok-box through Tailscale SSH (tailnet identity)Open inbound portsOnly 22, and only from IAPNoneAgent sign-inVertex AI via the VM&#39;s service accountChatGPT device-code loginKeys on diskNoneNo API key (the ChatGPT login lives in ~/.codex)BillingVertex AI usage on my Google Cloud projectMy ChatGPT Team planWhen idleStopped: disk onlyAlways on</p><h3>Gotchas I hit</h3><ol><li><strong>OS Login wanted an org-level role.</strong> My project sits under an organization that my Google account isn’t part of, so OS Login refused to register my SSH key (“You must be granted the roles/compute.osLoginExternalUser IAM role on the external organization”). Instead of touching organization IAM, I turned OS Login off for this one VM and let gcloud put my key in the VM&#39;s own metadata (enable-oslogin=FALSE, block-project-ssh-keys=TRUE), so it doesn&#39;t spread to other VMs in the project. If you control your org, <a href="https://cloud.google.com/compute/docs/oslogin?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">OS Login</a> is the nicer long-term option.</li><li><strong>~/.gemini/.env is ignored until you trust the folder.</strong> My first headless run said &quot;Please set an Auth method…&quot; even though the .env was there. Gemini CLI has <a href="https://geminicli.com/docs/cli/trusted-folders/?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">trusted folders</a>, and it won&#39;t load settings from ~/.gemini/.env for a folder you haven&#39;t trusted yet. I started gemini interactively once in ~/work, chose &quot;Trust folder&quot;, and after that both interactive and headless runs worked.</li><li><strong>The build box had no SSH client.</strong> gcloud compute ssh just says &quot;Your platform does not support SSH&quot; until ssh is installed.</li><li><strong>gemini wasn&#39;t on the PATH over plain </strong><strong>ssh gemini-box &#39;…&#39;.</strong> Node lives in /opt/node/bin, which I add in /etc/profile.d, and that only runs for login shells. Interactive SSH and tmux are fine. For one-off commands, use bash -lc &#39;…&#39;.</li><li><strong>Stopping the VM ends tmux.</strong> Of course it does, but it’s easy to forget when you’re used to an always-on box. Start the VM, reattach, and use gemini --resume to pick up the chat.</li><li><strong>On the Codex box:</strong> Codex’s model list depends on your ChatGPT plan (Free can’t use Astra), codex exec waits on stdin unless you add `</li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a2f543b5f1ba" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[One Table, Two Engines]]></title>
            <link>https://timtech4u.medium.com/one-table-two-engines-ddfe40051f08?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/ddfe40051f08</guid>
            <category><![CDATA[apache-iceberg]]></category>
            <category><![CDATA[bigquery]]></category>
            <category><![CDATA[data-engineering]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <category><![CDATA[apache-spark]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Mon, 28 Sep 2026 09:16:21 GMT</pubDate>
            <atom:updated>2026-09-28T09:16:21.013Z</atom:updated>
            <content:encoded><![CDATA[<p>I built a small African weather lakehouse, let Spark and BigQuery take turns editing the same table, and the whole thing cost me less than ten US cents.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0_73fVhiYQ7Bp-OFPKpMtA.png" /></figure><p>Almost every data team I’ve worked with ends up with the same data living in three places. The Spark people have their Parquet files in a bucket. The analysts have a copy in the warehouse. And somebody, somewhere, has a “clean” export for the dashboard that nobody remembers how to refresh. Three copies, three versions of the truth, and a Slack thread every Monday about which number is right.</p><p>So when the Google Developer Experts Cloud team kicked off a Lakehouse and Apache Iceberg content sprint this month, I wanted to test the big promise for myself: <strong>one copy of the data, and several engines that can all read <em>and write</em> it.</strong> I didn’t want the slides version. I wanted to build something real, break it, and see what actually holds up.</p><p>This is what I did on a Monday morning in Kigali, including the parts that surprised me.</p><h3>The idea in plain words</h3><p>If “lakehouse” sounds like buzzword soup, here is the version I use when I explain it to friends:</p><ul><li><strong>Apache Iceberg</strong> is a table format. Your data is still ordinary Parquet files in a Cloud Storage bucket, but Iceberg adds a “table of contents” on top: which files make up the table right now, what the columns are, and a history of every change (called <strong>snapshots</strong>).</li><li><strong>A catalog</strong> is the librarian. It knows where each table lives and which version is current, so two engines never disagree about what the table looks like.</li><li><strong>Engines</strong> are whoever reads or writes: Spark, BigQuery, Trino, Flink, and so on.</li></ul><p>Think of a shared Google Doc with version history, compared to emailing attachments back and forth. That’s the whole pitch.</p><p>On Google Cloud, the pieces are now called <strong>Lakehouse</strong> (this used to be BigLake) and the <strong>Lakehouse runtime catalog</strong> (formerly BigLake metastore). The catalog speaks the open <strong>Iceberg REST</strong> protocol, which means any Iceberg-aware engine can connect to it, not just Google’s. Heads-up: the CLI commands still say gcloud biglake, and serverless Spark is now called <strong>Managed Service for Apache Spark</strong>, but its commands are still gcloud dataproc. I kept tripping over the old and new names, so don&#39;t feel bad if you do too.</p><h3>What I built</h3><p>I wanted real data that was small, a little messy, and close to home. I picked <strong>NOAA’s daily weather records (GSOD)</strong>, which is a free public dataset in BigQuery, for <strong>12 African airports</strong>: Kigali, Nairobi, Lagos, Accra, Entebbe, Dar es Salaam, Addis Ababa, Cairo, Cape Town, Casablanca, Kinshasa and Abidjan, from January 2024 to August 2025. That’s about 7,000 rows. Tiny, but it’s real weather and it comes with real data quality problems, which turned out to be the fun part.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8xgVAY8NNWgbR0O5mlQozg.png" /></figure><p><em>The flow: raw Parquet lands in a staging bucket, Spark turns it into an Iceberg table, and BigQuery and Spark then take turns working on that same table through one catalog.</em></p><p>The plan:</p><ol><li>Land the raw data in a bucket, warts and all.</li><li>Use <strong>serverless Spark</strong> to turn it into an Iceberg table.</li><li>Use <strong>BigQuery</strong> to query it, fix it, and add columns, on the same table.</li><li>Go back to <strong>Spark</strong> and check it sees everything BigQuery did.</li><li><strong>Time travel</strong> from both sides.</li><li>Put <strong>Gemini</strong> on top, straight from BigQuery.</li></ol><p>Everything is in a small repo you can run yourself (details at the end). Here, I’ll stick to the story and the screenshots.</p><h3>Step 1: A catalog, two buckets, and a key-holder</h3><p>I created two buckets. The <strong>staging</strong> bucket is where raw files and job scripts go. The <strong>lake</strong> bucket holds the actual Iceberg table. Then I created the catalog and pointed it at the lake bucket.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vAsH65huOQX81am_lXYAzg.png" /></figure><p><em>One command creates the catalog. “Vended credentials” is the important setting.</em></p><p>That vended-credentials setting is worth a sentence. It means <strong>the catalog holds the keys to the lake bucket, not the engines</strong>. When Spark wants to read or write a table, it asks the catalog, and the catalog hands it a short-lived key that only works for that one table. So I only have to manage access in one place. Hold that thought, because it came back to bite me later.</p><h3>Step 2: Spark lands the raw data (and Kigali hits 9999.9°F)</h3><p>I exported the raw weather slice from BigQuery into the staging bucket as Parquet, then ran a serverless Spark batch to create the Iceberg table and load 2024 into it. There was no cluster to create or delete. The job starts, runs for about two minutes, and disappears.</p><p>When Spark printed a quick summary, I got my first laugh of the morning:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AGVFuPXN0IudX-dJ2_9sRw.png" /></figure><p><em>According to the raw data, Kigali’s hottest day in 2024 was 9999.9°F. So was Lagos’s.</em></p><p>Kigali is lovely, but it is not 9999.9°F. NOAA uses 9999.9 to mean &quot;missing&quot; for temperatures, and 99.99 for missing rainfall. That&#39;s exactly the kind of thing that sneaks into a dashboard and ruins someone&#39;s week. I left it in on purpose, because I wanted BigQuery to fix it later.</p><p>The one thing I did carefully in Spark was give the table two properties when I created it:</p><pre>TBLPROPERTIES (<br>  &#39;gcp.biglake.bigquery-dml.enabled&#39;     = &#39;true&#39;,  -- BigQuery may write to this table<br>  &#39;gcp.biglake.table-management.enabled&#39; = &#39;true&#39;   -- let Google compact small files for me<br>)</pre><p>Think of the first one as a permission slip. Without it, BigQuery can read a Spark-created table but can’t change it.</p><h3>Step 3: BigQuery reads it with zero setup</h3><p>This is the moment that sold me. I didn’t create an external table, a dataset, or any kind of link. I just queried the table by its four-part name, <strong>project.catalog.namespace.table</strong>:</p><pre>SELECT city, COUNTIF(max_temp_f = 9999.9) AS missing_max<br>FROM `my-project.lakehouse-demo-catalog.weather.daily_obs`<br>GROUP BY city;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_xDGS17b6kP6br9h7abaQw.png" /></figure><p><em>BigQuery reading the exact table Spark had written a minute earlier. Kigali has 40 days of missing rainfall in 2024, Entebbe 89.</em></p><p>A small detail I only noticed later: seconds after Spark committed its write, a BigQuery system job quietly refreshed its cached view of the table. I didn’t have to do anything.</p><h3>Step 4: BigQuery fixes the data and changes the table</h3><p>Now the part I was most curious about: <strong>writing</strong> from BigQuery to a table Spark owns.</p><p>First, the clean-up. One UPDATE turned all of NOAA&#39;s &quot;missing&quot; markers into proper empty values (NULLs). Then, because most of the continent thinks in Celsius, I added three new Celsius columns with ALTER TABLE and filled them in with another UPDATE.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5sHBY85sUG3BSxi6qDe2RA.png" /></figure><p><em>428 rows cleaned, three columns added, 4,216 rows backfilled. All from BigQuery, all on the Iceberg table.</em></p><p>It just worked. I’ll be honest that I expected it not to. The “Set up the Iceberg REST catalog” page in the docs still says, under Limitations, that you can’t modify these tables with BigQuery DDL or DML. The newer pages on <a href="https://docs.cloud.google.com/lakehouse/docs/table-options?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">table options</a> and <a href="https://docs.cloud.google.com/lakehouse/docs/alter-table?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">altering tables</a> say you can, as a <strong>Preview</strong> feature. In my test, the Preview wins. Just keep in mind that “Preview” means it can still change.</p><h3>Step 5: Back in Spark, everything is there</h3><p>The real test of “one table” is whether the<em>other</em>engine sees your changes. So I ran a second Spark job.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8SCrZQFSbcgDjipKbwMkLg.png" /></figure><p><em>Spark sees the three Celsius columns BigQuery added, BigQuery’s two commits in the history, and can still read the original raw version.</em></p><p>Three things made me smile here:</p><ul><li><strong>The new columns were just there.</strong> No refresh, no re-registering.</li><li><strong>The history tells the story.</strong> Spark’s first load shows up as an append, and BigQuery&#39;s two updates show up as overwrite snapshots. (Adding columns doesn&#39;t create a snapshot at all, since no data changed.)</li><li><strong>Time travel works.</strong> Asking Spark for the very first snapshot gave me the raw data back, 9999.9s and all, while the current version is clean.</li></ul><p>One small thing to know: BigQuery’s snapshots carry much less detail than Spark’s. Fields like “engine name” and “total records” were empty for BigQuery’s commits. If you plan to build monitoring on those snapshot details, check what each engine actually writes.</p><p>Then Spark appended the 2025 data, using the Celsius columns BigQuery had created. The two engines were now genuinely building one table together.</p><h3>Step 6: Time travel from BigQuery</h3><p>BigQuery can time travel on the same table too, using a timestamp:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NvpeMIMyJoOCZm8mp9aKlw.png" /></figure><p><em>“As of 07:50:56 UTC”, before BigQuery’s own clean-up, the table had 4,216 rows and the bad values. “Now”, it has 7,003 clean rows including Spark’s 2025 append.</em></p><p>I hit one gotcha: my first attempt put “then” and “now” in a single query, and BigQuery refused. It wants every mention of a table in one query to use the same point in time. Two separate queries solved it.</p><h3>Step 7: The permission surprise</h3><p>Remember the key-holder idea from Step 1? The theory was that Spark had no access to the lake bucket and could only get in through the catalog’s short-lived keys.</p><p>Then I read the fine print on the <strong>Dataproc Worker</strong> role, the one the quickstarts tell you to give your Spark service account. It includes permission to read and write objects in <strong>every bucket in the project</strong>. So my Spark job could reach straight into the lake bucket whenever it liked, and the neat key-holder story was only true on paper.</p><p>The fix was to make a copy of that role with the storage permissions removed, swap it in, and give Spark access to its staging bucket only:</p><pre>gcloud iam roles create lakehouseDemoSparkWorker --project &quot;$PROJECT_ID&quot; \<br>  --permissions &quot;$(gcloud iam roles describe roles/dataproc.worker --format=json \<br>                   | jq -r &#39;.includedPermissions[]&#39; | grep -v &#39;^storage\.&#39; | paste -sd, -)&quot;</pre><p>Then I wrote a tiny Spark job that tries to read one of the table’s files directly, and then reads the same table through the catalog. The first run, a couple of minutes after the swap, still got in: permission changes take a few minutes to spread. About five minutes later I ran it again:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t7sb5_yczmlb21KxuecLnQ.png" /></figure><p><em>Same Spark job, same identity, same file. Reading it directly gets “403 Forbidden”. Reading it through the catalog works.</em></p><p>This was the most useful thing I learned all day. <strong>Credential vending only protects you if your engines don’t already have broad storage access.</strong> If you’re rolling this out for a team, check what your service accounts can reach before you trust the diagram.</p><h3>Step 8: Gemini on top, for DevFest</h3><p>DevFest season is almost here, and a lot of us will be travelling to speak across the continent. So I asked a practical question: what was October and November actually like in each city last year, and what should a visiting speaker pack?</p><p>BigQuery can call Gemini directly in SQL with AI.GENERATE. I summarised the Iceberg table per city and asked Gemini for one sentence of packing advice, using only the numbers I gave it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qC3ZUHTT5RdKGCKw6dg4Ew.png" /></figure><p><em>Gemini in BigQuery, reading straight from the Iceberg table. Kigali: rain on 42 of 57 days in Oct and Nov 2024.</em></p><p>To be fair, the tips are a bit plain. When you tell a model to “only use the numbers given”, it mostly repeats the numbers back to you. The interesting part isn’t the prose. It’s that Gemini ran on lakehouse data <strong>without exporting anything</strong>. And now I have data to back up what everyone in Kigali already knows: if you’re coming to DevFest here in November, bring an umbrella.</p><h3>What it cost</h3><p>I kept everything small and serverless on purpose, and I labelled every job so I could add it all up afterwards.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cBiEHyvdlhd_fLEHvhuwpA.png" /></figure><p><em>BigQuery: about half a gigabyte billed, mostly the one-time export from the public dataset. Spark: four short batches at about a cent each.</em></p><p>All in, about <strong>six US cents</strong>: roughly $0.05 for the four Spark batches, less than a cent for BigQuery, a fraction of a cent for 13 short Gemini calls, and a few megabytes of storage. No clusters were left running at any point. Your numbers will vary with region and pricing, but for learning, this is basically free.</p><h3>Things I’d tell a friend before they try this</h3><ol><li><strong>Check your service account’s storage access.</strong> Dataproc Worker quietly grants access to every bucket in the project, which undercuts credential vending.</li><li><strong>BigQuery writes are Preview.</strong> They worked well for me, but they come with rules: Iceberg v2 only, copy-on-write, and simple partitioning (I used monthly partitions on a date). The <a href="https://docs.cloud.google.com/lakehouse/docs/table-options?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">table options page</a> lists them all.</li><li><strong>Set the table properties when you create the table in Spark</strong>, or BigQuery will be read-only on it.</li><li><strong>One timestamp per table per query</strong> when time travelling in BigQuery.</li><li><strong>Iceberg’s history tables (like </strong><strong>.snapshots) are Spark-only.</strong> BigQuery can&#39;t query them.</li><li><strong>Don’t panic at the big red stack trace.</strong> Spark’s CREATE TABLE ... AS SELECT printed about 60 lines of error about a &quot;metrics report&quot; failing. It&#39;s only a warning, and the table was created fine.</li><li><strong>Watch for small files.</strong> My export produced 39 files for 300 KB of data. That’s why the table management setting (automatic compaction) exists.</li><li><strong>The names changed, the commands didn’t.</strong> Lakehouse is gcloud biglake, and Managed Service for Apache Spark is gcloud dataproc.</li></ol><h3>Was it worth it?</h3><p>Yes. The part I cared about most, one copy of the data that different tools can both read and write, actually works today. Spark and BigQuery took turns on the same table, each saw the other’s changes immediately, and I could rewind to any earlier version from either side. For a team that’s tired of arguing about which copy is right, that’s a real change.</p><p>The two things I’d keep an eye on are the Preview label on BigQuery writes and the permissions story. The catalog handles access nicely, but only if you don’t give your engines a back door first.</p><p>Next, I want to connect a third engine (probably Trino) to the same catalog, and try the automatic compaction on a table that’s big enough to need it. If you try this on your own data, I’d love to hear which gotcha got you first.</p><p><strong>The code:</strong> every script, SQL file and Spark job from this post, plus a step-by-step README, is in the companion repo: <em>[GitHub link coming soon]</em>.</p><h3>References</h3><ul><li>What is Lakehouse? (Google Cloud docs): <a href="https://docs.cloud.google.com/lakehouse/docs/introduction?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://docs.cloud.google.com/lakehouse/docs/introduction?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>Quickstart: create and query an Iceberg table with the gcloud CLI: <a href="https://docs.cloud.google.com/lakehouse/docs/query-iceberg-tables-with-lakehouse?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://docs.cloud.google.com/lakehouse/docs/query-iceberg-tables-with-lakehouse?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>Set up the Iceberg REST catalog endpoint: <a href="https://docs.cloud.google.com/lakehouse/docs/set-up-lakehouse-iceberg-rest-catalog?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://docs.cloud.google.com/lakehouse/docs/set-up-lakehouse-iceberg-rest-catalog?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>Configure table options (BigQuery DML, table management): <a href="https://docs.cloud.google.com/lakehouse/docs/table-options?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://docs.cloud.google.com/lakehouse/docs/table-options?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>Query a table and time travel: <a href="https://docs.cloud.google.com/lakehouse/docs/query-table?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://docs.cloud.google.com/lakehouse/docs/query-table?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>Alter a table: <a href="https://docs.cloud.google.com/lakehouse/docs/alter-table?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://docs.cloud.google.com/lakehouse/docs/alter-table?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>The AI.GENERATE function in BigQuery: <a href="https://docs.cloud.google.com/bigquery/docs/reference/standard-sql/bigqueryml-syntax-ai-generate?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://docs.cloud.google.com/bigquery/docs/reference/standard-sql/bigqueryml-syntax-ai-generate?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>Managed Service for Apache Spark pricing: <a href="https://cloud.google.com/products/managed-service-for-apache-spark/pricing?utm_campaign=deveco_gdemembers&amp;utm_source=deveco">https://cloud.google.com/products/managed-service-for-apache-spark/pricing?utm_campaign=deveco_gdemembers&amp;utm_source=deveco</a></li><li>Codelab, Ingest and govern logistics data with Lakehouse: <a href="https://codelabs.developers.google.com/data-roadshow-26/lab1?utm_campaign=deveco_gdemembers&amp;utm_source=deveco#0">https://codelabs.developers.google.com/data-roadshow-26/lab1?utm_campaign=deveco_gdemembers&amp;utm_source=deveco#0</a></li><li>Apache Iceberg: <a href="https://iceberg.apache.org/">https://iceberg.apache.org/</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ddfe40051f08" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why a shared channel for coding agents fits my platform workflow]]></title>
            <link>https://timtech4u.medium.com/why-a-shared-channel-for-coding-agents-fits-my-platform-workflow-203868e8f512?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/203868e8f512</guid>
            <category><![CDATA[artificial-intelligence]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Thu, 17 Sep 2026 10:02:20 GMT</pubDate>
            <atom:updated>2026-09-18T14:33:24.231Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ODxdblkVuu71J__OOkEDxg.png" /></figure><p>Radio is a shared real-time channel for humans and AI coding agents — think Slack, but built so agents can talk to each other and to you without you copy-pasting between tools. You create a channel at radio.plasma.ai, paste the link into agents like Claude Code, Codex, Cursor, OpenCode, or Grok, and they join the same conversation to split work, clarify decisions, and collaborate across models or machines. In daily work this removes the handoff friction when one agent writes code and another reviews or tests, or when a local agent needs to coordinate with a cloud agent. The channel is also the record of how the work got done, and you can steer it from any device. For me as someone running multi-agent and platform workflows, that shared surface is the useful part: one place to delegate, monitor, and redirect instead of being the messenger between tools.</p><p><em>Original launch article by Nicholas Diao, Andrew Turner and Colton Berry, published September 14, 2026. </em><a href="https://www.plasma.ai/research/radio"><em>Original source</em></a><em>.</em></p><h3>Plasma Radio</h3><p>Nicholas Diao, Andrew Turner, Colton Berry · September 14, 2026</p><p>The easiest way for your agents to talk to each other.</p><p><a href="https://radio.plasma.ai/">Try it now</a></p><h3>Why we built it</h3><p>Most work now involves more than one agent, often from different providers. One writes the code while another tests it. One runs on your laptop while another runs in the cloud. But the agents can’t talk to each other. Each one only sees its own conversation, so you end up as the go-between, copying output from one window and pasting it into the next.</p><p>We built Radio to solve this problem. To create a clean line of communication between agents, simply hand them a link to a Radio channel. The agents join the channel and talk to each other, and to you, in real time.</p><p>Radio works with any agent that can fetch a URL, so Claude Code, Codex, Cursor, OpenCode, and Grok all join the same way. It works across machines and between people, and you can steer the agents from any device.</p><h3>How it works</h3><ol><li>Create a channel at <a href="https://radio.plasma.ai/">radio.plasma.ai</a></li><li>Copy the link</li><li>Paste into one or more agents</li><li>The agents join the channel. Send one message and they take it from there, replying to you and to each other</li></ol><h3>When to use it</h3><p>The simplest way to think about a Radio channel is as a meeting. Any time you would put two or more people in a room to work something out, you can put two agents in a channel. There are three kinds, and each one builds on the last.</p><ol><li><strong>Team meeting:</strong> All the agents on your computer in one channel. One agent writes the code while another tests it. Review a PR together, split up a task, debate a bug. Anywhere you are relaying messages between agents on your own machine, give them a channel instead.</li><li><strong>Cross-functional meeting:</strong> Agents in different places: your laptop, a cloud agent, a teammate’s machine. Their Claude talks to your Claude, Codex, Grok, etc. The channel is the shared surface, so nobody has to be the go-between.</li><li><strong>External meeting:</strong> Everything above, now multiplayer. Anyone with the link can read the channel and post to it, so someone outside the workflow can answer a question or redirect the work from any device.</li></ol><p>In every case, the channel is also the record. Everything you and the agents said to each other stays in one place, so you can see how the work got done.</p><h3>A core primitive of Fractal</h3><p>Radio is a core primitive of our first product, Fractal.</p><p>Fractal lets a team delegate real work to agents the way it would to people: pick the right model for each job, hand it a goal and a budget, and watch the work happen in real time.</p><p>You can see other building blocks of Fractal on our <a href="https://www.plasma.ai/research">Research page</a>.</p><h3>Coming Soon</h3><p>Fractal is coming to the cloud. See the tree, steer its nodes, and track costs as the work runs.</p><p>Early access opens soon.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=203868e8f512" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The AI that really does things.]]></title>
            <link>https://timtech4u.medium.com/the-ai-that-really-does-things-23cb37cd06c6?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/23cb37cd06c6</guid>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Thu, 03 Sep 2026 13:08:53 GMT</pubDate>
            <atom:updated>2026-09-03T13:08:53.094Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dbbWhsfnmaLWxhkPko3yPQ.png" /></figure><p>OpenClaw’s homepage says that. A few products now mean it the same way: an assistant with a computer, not only a chat tab.</p><p>This week I used Grok Bot. OpenClaw 2.0 (2026.8.2) is running on that computer. You do not need both. You can stop at Grok Bot. You can stop at ChatGPT Work. You can install OpenClaw on the Grok Bot computer, or on a machine you own, when you want WhatsApp or a ChatGPT subscription signed in once on a Gateway you control.</p><h3>A short map</h3><p>Not a ranking. Three places an assistant can actually run.</p><p>Where it runsYou talk to it fromHow you get it<strong>Grok Bot</strong>One persistent cloud computer per person. All of your Bots share it.Grok Bot app on desktop, iOS, or AndroidIncluded on Cursor Pro, Pro+, Ultra, and Teams. Or link an individual SuperGrok, SuperGrok Plus, SuperGrok Heavy, or X Premium+ account<strong>ChatGPT Work</strong>ChatGPT’s Work workspace, plus Computer Use on the desktop appChatGPT app — Chat, Work, and CodexWork on web and mobile is on Pro, Enterprise, and Edu (Plus and Business followed). The desktop app puts Chat, Work, and Codex together<strong>OpenClaw</strong>A Gateway on a machine you pick — including this Grok Bot computer, a Mini, a VPS, a PiControl UI, WhatsApp, Telegram, iMessage, Slack, Signal, phone nodeInstall it. 2.0 looks for a ChatGPT or Claude login already on that machine</p><h3>Set up Grok Bot</h3><p>Grok Bot signs in with your Cursor account. The computer is hosted. The app on your Mac, Windows, Linux, or phone is a thin client. Close the lid. Work keeps going.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RRaWHOlxiN05OmxBVRJIDQ.png" /><figcaption>Grok Bot</figcaption></figure><p><strong>If you already pay for Cursor:</strong> Pro, Pro+, Ultra, or a Teams seat already includes Grok Bot. Sign in with that account. Ultra has the highest weekly usage on the Cursor side. You do not install a server.</p><p><strong>If you already pay for Grok:</strong> link an individual SuperGrok, SuperGrok Plus, SuperGrok Heavy, or X Premium+ account from the Grok Bot plan screen. That grant sits on the Cursor account. SuperGrok Team and SuperGrok Enterprise do not link. SuperGrok Lite does not include Grok Bot. Linking does not cancel a Cursor plan.</p><p>What you do:</p><ol><li>Install the Grok Bot desktop app from the downloads page (macOS, Windows, Linux). Phone apps exist too.</li><li>Sign in with Cursor (browser window).</li><li>Create a Bot: a short name, one job, a description of how it should work.</li><li>Give it a first task with an outcome, sources, constraints, and a review point.</li><li>When it hits a login, take over the computer for the password or 2FA. The session stays on the shared computer.</li></ol><p>Connectors (Slack, Gmail, GitHub, Drive, and the rest) go through Settings → Plugins. All Bots on the account share files and browser logins, so treat a login as account-wide.</p><p>I already wrote the sit-down layer. Herdr is how you attach to a remote machine, including this one. This piece is not that.</p><h3>ChatGPT Work</h3><p>ChatGPT Work is OpenAI’s workspace for getting a job to a finished file — slides, sheets, docs, Sites — with Codex technology built in. On the desktop app it sits next to Chat and Codex. Computer Use can click, type, and move files on your computer in the background, including as part of a scheduled task.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AwK1RNhlkP0zEgSPt5bzYA.png" /><figcaption>ChatGPT Work</figcaption></figure><p>That is a computer. It is ChatGPT’s computer, in ChatGPT’s app.</p><p>OpenClaw can still use a ChatGPT Plus or Pro login as the <em>model</em>. That is <strong>ChatGPT Login</strong> in 2.0: sign in once on the Gateway. It does not replace ChatGPT Work. It is how OpenClaw borrows the subscription you already pay for.</p><p>Gemini 3.8 in OpenClaw still wants a Google AI Studio key. A Google AI Pro/Ultra subscription does not carry over.</p><h3>Run OpenClaw on the Grok Bot computer</h3><p>OpenClaw is a self-hosted gateway. You pick the machine. 2.0 rebuilt the browser app so it opens as a chat, and first-run setup looks for a ChatGPT or Claude subscription already on that computer.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BW7ycekVrSO-lqcoDWaPWg.png" /></figure><p>This Grok Bot computer already had Node. It did not have Docker. Rakazo and OpenGrokBot want Docker, so they did not run here. OpenClaw installed.</p><p>What I actually did:</p><ol><li>Install OpenClaw 2.0 on the Grok Bot computer.</li><li>Start the Gateway on loopback.</li><li>Open the Control UI. It is a chat, not a YAML dump.</li><li>Click <strong>ChatGPT Login</strong>. Sign in once with a Plus/Pro account.</li><li>Pair a phone, or connect WhatsApp / Telegram and stay there.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SgVVQL1ERspqeBg4TsJW1w.png" /><figcaption>ChatGPT Login</figcaption></figure><p>Permissions: turn down “Default (Full Access)” for anyone who is not you. One folder, read-only at first. No payments. No sending email. Approve anything that wants to leave the machine.</p><p>The same install works on a spare Mac mini, a VPS, or a Pi. The Grok Bot computer is just the machine I had on.</p><p>What 2.0 changed, in practice: it opens as a conversation; setup uses a subscription you already pay for; the phone is a remote. Wiring ChatGPT Login all the way into a first reply is still a helper job. Do not hand someone a half-finished Gateway and walk away.</p><h3>Which computer</h3><p><strong>Grok Bot</strong> if you want an assistant on a computer that is already on, from the Grok Bot app, with connectors.</p><p><strong>ChatGPT Work</strong> if you already live in ChatGPT and want Work / Codex / Computer Use in that app.</p><p><strong>OpenClaw on the Grok Bot computer</strong> if that box is already running and you want WhatsApp or Telegram on it, or a ChatGPT subscription next to Grok.</p><p><strong>OpenClaw on a machine you own</strong> if you want the Gateway on hardware you picked.</p><p>Rakazo is a visual cousin of Grok Bot (iPhone/Android app) and still beta, Docker required. OpenGrokBot puts each bot in its own container; Telegram is still on the roadmap. Neither ran here this week.</p><p>The AI that really does things still needs a computer. These are three ways to have one.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=23cb37cd06c6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The machine can live anywhere. Herdr is how you sit down at it.]]></title>
            <link>https://timtech4u.medium.com/the-machine-can-live-anywhere-herdr-is-how-you-sit-down-at-it-1f1c44379094?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/1f1c44379094</guid>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[developer-tools]]></category>
            <category><![CDATA[remote-work]]></category>
            <category><![CDATA[ai-agent]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Wed, 19 Aug 2026 10:32:40 GMT</pubDate>
            <atom:updated>2026-08-19T10:32:40.863Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*amHdnWQ1z63TCcE7.png" /></figure><p>In April I wrote that <a href="https://dev.to/timtech4u/your-ai-coding-agent-deserves-its-own-cloud-machine-1ino">your AI coding agent deserves its own cloud machine</a>. I meant it. I moved Claude Code onto a GCP VM, put it in tmux, tunneled ports back to localhost, and treated the laptop as a thin client. From my phone I checked on the agent while grabbing coffee.</p><p>That article was about <em>where the work runs</em>. This one is about <em>how you sit down at it</em>.</p><p>The missing piece is <a href="https://herdr.dev/">Herdr</a> — specifically herdr --remote.</p><p>Yesterday Duyet posted that he installed Tailscale and Herdr on a <a href="https://x.com/_duyet/status/2089665924454633766">Grok Bot</a> computer, then attached from his Mac:</p><pre>herdr --remote box@duyetbot</pre><p>I did the same thing today, on a box named grey. One command from the MacBook. On the other side: a persistent Herdr server, a workspace, and Grok 4.6 already running.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*tLztVLNcXZQNDlOC.png" /></figure><p>I did not SSH in first and then remember tmux binds. I did not rebuild a layout. The session was already there.</p><p>That is the product.</p><h3>The gap after tmux</h3><p>tmux keeps a shell alive. That is why I used it in April. Close the laptop, come back, tmux attach. It works.</p><p>What tmux does not do:</p><ul><li>know which pane is an agent</li><li>tell you which one is blocked, working, idle, or done</li><li>give you a thin client that feels like the machine is in front of you</li><li>install itself on a fresh box with one command</li><li>stream the same UI from a Vercel sandbox, a Grok Bot computer, a Cursor VM, or a Hetzner VPS without changing how you work</li></ul><p><a href="https://herdr.dev/compare/">Herdr’s own compare page</a> puts it cleanly: tmux sees panes. Herdr sees agents. Manager apps (Conductor, Emdash, the rest) put the herd in a window — quit the window, the herd goes with it. Herdr is the other way around. The server owns the terminals. Every UI is a client. Detach, crash the TUI, close the lid. The agents do not notice.</p><p>Can Celik, who built Herdr, said the quiet part in the <a href="https://herdr.dev/blog/herdr-is-joining-y-combinator/">Y Combinator announcement</a> (F26, runtime stays Apache-2.0):</p><blockquote><em>Once you have the runtime, where they run stops mattering. You should be able to run them anywhere and keep them running.</em></blockquote><p>And then the roadmap sentence that this post is really about:</p><blockquote><em>A laptop, a VPS for the six-hour job, a sandbox for risky code. Herdr can run anywhere today, but those machines are disconnected. They should be connected.</em></blockquote><p>--remote is how they start connecting.</p><h3>What --remote actually is</h3><p>Two official paths, from <a href="https://herdr.dev/docs/how-to-work/">How to work with Herdr</a>:</p><p><strong>1. SSH first, then Herdr</strong> — tmux-style. Use this on a phone.</p><pre>ssh you@server<br>herdr</pre><p><strong>2. Thin client from the machine you are holding.</strong> This is the one that feels like the box is local. Your Herdr talks SSH, starts or attaches the remote server, and streams the UI back. Local keybinds stay local. A screenshot on your Mac clipboard can land in the remote pane.</p><pre>herdr --remote workbox<br>herdr --remote ssh://you@server:2222<br>herdr --remote box@grey</pre><p>If the remote does not have Herdr yet, an interactive --remote will install it. Can&#39;s line: depending on the network, you are a couple of seconds from an agent running.</p><p>Detach with ctrl+b q. The server stays. Reattach with the same command.</p><p>That is the inversion. The laptop is no longer the computer. The laptop is the chair.</p><h3>The menu of machines</h3><p>Compute got cheap and weird. You can rent a place for an agent in a dozen shapes before lunch. None of these are theoretical — they all speak SSH, or something close enough.</p><p>Where the box livesWhat you getHow you reach it<strong>Your laptop</strong>Fast UI, bad thermalsherdr<strong>A cloud VM</strong> (GCP, AWS, Hetzner, Fly)Always-on, you pay for the hourherdr --remote user@vm<a href="https://vercel.com/docs/sandbox"><strong>Vercel Sandbox</strong></a>Firecracker microVM, persistent by default, SSH as of January 2026sandbox ssh &lt;id&gt; then herdr, or point --remote at that SSH<strong>Grok Bot&#39;s computer</strong>A real Linux box next to the chatTailscale (or any SSH) + herdr --remote box@grey<strong>Cursor cloud / cloud agent VM</strong>A throwaway machine that already has the repoSSH if the environment exposes it, then Herdr<strong>A GPU pod</strong>The job that should not run on a MacBookSame --remote<strong>Your phone</strong>No Herdr app requiredAny SSH client, then herdr — the TUI adapts</p><p>The providers will keep multiplying. The attach command does not have to.</p><p>Vercel is the example people keep asking about, so here is the honest version. <a href="https://vercel.com/docs/sandbox">Sandbox</a> is a Firecracker microVM for untrusted or agent-generated code. It is persistent by default: stop it, the filesystem snapshots, resume later. In January 2026 they shipped <a href="https://vercel.com/changelog/ssh-into-running-sandboxes-with-the-sandbox-cli">sandbox ssh</a>. While you are connected, the timeout extends in 5-minute increments, up to five hours. That is not a 24/7 VPS. It is a scratch computer you can actually sit down at. Put Herdr on it and the session outlives the tab you used to create the sandbox — for as long as the sandbox itself is allowed to live.</p><p>Grok Bot, Cursor Cloud, Codespaces, a home lab: same pattern. The product gives you a machine. Herdr gives you a place to inhabit it with the agent UI you already use.</p><h3>A worked example: Grok Bot + Tailscale + a Mac</h3><p>I am not going to pretend this is the only way. It is the way I actually did it today, after Duyet’s tweet.</p><p><strong>On the box</strong> (the Grok Bot computer — Debian, user box):</p><pre># Herdr<br>curl -fsSL https://herdr.dev/install.sh | sh<br>herdr server          # headless is enough; or just `herdr`</pre><pre># Grok Build, or Claude, or Codex — Herdr does not wrap them<br>grok</pre><p><strong>A pipe.</strong> --remote is SSH. I used Tailscale because the box has no public IP I wanted to open. Install Tailscale on the box and the Mac, join the <em>same</em> tailnet, enable Tailscale SSH. Hostname: grey.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Ztkbj3tysp7Sjbtg.png" /></figure><p>If you mix Google and GitHub identities, you will land on two tailnets and the machines will not see each other. I did that. Fix: pick the identity your laptop already uses.</p><p><strong>On the Mac:</strong></p><pre>herdr --remote box@grey<br># if MagicDNS misses:<br>herdr --remote box@100.70.59.5</pre><p>Grok was already in the session. The sidebar showed ~ / grok. I did not start it from the laptop.</p><p><strong>The catch, because this is a Grok Bot computer and not a VPS:</strong> closing the chat is fine. Quitting Grok Bot, or anything that sleeps or recreates that computer, is not. herdr --remote talks to the box, not to your Mac. If the box is gone, grey disappears from Tailscale. We already watched a restart wipe the Tailscale package once. Treat Grok Bot as a convenient host, not an SLA.</p><p>For a real always-on herd, use a VM you control. The attach command stays the same.</p><h3>How I work now</h3><p>Morning, on the Mac:</p><pre>herdr --remote box@grey</pre><p>The workspace is where I left it. Agents that ran overnight are either done, blocked, or still working. I do not hunt panes.</p><p>A throwaway repro? Vercel Sandbox, sandbox ssh, herdr, do the dangerous thing, snapshot or kill it.</p><p>A six-hour eval? The GPU box. Same --remote.</p><p>Phone? ssh box@grey then herdr. <a href="https://herdr.dev/docs/how-to-work/">Official docs</a>: no mobile app required. moshi works on iPhone.</p><p>Named sessions if one host has two herds:</p><pre>herdr --remote box@grey --session agents</pre><p>Repeat targets go in SSH config so you stop typing users and ports:</p><pre>Host grey<br>  HostName 100.70.59.5<br>  User box</pre><pre>herdr --remote grey</pre><h3>What this is not</h3><p>It is not “SSH, but pretty.” It is a runtime with clients.</p><p>It is not a replacement for Cursor, Claude Code, Grok Build, or Codex. <a href="https://herdr.dev/">Herdr does not wrap them.</a> It owns their terminals.</p><p>It is not a reason to keep a Grok Bot chat open 24/7. Put Herdr on the machine that is allowed to stay up.</p><p>It is not locked to Tailscale. WireGuard, a public SSH port, a Vercel sandbox SSH session, a Host block — if ssh you@host works, herdr --remote you@host works.</p><h3>Quick reference</h3><p>WhatCommandInstall Herdrcurl -fsSL https://herdr.dev/install.sh \| shLocal sessionherdrDetachctrl+b qStop the serverherdr server stopThin-client remoteherdr --remote user@hostPhone / plain SSHssh user@host then herdrNamed remote sessionherdr --remote host --session agentsVercel scratch boxsandbox ssh &lt;id&gt; then herdrThis writeup&#39;s hostherdr --remote box@grey</p><p>The April article was: give the agent a machine, put tmux on it, make the laptop thin.</p><p>This one is: the machines are already everywhere. Herdr is how you sit down at any of them without changing the ritual.</p><p>The chair is portable. Put it on every computer you actually want to use.</p><p><em>Sources: </em><a href="https://herdr.dev/"><em>herdr.dev</em></a><em>, </em><a href="https://herdr.dev/docs/how-to-work/"><em>How to work with Herdr</em></a><em>, </em><a href="https://herdr.dev/docs/persistence-remote/"><em>Persistence and remote</em></a><em>, </em><a href="https://herdr.dev/compare/"><em>Compare</em></a><em>, </em><a href="https://herdr.dev/blog/herdr-is-joining-y-combinator/"><em>Herdr joins YC</em></a><em>, </em><a href="https://vercel.com/docs/sandbox"><em>Vercel Sandbox</em></a><em>, </em><a href="https://vercel.com/changelog/ssh-into-running-sandboxes-with-the-sandbox-cli"><em>Sandbox SSH changelog</em></a><em> (15 Jan 2026), </em><a href="https://x.com/_duyet/status/2089665924454633766"><em>Duyet’s tweet</em></a><em> (18 Aug 2026). Screenshots from my Grok Bot computer, 19 Aug 2026.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1f1c44379094" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Building an AI Agent Mesh with Gemini 3, OpenClaw, and ACPX]]></title>
            <link>https://timtech4u.medium.com/building-an-ai-agent-mesh-with-gemini-3-openclaw-and-acpx-7b6ab5f1cbf4?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/7b6ab5f1cbf4</guid>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Mon, 09 Mar 2026 22:50:19 GMT</pubDate>
            <atom:updated>2026-03-10T11:35:03.838Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GKZ-T6x2X6Qe0cWgxf7SCQ.png" /></figure><p>I texted a Telegram bot: “Build me a dashboard.” Behind the scenes, an AI gateway powered by Google’s Gemini 3.1 Pro evaluated the request, selected the most suitable coding agent, and spawned a headless Codex session through the Agent Client Protocol. Codex wrote the code, captured Playwright screenshots, and delivered the results directly to my Telegram chat. I monitored the entire pipeline in real time from a split-pane terminal on my laptop.</p><p>I built this system over a weekend on a Google Cloud Platform virtual machine, and by the end of it, I was holding multi-turn conversations with Codex through a persistent session while observing the full orchestration pipeline through <a href="https://github.com/manaflow-ai/cmux">Cmux</a>.</p><h3>The Problem: Agents Don’t Talk to Each Other</h3><p>Every coding agent available today operates as a standalone command-line tool:</p><pre>codex &quot;create a hello world script&quot;<br>claude -p &quot;refactor this function&quot;<br>gemini &quot;explain this error&quot;</pre><p>Each invocation is stateless. There is no mechanism to route a task from one agent to another based on the agent’s strengths. There is no way to maintain multi-turn context across prompts. You cannot orchestrate agents from a chat interface like Telegram or Discord. And there is no visibility into what agents are doing in real time.</p><p>What we need is a protocol that agents can speak, a gateway that routes requests between them, and a terminal environment that provides full observability.</p><h3>The First Thing That Worked: Telegram to Codex in Two Minutes</h3><p>I sent this message to my Telegram bot:</p><blockquote><em>Hey Bee, spawn a Codex session and create a Python script at /tmp/fibonacci.py that prints the first 10 Fibonacci numbers, then run it and show me the output.</em></blockquote><p>Within two minutes, the bot responded with the complete output: 0 1 1 2 3 5 8 13 21 34.</p><p>Here is what happened under the hood. The message hit <a href="https://github.com/openclaw/openclaw">OpenClaw</a>, which handed it to <a href="https://ai.google.dev/">Gemini 3.1 Pro</a>. Gemini read its routing skill document, classified the request as a coding task, and triggered the <a href="https://github.com/openclaw/acpx">ACPX</a> plugin with agentId: &quot;codex&quot;. ACPX spawned a headless Codex instance through the <a href="https://agentclientprotocol.com/">Agent Client Protocol</a>, the JSON-RPC 2.0 standard created by <a href="https://github.com/zed-industries/agent-client-protocol">Zed Industries</a> for structured agent communication. Codex created the file, executed it, captured the output. The result flowed back through ACPX to OpenClaw, where Gemini formatted a human-readable response and delivered it to Telegram.</p><p>One text message in. Working code and output back. No SSH. No terminal. Just a chat.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*V7YxhNNqnJy0FLQSwTZE0w.png" /></figure><h3>Persistent Sessions: Picking Up Where You Left Off</h3><p>That first demo was fire-and-forget. Send a prompt, get a result, session dies. But real development is iterative. You explore, modify, test, refine. You need the agent to remember what it already did.</p><p>ACPX supports persistent sessions that maintain full context across multiple prompts:</p><pre># Create a persistent session<br>acpx codex sessions new --name workspace</pre><pre># First prompt: explore the project<br>acpx codex -s workspace &quot;list the files in /tmp/workspace-assistant/&quot;</pre><pre># Second prompt: Codex remembers the context from the first<br>acpx codex -s workspace &quot;add a Pi agent card to main.ts&quot;</pre><pre># Third prompt: builds on all previous work<br>acpx codex -s workspace &quot;take a Playwright screenshot of the updated dashboard&quot;</pre><pre># Close the session when finished<br>acpx codex sessions close workspace</pre><p>I tested this workflow live. I created a session named workspace, asked Codex to modify a Vite dashboard, then asked it to capture Playwright screenshots. All three prompts executed with full context retention. Codex remembered which files existed, what changes it had made, and could build on its previous work without re-explanation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FC9MiyX_RqevWOccRhotDg.png" /></figure><h3>The Screenshot That Sold Me</h3><p>This was the moment the system stopped feeling like a prototype.</p><p>I asked Codex, through Telegram, to capture Playwright screenshots of the Vite dashboard running on the virtual machine. The workflow:</p><ol><li>I sent a message in Telegram requesting screenshots</li><li>Gemini 3 routed the request to Codex through ACPX</li><li>Codex installed Playwright and launched headless Chromium</li><li>Codex navigated to localhost:4173, captured the light mode view</li><li>Codex toggled dark mode through DOM manipulation, captured the dark mode view</li><li>Both screenshots were uploaded directly to Telegram through the Bot API</li></ol><p>Actual rendered images of a running dashboard, captured by a coding agent, delivered to a chat thread. Not text. Not logs. Screenshots.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*A1irgm4NAtbLLiTdeQ0SoQ.png" /></figure><h3>Making It Interactive: acpx-chat.sh</h3><p>Persistent sessions are powerful, but the ergonomics are rough. Every prompt requires the full command:</p><pre>acpx codex -s workspace &quot;your prompt here&quot;</pre><p>So I built acpx-chat.sh, a readline-based wrapper that transforms ACPX into an interactive chat. Here is an actual session transcript:</p><p><a href="https://gist.github.com/Timtech4u/bec3b9509abcdd8102bd72fe9267f4e0">View the full acpx-chat.sh source on GitHub Gist</a></p><pre>$ ./acpx-chat.sh codex workspace<br>acpx-chat -- interactive ACP session<br>agent: codex  session: workspace<br>Type your prompt and press Enter. Ctrl+D or &#39;exit&#39; to quit.</pre><pre>you&gt; What files did we work on today?</pre><pre>[acpx] session workspace (019cd33a...) -- agent connected<br>Today we worked on:<br>- /tmp/workspace-assistant/src/main.ts<br>- /tmp/workspace-updated.png</pre><pre>you&gt; What changes did we make to main.ts?</pre><pre>[acpx] session workspace (019cd33a...) -- agent connected<br>We added one new entry to the agents array:<br>  { name: &#39;Pi&#39;, status: &#39;idle&#39;, protocol: &#39;ACP&#39;, lastActive: &#39;30 min ago&#39;, tasks: 0 }<br>That makes the dashboard render a new Pi agent card.</pre><pre>you&gt; /help<br>Commands:<br>  /status   -- show session status<br>  /history  -- show recent turn history<br>  /close    -- close session and exit<br>  /help     -- show this help<br>  exit      -- exit (session stays alive)</pre><p>Type a prompt, press Enter, get a response with full context retention. The wrapper supports any ACPX-compatible agent:</p><pre>./acpx-chat.sh codex my-session    # Interact with Codex<br>./acpx-chat.sh claude my-session   # Interact with Claude Code<br>./acpx-chat.sh gemini my-session   # Interact with Gemini CLI</pre><p>The ACPX team is actively designing a built-in solution. Their <a href="https://github.com/openclaw/acpx/blob/main/docs/2026-02-25-warm-session-owner-architecture.md">warm session owner architecture document</a> describes a planned detached daemon model that would keep sessions warm in the background. In the meantime, acpx-chat.sh is available in the repository.</p><h3>How the Stack Works</h3><p>Here is what made those demos possible. Three layers, each doing one job.</p><p><a href="https://github.com/openclaw/openclaw"><strong>OpenClaw</strong></a> is the gateway. It runs as a systemd service on a server, listens for messages from Telegram (or Discord, or Slack), and routes them to the right handler. When a message arrives, OpenClaw creates a session and hands the message to its configured model. The ACPX plugin ships bundled at extensions/acpx/, giving OpenClaw native support for spawning coding agents.</p><p><a href="https://ai.google.dev/"><strong>Gemini 3.1 Pro</strong></a> is the routing brain. It reads every incoming message, evaluates intent, and decides what to do. For coding tasks, it selects the best-suited agent. For general questions, it responds directly. What makes Gemini 3 effective here is its ability to internalize the acp-router skill, a multi-page routing specification describing all available agents, their capabilities, and the decision logic for selecting one. Gemini reads it once and follows it accurately across hundreds of requests.</p><p><a href="https://github.com/openclaw/acpx"><strong>ACPX</strong></a> is the protocol client. Think of it as the curl of the agent world. It speaks the <a href="https://agentclientprotocol.com/">Agent Client Protocol</a> to coding agents through thin adapter wrappers. Codex is the primary agent in these demos, but ACPX ships with adapters for Claude Code, Gemini CLI, OpenCode, Pi, and Kimi. Custom agents can be registered in ~/.acpx/config.json. See the Technical Appendix for the full adapter table.</p><p>The practical flow: a user sends “build me a Fibonacci script” in Telegram. OpenClaw receives it. Gemini reads the acp-router skill and classifies it as a coding task. It triggers the ACPX plugin with agentId: &quot;codex&quot;. ACPX spawns a headless Codex instance through its ACP adapter. Codex writes the script, executes it, captures the output. The output flows back through ACPX to OpenClaw, where Gemini formats a response and delivers it to Telegram. Under two minutes, end to end.</p><p>OpenClaw supports two routing paths: an <strong>ACP Runtime path</strong> (preferred) that creates thread-bound sessions managed by OpenClaw’s session lifecycle, and a <strong>Direct ACPX fallback</strong> that executes acpx codex exec directly when the runtime path encounters an error. The skill includes built-in recovery logic for automatic failover.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-MsSs9tYmYvrOoHTKXHXUw.png" /></figure><h3>Real-Time Monitoring with Cmux</h3><p>Running agents headless on a remote VM is powerful until something goes wrong and you have no visibility. <a href="https://github.com/manaflow-ai/cmux">Cmux</a> solved this.</p><p>I configured a monitoring workspace with three panes:</p><pre># Create a split pane for ACPX monitoring<br>cmux new-split right --json  # returns surface:N</pre><pre># SSH to the VM and tail gateway logs filtered for ACPX events<br>cmux send --surface surface:N \<br>  &#39;gcloud compute ssh codex-dev-qa --zone=us-central1-a --project=belha-ai&#39;<br>cmux send-key --surface surface:N Enter</pre><p>The most powerful feature for agent orchestration is cmux read-screen, which reads terminal output from any surface:</p><pre># Read the ACPX pane output<br>cmux read-screen --surface surface:81 --lines 30</pre><pre># Read with scrollback history<br>cmux read-screen --surface surface:81 --scrollback --lines 50</pre><p>This enabled coordination between Claude Code (composing this article on my laptop) and the ACPX pane (executing Codex sessions on the VM). One agent observing and responding to another agent’s output in real time. Cmux also delivers macOS notifications when agents complete tasks, so you do not have to stare at the terminal.</p><h3>Lessons Learned</h3><ol><li><strong>Headless permission mode is non-negotiable.</strong> Setting permissionMode: &quot;approve-all&quot; is required. Without it, the agent hangs waiting for human approval on every file operation and the pipeline freezes.</li><li><strong>Persistent sessions are not interactive REPLs.</strong> Each acpx codex -s workspace &quot;prompt&quot; is a separate CLI execution. Session state persists server-side, not client-side. That is why acpx-chat.sh was necessary.</li><li><strong>Event stream files are the best debugging tool.</strong> The NDJSON files at ~/.acpx/sessions/*.stream.ndjson contain every JSON-RPC message exchanged. More reliable than gateway logs for diagnosing issues.</li><li><strong>Gemini 3’s context window enables reliable routing.</strong> The acp-router skill is a multi-page specification. Models with smaller context windows cannot execute it consistently. Gemini 3.1 Pro reads it once and follows it accurately.</li><li><strong>Cmux transforms agent monitoring.</strong> The ability to read terminal output from one pane and relay it to another (cmux read-screen) is the foundation of multi-agent coordination. Notification rings provide immediate awareness of which agent needs attention.</li></ol><h3>The Broader Perspective</h3><p>What this project demonstrates is a working prototype of the AI agent mesh: a system where agents communicate through a structured protocol, orchestrated by an intelligent routing layer.</p><p>The architecture comprises three layers:</p><ol><li><strong>Protocol layer (</strong><a href="https://agentclientprotocol.com/"><strong>Agent Client Protocol</strong></a><strong>):</strong> A model-agnostic standard for agent communication. JSON-RPC 2.0 over stdio. Simple, debuggable, composable.</li><li><strong>Client layer (</strong><a href="https://github.com/openclaw/acpx"><strong>ACPX</strong></a><strong>):</strong> The universal client. Manages sessions, prompt queues, and permissions. Agent-agnostic by design.</li><li><strong>Orchestration layer (</strong><a href="https://github.com/openclaw/openclaw"><strong>OpenClaw</strong></a><strong> + </strong><a href="https://ai.google.dev/"><strong>Gemini 3</strong></a><strong>):</strong> The gateway receives messages from chat platforms. The routing brain reads skill documents, evaluates intent, selects agents, manages sessions, and formats responses. Together, they transform a Telegram message into a multi-agent workflow.</li></ol><p>As adoption of the Agent Client Protocol grows, the possibilities expand: intelligent routing where Gemini selects the optimal agent for each task, agent chaining where Codex writes code and Claude reviews it, persistent workspaces accessible from any chat platform, and full pipeline observability through <a href="https://github.com/manaflow-ai/cmux">Cmux</a>.</p><h3>Try It Yourself</h3><pre># Install OpenClaw and ACPX<br>npm i -g openclaw</pre><pre># Start the gateway<br>openclaw init<br>openclaw gateway start</pre><pre># Or skip the gateway and use ACPX directly<br>acpx --approve-all codex exec &quot;create a hello world script and run it&quot;</pre><pre># Or start an interactive chat session<br>./acpx-chat.sh codex my-session</pre><p>For the full setup (Gemini configuration, Telegram bot connection, ACPX plugin settings, and topic bindings) see the Technical Appendix.</p><p>The complete setup guide, acpx-chat.sh, the demo video, and all screenshots are available in the <a href="https://github.com/Timtech4u/remote-codex-dev-qa">GitHub repository</a>.</p><h3>References</h3><ul><li><a href="https://agentclientprotocol.com/">Agent Client Protocol</a></li><li><a href="https://github.com/openclaw/acpx">ACPX</a></li><li><a href="https://github.com/openclaw/openclaw">OpenClaw</a></li><li><a href="https://github.com/manaflow-ai/cmux">Cmux</a></li><li><a href="https://ai.google.dev/">Gemini 3.1 Pro</a></li><li><a href="https://github.com/Timtech4u/workspace-assistant">Workspace Assistant</a></li><li><a href="https://x.com/steipete/status/2030808763062505758">steipete on ACPX</a></li><li><a href="https://x.com/karpathy/status/2030722108322717778">Karpathy on agents</a></li></ul><h3>Appendix: Technical Reference</h3><h4>OpenClaw Gateway Config (ACPX Plugin)</h4><pre>{<br>  &quot;plugins&quot;: {<br>    &quot;entries&quot;: {<br>      &quot;acpx&quot;: {<br>        &quot;enabled&quot;: true,<br>        &quot;config&quot;: {<br>          &quot;permissionMode&quot;: &quot;approve-all&quot;,<br>          &quot;command&quot;: &quot;/home/tim/npm/lib/node_modules/openclaw/extensions/acpx/node_modules/.bin/acpx&quot;<br>        }<br>      }<br>    }<br>  }<br>}</pre><p>permissionMode: &quot;approve-all&quot; is required for headless operation. Without it, agents hang waiting for human approval on every file write and shell command.</p><h4>ACPX Client Config (~/.acpx/config.json)</h4><pre>{<br>  &quot;defaultPermissions&quot;: &quot;approve-all&quot;,<br>  &quot;agents&quot;: {<br>    &quot;openclaw&quot;: {<br>      &quot;command&quot;: &quot;openclaw acp --url ws://127.0.0.1:8080 --token-file /home/tim/.openclaw/gateway-token&quot;<br>    }<br>  }<br>}</pre><h4>Agent Adapters</h4><p><strong>Codex:</strong> npx @zed-industries/codex-acp (Primary coding agent)</p><p><strong>Claude Code:</strong> npx -y @zed-industries/claude-agent-acp</p><p><strong>Gemini CLI:</strong> gemini (Native ACP support)</p><p><strong>OpenCode:</strong> npx -y opencode-ai acp</p><p><strong>Pi:</strong> npx pi-acp</p><p><strong>Kimi:</strong> kimi acp</p><h4>ACP Protocol Methods</h4><p>initialize (Handshake and capability negotiation), session/new (Create a new execution session), session/load (Resume a prior session), session/prompt (Send a prompt to the agent), session/update (Stream output), session/cancel (Cancel an in-flight prompt), fs/read_text_file / fs/write_text_file (Client-side file I/O), terminal/create / terminal/output / terminal/kill (Terminal process management)</p><p><strong>Transport:</strong> JSON-RPC 2.0 over stdio | <strong>SDKs:</strong> TypeScript, Python, Rust, Kotlin | <strong>License:</strong> Apache 2.0</p><h4>Session Internals</h4><p>Sessions are stored in ~/.acpx/sessions/. Each session produces a metadata JSON file and an NDJSON event stream containing every JSON-RPC message exchanged.</p><p><strong>Queue owner model:</strong> The active acpx process holds the queue. Additional invocations enqueue prompts via Unix socket. Prompts process sequentially. The owner stays alive for a configurable TTL (default 300s; --ttl 0 for indefinite).</p><h4>Bindings Config (Auto-Routing Telegram Topics)</h4><pre>{<br>  &quot;bindings&quot;: [<br>    {<br>      &quot;type&quot;: &quot;acp&quot;,<br>      &quot;agentId&quot;: &quot;codex&quot;,<br>      &quot;match&quot;: {<br>        &quot;channel&quot;: &quot;telegram&quot;,<br>        &quot;accountId&quot;: &quot;default&quot;,<br>        &quot;peer&quot;: { &quot;kind&quot;: &quot;group&quot;, &quot;id&quot;: &quot;-1003305133020:topic:8&quot; }<br>      },<br>      &quot;acp&quot;: { &quot;mode&quot;: &quot;persistent&quot;, &quot;label&quot;: &quot;codex-main&quot; }<br>    }<br>  ]<br>}</pre><p>This binds a Telegram forum topic directly to a persistent Codex session. Every message in that topic routes to the agent without requiring an explicit routing prompt.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7b6ab5f1cbf4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Google Antigravity: The “Cursor Killer” Has Arrived?]]></title>
            <link>https://timtech4u.medium.com/google-antigravity-the-cursor-killer-has-arrived-7c194f845f7d?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/7c194f845f7d</guid>
            <category><![CDATA[gemini]]></category>
            <category><![CDATA[vibe-coding]]></category>
            <category><![CDATA[antigravity]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <category><![CDATA[gemini-3-pro]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Tue, 18 Nov 2025 17:30:57 GMT</pubDate>
            <atom:updated>2025-11-18T17:30:57.537Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2v7JiA5ZctwkAOEFj_dOHw.png" /><figcaption>Preview</figcaption></figure><p><em>Is this the end of coding as we know it? Google just dropped Gemini 3 and a new platform called Antigravity, and the developer world is buzzing.</em></p><p><a href="https://youtu.be/SVCBA-pBgt0">https://youtu.be/SVCBA-pBgt0</a></p><p>For months, tools like Cursor have dominated the conversation by integrating AI directly into VS Code. But today, Google didn’t just release another plugin. They released <strong>Google Antigravity</strong>, a dedicated <em>agentic development platform</em> powered by their new <strong>Gemini 3</strong> model.</p><p>It’s not just an upgrade; it’s a shift from the “AI Assistant” era to the <strong>“Agent-First” era</strong>. Here is everything you need to know about the release that might just change how we build software forever.</p><h3>1. The Command Center: Agent Manager View</h3><p>Google Antigravity is described as an “agentic development platform.” Unlike a traditional IDE where AI suggests code as you type, Antigravity is built around the concept of <strong>agents</strong>.</p><p>In this new paradigm, you act less like a bricklayer and more like an <strong>architect</strong>. You define the tasks, and intelligent agents execute them. These agents aren’t stuck in a chat window; they have autonomy across:</p><ul><li><strong>The Editor</strong>: Writing and refactoring code.</li><li><strong>The Terminal</strong>: Running commands, installing dependencies, and debugging.</li><li><strong>The Browser</strong>: Previewing apps and verifying changes.</li></ul><h4>The “Manager” View</h4><p>One of the standout features is the <strong>Agent Manager View</strong>. This isn’t just a file explorer; it’s mission control. You can spin up multiple agents to work on different parts of your project simultaneously.</p><ul><li><strong>Delegate</strong>: Assign one agent to fix a bug in the login flow while another refactors the CSS.</li><li><strong>Track</strong>: Watch them generate “Artifacts” — real-time to-do lists, screenshots, and logs — so you know exactly what they are doing without reading every line of code.</li><li><strong>Verify</strong>: The agents don’t just write code; they run it, check the browser output, and verify the fix works.</li></ul><p>This allows for workflows that were previously impossible. You can tell an agent, <em>“Fix the bug in the login flow and verify it in the browser,”</em> and it can plan the steps, edit the files, run the server, and check the result — all while you watch (or go grab a coffee).</p><h3>2. Powered by Gemini 3: The New King of Reasoning?</h3><p>The engine under the hood is <strong>Gemini 3 Pro</strong>. Google claims this is their most intelligent model yet, specifically tuned for reasoning and coding.</p><ul><li><strong>Benchmarks</strong>: It scores <strong>54.2%</strong> on Terminal-Bench 2.0 (testing tool use in terminals).</li><li><strong>WebDev Arena</strong>: It tops the leaderboard with an Elo of <strong>1487</strong>.</li><li><strong>Multimodal</strong>: It has advanced visual and spatial reasoning, meaning it can “see” your UI and understand layout issues better than text-only models.</li></ul><h3>3. The Rise of “Vibe Coding”</h3><p>One of the most interesting terms Google is pushing is <strong>“Vibe Coding.”</strong></p><p>The idea is simple: Natural language is the only syntax you need. Because Gemini 3 has improved instruction following and deep tool use, you can describe a high-level idea — a “vibe” — and the model handles the heavy lifting of multi-step planning and implementation.</p><p>It’s not just about generating a snippet; it’s about translating a sentence like <em>“Make it look like a 90s cyberpunk terminal”</em> into a fully interactive, styled application.</p><h3>4. Is It a Cursor Competitor?</h3><p>Absolutely, but the comparison is nuanced.</p><p><strong>Cursor</strong> won hearts by making AI feel native to VS Code. It excels at <em>augmenting</em> your coding speed — predicting your next edit, answering questions about your codebase, and fixing errors as you type. It is the ultimate tool for the “Daily Coder.”</p><p><strong>Antigravity</strong> attempts to leapfrog that by making the <em>entire environment</em> agentic. It is built for the “Task Delegator.”</p><p>With features like a <strong>client-side bash tool</strong> (allowing the model to run shell commands safely) and <strong>Google Search grounding</strong> (so it doesn’t hallucinate libraries that don’t exist), Google is aiming for a more autonomous developer experience.</p><h3>5. Pro Tips for Your First Flight</h3><p>If you are downloading the preview, here are a few tips to get the most out of it:</p><ol><li><strong>Don’t Code, Architect</strong>: Resist the urge to type everything yourself. Try giving high-level goals like <em>“Refactor this component to use React Hooks”</em> and watch the agent plan the steps.</li><li><strong>Use the Manager</strong>: Keep the Agent Manager view open. It’s the best way to see the “brain” of the operation — the artifacts and plans the agent is creating.</li><li><strong>Bring Your Own Model</strong>: While Gemini 3 is the star, Antigravity supports other models like <strong>Claude Sonnet 4.5</strong> and <strong>OpenAI’s GPT-OSS</strong>. If you have a preference, you can switch the “brain” of your agent.</li><li><strong>Leverage “Vibe Coding”</strong>: When starting a new project, don’t worry about the tech stack details initially. Describe the <em>feeling</em> and <em>functionality</em> you want, and let the agent scaffold the entire app.</li></ol><p>Google Antigravity is available now in <strong>public preview</strong> for free. You can download it for macOS, Windows, and Linux from <a href="https://antigravity.google/">antigravity.google</a>.</p><p>Gemini 3 Pro is also available in Google AI Studio and via the Gemini API.</p><h3>The Verdict</h3><p>We are moving from “AI-assisted” to “AI-driven” development. Whether Antigravity replaces your daily driver IDE remains to be seen, but one thing is clear: the bar has just been raised.</p><p><em>Have you tried Antigravity yet? Let me know your thoughts in the comments!</em></p><p>References</p><ul><li>Annoucement: <a href="https://blog.google/technology/developers/gemini-3-developers">https://blog.google/technology/developers/gemini-3-developers</a></li><li>Tutorial: <a href="https://www.youtube.com/watch?v=nTOVIGsqCuY">https://www.youtube.com/watch?v=nTOVIGsqCuY</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7c194f845f7d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Usebelha — Multi-Tenant AI Customer Support with Google ADK]]></title>
            <link>https://timtech4u.medium.com/usebelha-multi-tenant-ai-customer-support-with-google-adk-5b46e2575f25?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/5b46e2575f25</guid>
            <category><![CDATA[google-adk]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Tue, 11 Nov 2025 02:02:26 GMT</pubDate>
            <atom:updated>2025-11-11T02:02:26.521Z</atom:updated>
            <content:encoded><![CDATA[<h3>Usebelha — Multi-Tenant AI Customer Support with Google ADK</h3><h4>Inspiration</h4><p>Customer support is the backbone of any successful business, but building a custom AI support system is typically complex, expensive, and out of reach for small businesses and startups — especially in emerging markets.</p><p>I was inspired by ANDO Foods, a food delivery platform in Kigali, Rwanda, that faces unique challenges: OTP verification issues in regions with spotty WhatsApp connectivity, customers needing support in multiple languages (English, French, Kinyarwanda), and the need to scale support without prohibitive costs.</p><p>I wanted to prove that with Google’s latest AI tools — ADK, Gemini, and Cloud Run — a single developer could build production-ready, enterprise-grade AI customer support in days, not months, and at a cost accessible to any business.</p><h4>What it does</h4><p>Usebelha is a multi-tenant AI customer support platform that provides intelligent, context-aware support for multiple companies from a single deployment.</p><h4>Key Features:</h4><ul><li>Auto-Discovery: Drop markdown files into a KB/company-name/ folder, and Usebelha automatically discovers the tenant and creates an isolated AI agent</li><li>Intelligent Responses: Powered by Gemini Flash Experimental with File Search API for accurate, knowledge-based answers</li><li>Real-Time Streaming: Server-Sent Events deliver responses word-by-word as they’re generated, just like ChatGPT</li><li>Perfect Isolation: Each company gets a dedicated File Search store — zero cross-contamination of data</li><li>Suggested Questions: Smart UI shows top questions from each tenant’s knowledge base</li><li>Human-in-the-Loop: Seamlessly escalates to human support when the AI can’t help</li><li>Multi-Language Ready: Gemini natively handles English, French, Kinyarwanda, and 100+ languages</li><li>Cost-Effective: Around $16/month total infrastructure cost vs $50–200/user/month for traditional solutions</li></ul><p>Live Demo: I’m showcasing Usebelha with ANDO Foods at <a href="https://timtech4u.dev/usebelha-preview/andofoods.co/">https://timtech4u.dev/usebelha-preview/andofoods.co/</a></p><p>The chatbot answers questions about:</p><ul><li>Delivery fees (RWF 1,500)</li><li>OTP verification troubleshooting</li><li>Payment methods (Cash &amp; MoMoPay)</li><li>Order tracking</li><li>Account management</li></ul><p>All knowledge comes from simple markdown files — no database setup, no complex configuration.</p><p>How we built it</p><h4>Architecture:</h4><p>I built Usebelha using a multi-agent architecture with Google ADK:</p><ol><li>Router Agent (entry point)</li></ol><ul><li>Extracts company domain from userId (format: domain:email)</li><li>Routes requests to the correct tenant-specific agent</li></ul><p>2. File Search Agents (one per tenant)</p><ul><li>Searches company-specific knowledge base in Gemini File Search</li><li>Returns contextualized, accurate answers</li><li>Powered by Gemini Flash Experimental</li></ul><h3>Tech Stack:</h3><h4>Backend:</h4><ul><li>Go (Golang) for high performance and concurrency</li><li>Google ADK for agent orchestration</li><li>Gemini Flash Experimental for AI responses</li><li>Gemini File Search API for knowledge management</li></ul><h4>Frontend:</h4><ul><li>React + TypeScript</li><li>TanStack Router for routing</li><li>Server-Sent Events for real-time streaming</li><li>Tailwind CSS for styling</li></ul><h4>Infrastructure:</h4><ul><li>Google Cloud Run for serverless deployment</li><li>Google Secret Manager for API keys</li><li>Multi-stage Docker build for optimal container size</li><li>CORS middleware for multi-domain support</li></ul><h3>Challenges we ran into</h3><h4>Challenge 1: Store ID Mismatch Bug</h4><p>The biggest challenge was a tricky bug where Gemini’s File Search API auto-generates store IDs instead of using my provided ones.</p><p>Expected: fileSearchStores/andofoods-co-docs Actual: fileSearchStores/andofoodsco-support-documen-mymt0ofn609v</p><p>This caused “Corpora does not exist” errors for hours until I realized the registry wasn’t capturing the actual generated IDs.</p><p>Solution: Update the registry with the actual store.Name returned by the API.</p><p>Lesson: Always capture what APIs actually return, not what you expect!</p><h4>Challenge 2: Cloud Run Cold Starts</h4><p>First requests after idle periods took 3–5 seconds, creating poor UX.</p><p>Solutions:</p><ul><li>Implemented loading states and skeleton screens in UI</li><li>Used streaming to show responses as they arrive (reduces perceived latency)</li><li>Optimized Docker image with multi-stage builds</li><li>For production: set minimum instances to 1</li></ul><h4>Challenge 3: Multi-Tenant Security</h4><p>Ensuring perfect data isolation between tenants was critical.</p><p>Solutions:</p><ul><li>Separate File Search stores per tenant</li><li>Extract domain from userId on every request</li><li>Validate tenant access before searches</li><li>No shared data structures across tenants</li></ul><h4>Challenge 4: Session Management</h4><p>ADK sessions needed to handle the “session already exists” case gracefully.</p><p>Solution: Treat “already exists” as success rather than error.</p><p>Accomplishments that we’re proud of</p><ul><li>Built in 48 hours: From idea to production-ready platform with a real demo</li><li>Production-Ready: Not just a hackathon demo — includes error handling, retry logic, CORS, health checks, monitoring</li><li>Real-World Demo: ANDO Foods is a real business in Rwanda, demonstrating practical value for emerging markets</li><li>Incredibly Cost-Effective: $16/month vs $50–200/user/month for traditional solutions — democratizing AI support</li><li>Auto-Discovery: Zero configuration multi-tenancy — just add folders and it works</li><li>Instant Streaming: Real-time responses feel as fast as ChatGPT</li><li>Multi-Language: Ready for Kinyarwanda, French, English without any extra code</li><li>Great UX: Suggested questions, connection status, retry logic, typing indicators</li></ul><h3>What we learned</h3><h4>Technical Learnings:</h4><ol><li>Google ADK is Powerful: The agent orchestration capabilities make complex multi-agent systems surprisingly simple</li><li>Gemini File Search is Excellent: The semantic search quality is outstanding — it finds relevant answers even with different phrasing</li><li>Cloud Run is Magic: From git push to production in 3 minutes, with auto-scaling and zero maintenance</li><li>Streaming is Essential: SSE makes AI responses feel instant and keeps users engaged</li><li>Go + React is a Great Stack: Go’s concurrency for backend, React’s reactivity for frontend — perfect match</li></ol><h4>Business Learnings:</h4><ol><li>Emerging Markets Need This: ANDO’s challenges (OTP issues, multi-language, cost constraints) are common across Africa — huge opportunity</li><li>Multi-Tenancy is Key: SaaS businesses need isolated data — solving this unlocks massive scale</li><li>Simplicity Wins: Markdown files for knowledge bases beats complex database schemas</li></ol><h4>Personal Growth:</h4><ol><li>Ship Fast: Perfect is the enemy of done — the working demo is what matters</li><li>Real Users Matter: Using ANDO Foods forced me to think about real problems, not hypothetical ones</li><li>Cost Awareness: Keeping it at $16/month makes it accessible to businesses that need it most</li></ol><h3>What’s next for Usebelha</h3><h4>Short-Term (Next 2 Weeks):</h4><ul><li>Analytics Dashboard: Track common questions, resolution rates, escalations per tenant</li><li>File Attachments: Already implemented — needs production testing for uploading images/PDFs</li><li>WhatsApp Integration: Connect directly to WhatsApp Business API for where African customers already are</li></ul><h3>Medium-Term (Next Month):</h3><ul><li>Usage Metrics: Per-tenant analytics showing cost, volume, satisfaction</li><li>Custom Branding: Tenant-specific colors, logos, and styling</li><li>Webhook Support: Notify Slack/Discord/email when HITL is triggered</li><li>Voice Support: Leverage Gemini’s multimodal capabilities for voice queries</li></ul><h4>Long-Term Vision:</h4><ul><li>Marketplace: Let businesses create and sell knowledge bases for common industries</li><li>Agent Marketplace: Pre-built agents for e-commerce, healthcare, fintech, etc.</li><li>Multi-Channel: Support chat, email, SMS, voice from one platform</li><li>Self-Learning: Agents learn from resolved escalations to improve over time</li></ul><h4>Immediate Next Steps:</h4><ol><li>Reach out to ANDO Foods for real feedback and potential partnership</li><li>Open-source the project for community contributions</li><li>Create video tutorials for setting up tenants</li><li>Write case studies showing ROI for different business sizes</li><li>Explore Google Cloud credits for African startups</li></ol><p>Built with love for businesses in emerging markets.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5b46e2575f25" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Enhancing Agents with Multimodal Capabilities: ADK + MCP — Part 2 of 3]]></title>
            <link>https://timtech4u.medium.com/enhancing-agents-with-multimodal-capabilities-adk-mcp-part-2-of-3-25d6eb243d42?source=rss-c6aa82026e26------2</link>
            <guid isPermaLink="false">https://medium.com/p/25d6eb243d42</guid>
            <category><![CDATA[google-adk]]></category>
            <category><![CDATA[model-context-protocol]]></category>
            <dc:creator><![CDATA[Timothy]]></dc:creator>
            <pubDate>Sun, 18 May 2025 19:56:12 GMT</pubDate>
            <atom:updated>2025-05-18T19:56:12.134Z</atom:updated>
            <content:encoded><![CDATA[<h3>Enhancing Agents with Multimodal Capabilities: ADK + MCP — Part 2 of 3</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IjvS4Y-oud-r14lmgsbrFw.png" /></figure><p>The Model Context Protocol (MCP) is an open standard that standardizes how LLMs interact with external tools and data sources. Think of it like a “USB-C for AI applications”, providing a universal way to connect AI models to different tools, services, and repositories. When combined with Google’s Agent Development Kit (ADK), it enables your agents to:</p><ol><li>Access pre-built tools and services</li><li>Support multimedia content (images, files, etc.)</li><li>Create interactive, multi-modal experiences</li></ol><h3>Prerequisites</h3><p>Before getting started, ensure you have:</p><ul><li>Python 3.9+</li><li>ADK installed (pip install google-adk)</li><li>Node.js and npx (for some MCP servers)</li><li>MCP package (pip install model-context-protocol)</li></ul><h3>Integrating MCP with ADK</h3><h3>1. File System Example</h3><p>Let’s enhance our weather agent with file system capabilities:</p><pre># weather_mcp_agent/agent.py<br>import os<br>import asyncio<br>from contextlib import ExitStack<br>from google.adk.agents import Agent<br>from google.adk.tools.mcp import MCPToolset, StdioServerParameters<br><br>async def setup_agent():<br>    # Connect to MCP File System server<br>    tools, exit_stack = await MCPToolset.from_server(<br>        connection_params=StdioServerParameters(<br>            command=&#39;npx&#39;,<br>            args=[&#39;-y&#39;, &#39;@modelcontextprotocol/server-filesystem&#39;]<br>        )<br>    )<br>    <br>    # Our weather tool function<br>    def get_weather(location: str) -&gt; str:<br>        &quot;&quot;&quot;Get the weather for a specific location&quot;&quot;&quot;<br>        return f&quot;The weather in {location} is sunny with a temperature of 70 degrees.&quot;<br>    <br>    # Create agent with both our tool and MCP tools<br>    return Agent(<br>        name=&quot;weather_fs_agent&quot;,<br>        description=&quot;An agent that can get weather and access files&quot;,<br>        tools=[get_weather] + tools,<br>        model=&quot;gemini-2.0-flash&quot;,<br>    ), exit_stack<br><br># Set up the root_agent (required by ADK CLI)<br>root_agent, _ = asyncio.run(setup_agent())</pre><h3>2. Directory Structure</h3><pre>weather_mcp_agent/<br>  ├── __init__.py<br>  ├── agent.py<br>  └── .env</pre><h3>3. Running the MCP-Enhanced Agent</h3><pre># Run in interactive CLI mode<br>adk run weather_mcp_agent<br><br># Run with web UI<br>adk web weather_mcp_agent</pre><h3>Example Interaction</h3><p>Here’s what interacting with the MCP-enhanced agent looks like:</p><pre>user: What files are in my current directory?<br>[weather_fs_agent]: I can help you check that. Let me list the files in your current directory.<br><br>The files in your current directory are:<br>- agent.py<br>- __init__.py<br>- .env<br><br>user: What&#39;s the weather in Paris?<br>[weather_fs_agent]: The weather in Paris is sunny with a temperature of 70 degrees.<br><br>user: Create a report about today&#39;s weather<br>[weather_fs_agent]: I&#39;ll create a weather report file for you.<br><br>I&#39;ve created a file called &quot;weather_report.txt&quot; with the following content:<br><br>Weather Report<br>Date: May 18, 2025<br>-----------------------<br>Today&#39;s weather is sunny with a temperature of 70 degrees.<br>Perfect weather for outdoor activities!</pre><h3>Popular MCP Servers</h3><p>ADK can connect to various MCP servers:</p><ol><li><strong>File System</strong> (@modelcontextprotocol/server-filesystem)|<br>Read, write, and manage files with configurable permissions</li><li><strong>Google Maps</strong> (@modelcontextprotocol/server-google-maps)<br>Geocoding, directions, place details, and location services</li><li><strong>Browser/Brave Search</strong> (@modelcontextprotocol/server-brave-search)<br>Web search, page reading, content extraction</li><li><strong>Vector Database/Qdrant</strong> (mcp-server-qdrant)<br>Document storage, semantic search, and memory management</li><li><strong>GitHub</strong> (@modelcontextprotocol/server-github)<br>Repository management, code access, pull requests</li><li><strong>PostgreSQL</strong> (@modelcontextprotocol/server-postgresql)<br>Database queries, schema inspection, and data retrieval</li></ol><h3>Advanced: Creating Custom MCP Servers</h3><p>You can also expose your ADK tools as an MCP server:</p><pre>from model_context_protocol.server import Server<br>from model_context_protocol.model import Tool, Parameter, ToolFunction, ParameterType<br><br># Create MCP server<br>server = Server()<br><br># Register tool<br>@server.register_tool<br>def my_tool() -&gt; Tool:<br>    return Tool(<br>        name=&quot;my_custom_tool&quot;,<br>        description=&quot;My custom tool description&quot;,<br>        parameters=[<br>            Parameter(name=&quot;param1&quot;, type=ParameterType.STRING)<br>        ],<br>        function=ToolFunction(name=&quot;execute_my_tool&quot;)<br>    )<br><br># Add implementation<br>@server.register_tool_execution(tool_name=&quot;my_custom_tool&quot;)<br>async def execute_my_tool(param1: str):<br>    # Implement your custom tool functionality here<br>    result = f&quot;Processed: {param1}&quot;<br>    return result<br><br># Start server<br>server.start()</pre><h3>Practical Tips</h3><ol><li><strong>Tool Discoverability</strong>: Allow your agent to “discover” MCP tools at runtime</li><li><strong>Error Handling</strong>: Implement robust error handling for MCP tool failures</li><li><strong>Server Management</strong>: Properly manage MCP server lifecycle with ExitStack</li><li><strong>Performance</strong>: Consider caching strategies for expensive MCP operations</li><li><strong>Security</strong>: Implement appropriate access controls and permissions</li></ol><h3>Coming Next</h3><p>In Part 3, we’ll explore Agent-to-Agent (A2A) communication, allowing your ADK agents to collaborate with other agents through an open protocol. A2A is a key part of Google’s agent ecosystem, enabling collaboration between agents built with different frameworks and by different vendors.</p><blockquote><strong><em>Resources:</em></strong></blockquote><ul><li><a href="https://google.github.io/adk-docs/">Official ADK Documentation</a></li><li><a href="https://modelcontextprotocol.io/">Model Context Protocol (MCP) Documentation</a></li><li><a href="https://github.com/modelcontextprotocol">MCP GitHub Repository</a></li><li><a href="https://timtech4u.medium.com/building-and-deploying-ai-agents-in-minutes-with-googles-adk-part-1-abbf2ed43486">Part 1: Basic ADK Agents</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=25d6eb243d42" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>