• Home
  • Contact Me
  • How I Emailed You
  • Tableau Email Report
  • Gsheet Example
  • More
    • Home
    • Contact Me
    • How I Emailed You
    • Tableau Email Report
    • Gsheet Example
  • Home
  • Contact Me
  • How I Emailed You
  • Tableau Email Report
  • Gsheet Example

U + Me = Us

U + Me = UsU + Me = UsU + Me = Us

How I Emailed You...

If you received an email from me, here's how I did it

If you didn't receive an email from me, well, this might still be interesting!

The Process

I went to https://www.tableau.com/partners/search, and filtered by Manufacturing partners (as a Mechanical Engineer, I've been in manufacturing sales / marketing for 10+ years).


I then hired for a small fee, someone to give me contact info for all those companies, along with locations.


Then I created this python script, using Replit, to find the weather for your location, have a chat with Chat GPT to craft a message, and then email you, using my sendgrid template. 


Then created a Tableau report that updates on the results! FUN!


Here's some sample code I made:


# Define a function to rewrite email

def rewrite_email(email_body, First_Name, Temperature, City, Distance):

    response = openai.Completion.create(

        engine="text-davinci-003",

        prompt=f"re-write this as a sales email being funny about the weather and location the lead is looking at. Please pass back lines with <br> where you have a line break so I can paste this into html.  I want to try to make a pun about the weather temperature where they live and how I can heat up their business even more. The email now is: {email_body}",

        max_tokens=600,

        temperature=1

    )

    return response.choices[0].text.strip()


# Read the CSV file

def process_csv(csv_filename):

    with open(csv_filename, 'r') as file:

        reader = csv.DictReader(file)


        for row in reader:

            Company_Name = row['Company_Name']

            email_body = f'Hi {row["First_Name"]},<br><br> I created this python program solely to try to get a gig using Tableau in the manufacturing space, and I found {Company_Name} super exciting! I see it is going to be {row["Temperature"]}F in {row["City"]} and you know what? With me, it\'ll be even hotter for your business.<br>\ I am located in Chicago, which is about {row["Distance"]} miles away, but working with me is a lot closer than can be measured in miles; plus, who\'s really counting?! Except me, because I love counting and data, and I\'d love to work with you. Can we bring the heat together? Let\'s talk!'

            rewritten_email = rewrite_email(email_body, row["First_Name"], row["Temperature"], row["City"], row["Distance"])

            # Process the rewritten email as desired

            print(rewritten_email)


# Call the process_csv function with your CSV file

process_csv('output_updated_distance.csv')



Copyright © 2023 U Candidate - All Rights Reserved.

Powered by Canidates

  • Home
  • Contact Me
  • How I Emailed You
  • Tableau Email Report
  • Gsheet Example

This website uses cookies.

We use cookies to analyze website traffic and optimize your website experience. By accepting our use of cookies, your data will be aggregated with all other user data.

DeclineAccept