Drug-Safety Agent on Databricks · Architecture · The suite behind it
How the specification, the harness and the gates fit
The agent is not built alone. A written specification states what must hold. A shared library enforces what it can. A simulated world lets scenarios try to break the rest, and four gates say pass or fail. A failure points back at the layer that should change.
The specification (an Application Operation Agent Spec) is a 396-line file in the clean-ai-engineering repository. It lists the operations, the state machine for a draft, the refusals and the required properties such as "every number equals a tool result". It is still a draft: it carries assumptions the owner has not confirmed.
A finding goes upstream. When we built this agent we found two things the specification did not say (who owns the assessment store, and that every row needs a key). Those were written back into the specification, not worked around in code.