网页
综合
更新时间 2026-10-01 23:52:58
The AI clerk approved a 41 cm dragon. Your job is to stamp DENIED. - DEV Community
自动蜘蛛
dev.to
正文约 6000 字
Sanity Challenge Path Two Submission
This is a submission for the Sanity Challenge, Path Two: Vibe-Code Something Strange
The Bureau of Imaginary Permits: a pixel-art inspection-booth game about bureaucracy for things that don't exist, running on real Sanity Workflows.
You take the window. Applicants step up one at a time, wanting a Licence to Whistle on Tuesdays, a Permit to Keep a Small Dragon (Indoor), or the Deed to a Medium-Sized Cloud. They slide over their papers: an application, a Citizen Card with a photo, sometimes a licence they already hold.
Every file arrives already passed by Clerk Third Class, an AI. Its memo sits on your desk: "Named dragon, licensed puddle on file, fire plan mentions water. In order." The clerk is tired, though. The dragon is 41 cm, and the Rulebook says 35. You pull out the stamp tray, slam DENIED into the box, and hand the papers back.
That is the Workflows bonus prompt played straight: "an agent can move a draft forward and a person can approve it." Here the agent always moves it forward, and the person is the only thing standing between a forged Citizen Card and a Licence to Look Up.
Behind the window there is a real citizen side. Anyone can file a permit:
Play: https://bureau-of-imaginary-permits.vercel.app/shift (no account; seven applicants a day, two days)
The citizen side: a real file that went through both AIs and two human signatures, with the GROQ rule behind every move.
A pixel-art inspection-booth game about bureaucracy for things that don't exist, built on Sanity Workflows.
Play: https://bureau-of-imaginary-permits.vercel.app/shift (no account needed)
You take the window. Applicants step up one by one, wanting a Licence to Whistle on Tuesdays, a Permit to Keep a Small Dragon (Indoor), or the Deed to a Medium-Sized Cloud. Each hands over a Citizen Card, an application, and sometimes a licence they already hold.
The AI clerk has already passed every file. The clerk is tired. Your job is to compare the papers against the Rulebook and the day's bulletin, stamp APPROVED or DENIED, and hand them back. Wrong stamps print a citation. Day 2 changes the rules.
There is also a real citizen side. Anyone can file a permit: a real AI clerk (Gemini) reads it, a second AI (the Ministry of Weather) rules on anything in the sky, and human…
IDE: Claude Code (Opus 5.5) in a Windows terminal. I typed very little, and that's the honest shape of this build. Claude wrote, ran and tested everything, and kept a BUILD-LOG.md as it went. This section comes from that log.
That's it. Everything else below is what an agent did with those sentences, including where it went wrong.
The first build was a tasteful government-forms site: paper colours, a serif, rubber-stamp CSS. It worked end to end, but it looked like every other "nice" AI-built site. That was my second "too vibecoded" across two challenge entries, so the brief became: commit to a world.
Claude's first plan was to model the process itself, with a workflow type holding stages[] and transitions[]. Before writing it, it followed the "Workflows" link in the challenge post and found @sanity/workflow-engine (early access, on npm):
The hand-rolled schema was dropped. There are now four chains, all data:
Starting a shift turns the day's scripted case documents into real applications, each governed by a booth-inspection instance. Your stamp is a real fireAction. The server then scores it from the decision the engine recorded on the instance, checked against case.truth. The browser never reports its own score. Day sheets are shift documents, which is the leaderboard.
Honesty note: the clerk memos on scripted applicants are authored, not generated. Every file at the window arrives "passed" because that's the premise. If the real clerk saw those files, it would reject them, and they'd never reach you. The citizen side uses the real AI clerk.
After the fix, it quotes the answer that fails ("'Any time she fancies' fails the rule…") and accepts a correct reply.
Citizen files that reach a human desk land in the Stamp Desk, a React app deployed into the Sanity dashboard and built on @sanity/workflow-sdk:
I checked a real stamp on the instance. The approve row is signed by my own Sanity user with executionContext: {kind: "sdk", runtime: "browser"}. The website's server token signs its rows as bureau-web. The move to issued was committed by the same browser session: the engine runs the cascade inside fireAction, so a human stamp needs no server.
Status: Sanity Workflows is a real npm engine (@sanity/workflow-engine 0.36, early access). I'm reading its API so the permit approval chains run on the actual engine and aren't hand-rolled.
Everything is deployed. One check is still blocked on you: IP-ZQ8YWL is still waiting at the Under-Secretary's desk, so I haven't seen a stamp from the Stamp Desk yet.
Your next steps: 1. In the Stamp Desk, click Stamp APPROVED on IP-ZQ8YWL and send me a screenshot. - I'll then check that the engine recorded the stamp under your Sanity identity, not the server's token. The post's App SDK claim depends on that, so it stays unconfirmed until then. - The desk shows your real name ("Signing as…"). Blur it in any screenshot that goes into the post. 2. Create the repo and push it. Run these yourself: cd [REDACTED]\Desktop\bureau-of-imaginary-permits git init git add . git commit -m "initial commit" gh repo create malbolged/bureau-of-imaginary-permits --public --source . --push submission/ and .env are in .gitignore, so neither gets pushed.
Ready on disk (in bureau-of-imaginary-permits\): - README.md, and BUILD-LOG.md kept up to date as the build went. - submission\post.md: the full DEV draft in the Path Two template, with the required first line and an explicit answer on which AI-native IDE was used. It still has three placeholders: screenshots, the desk screenshot and the session embed. - submission\images\: 5 production screenshots (home, application form, file returned to the citizen, issued cloud cer
本页为82搜索生成的网页快照,内容来自站内索引;演示数据的原文链接仅作示例。