File size: 2,319 Bytes
05d1964
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
00b7b9a
05d1964
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1428cee
00b7b9a
 
1428cee
05d1964
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
import streamlit as st
import requests
import json
import os


# Define the API endpoints
API_BASE_URL =  os.environ.get("MY_SECRET_KEY")  # Adjust this if your API is hosted elsewhere
EVALUATE_ENDPOINT = f"{API_BASE_URL}/api/evaluate_pitch_deck"
st.title("Pitch Deck Analyzer")


# File uploader
uploaded_file = st.file_uploader("Upload your pitch deck (PDF)", type="pdf")

if uploaded_file is not None:
    

    # Evaluate pitch deck
    st.header("Pitch Deck Evaluation")
    
    # Investor criteria inputs
    #industry_focus = st.text_input("Industry Focus")
    industry_focus = st.selectbox("industry_focus", ["Technology","Healthcare","Consumer Goods","Energy & Sustainability","Financial Services","Media & Entertainment","Real Estate & PropTech","Agriculture & FoodTech","Transportation & Logistics",
"Education & EdTech",
"Telecommunications",
"Manufacturing & Industrial Tech",
"Automotive & Mobility",
"Cleantech & Environmental Tech",
"Space & Aerospace"]) 
    investment_stage = st.selectbox("Investment Stage", 
                                    ["Seed", "Series A", "Series B", "Growth", "Late Stage"])
    #geographical_focus = st.text_input("Geographical Focus")
    geographical_focus = st.selectbox("geographical_focus ", ["North America",
"Europe",
"Asia",
"Latin America",
"Middle East",
"Africa",
"Australia & Oceania",
"Global/International"])
    risk_appetite = st.selectbox("Risk Appetite", ["Low", "Medium", "High"])

    if st.button("Evaluate Pitch Deck"):
        with st.spinner("Evaluating pitch deck..."):
            files = {"pitch_file": ("pitch_deck.pdf", uploaded_file.getvalue(), "application/pdf")}
            data = {
                "industry_focus": industry_focus,
                "investment_stage": investment_stage,
                "geographical_focus": geographical_focus,
                "risk_appetite": risk_appetite
            }
            response = requests.post(EVALUATE_ENDPOINT, files=files, data=data)
            if response.status_code == 200:
                result = response.json()
                st.subheader("Summary")
                st.write(result["summary"])
                
            else:
                st.error(f"Error: {response.status_code} - {response.text}")
    
else:
    st.info("Please upload a pitch deck to get started.")