LeoWalker commited on
Commit
f6cf9cc
Β·
1 Parent(s): 0be547e

Updated Arnold and Tony's speaker profiles along with updating to add Groq.

Browse files
hype_pack/streamlit_app.py CHANGED
@@ -9,8 +9,7 @@ from hype_pack.utils.nodes import (
9
  )
10
  from hype_pack.utils.speaker_profiles import (
11
  tony_robbins,
12
- les_brown,
13
- eric_thomas,
14
  simon_sinek,
15
  speaker_voice_map
16
  )
@@ -19,6 +18,9 @@ import tempfile
19
  import os
20
  import uuid
21
 
 
 
 
22
  # Configure Streamlit page
23
  st.set_page_config(
24
  page_title="HypeCast Generator",
@@ -29,8 +31,7 @@ st.set_page_config(
29
  # Add speaker profiles dictionary after imports
30
  speaker_profiles = {
31
  "Tony Robbins": tony_robbins,
32
- "Les Brown": les_brown,
33
- "Eric Thomas": eric_thomas,
34
  "Simon Sinek": simon_sinek
35
  }
36
 
@@ -74,13 +75,29 @@ def main():
74
  # Create a wider central column for the radio buttons
75
  col1, col2, col3 = st.columns([1, 2, 1])
76
  with col2:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
77
  selected_speaker = st.radio(
78
  "Select your motivational speaker",
79
- options=["Tony Robbins πŸ”₯", "Les Brown ⚑", "Eric Thomas πŸ’ͺ", "Simon Sinek 🌟"],
80
  label_visibility="collapsed",
81
  horizontal=True,
82
- key="speaker_selection",
83
- help="" # This removes the (?) icon
84
  )
85
  st.session_state.selected_speaker = selected_speaker.split()[0] + " " + selected_speaker.split()[1]
86
 
 
9
  )
10
  from hype_pack.utils.speaker_profiles import (
11
  tony_robbins,
12
+ arnold_schwarzenegger,
 
13
  simon_sinek,
14
  speaker_voice_map
15
  )
 
18
  import os
19
  import uuid
20
 
21
+ from dotenv import load_dotenv
22
+ load_dotenv()
23
+
24
  # Configure Streamlit page
25
  st.set_page_config(
26
  page_title="HypeCast Generator",
 
31
  # Add speaker profiles dictionary after imports
32
  speaker_profiles = {
33
  "Tony Robbins": tony_robbins,
34
+ "Arnold Schwarzenegger": arnold_schwarzenegger,
 
35
  "Simon Sinek": simon_sinek
36
  }
37
 
 
75
  # Create a wider central column for the radio buttons
76
  col1, col2, col3 = st.columns([1, 2, 1])
77
  with col2:
78
+ # Add custom CSS to center the radio buttons
79
+ st.markdown(
80
+ """
81
+ <style>
82
+ div.row-widget.stRadio > div {
83
+ flex-direction: row;
84
+ justify-content: center;
85
+ }
86
+ div.row-widget.stRadio > div[role="radiogroup"] > label {
87
+ margin: 0 10px; /* Add some spacing between buttons */
88
+ text-align: center;
89
+ }
90
+ </style>
91
+ """,
92
+ unsafe_allow_html=True
93
+ )
94
+
95
  selected_speaker = st.radio(
96
  "Select your motivational speaker",
97
+ options=["Tony Robbins πŸ”₯", "Arnold Schwarzenegger ⚑", "Simon Sinek 🌟"],
98
  label_visibility="collapsed",
99
  horizontal=True,
100
+ key="speaker_selection"
 
101
  )
102
  st.session_state.selected_speaker = selected_speaker.split()[0] + " " + selected_speaker.split()[1]
103
 
hype_pack/utils/nodes.py CHANGED
@@ -1,5 +1,7 @@
1
  from typing import List
2
  from langchain_openai import ChatOpenAI
 
 
3
  from langchain.prompts import ChatPromptTemplate
4
  from hype_pack.utils.state import InterviewState, ReferenceMaterial, QuestionList, HypeCastTranscript
5
  from hype_pack.utils.speaker_profiles import speaker_voice_map
@@ -22,8 +24,12 @@ def build_reference_material_node(interview_state: InterviewState) -> InterviewS
22
  Analyzes candidate background to generate material for motivational speeches.
23
  """
24
  with tracing_v2_enabled(tags=["reference_material"]):
25
- llm = ChatOpenAI(
26
- model="gpt-4o-mini",
 
 
 
 
27
  temperature=0.1
28
  ).with_structured_output(ReferenceMaterial)
29
 
@@ -80,8 +86,12 @@ def generate_questions_node(interview_state: InterviewState) -> InterviewState:
80
  Generates questions and manages the question history.
81
  """
82
  with tracing_v2_enabled(tags=["questions"]):
83
- llm = ChatOpenAI(
84
- model="gpt-4o-mini",
 
 
 
 
85
  temperature=0.35
86
  ).with_structured_output(QuestionList)
87
 
@@ -136,8 +146,12 @@ def generate_transcript_node(interview_state: InterviewState, speaker_profile: d
136
  Generates a concise, TTS-friendly motivational speech.
137
  """
138
  with tracing_v2_enabled(tags=["transcript"]):
139
- llm = ChatOpenAI(
140
- model="gpt-4o-mini",
 
 
 
 
141
  temperature=0.6
142
  ).with_structured_output(HypeCastTranscript)
143
 
 
1
  from typing import List
2
  from langchain_openai import ChatOpenAI
3
+ from langchain_groq import ChatGroq
4
+ from langchain_fireworks import ChatFireworks
5
  from langchain.prompts import ChatPromptTemplate
6
  from hype_pack.utils.state import InterviewState, ReferenceMaterial, QuestionList, HypeCastTranscript
7
  from hype_pack.utils.speaker_profiles import speaker_voice_map
 
24
  Analyzes candidate background to generate material for motivational speeches.
25
  """
26
  with tracing_v2_enabled(tags=["reference_material"]):
27
+ # llm = ChatOpenAI(
28
+ # model="gpt-4o-mini",
29
+ # temperature=0.1
30
+ # ).with_structured_output(ReferenceMaterial)
31
+ llm = ChatGroq(
32
+ model="llama-3.2-90b-vision-preview",
33
  temperature=0.1
34
  ).with_structured_output(ReferenceMaterial)
35
 
 
86
  Generates questions and manages the question history.
87
  """
88
  with tracing_v2_enabled(tags=["questions"]):
89
+ # llm = ChatOpenAI(
90
+ # model="gpt-4o-mini",
91
+ # temperature=0.35
92
+ # ).with_structured_output(QuestionList)
93
+ llm = ChatGroq(
94
+ model="llama-3.2-90b-vision-preview",
95
  temperature=0.35
96
  ).with_structured_output(QuestionList)
97
 
 
146
  Generates a concise, TTS-friendly motivational speech.
147
  """
148
  with tracing_v2_enabled(tags=["transcript"]):
149
+ # llm = ChatOpenAI(
150
+ # model="gpt-4o-mini",
151
+ # temperature=0.6
152
+ # ).with_structured_output(HypeCastTranscript)
153
+ llm = ChatGroq(
154
+ model="llama-3.2-90b-vision-preview",
155
  temperature=0.6
156
  ).with_structured_output(HypeCastTranscript)
157
 
hype_pack/utils/speaker_profiles.py CHANGED
@@ -123,7 +123,39 @@ simon_sinek = {
123
  """
124
  }
125
 
126
- speaker_voice_map = {"tony_robbins": 'c9688674-b48f-4e3b-860b-5e16be2821df',
127
- "les_brown": '7eca7f7b-8f25-4858-a852-6f3ec40c6f3d',
128
- "eric_thomas": 'b2f8b06a-a997-42c5-88be-620c275ae060',
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
129
  "simon_sinek": 'e8662e26-e528-48d2-a700-3e6b2b830e4f'}
 
123
  """
124
  }
125
 
126
+ arnold_schwarzenegger = {
127
+ "core_message_structure": """
128
+ - Vision statement β†’ Personal challenge β†’ Overcoming obstacles β†’ Universal lesson β†’ Call to action
129
+ - Uses "rules for success" framework
130
+ - Builds credibility through personal achievement stories
131
+ - Emphasizes practical, actionable steps
132
+ """,
133
+
134
+ "engagement_questions": """
135
+ - Who wants to be a champion?
136
+ - What is your vision for yourself?
137
+ - How hard are you willing to work?
138
+ - What rules are you willing to break?
139
+ - Who is ready to take the first step?
140
+ """,
141
+
142
+ "signature_language_patterns": """
143
+ - Decisive statements ("I'll be back", "No problemo", "Trust yourself")
144
+ - Success mindset phrases ("Break the rules", "Work your ass off", "Trust your vision")
145
+ - Motivational commands ("Do it now!", "Make it happen!", "Push harder!")
146
+ - Personal responsibility phrases ("No one will do it for you", "You have to want it")
147
+ """,
148
+
149
+ "story_framework": """
150
+ - Starts with immigrant/underdog position
151
+ - Describes specific goal or vision
152
+ - Details obstacles and naysayers
153
+ - Highlights breakthrough moments
154
+ - Connects to universal success principles
155
+ - Ends with empowering call to action
156
+ """
157
+ }
158
+
159
+ speaker_voice_map = {"tony_robbins": '9aa85af4-13d5-4327-a768-11e3d741eb03',
160
+ "arnold_schwarzenegger": '1029ecf6-f433-4a7d-ae89-ddac21e7d7d2',
161
  "simon_sinek": 'e8662e26-e528-48d2-a700-3e6b2b830e4f'}
pyproject.toml CHANGED
@@ -10,11 +10,14 @@ packages = [
10
  [tool.poetry.dependencies]
11
  python = ">3.9.7,<3.13"
12
  langchain = ">=0.3.0,<0.4.0"
 
13
  langchain-openai = ">=0.2.0"
14
  langchain-anthropic = ">=0.2.0,<0.3.0"
15
- langchain-google-genai = ">=0.0.5"
16
- langchain-community = ">=0.3.0,<0.4.0"
17
- langgraph = "*"
 
 
18
  pydantic = ">=2.0.0,<3.0.0"
19
  python-dotenv = "^1.0.0"
20
  openai = ">=1.6.1"
 
10
  [tool.poetry.dependencies]
11
  python = ">3.9.7,<3.13"
12
  langchain = ">=0.3.0,<0.4.0"
13
+ langchain-core = ">=0.3.15"
14
  langchain-openai = ">=0.2.0"
15
  langchain-anthropic = ">=0.2.0,<0.3.0"
16
+ langchain-groq = ">=0.2.1"
17
+ langchain-mistralai = ">=0.0.5"
18
+ langchain-fireworks = ">=0.2.1"
19
+ langchain-community = ">=0.3.7,<0.4.0"
20
+ langgraph = ">=0.0.1"
21
  pydantic = ">=2.0.0,<3.0.0"
22
  python-dotenv = "^1.0.0"
23
  openai = ">=1.6.1"