AI app to find real-time that gives quick insights into latest changes in digital marketingss' ads who are spending a lot of money (and thus taking more data-led decisions) " "It uses Pathway’s LLM App features to build real-time LLM(Large Language Model)-enabled data pipeline in Python and join data from multiple input sources.
The primary end users of AdsGPT are Digital Marketer, Marketing Leaders and Companies interested in gaining insights into the advertisements published by their competitors.
Maximizing Revenues
Ad copies have unstructured data / patterns, and advertisers need easy recommendations in natural language without a huge learning curve.
The code establishes a connection with the database and generates a JSONL file whenever there are updates in the database. The variable "last_known_row_count" monitors these updates to ensure real-time generation of the JSON file.
Example only supports Unix-like systems (such as Linux, macOS, BSD). If you are a Windows user, we highly recommend leveraging Windows Subsystem for Linux (WSL) or Dockerize the app to run as a container.
- Make sure that Python 3.10 or above installed on your machine.
- Download and Install Pip to manage project packages.
- Create an OpenAI account and generate a new API Key: To access the OpenAI API, you will need to create an API Key. You can do this by logging into the OpenAI website and navigating to the API Key management page.
Then, follow the easy steps to install and get started using the sample app.
This is done with the git clone
command followed by the URL of the repository:
git clone https://github.com/atulkrishna-4100/AdsGPT_Pathway_project.git
Next, navigate to the project folder:
cd Ads_Pathway_project
Create .env
file in the root directory of the project, copy and paste the below config, and replace the {OPENAI_API_KEY}
configuration value with your key.
OPENAI_API_TOKEN={OPENAI_API_KEY}
HOST=0.0.0.0
PORT=8080
EMBEDDER_LOCATOR=text-embedding-ada-002
EMBEDDING_DIMENSION=1536
MODEL_LOCATOR=gpt-3.5-turbo
MAX_TOKENS=200
TEMPERATURE=0.0
Install the required packages:
pip install --upgrade -r requirements.txt
Create a new virtual environment in the same folder and activate that environment:
python -m venv pw-env && source pw-env/bin/activate
python main.py
You can run the UI separately by navigating to cd advertisements/ui
and running Streamlit app
streamlit run app.py
command. It connects to the Discounts backend API automatically and you will see the UI frontend is running http://localhost:8501/ on a browser: