EMAILOUT / README.md
Seth
update
03708bb
---
title: EMAILOUT
emoji: πŸ”₯
colorFrom: pink
colorTo: gray
sdk: docker
pinned: false
license: mit
---
# EMAILOUT - AI-Powered Email Sequence Generator
A Hugging Face Space application for generating personalized email outreach sequences using GPT.
## Features
- πŸ“€ Upload CSV files from Apollo with contact information
- 🎯 Select and customize products for outreach campaigns
- ✏️ Edit email prompt templates for each product
- πŸ€– AI-powered sequence generation using GPT (up to 10 emails per contact)
- πŸ“Š Real-time streaming of generated sequences
- πŸ’Ύ Download sequences as CSV for use in Klenty and other email tools
- πŸš€ Smartlead integration for direct campaign creation and lead pushing
- πŸ“ˆ Run history tracking for all Smartlead pushes
## Setup
1. Set your API keys as secrets in Hugging Face Spaces:
- Go to Settings β†’ Secrets
- Add `OPENAI_API_KEY` with your OpenAI API key value
- Add `SMARTLEAD_API_KEY` with your Smartlead Admin API key value (required for Smartlead integration)
- Add `SMARTLEAD_CLIENT_API_KEY` with your Smartlead Client API key value (optional, may be required for certain operations)
2. The app will automatically:
- Create SQLite database in `/data/emailout.db`
- Store uploaded CSV files in `/data/uploads/`
- Generate and store email sequences
- Track Smartlead run history
## Usage
1. **Upload CSV**: Upload your Apollo CSV file with contacts
2. **Select Products**: Choose which products to focus on for outreach
3. **Configure Prompts**: Customize email templates for each product
4. **Generate**: Let AI create personalized sequences for each contact (up to 10 emails per contact)
5. **Export Options**:
- **Download CSV**: Export sequences as CSV for Klenty, Outreach, etc.
- **Push to Smartlead**: Directly create campaigns and push leads to Smartlead
6. **View History**: Check run history for all Smartlead pushes
## Tech Stack
- **Frontend**: React + Vite + Tailwind CSS + Framer Motion + React Router
- **Backend**: FastAPI + Python
- **AI**: OpenAI GPT API
- **Database**: SQLite (Hugging Face Spaces persistent storage)
- **Integration**: Smartlead API for campaign management
## API Endpoints
- `POST /api/upload-csv` - Upload CSV file
- `POST /api/save-prompts` - Save prompt templates
- `GET /api/generate-sequences` - Generate sequences (SSE stream)
- `GET /api/download-sequences` - Download sequences as CSV (with all subject/body columns)
- `POST /api/push-to-smartlead` - Push sequences to Smartlead campaign
- `GET /api/smartlead-runs` - Get Smartlead run history
## Smartlead Integration
The app supports direct integration with Smartlead:
- Create new campaigns or use existing ones
- Automatically build sequence templates with variables ({{subject_1}}..{{subject_10}}, {{body_1}}..{{body_10}})
- Push leads with custom variables for personalized sequences
- Track all runs in the Run History page
- Dry run mode for testing without sending to Smartlead
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference