v0.42 Release: A Doodle of the Day, Chosen and Drawn by Smarter’s Own AI Applications
v0.41 gave the people who run a Smarter platform an MCP server for their help desk. v0.42 puts Smarter’s own AI applications to work for the platform itself. Two LLMClients now choose and draw the illustration on the sign-in page each day, a third answers the staff’s operations questions, and a new staffOnly setting keeps all three out of everyone else’s sight.
This post covers v0.41.1 through v0.42.0.
| Change | What it does |
|---|---|
| The Doodle | The sign-in page shows a small illustration that is decorated for holidays and days worth celebrating, and can differ by region. |
| AI editor and artist | Two LLMClients choose each region’s doodle, follow what each region is reading about, and draw occasions the catalog has no artwork for. |
| Staff-only LLMClients | An LLMClient that only the platform’s own staff can see, chat with or call. |
| Smarter Sysadmin | A staff-only LLMClient that answers operations and help desk questions with the MCPServer’s staff-only tools. |
| One email, one user | Users who shared an email address are merged, and an address now belongs to one user. |
A doodle on the sign-in page
The sign-in pages used to show a greyscale stock illustration of crypto widgets, which had nothing to do with Smarter. It is replaced by the Doodle. That’s a small, colorful scene of an LLMClient’s chat window, with the plugin, guardrail, vectorstore and secret around it, decorated for the day in the spirit of a search engine’s doodle. On Pi Day the digits of pi float above it. On Diwali, diyas glow below it.
The catalog has 19 occasions and a plain default scene. They include New Year’s Day, Lunar New Year, Python’s birthday, International Women’s Day, Pi Day, Eid al-Fitr, Earth Day, Ada Lovelace Day, Dia de Muertos, Diwali, Hanukkah, Christmas, and the national days of Canada, Mexico and the United States, in their colors rather than their flags. Each occasion is a YAML file and an SVG of its props.
slug: diwali
name: Diwali
category: celebration
caption: Happy Diwali!
alt_text: Glowing diyas line the ground below a Smarter LLMClient, under a string of colorful lights.
link_url: https://en.wikipedia.org/wiki/Diwali
priority: 70
regions: [south-asia, southeast-asia, us, ca, europe, oceania, africa, global]
schedule:
kind: holiday
country: IN
holiday: Diwali
- Twelve regions. The browser sends its time zone, and Smarter maps it to one of 12 regions, such as Latin America, South Asia or Oceania. A holiday starts at the visitor’s local midnight. No IP address is looked up, and nothing about the visitor is stored.
- Three kinds of date. A fixed date, the nth weekday of a month, or a country’s holiday by name. Moving holidays such as Diwali, Lunar New Year, Eid al-Fitr, Hanukkah and Thanksgiving are dated by the
holidayspackage. - Planned a week ahead. A background job plans every region’s doodle from yesterday to seven days ahead, every six hours, and deletes doodles older than 30 days.
- People have the last word. Superusers can override any day’s doodle in the Django admin, and Preview the week shows every region’s doodle of every planned day, with an Approve and a Reject button on each. A doodle a person chose is never replanned.
- It never breaks sign-in. The page shows the plain scene at once, and keeps it if anything fails.
An editor and an artist that are LLMClients
A calendar only celebrates what’s in its catalog. So two staff-only LLMClients, smarter_doodle_editor and smarter_doodle_artist, now help. Once for each new day, the platform sends the editor a JSON list of what is due in each region. That covers the catalog’s occasions, the region’s other public holidays, and, for today and tomorrow, what the region is reading about on Wikipedia. The editor chooses one for each region. When it picks something the catalog has no artwork for, the artist draws it.
The platform prompts them through the same chat API as any other LLMClient, so their system prompts, Guardrails, journal and cost accounting all apply. When the editor or the artist chose a doodle, the sign-in page says so (“Chosen by a Smarter AI application” or “Drawn by a Smarter AI application”), with a Learn how link.
In local testing, the editor chose Diwali where it was due, and drew Japan’s Culture Day, Liberia’s Thanksgiving and the Formula One season.
Following trends
Holidays can be planned a week ahead. A World Cup final can’t. For today and tomorrow, the editor takes a second look, with each region’s most viewed Wikipedia articles from the Wikimedia pageviews API, in the languages its readers use (Spanish and Portuguese for Latin America, for example). Smarter reads each article’s English label and description from Wikidata, and keeps only occasions such as a tournament, a festival, an eclipse or a launch. People, dates and anything with a blocked word are dropped before the editor sees them.
Security
Nothing the editor or the artist answers is trusted.
- Only what it was given. Every choice is checked again. It must be one of the region’s candidates, have a short caption, alt text, and an English Wikipedia link or none.
- Blocked topics. Mourning, war, politics, monarchy, accidents, crimes, disasters and a single religion’s holy days are refused, with the same language matching as plugin selectors. That covers plurals, typos and synonyms, but never a word inside another word.
- A tone check by a Guardrail. Word lists can’t tell sad news from a festival, so every occasion that would be drawn is judged by
upbeat_occasion_input, anllm_judgeGuardrail. If the judge declines, fails or is missing, the occasion is declined. In testing, it declined a Diwali trend. - A strict SVG sanitizer. The artist’s drawing keeps only shapes, groups and styles, and only geometry, paint, transform and class attributes. Event handlers, links,
url(),javascript:anddata:are removed, and its CSS may only animate its own prefixed classes, so it can’t restyle the page. - Approval first. A drawn doodle is proposed, and waits for a superuser’s approval, unless you turn on
enable_doodle_auto_approve. If the artist fails, the calendar’s doodle stays.
apiVersion: smarter.sh/v1
kind: Guardrail
metadata:
name: upbeat_occasion_input
description: Judges whether an occasion is fun, upbeat and celebratory enough for a cheerful illustration,
with a small LLM. The sign-in page's doodle declines every occasion that it triggers on.
version: 1.0.0
spec:
config:
isActive: true
mode: enforce
stage: input
category: custom
strategy: llm_judge
judgePrompt: |-
You decide whether an occasion is right for a small, cheerful illustration that decorates the
sign-in page of an educational platform, seen by students and teachers around the world.
...
model: gpt-6-luna
threshold: 0.5
action: block
message: This occasion isn't upbeat enough for a doodle.
Each switch is a waffle switch, so an operator can turn off the AI editor, the AI artwork, the trends or the credit line separately. Without the example manifests, the calendar alone chooses.
For a walkthrough of the design, read An LLM Editor and an SVG Artist, which is also where the sign-in page’s Learn how link goes.
LLMClients for staff only
Some LLMClients are for the people who run the platform, because their tools read what nobody else may see. A new manifest setting, spec.config.prompt.staffOnly, hides an LLMClient from everyone but the platform’s staff. That includes the lists, the workbench, the deployment page, the REST API and its prompt URL, which answers 404. Superusers of other accounts don’t see it either.
apiVersion: smarter.sh/v1
kind: LLMClient
metadata:
name: smarter_sysadmin
description: "A site reliability engineer for the staff of this Smarter platform, who answers help desk questions from its health, its pod logs and its users' accounts."
version: 1.0.0
spec:
config:
prompt:
staffOnly: true
appName: Smarter Sysadmin
defaultModel: gpt-6-luna
provider: openai
deployed: false
mcpClients:
- smarter_operations
- smarter_project
guardrails:
- prompt_injection_keyword_input
- secrets_redaction_input
- secrets_leak_output
- script_injection_output
- Platform staff, defined. Platform staff are active staff users of the Smarter account, the account that runs the platform. The admins of customer accounts are staff of their own accounts only.
- Only staff can own one. The manifest broker refuses
staffOnly: truefrom anyone else. - Never copied, never deployed.
load_from_githubapplies a staff-only LLMClient to the Smarter account only, never copies it into other accounts, and never deploys it.
Smarter Sysadmin
smarter_sysadmin is the first staff-only LLMClient in the example manifests. It answers questions such as “Is Smarter healthy right now?” or “A user says their prompt failed with a system error an hour ago. What happened?” with the MCPServer’s staff-only tools, and reads Smarter’s code to explain an error it found in the logs. In v0.41 those tools could only be used from Claude Code with a personal API key. Now a staff member can use them from the workbench.
Security
An MCPClient sends the same credential for everyone who chats, so the MCPServer could not know who was asking. Now the platform says so itself.
- A signed identity. For a request to its own staff-only endpoint, the platform adds the chatting user’s ID, signed with its secret key, and valid for five minutes. No other MCP server ever receives it, and an MCPClient manifest can’t set that header.
- Platform staff only. The endpoint refuses anyone who is not platform staff. In v0.41 it accepted any active user with
is_staff, which includes the admins of customer accounts. That was too broad, and is fixed. - Audited and never cached. Every call is recorded under the staff member who asked, and its result is never cached, so each one reaches the audit trail.
📖 Staff-only LLMClients · 📖 MCPServer documentation
One email address, one user
On one platform, a person’s sign-in failed eight times in an hour with a server error. Two users had the same email address, and Django’s user model doesn’t require it to be unique. A password reset didn’t help, because it reset only one of them.
v0.42 merges users who share an address, then makes the address unique in the database.
- Who survives. Addresses are compared without case or trailing spaces. The user who signed in most recently keeps their username and credentials, and takes the others’ resources, the earliest join date and any staff or active flags. A survivor that signs in with Google or GitHub takes a duplicate’s password, so password sign-in keeps working.
- Nothing left behind. Every row that belongs to a duplicate, including its social sign-ins and API keys, moves to the survivor. A name clash, such as two Secrets with the same name, is solved by renaming one to
<name>_merged_<id>, and logged. - No side effects. The merge sends no signals, so it never deploys, undeploys or changes DNS.
- Preview it first.
manage.py merge_duplicate_users --dry-run --verbosereports what would be merged, renamed, moved and deleted, without changing anything.
Sign-up now rejects an address that another user has, in any case. The sign-in page’s server error no longer shows the exception’s text.
Fixes and operations
- Reasoning models and temperature. OpenAI reasoning models accept only their default temperature when a request has no
reasoning_effort. The request for the final answer after tool calls has none, so prompts that called tools failed with a system error after the tools had run. Smarter now retries once without temperature, and remembers the model.llm_judgeGuardrails had the same problem on such models, and every one of them failed. They are retried the same way. - One MCPServer, two sets of tools. The code and docs described two MCP servers. There is one, with public tools and staff-only tools at separate endpoints, and its docs are now one page. The endpoints and tools are unchanged.
- Email addresses masked in logs. The email service logged every recipient’s full address. It now logs
j****@example.com. - A Mailchimp API key leak. An error from Mailchimp logged the API key in plain text. It no longer does.
- Fewer false redactions. Grafana Alloy’s redaction rules hid Secret names, values that Smarter had already masked, and source lines of tracebacks. 44 of 46 redactions in one day of production logs were false positives. The rules are narrower, and a new test checks that real credentials are still redacted.
- Documentation links. 172 links in the console, emails, the API contract, the Slack bot and the MCPServer pointed to the old
docs.smarter.sh/en/latest/layout, which only worked through a redirect, and some named pages that had moved. They now point to the current pages. - What’s New. The dashboard’s What’s New widget still listed Extensions, from v0.27, as the newest feature. It now lists the features of v0.30 to v0.41.
- A code review. A pass over the whole Django codebase split dense lines, added about 1,200 docstrings, and fixed type errors. It also fixed a handful of crashes in edge cases, such as a password email that sent an error page as its body, and a Pinecone search with a score threshold that raised an error when a match had no score. All 6,971 tests pass.
Upgrading
- Duplicate users are merged automatically. The account app’s migrations merge every group of users that share an address, then add the unique index. The merge can’t be undone. Before you deploy, run
manage.py merge_duplicate_users --dry-run --verbosefrom the new image against your database to see exactly what will change. - Check who used the operations tools. The staff-only endpoint now refuses staff users outside the Smarter account. Look at Operations Tool Calls in the Django admin for calls by anyone who was never meant to have access.
- New migrations.
llmclientaddsstaff_only, and the newdoodleapp adds its tables. The init job applies them. - Outbound requests. The doodle’s trends read the Wikimedia pageviews API and Wikidata. If your namespace restricts egress, allow them, or turn off
enable_doodle_trends. - Waffle switches.
enable_doodle,enable_doodle_regional,enable_doodle_animation,enable_doodle_caption,enable_doodle_llm_editor,enable_doodle_llm_artwork,enable_doodle_trends,enable_doodle_ai_creditandlog_doodleare on by default.enable_doodle_auto_approveis off, so a drawn doodle waits for a superuser. - Alloy’s rules change when the Helm chart is next deployed.
manage.py initialize_platformnow loads the doodle’s themes and plans its doodles.load_from_githubapplies the new staff-only LLMClients (smarter_sysadmin,smarter_doodle_editor,smarter_doodle_artist) and theupbeat_occasion_inputGuardrail to the Smarter account only.
What’s next
The operations work from v0.41 continues, with request IDs in log lines, so that one request can be followed through the platform.
The full list of changes is in the changelog, from v0.41.1 to v0.42.0. To try the release, start with the documentation, or browse the code on GitHub.
