Diagram Cog
by @nitishgargiitd
AI diagram generation powered by CellCog. Flowcharts, system architecture, mind maps, org charts, ER diagrams, sequence diagrams, Gantt charts, network diagr...
clawhub install diagram-cogπ About This Skill
name: diagram-cog description: "AI diagram generation powered by CellCog. Flowcharts, system architecture, mind maps, org charts, ER diagrams, sequence diagrams, Gantt charts, network diagrams. Describe your system in plain English, get interactive diagrams or print-ready PDFs." metadata: openclaw: emoji: "π" os: [darwin, linux, windows] requires: bins: [python3] env: [CELLCOG_API_KEY] author: CellCog homepage: https://cellcog.ai dependencies: [cellcog]
Diagram Cog - Describe It in Words, Get It as a Diagram
Describe your system, process, or idea in plain English β CellCog produces professional, interactive diagrams you can share with a URL.
No Visio. No Lucidchart. No dragging boxes around for hours. Just describe what you need, and CellCog renders it as an interactive web page you can zoom, pan, and click β or a print-ready PDF for documentation.
How to Use
For your first CellCog task in a session, read the cellcog skill for the full SDK reference β file handling, chat modes, timeouts, and more.
OpenClaw (fire-and-forget):
result = client.create_chat(
prompt="[your task prompt]",
notify_session_key="agent:main:main",
task_label="my-task",
chat_mode="agent",
)
All agents except OpenClaw (blocks until done):
from cellcog import CellCogClient
client = CellCogClient(agent_provider="openclaw|cursor|claude-code|codex|...")
result = client.create_chat(
prompt="[your task prompt]",
task_label="my-task",
chat_mode="agent",
)
print(result["message"])
Why Diagrams Are Hard
Creating good diagrams manually is surprisingly painful:
CellCog eliminates all of this. Describe your diagram in words, get a shareable interactive URL. Need to change something? Just ask.
What Makes This Different
Other AI diagram tools output a static image. CellCog does something fundamentally different.
CellCog reasons about your system, picks the right rendering approach, and deploys an interactive web application you can share with a URL. Zoom into your microservices architecture. Click a node to see details. Pan across a sprawling org chart. Or export to a print-ready PDF for your board deck.
| What You Ask For | What CellCog Actually Does | |-----------------|---------------------------| | "Diagram my microservices" | Reasons about the architecture β generates Mermaid/D3 code β deploys interactive web app β delivers shareable URL | | "Flowchart for our hiring process" | Analyzes the process β renders with proper decision logic β color-codes paths β interactive HTML with click states | | "ER diagram for my database" | Understands entity relationships β generates diagram with cardinality β exports as both interactive HTML and PDF | | "Mind map for brainstorming" | Explores the topic β creates hierarchical structure β deploys zoomable, expandable mind map |
The power comes from having a world-class coding agent, multiple rendering libraries (Mermaid.js, D3.js, custom SVG, Highcharts), and built-in app deployment β all orchestrated together. When standard tools fall short, the agent writes custom code.
What Diagrams You Can Create
Flowcharts & Process Flows
Visualize any process or decision tree:
Example prompt: > "Create an interactive flowchart for our hiring process: > > Steps: > 1. Job posted β Applications received > 2. Resume screening (HR) β Pass/Fail > 3. Phone screen (Recruiter) β Pass/Fail > 4. Technical interview (Engineering) β Pass/Fail > 5. Culture interview (Team) β Pass/Fail > 6. Offer β Accept/Decline > 7. If decline β Back to step 2 with next candidate > > Color-code: Green for forward progress, red for rejection paths, yellow for decision points. > Include average time at each stage."
System Architecture
Technical diagrams for engineering teams:
Example prompt: > "Create a system architecture diagram for a SaaS application: > > Frontend: React app on CloudFront/S3 > API: FastAPI on ECS Fargate behind ALB > Auth: Firebase Authentication > Database: PostgreSQL on RDS (primary + read replica) > Cache: Redis on ElastiCache > Queue: SQS for async jobs > Workers: Celery on ECS > Storage: S3 for user uploads > Monitoring: CloudWatch + Datadog > > Show the data flow between components with arrows. > Group by VPC / public / external. > Interactive β I want to be able to zoom into each component."
Mind Maps & Concept Maps
Brainstorm and organize ideas:
Example prompt: > "Create an interactive mind map for 'AI in Healthcare': > > Central node: AI in Healthcare > > Main branches: > - Diagnostics (imaging, pathology, genomics) > - Drug Discovery (target identification, clinical trials, molecule design) > - Patient Care (chatbots, monitoring, personalized medicine) > - Operations (scheduling, billing, supply chain) > - Research (literature mining, clinical data analysis) > > Each branch should have 3-5 sub-topics with brief descriptions. > Color-code by maturity: green = in production, yellow = clinical trials, red = research stage."
Org Charts
Visualize organizational structure:
UML Diagrams
Software engineering diagrams:
Example prompt: > "Create a sequence diagram for a payment processing flow: > > Actors: User, Frontend, API Server, Payment Service, Stripe, Database > > Flow: > 1. User clicks 'Pay' β Frontend sends payment request to API > 2. API creates payment intent with Stripe > 3. Stripe returns client secret > 4. API sends client secret to Frontend > 5. Frontend confirms payment with Stripe.js > 6. Stripe sends webhook to API > 7. API updates order status in Database > 8. API sends confirmation email to User > > Include error paths: payment declined, webhook timeout."
ER Diagrams
Database design and data modeling:
Network Diagrams
IT infrastructure visualization:
Gantt Charts & Timelines
Project planning and scheduling:
Swimlane Diagrams
Cross-functional process visualization:
User Journey Maps
Customer experience visualization:
Output Formats
| Format | Features | Best For | |--------|----------|----------| | Interactive HTML | Zoom, pan, click, hover, responsive, shareable via URL | Presentations, team sharing, exploration | | PDF | Print-ready, static, professional | Documentation, email attachments, printing |
CellCog defaults to interactive HTML β the whole point is diagrams you can explore, not static images. Request PDF explicitly when you need print-ready output.
Chat Mode for Diagrams
| Scenario | Recommended Mode |
|----------|------------------|
| Individual diagrams β flowcharts, org charts, ER diagrams, mind maps | "agent" |
| Complex multi-diagram documentation, full system design docs with multiple views | "agent team" |
Use "agent" for most diagrams. Individual flowcharts, architecture diagrams, and org charts execute well in agent mode.
Use "agent team" for comprehensive documentation β when you need multiple interconnected diagrams that form a complete system design document.
Example Prompts
Quick flowchart: > "Create a flowchart for returning a product on our e-commerce site. Include: initiate return β reason selection β approval check β shipping label β refund processing β confirmation. Show the happy path and the rejection path."
Architecture diagram: > "Diagram our production infrastructure: > > Load Balancer β 3 API servers β PostgreSQL (primary + replica) > API servers also talk to Redis cache and S3 for file storage > Background workers pull from SQS queue > Everything monitored by Datadog > > Show it as a clean architecture diagram with arrows showing data flow direction."
Mind map: > "Create a mind map for planning a product launch: > > Center: Product Launch > Branches: Marketing, Engineering, Sales, Support, Legal > Each branch should have 4-6 specific tasks > Color-code by priority: red = critical path, yellow = important, green = nice to have"
Database ER diagram: > "Create an ER diagram for a project management tool: > > Entities: User, Organization, Project, Task, Comment, Attachment, Label > > Key relationships: > - Users belong to Organizations (many-to-many) > - Projects belong to Organizations > - Tasks belong to Projects, assigned to Users > - Comments belong to Tasks, created by Users > - Tasks can have multiple Labels (many-to-many) > > Show primary keys, foreign keys, and cardinality."
Tips for Better Diagrams
1. Describe the components and relationships: "A connects to B which talks to C" is all CellCog needs. Don't worry about layout.
2. Specify the diagram type: "Flowchart", "sequence diagram", "ER diagram" β naming the type helps CellCog choose the right rendering approach.
3. Include data flow direction: For architecture diagrams, mention which way data flows. "Frontend β API β Database" is clearer than just listing components.
4. Request interactivity: "I want to zoom in" or "clickable components" tells CellCog to build an interactive experience.
5. Color-coding helps: "Color-code by team" or "green for success paths, red for error paths" makes diagrams immediately useful.
6. Think about audience: "For the engineering team" vs. "for the board presentation" changes the level of technical detail.
If CellCog is not installed
Run /cellcog-setup (or /cellcog:cellcog-setup depending on your tool) to install and authenticate.
OpenClaw users: Run clawhub install cellcog instead.
Manual setup: pip install -U cellcog and set CELLCOG_API_KEY. See the cellcog skill for SDK reference.