Skip to content

gavinwei121/marketing-agent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Marketing Agent

This repository contains a full-stack “marketing research agent” app.

Users create chat sessions (“projects”) via the FastAPI backend. For each session, the backend runs an OpenRouter/OpenAI-compatible LLM in a tool-using loop (e.g. web_search, get_content, simulate_behavior), streams progress as text/tool blocks to the frontend via Server-Sent Events (SSE), and persists the resulting blocks and project metadata in Supabase.

Capabilities

Use combined web search tool to access public data, social media and the internet for general information, and initiate sub-agents to simulate the behaviors of consumers of different profiles.

Setup

pip install -r requirements.txt

Backend environment variables

The backend reads API keys from the process environment (backend/credentials.py has no hardcoded defaults). Set these before starting the API:

Variable Purpose
EXA_API_KEY Exa web search
OPENROUTER_API_KEY LLM calls via OpenRouter
SUPABASE_SECRET_KEY Supabase server client (service role / secret key)
SUPABASE_PUBLIC_KEY Publishable key if your code paths need it

Example:

export EXA_API_KEY="..."
export OPENROUTER_API_KEY="..."
export SUPABASE_SECRET_KEY="..."
export SUPABASE_PUBLIC_KEY="..."

API Endpoints

Method Path Description
GET /api/chats List recent chat sessions
GET /api/work/{id} Get work process (blocks + metadata) for a chat
GET /api/work/{id}/stream Stream work-process blocks via SSE
POST /api/chats Create a new chat session

Launch

  1. Backend: cd backend && source run.txt
  2. Frontend: cd agent-app && npm run dev

Note

marketing agent folder is a testing workspace, not part of the project in production

About

Agent that does marketing for customers of different cultural contexts

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors