Beauty Diagram
by @levi840714
Use when the user asks for a presentation-ready Mermaid / PlantUML diagram (e.g. "beautify this flowchart", "make this look like a deck slide", "produce an S...
User: "Add a beautified version of this mermaid block to my README."
Agent steps:
1. Use the one-step path: bd embed-url ./architecture.mmd --share
β saves the diagram and prints the embed URL, e.g.
https://api.beauty-diagram.com/v1/share/abc12345xyz0.svg
2. Replace the raw mermaid block in README with:
!Architecture
3. (Optional) Confirm with the user that watermark behavior matches their plan
(free owner β watermarked; pro/premium owner β clean).
| Symptom | Likely cause | Resolution |
|---|---|---|
| not_authenticated | No key, no session | bd auth login |
| scope_missing | Key lacks scope (e.g. ai:write for bd ai generate) | Recreate key with required scope at /account/api-keys |
| plan_not_allowed | Plan does not include this capability (AI is Pro / Premium only) | Upgrade or skip the call |
| parse_failed | Source not valid Mermaid / PlantUML | Check the source β bd beautify will surface a parse error too |
| quota_exhausted | Plan limit hit (anon: 1 export/IP/24h; free: 3 exports/mo; pro: 100 exports + 100 AI gens/mo; premium: β exports + 500 AI gens/mo) | Sign in, wait for reset, or upgrade β hints in the response body has the URLs |
| rate_limited | Anonymous IP bucket full (20 /v1/beautify requests / minute) or AI per-key bucket (30 /min) | Sign in or wait |
| source_too_large | Source > 100 KB | Split the diagram |
| output_too_large | PNG raster exceeds 8192 px | Lower --quality or simplify |
| prompt_injection | AI prompt looked like an injection attempt | Rephrase as a plain diagram description ("a flowchart of β¦") |
| instruction_rejected | AI judged the prompt was not about a diagram | Rephrase to describe a concrete diagram. Quota was NOT consumed |
| parse_failed_after_retry | AI output was unparseable Mermaid even after one retry | Rephrase, or write Mermaid by hand. Quota was NOT consumed |
| safety_blocked | Provider safety filter rejected the request | Rephrase the prompt |
| upstream_timeout / upstream_error | AI provider was slow or failed | Retry after a moment |
clawhub install beauty-diagram