Added new Demo

This commit is contained in:
ShubhamSaboo
2025-06-01 14:25:51 -05:00
parent 5a27fbcf71
commit 805507ef0c
19 changed files with 406 additions and 16 deletions

View File

@@ -1 +0,0 @@
GOOGLE_API_KEY=your_gemini_api_key_here

View File

@@ -38,7 +38,7 @@ Follow these steps to set up and run the application:
1. **Clone the Repository**:
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd ai_agent_tutorials/ai_mental_wellbeing_agent
cd advanced_ai_agents/multi_agent_apps/ai_mental_wellbeing_agent
```
2. **Install Dependencies**:

View File

@@ -12,7 +12,7 @@ This Streamlit app empowers you to research top stories and users on HackerNews
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/multi_agent_researcher
cd advanced_ai_agents/multi_agent_apps/multi_agent_researcher
```
2. Install the required dependencies:

View File

@@ -0,0 +1,84 @@
# 🚀 Product Launch Intelligence Agent
A **streamlined intelligence hub** for Go-To-Market (GTM) & Product-Marketing teams.
Built with **Agno + Firecrawl + Streamlit**, the app turns scattered public-web data into concise, actionable launch insights.
## 🎯 Core Use-Cases
| Tab | What You Get |
|-----|--------------|
| **Competitor Analysis** | GTM-focused breakdown of a rival's latest launches key messaging, differentiators, pricing cues & launch channels |
| **Market Sentiment** | Consolidated review themes & social chatter split by 🚀 *positive* / ⚠️ *negative* drivers |
| **Launch Metrics** | Publicly available KPIs press coverage, engagement numbers, qualitative "buzz" signals |
Responses are neatly rendered in markdown with a two-step process:
1. First, a concise bullet list of key findings
2. Then, an expanded 1200-word analysis with executive summary, deep dive, and recommendations
## 🛠️ Tech Stack
| Layer | Details |
|-------|---------|
| Data | **Firecrawl** search + crawl (async, poll-based) |
| Agent | **Agno** single-agent with FirecrawlTools & markdown output |
| UI | **Streamlit** wide layout, custom CSS, tabbed workflow |
| LLM | **OpenAI GPT-4o** for analysis and insights |
### How to get Started?
1. Clone the GitHub repository
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd advanced_ai_agents/multi_agent_apps/product_launch_intelligence_agent
```
2. Install the required dependencies:
```bash
pip install -r requirements.txt
```
3. **Set up API Keys**
You can provide your API keys in two ways:
- **Environment Variables**: Add to `.env` file
```ini
OPENAI_API_KEY=sk-************************
FIRECRAWL_API_KEY=fc-************************
```
- **UI Input**: Enter keys directly in the app's sidebar
3. **Run**
```bash
streamlit run product_launch_intelligence_agent.py
```
4. **Navigate** to <http://localhost:8501> and start exploring.
## 🕹️ Using the Application
1. **Enter API Keys** in the sidebar if not set in environment variables
2. Pick a tab (Competitor ▸ Sentiment ▸ Metrics)
3. Enter the **company / product / hashtag** requested
4. Hit **Analyze** a spinner indicates data gathering
5. Review the two-part analysis:
- Initial bullet points for quick insights
- Expanded report with detailed analysis
## 📦 Output Structure
The analysis is structured in two parts:
1. **Quick Bullet Points** (max 10 bullets)
- Concise key findings
- Easy to scan and share
2. **Expanded Analysis** (~1200 words)
- Executive Summary (<120 words)
- Deep Dive Analysis (with sub-headings)
- Actionable Recommendations
- Key Risks / Watch-outs

View File

@@ -0,0 +1,304 @@
import streamlit as st
from agno.agent import Agent
from agno.models.openai import OpenAIChat
from agno.tools.firecrawl import FirecrawlTools
from dotenv import load_dotenv
from datetime import datetime
from textwrap import dedent
import os
# ---------------- Page Config & Styles ----------------
st.set_page_config(page_title="Product Intelligence Agent", page_icon="🚀", layout="wide")
st.markdown(
"""
<style>
/* Custom CSS for a sleek look */
.stButton>button {
border-radius: 5px;
height: 3em;
font-weight: 600;
}
.analysis-box {
padding: 1rem;
border-radius: 0.5rem;
background-color: #f9f9f9;
border: 1px solid #e1e1e1;
}
div[data-testid="stExpander"] div[role="button"] p {
font-size: 1.05rem;
font-weight: 600;
}
</style>
""",
unsafe_allow_html=True,
)
# ---------------- Environment & Agent ----------------
load_dotenv()
# Add API key inputs in sidebar
with st.sidebar.expander("🔑 API Keys", expanded=True):
openai_key = st.text_input("OpenAI API Key", type="password", value=os.getenv("OPENAI_API_KEY", ""))
firecrawl_key = st.text_input("Firecrawl API Key", type="password", value=os.getenv("FIRECRAWL_API_KEY", ""))
# Set environment variables
if openai_key:
os.environ["OPENAI_API_KEY"] = openai_key
if firecrawl_key:
os.environ["FIRECRAWL_API_KEY"] = firecrawl_key
# Initialize agent only if both keys are provided
if openai_key and firecrawl_key:
launch_analyst = Agent(
name="Product Launch Analyst",
description=dedent("""
You are a senior Go-To-Market strategist who evaluates competitor product launches with a critical, evidence-driven lens.
Your objective is to uncover:
• How the product is positioned in the market
• Which launch tactics drove success (strengths)
• Where execution fell short (weaknesses)
• Actionable learnings competitors can leverage
Always cite observable signals (messaging, pricing actions, channel mix, timing, engagement metrics). Maintain a crisp, executive tone and focus on strategic value.
"""),
model=OpenAIChat(id="gpt-4o"),
tools=[FirecrawlTools(search=True, crawl=True, limit=8, poll_interval=10)],
show_tool_calls=True,
markdown=True,
exponential_backoff=True,
delay_between_retries=2,
)
else:
launch_analyst = None
st.warning("⚠️ Please enter both API keys in the sidebar to use the application.")
# ---------------- Helper to display response ----------------
def display_agent_response(resp):
"""Render different response structures nicely."""
if hasattr(resp, "content") and resp.content:
st.markdown(resp.content)
elif hasattr(resp, "messages"):
for m in resp.messages:
if m.role == "assistant" and m.content:
st.markdown(m.content)
else:
st.markdown(str(resp))
# Helper to expand bullet summary into 1200-word general report
def expand_insight(bullet_text: str, topic: str) -> str:
if not launch_analyst:
st.error("⚠️ Please enter both API keys in the sidebar first.")
return ""
prompt = (
f"Using ONLY the bullet points below, craft an in-depth (~1200-word) launch analysis report on {topic}.\n"
f"Structure:\n"
f"1. Executive Summary (<120 words)\n"
f"2. Strengths & Opportunities (what worked well)\n"
f"3. Weaknesses & Gaps (what didn't work or could be improved)\n"
f"4. Actionable Recommendations (bullet list)\n"
f"5. Key Risks / Watch-outs\n\n"
f"Bullet Points:\n{bullet_text}\n\n"
f"Ensure analysis is objective, evidence-based and references the bullet insights. Keep paragraphs short (≤120 words)."
)
long_resp = launch_analyst.run(prompt)
return long_resp.content if hasattr(long_resp, "content") else str(long_resp)
# Helper to craft competitor-focused launch report for product managers
def expand_competitor_report(bullet_text: str, competitor: str) -> str:
if not launch_analyst:
st.error("⚠️ Please enter both API keys in the sidebar first.")
return ""
prompt = (
f"Transform the insight bullets below into a professional launch review for product managers analysing {competitor}.\n\n"
f"Produce well-structured **Markdown** with a mix of tables, call-outs and concise bullet points — avoid long paragraphs.\n\n"
f"=== FORMAT SPECIFICATION ===\n"
f"# {competitor} Launch Review\n\n"
f"## 1. Market & Product Positioning\n"
f"• Bullet point summary of how the product is positioned (max 6 bullets).\n\n"
f"## 2. Launch Strengths\n"
f"| Strength | Evidence / Rationale |\n|---|---|\n| … | … | (add 4-6 rows)\n\n"
f"## 3. Launch Weaknesses\n"
f"| Weakness | Evidence / Rationale |\n|---|---|\n| … | … | (add 4-6 rows)\n\n"
f"## 4. Strategic Takeaways for Competitors\n"
f"1. … (max 5 numbered recommendations)\n\n"
f"=== SOURCE BULLETS ===\n{bullet_text}\n\n"
f"Guidelines:\n"
f"• Populate the tables with specific points derived from the bullets.\n"
f"• Only include rows that contain meaningful data; omit any blank entries."
)
resp = launch_analyst.run(prompt)
return resp.content if hasattr(resp, "content") else str(resp)
# Helper to craft market sentiment report
def expand_sentiment_report(bullet_text: str, product: str) -> str:
if not launch_analyst:
st.error("⚠️ Please enter both API keys in the sidebar first.")
return ""
prompt = (
f"Use the tagged bullets below to create a concise market-sentiment brief for **{product}**.\n\n"
f"### Positive Sentiment\n"
f"• List each positive point as a separate bullet (max 6).\n\n"
f"### Negative Sentiment\n"
f"• List each negative point as a separate bullet (max 6).\n\n"
f"### Overall Summary\n"
f"Provide a short paragraph (≤120 words) summarising the overall sentiment balance and key drivers.\n\n"
f"Tagged Bullets:\n{bullet_text}"
)
resp = launch_analyst.run(prompt)
return resp.content if hasattr(resp, "content") else str(resp)
# Helper to craft launch metrics report
def expand_metrics_report(bullet_text: str, launch: str) -> str:
if not launch_analyst:
st.error("⚠️ Please enter both API keys in the sidebar first.")
return ""
prompt = (
f"Convert the KPI bullets below into a launch-performance snapshot for **{launch}** suitable for an executive dashboard.\n\n"
f"## Key Performance Indicators\n"
f"| Metric | Value / Detail | Source |\n"
f"|---|---|---|\n"
f"| … | … | … | (include one row per KPI)\n\n"
f"## Qualitative Signals\n"
f"• Bullet list of notable qualitative insights (max 5).\n\n"
f"## Summary & Implications\n"
f"Brief paragraph (≤120 words) highlighting what the metrics imply about launch success and next steps.\n\n"
f"KPI Bullets:\n{bullet_text}"
)
resp = launch_analyst.run(prompt)
return resp.content if hasattr(resp, "content") else str(resp)
# ---------------- UI ----------------
st.title("🚀 Product Launch Intelligence Agent")
st.caption("AI Agent powered insights for GTM, Product Marketing & Growth Teams")
# Create tabs for analysis types
analysis_tabs = st.tabs(["Competitor Analysis", "Market Sentiment", "Launch Metrics"])
# Persistent storage for latest response
if "analysis_response" not in st.session_state:
st.session_state.analysis_response = None
st.session_state.analysis_meta = {}
# -------- Competitor Analysis Tab --------
with analysis_tabs[0]:
st.subheader("🔍 Competitor Launch Analysis")
competitor_name = st.text_input("Competitor name", key="competitor_input")
cols = st.columns([2, 1])
with cols[0]:
if st.button("Analyze", key="competitor_btn") and competitor_name:
if not launch_analyst:
st.error("⚠️ Please enter both API keys in the sidebar first.")
else:
with st.spinner("Gathering competitive insights..."):
try:
bullets = launch_analyst.run(
f"Generate up to 16 evidence-based insight bullets about {competitor_name}'s most recent product launches.\n"
f"Format requirements:\n"
f"• Start every bullet with exactly one tag: Positioning | Strength | Weakness | Learning\n"
f"• Follow the tag with a concise statement (max 30 words) referencing concrete observations: messaging, differentiation, pricing, channel selection, timing, engagement metrics, or customer feedback."
)
long_text = expand_competitor_report(
bullets.content if hasattr(bullets, "content") else str(bullets),
competitor_name
)
st.session_state.analysis_response = long_text
st.session_state.analysis_meta = {
"type": "Competitor Analysis",
"query": competitor_name,
"timestamp": datetime.utcnow().isoformat()
}
st.success("✅ Analysis ready")
except Exception as e:
st.error(f"❌ Error: {e}")
if st.session_state.analysis_response and st.session_state.analysis_meta.get("type") == "Competitor Analysis":
st.markdown("### 📊 Results")
st.markdown(st.session_state.analysis_response)
# -------- Market Sentiment Tab --------
with analysis_tabs[1]:
st.subheader("💬 Market Sentiment Analysis")
product_name = st.text_input("Product name", key="sentiment_input")
cols = st.columns([2, 1])
with cols[0]:
if st.button("Analyze", key="sentiment_btn") and product_name:
if not launch_analyst:
st.error("⚠️ Please enter both API keys in the sidebar first.")
else:
with st.spinner("Collecting market sentiment..."):
try:
bullets = launch_analyst.run(
f"Summarize market sentiment for {product_name} in <=10 bullets. "
f"Cover top positive & negative themes with source mentions (G2, Reddit, Twitter)."
)
long_text = expand_sentiment_report(
bullets.content if hasattr(bullets, "content") else str(bullets),
product_name
)
st.session_state.analysis_response = long_text
st.session_state.analysis_meta = {
"type": "Market Sentiment",
"query": product_name,
"timestamp": datetime.utcnow().isoformat()
}
st.success("✅ Sentiment analysis ready")
except Exception as e:
st.error(f"❌ Error: {e}")
if st.session_state.analysis_response and st.session_state.analysis_meta.get("type") == "Market Sentiment":
st.markdown("### 📈 Sentiment Insights")
st.markdown(st.session_state.analysis_response)
# -------- Launch Metrics Tab --------
with analysis_tabs[2]:
st.subheader("📈 Launch Performance Metrics")
product_launch = st.text_input("Product name / Launch campaign", key="metrics_input")
cols = st.columns([2, 1])
with cols[0]:
if st.button("Analyze", key="metrics_btn") and product_launch:
if not launch_analyst:
st.error("⚠️ Please enter both API keys in the sidebar first.")
else:
with st.spinner("Fetching launch performance data..."):
try:
bullets = launch_analyst.run(
f"List (max 10 bullets) the most important publicly available KPIs & qualitative signals for {product_launch}. "
f"Include engagement stats, press coverage and social traction if available."
)
long_text = expand_metrics_report(
bullets.content if hasattr(bullets, "content") else str(bullets),
product_launch
)
st.session_state.analysis_response = long_text
st.session_state.analysis_meta = {
"type": "Launch Metrics",
"query": product_launch,
"timestamp": datetime.utcnow().isoformat()
}
st.success("✅ Metrics analysis ready")
except Exception as e:
st.error(f"❌ Error: {e}")
if st.session_state.analysis_response and st.session_state.analysis_meta.get("type") == "Launch Metrics":
st.markdown("### 📊 Metric Highlights")
st.markdown(st.session_state.analysis_response)
# ---------------- Sidebar ----------------
st.sidebar.header(" About")
st.sidebar.markdown(
"""
**Product Launch Intelligence Agent** helps GTM teams quickly:
- Benchmark competitor launches
- Monitor market sentiment pre/post-launch
- Track launch performance signals
Built with **Agno** & **Firecrawl**.
"""
)

View File

@@ -0,0 +1,4 @@
streamlit
agno
firecrawl

View File

@@ -13,7 +13,7 @@ This Streamlit app implements an AI-powered customer support agent for synthetic
1. Clone the GitHub repository
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_customer_support_agent
cd advanced_ai_agents/single_agent_apps/ai_customer_support_agent
```
2. Install the required dependencies:

View File

@@ -29,7 +29,7 @@ A powerful research assistant that leverages OpenAI's Agents SDK and Firecrawl's
1. Clone this repository:
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd ai_agent_tutorials/ai_deep_research_agent
cd advanced_ai_agents/single_agent_apps/ai_deep_research_agent
```
2. Install the required packages:

View File

@@ -38,7 +38,7 @@ Before anything else, Please get a free Gemini API Key provided by Google AI her
1. **Clone the Repository**:
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_health_fitness_agent
cd advanced_ai_agents/single_agent_apps/ai_health_fitness_agent
```
2. **Install the dependencies**

View File

@@ -13,7 +13,7 @@ This Streamlit app is an AI-powered investment agent built with Agno's AI Agent
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_investment_agent
cd advanced_ai_agents/single_agent_apps/ai_investment_agent
```
2. Install the required dependencies:

View File

@@ -12,7 +12,7 @@ This Streamlit app is an AI-powered journalist agent that generates high-quality
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_journalist_agent
cd advanced_ai_agents/single_agent_apps/ai_journalist_agent
```
2. Install the required dependencies:

View File

@@ -13,7 +13,7 @@ The AI Lead Generation Agent automates the process of finding and qualifying pot
1. **Clone the repository**:
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd ai_agent_tutorials/ai_lead_generation_agent
cd advanced_ai_agents/single_agent_apps/ai_lead_generation_agent
```
3. **Install the required packages**:
```bash

View File

@@ -14,7 +14,7 @@ This Streamlit application leverages multiple AI agents to create comprehensive
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_meeting_agent
cd advanced_ai_agents/single_agent_apps/ai_meeting_agent
```
2. Install the required dependencies:

View File

@@ -12,7 +12,7 @@ This Streamlit app is an AI-powered movie production assistant that helps bring
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_movie_production_agent
cd advanced_ai_agents/single_agent_apps/ai_movie_production_agent
```
2. Install the required dependencies:

View File

@@ -12,7 +12,7 @@ This Streamlit app is an AI-powered personal finance planner that generates pers
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_personal_finance_agent
cd advanced_ai_agents/single_agent_apps/ai_personal_finance_agent
```
2. Install the required dependencies:

View File

@@ -39,7 +39,6 @@ An advanced web extraction and analysis tool built using Firecrawl's FIRE-1 agen
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd advanced_ai_agents/single_agent_apps/ai_startup_insight_fire1_agent
```
# Install dependencies

View File

@@ -31,7 +31,7 @@ An Agno agentic system that provides expert software architecture analysis and r
```bash
# Clone the repository
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/ai_agent_tutorials/ai_system_architect_r1
cd advanced_ai_agents/single_agent_apps/ai_system_architect_r1
# Install dependencies
pip install -r requirements.txt

View File

@@ -14,7 +14,7 @@ LLM app with RAG to chat with GitHub Repo in just 30 lines of Python Code. The a
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/chat_with_X_tutorials/chat_with_github
cd advanced_llm_apps/chat_with_X_tutorials/chat_with_github
```
2. Install the required dependencies:

View File

@@ -14,7 +14,7 @@ LLM app with RAG to chat with Gmail in just 30 lines of Python Code. The app use
```bash
git clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/chat_with_X_tutorials/chat_with_gmail
cd advanced_llm_apps/chat_with_X_tutorials/chat_with_gmail
```
2. Install the required dependencies