← All agents

AI & research · One purpose, multiple implementations

Translate questions about e-mails into SQL queries and run them

Adapt the published “Translate questions about e-mails into SQL queries and run them” workflow to other implementations while preserving its documented behavior.

The source contains 23 executable nodes and 25 connections. This draft is derived from the n8n export; it needs a human-reviewed purpose, input/output contract, and behavioral tests before a port can claim equivalence.

Open agent files on GitHub ↗

Shared workflow

This initial Mermaid diagram shows observed connections from the n8n source, including model and tool dependencies. Unresolved connections are listed under Evidence. It is a starting point for the shared design; it does not execute the agent or establish correctness.

Rendering the workflow diagram…

Read the Mermaid source
flowchart LR
  n0["Add table name to output"]
  n1["Convert data to binary"]
  n2["Save file locally"]
  n3["Extract data from file"]
  n4["Chat Trigger"]
  n5["When clicking #34;Test workflow#34;"]
  n6["Combine schema data and chat input"]
  n7["Load the schema from the local file"]
  n8["Extract SQL query"]
  n9["Check if query exists"]
  n10["Format query results"]
  n11["Combine query result and chat answer"]
  n12["List all columns in a table"]
  n13["List all tables in a database"]
  n14["Ollama Chat Model"]
  n15["Postgres"]
  n16["Add trailing semicolon"]
  n17["Check for trailing semicolon"]
  n18["WorkflowTrigger"]
  n19["If ran manually"]
  n20["If file exists or already retried generating it"]
  n21["AI Agent"]
  n22["Format empty output"]
  n21 -->|"main out 0 to in 0"| n8
  n15 -->|"main out 0 to in 0"| n10
  n4 -->|"main out 0 to in 0"| n7
  n19 -->|"main out 1 to in 0"| n7
  n18 -->|"main out 0 to in 0"| n7
  n8 -->|"main out 0 to in 0"| n17
  n14 -->|"ai_languageModel out 0 to in 0"| n21
  n2 -->|"main out 0 to in 0"| n19
  n10 -->|"main out 0 to in 0"| n11
  n9 -->|"main out 0 to in 1"| n11
  n9 -->|"main out 0 to in 0"| n15
  n9 -->|"main out 1 to in 0"| n22
  n16 -->|"main out 0 to in 0"| n9
  n1 -->|"main out 0 to in 0"| n2
  n3 -->|"main out 0 to in 0"| n6
  n0 -->|"main out 0 to in 0"| n1
  n12 -->|"main out 0 to in 0"| n0
  n17 -->|"main out 0 to in 0"| n16
  n17 -->|"main out 1 to in 0"| n9
  n13 -->|"main out 0 to in 0"| n12
  n5 -->|"main out 0 to in 0"| n13
  n6 -->|"main out 0 to in 0"| n21
  n7 -->|"main out 0 to in 0"| n20
  n20 -->|"main out 0 to in 0"| n3
  n20 -->|"main out 1 to in 0"| n13
Read the specification and unresolved requirements ↗

Implementations

Each implementation shares the agent’s purpose. Available source, planned ports, and verified results are labeled separately.

Plain Python

Planned · no code yet

Read the implementation plan ↗

Pydantic AI

Planned · no code yet

Read the implementation plan ↗

CrewAI Flow

Planned · no code yet

Read the implementation plan ↗

CrewAI Crew

Planned · no code yet

Read the implementation plan ↗

LangGraph

Planned · no code yet

Read the implementation plan ↗

Build or operate with an assistant

Each prompt includes separate build and operating instructions tailored to this agent. They are untested instructions, not working implementations. Check the chosen product’s actual capabilities before using it.

Evidence and remaining work

The bulk collection has publication checks, not live-service testing. Diagrams and prompts are documentation. A port needs reviewed schemas, fixtures, actual execution results, and explicit limits before claiming equivalent behavior.

  • Define input/output schemas and expected outputs.
  • Review source expressions, external actions, and failure behavior.
  • Determine whether model judgment is required or deterministic rules suffice.

Curated by Nik Bear Brown. Preserve each implementation’s original attribution and license. These source templates are separate from the audited Claude directory.