Jev email intent workflow
Async LangGraph example where a Jev Choice labels each email as invoice or general and routes it to a handler.
Overview
Jev email intent workflow is a small async LangGraph graph that sends an email to Jev, gets a typed Choice of invoice or general, and routes to a demo handler that sets a destination (accounts payable or general inbox) in graph state. Handlers do not send email or make payments.
Input emails are ten mocked, labelled examples (five invoice requests and five general emails, two of which mention invoices), while classification makes real TypeSafe calls, one per email, defaulting to jev-1.12. Output shows intent, confidence, both label probabilities, destination, model and a comparison with the expected label, which is never sent to Jev. API failures stop execution rather than inventing an intent. Unit tests mock the SDK and verify routing, not accuracy, and the README calls the examples a smoke check rather than a benchmark.
What the decision model decides
| Type | Question | Answers |
|---|---|---|
| Choice | What is the primary intent of this email? | invoice · general |
How it works
- Load a mocked email into graph state
- detect_intent node asks Jev the Choice
- Route to accounts_payable or general_inbox
- Print intent, probabilities and comparison to the expected label
Strengths
- Minimal, readable LangGraph integration
- Fails loudly on API errors
- Credential-free tests
Caveats
- Ten mocked emails only
- Always routes to one of two handlers regardless of confidence
Getting started
`uv sync`, set TYPESAFE_API_KEY in .env, then `uv run python main.py`.At a glance
- Type
- App
- Status
- prototype
- Language
- Python
- Runtime
- LangGraph (async)
- Has code
- yes
- Has tests
- yes
Use cases and integrations
How curated lists describe it
Back-office automation: async LangGraph workflow gets a typed Jev `Choice` (`invoice` or `general`) and routes each inbound email to the matching handler.
yibie/awesome-jevAn async LangGraph example that classifies mocked emails as invoice-related or general.
logicrw/awesome-jev-projectsLangGraph email-intent workflow using a typed Jev choice.
cobanov/awesome-jevAsync LangGraph workflow that gets a typed Jev Choice (invoice or general) and routes each inbound email to the matching handler.
hellogumbo/awesome-jev
Frequently asked questions
What does Jev decide?
Whether an email is about an invoice or is general.
Does it send emails or pay invoices?
No, handlers only set a destination in graph state.
Is it an accuracy benchmark?
No, the ten examples are a smoke check.
Related projects
n8n Jev Decision node that sends confident items onward automatically and routes uncertain ones to a person.
ProjectbetaTypeScriptSmall Go agent-loop library with an optional goodall/typesafe package that uses Jev as a tool or hook beside chat models.
LibrarybetaGoRuby gem making semantic checks ordinary methods: feels?, decide and score on model fields, with Rails validations.
LibrarybetaRubyAlibaba's AgentScope 2.0 agent framework, which added a JevClassifierModel for binary, choice and score decisions via the TypeSafe SDK.
ProjectproductionPythonOpen-source AI email assistant; listed as using Jev as an optional classifier for email intent and triage.
ProjectproductionTypeScriptConfig-driven IMAP inbox classifier with a terminal UI where Jev answers yes/no per category to tag, move, flag or notify.
ProjectbetaPython