This solution fetches event data from the Eventbrite API, allows users to input preferences for event selection, and ranks the top 10 events based on relevance to the user-defined criteria. It outputs the results in a structured text file.
- Fetches 10 different event data from the Eventbrite API.
- Allows users to define a custom event strategy via terminal inputs.
- Generates an input JSON file (
input_events.json) with event data. - Ranks the top 10 events based on user-defined relevance criteria.
- Outputs the ranked results in
top_10_events.txt.
- Obtain an API key from Eventbrite API Platform.
- Normally you would have to replace the placeholder my API in the script with your actual API key, but for the sake of this demonstrate I will provide my own API key.
input_events.json:- Generated by the script with enriched event data fetched from Eventbrite.
- User inputs (e.g., target audience, objectives, etc.) are entered via the terminal.
top_10_events.txt:- A structured output file listing the top 10 events ranked by relevance.
- Includes event name, URL, description, and relevance rank.
The script uses the following user-defined criteria:
- Target Audience: Description of intended attendees (e.g., job titles, demographics).
- Objectives: Goals like networking, lead generation, or brand awareness.
- Industry Sector: Specific industry sectors like technology or healthcare.
- Geographic Focus: Preferred regions for events (e.g., "NYC, NY").
- Budget Constraints: User-defined acceptable budget ranges.
- KPIs: Key performance indicators, e.g., attendee count or leads generated.
The script calculates a relevance score for each event based on:
- Location Match: +50 points for close matches.
- Objective Match: +25 points for aligning objectives.
- Industry Match: +25 points for aligning industry sectors.
- Available Tickets: +10 points if tickets are available.
- Sold Out: -10 points for events marked as sold out.
The output is a ranked list of the top 10 events matching the user’s strategy. Each entry includes:
- Event Name
- Event URL
- Brief Description
- Relevance Rank
- Events without venue or ticket data are excluded.
- If the user's geographic focus does not match any event location, no location weight is applied.
- Events are ranked based solely on available data from the Eventbrite API.
To execute the solution:
- Clone the repository
- python main.py
- Follow the prompts to input your event strategy.
- The script generates input_events.json and ranks events into top_10_events.txt.
- Relies on the Eventbrite API for accurate data.
- Location matching is simplified to a text-based comparison rather than real geographic distances.
- Assumes user inputs are formatted correctly and within valid ranges.