LaunchKit · 2026
Back to Skills

langchain-email-agent

The `EmailAgent` class provides an AI-powered email composition and sending capability using LangChain.

0
730 downloads
by @jawadsadiq01

Setup & Installation

openclaw skills install @jawadsadiq01/langchain-email-agent

Or with the ClawHub CLI, for registry-managed skill folders outside a full OpenClaw workspace:

npx clawhub install langchain-email-agent

What This Skill Does

An AI agent that composes and sends emails using LangChain with OpenAI's GPT model. Before any email is sent, a human-in-the-loop middleware step requires explicit approval, edit, or rejection.

The built-in approval gate prevents accidental sends, making it safer than fully autonomous email agents.

When to use it

  • Drafting outreach emails with tone instructions
  • Sending meeting requests with AI-written copy
  • Reviewing AI-composed emails before delivery
  • Composing follow-up emails from minimal input
  • Automating email drafts while keeping human oversight

Example Workflow

Here's how your AI assistant might use this skill in practice.

INPUT

User asks: 'Send a formal meeting request to john@example.com'

AGENT
  1. 1Agent receives recipient email, name, subject, body, and instructions
  2. 2GPT model composes a formal email based on the provided parameters
  3. 3humanInTheLoopMiddleware intercepts before the EmailTool executes
  4. 4User reviews the composed email and chooses to approve, edit, or reject
  5. 5Agent sends the email if approved and returns the result
OUTPUT

Confirmation string from the agent indicating the email was sent

Requirements

Accounts, API keys, or tools you or your AI assistant may need to set up while using this skill.

OPENAI_API_KEY environment variableEmail account credentials or SMTP configuration for the underlying email tool