bparrino commited on
Commit
5d86a10
·
verified ·
1 Parent(s): 88b363c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +91 -66
app.py CHANGED
@@ -99,6 +99,18 @@ st.markdown("""
99
  background-color: #f8f9fa;
100
  color: #666;
101
  }
 
 
 
 
 
 
 
 
 
 
 
 
102
  </style>
103
  """, unsafe_allow_html=True)
104
 
@@ -292,13 +304,17 @@ def calculate_format_scores(audience_type, budget, objectives, goals, timeline,
292
 
293
  # Objectives matching
294
  objective_matches = {
295
- "Skill development": ["simulation_training", "video_tutorials", "gamified_learning", "elearning_courses"],
296
- "Compliance training": ["elearning_courses", "pdf_guides", "webinar_series", "blended_learning", "powerpoint_presentations"],
297
- "Product knowledge": ["video_tutorials", "elearning_courses", "webinar_series", "mobile_learning", "powerpoint_presentations"],
298
- "Onboarding": ["blended_learning", "elearning_courses", "video_tutorials", "powerpoint_presentations"],
299
- "Certification prep": ["elearning_courses", "blended_learning", "webinar_series", "pdf_guides"],
300
- "Behavior change": ["gamified_learning", "simulation_training", "microlearning_modules", "video_tutorials"],
301
- "Knowledge sharing": ["webinar_series", "pdf_guides", "elearning_courses", "video_tutorials", "powerpoint_presentations"]
 
 
 
 
302
  }
303
 
304
  for objective in objectives:
@@ -315,12 +331,16 @@ def calculate_format_scores(audience_type, budget, objectives, goals, timeline,
315
 
316
  # Goals matching
317
  goal_matches = {
318
- "Reduce training costs": ["microlearning_modules", "pdf_guides", "webinar_series", "elearning_courses", "powerpoint_presentations"],
319
- "Improve engagement": ["gamified_learning", "simulation_training", "video_tutorials", "mobile_learning"],
320
- "Scale training globally": ["elearning_courses", "mobile_learning", "webinar_series", "microlearning_modules"],
321
- "Faster deployment": ["microlearning_modules", "pdf_guides", "webinar_series", "mobile_learning", "powerpoint_presentations"],
322
- "Better retention": ["gamified_learning", "simulation_training", "microlearning_modules", "video_tutorials"],
323
- "Measurable results": ["elearning_courses", "gamified_learning", "simulation_training", "blended_learning"]
 
 
 
 
324
  }
325
 
326
  for goal in goals:
@@ -387,33 +407,41 @@ with col1:
387
  help="How quickly do you need the training content ready?"
388
  )
389
 
390
- # Objectives
391
  objectives = st.multiselect(
392
- "What are your main training objectives?",
393
  [
394
- "Skill development",
395
- "Compliance training",
396
- "Product knowledge",
397
- "Onboarding",
398
- "Certification prep",
399
- "Behavior change",
400
- "Knowledge sharing"
 
 
 
 
401
  ],
402
- help="What specific outcomes do you need to achieve? Select all that apply (you can choose multiple)"
403
  )
404
 
405
- # Goals
406
  goals = st.multiselect(
407
- "What are your key goals?",
408
  [
409
- "Reduce training costs",
410
- "Improve engagement",
411
- "Scale training globally",
412
- "Faster deployment",
413
- "Better retention",
414
- "Measurable results"
 
 
 
 
415
  ],
416
- help="What business metrics matter most to your organization? Select your top priorities"
417
  )
418
 
419
  # Interaction Level
@@ -432,6 +460,14 @@ with col1:
432
  help="Tell us about any special requirements or constraints"
433
  )
434
 
 
 
 
 
 
 
 
 
435
  # Examples for inspiration
436
  with st.expander("Need help? See example scenarios", expanded=False):
437
  st.markdown('<div class="examples-section">', unsafe_allow_html=True)
@@ -441,22 +477,22 @@ with col1:
441
  "title": "New Employee Onboarding",
442
  "audience": "New hires",
443
  "budget": "Medium",
444
- "objectives": ["Onboarding", "Skill development"],
445
- "goals": ["Better retention", "Faster deployment"]
446
  },
447
  {
448
  "title": "Sales Team Product Training",
449
  "audience": "Sales teams",
450
  "budget": "High",
451
- "objectives": ["Product knowledge", "Skill development"],
452
- "goals": ["Improve engagement", "Measurable results"]
453
  },
454
  {
455
  "title": "Compliance Training Rollout",
456
  "audience": "Corporate employees",
457
  "budget": "Low",
458
- "objectives": ["Compliance training"],
459
- "goals": ["Scale training globally", "Reduce training costs"]
460
  }
461
  ]
462
 
@@ -477,7 +513,7 @@ with col1:
477
  if not objectives:
478
  st.info("Please select at least one training objective")
479
  elif not goals:
480
- st.info("Please select at least one goal")
481
 
482
  # Display recommendations
483
  with col2:
@@ -548,13 +584,12 @@ with col2:
548
  </div>
549
  """, unsafe_allow_html=True)
550
 
551
- # Add "Get Custom Proposal" button for top recommendation
552
  if i == 0:
553
  st.markdown('<div style="margin-top: 15px;">', unsafe_allow_html=True)
554
- if st.button(f"🎯 Get Custom Proposal for {format_data['name']}", key=f"proposal_{format_id}", use_container_width=True):
555
  st.balloons()
556
- st.success("🚀 Great choice! We'll be in touch within 24 hours to discuss your custom proposal.")
557
- # In a real implementation, this would trigger a lead capture form or redirect
558
  st.markdown('</div>', unsafe_allow_html=True)
559
 
560
  st.markdown('</div>', unsafe_allow_html=True)
@@ -596,7 +631,7 @@ with col2:
596
  st.write(f"- **Additional Context:** {recommendations['params']['context']}")
597
 
598
  # Action buttons
599
- col_b1, col_b2, col_b3 = st.columns(3)
600
 
601
  with col_b1:
602
  # Generate report
@@ -616,29 +651,19 @@ with col2:
616
  )
617
 
618
  with col_b2:
619
- # Consultation CTA
620
- if st.button("🤝 Schedule Consultation", use_container_width=True):
621
- st.success("🎉 Perfect! A Motivation Technologies expert will contact you within 24 hours to discuss your training needs.")
622
- # In a real implementation, this would redirect to a booking calendar
623
-
624
- with col_b3:
625
  # New analysis button
626
  if st.button("🔄 New Analysis", use_container_width=True):
627
- st.session_state["recommendations"] = None
628
- st.rerun()
629
-
630
- else:
631
- # Placeholder
632
- st.markdown("""
633
- <div class="placeholder-area">
634
- <h3>🎯 Your Recommendations Will Appear Here</h3>
635
- <p>Fill out your training requirements and click 'Get My Recommendations' to discover the best content formats for your needs.</p>
636
- </div>
637
- """, unsafe_allow_html=True)
638
 
639
  # Footer
640
- st.markdown("""
641
- <div class="footnote">
642
- <p><strong>Note:</strong> Recommendations are based on industry best practices and typical use cases. Consider piloting your chosen format with a small group before full deployment. Results may vary based on your specific context and constraints.</p>
643
- </div>
644
- """, unsafe_allow_html=True)
 
99
  background-color: #f8f9fa;
100
  color: #666;
101
  }
102
+ .consultation-cta {
103
+ background-color: #e8f5e8;
104
+ border: 1px solid #4CAF50;
105
+ border-radius: 8px;
106
+ padding: 15px;
107
+ margin: 20px 0;
108
+ text-align: center;
109
+ }
110
+ .consultation-cta h4 {
111
+ color: #2d6a2d;
112
+ margin-bottom: 10px;
113
+ }
114
  </style>
115
  """, unsafe_allow_html=True)
116
 
 
304
 
305
  # Objectives matching
306
  objective_matches = {
307
+ "Build technical expertise & hard skills": ["simulation_training", "video_tutorials", "gamified_learning", "elearning_courses"],
308
+ "Develop leadership & management capabilities": ["blended_learning", "webinar_series", "elearning_courses", "simulation_training"],
309
+ "Ensure compliance & meet regulatory requirements": ["elearning_courses", "pdf_guides", "webinar_series", "blended_learning", "powerpoint_presentations"],
310
+ "Master product knowledge & service delivery": ["video_tutorials", "elearning_courses", "webinar_series", "mobile_learning", "powerpoint_presentations"],
311
+ "Onboard & integrate new team members": ["blended_learning", "elearning_courses", "video_tutorials", "powerpoint_presentations"],
312
+ "Strengthen safety protocols & risk management": ["simulation_training", "video_tutorials", "elearning_courses", "gamified_learning"],
313
+ "Boost sales performance & customer relationships": ["gamified_learning", "video_tutorials", "mobile_learning", "simulation_training"],
314
+ "Achieve professional certifications & credentials": ["elearning_courses", "blended_learning", "webinar_series", "pdf_guides"],
315
+ "Standardize processes & operational procedures": ["video_tutorials", "elearning_courses", "pdf_guides", "microlearning_modules"],
316
+ "Enhance communication & interpersonal skills": ["blended_learning", "webinar_series", "gamified_learning", "elearning_courses"],
317
+ "Navigate organizational change & transformation": ["blended_learning", "webinar_series", "gamified_learning", "microlearning_modules"]
318
  }
319
 
320
  for objective in objectives:
 
331
 
332
  # Goals matching
333
  goal_matches = {
334
+ "Maximize training ROI & minimize costs": ["microlearning_modules", "pdf_guides", "webinar_series", "elearning_courses", "powerpoint_presentations"],
335
+ "Drive learner engagement & motivation": ["gamified_learning", "simulation_training", "video_tutorials", "mobile_learning"],
336
+ "Scale training across distributed teams": ["elearning_courses", "mobile_learning", "webinar_series", "microlearning_modules"],
337
+ "Accelerate training deployment & time-to-market": ["microlearning_modules", "pdf_guides", "webinar_series", "mobile_learning", "powerpoint_presentations"],
338
+ "Improve knowledge retention & skill application": ["gamified_learning", "simulation_training", "microlearning_modules", "video_tutorials"],
339
+ "Generate measurable business impact & results": ["elearning_courses", "gamified_learning", "simulation_training", "blended_learning"],
340
+ "Enhance accessibility & learning flexibility": ["mobile_learning", "elearning_courses", "microlearning_modules", "pdf_guides"],
341
+ "Foster continuous learning culture": ["microlearning_modules", "gamified_learning", "mobile_learning", "blended_learning"],
342
+ "Ensure consistent training quality & standards": ["elearning_courses", "video_tutorials", "pdf_guides", "webinar_series"],
343
+ "Support performance improvement & productivity": ["simulation_training", "gamified_learning", "microlearning_modules", "blended_learning"]
344
  }
345
 
346
  for goal in goals:
 
407
  help="How quickly do you need the training content ready?"
408
  )
409
 
410
+ # Updated Objectives with stronger, more specific language
411
  objectives = st.multiselect(
412
+ "What are your primary training objectives? (Select what you want to achieve)",
413
  [
414
+ "Build technical expertise & hard skills",
415
+ "Develop leadership & management capabilities",
416
+ "Ensure compliance & meet regulatory requirements",
417
+ "Master product knowledge & service delivery",
418
+ "Onboard & integrate new team members",
419
+ "Strengthen safety protocols & risk management",
420
+ "Boost sales performance & customer relationships",
421
+ "Achieve professional certifications & credentials",
422
+ "Standardize processes & operational procedures",
423
+ "Enhance communication & interpersonal skills",
424
+ "Navigate organizational change & transformation"
425
  ],
426
+ help="What specific learning outcomes do you need to achieve? Select all that apply - be as specific as possible about your training objectives"
427
  )
428
 
429
+ # Updated Goals with stronger, more business-focused language
430
  goals = st.multiselect(
431
+ "What are your key strategic goals? (Select what success looks like)",
432
  [
433
+ "Maximize training ROI & minimize costs",
434
+ "Drive learner engagement & motivation",
435
+ "Scale training across distributed teams",
436
+ "Accelerate training deployment & time-to-market",
437
+ "Improve knowledge retention & skill application",
438
+ "Generate measurable business impact & results",
439
+ "Enhance accessibility & learning flexibility",
440
+ "Foster continuous learning culture",
441
+ "Ensure consistent training quality & standards",
442
+ "Support performance improvement & productivity"
443
  ],
444
+ help="What business outcomes matter most to your organization? Select your top 2-3 priorities to maximize impact and ROI"
445
  )
446
 
447
  # Interaction Level
 
460
  help="Tell us about any special requirements or constraints"
461
  )
462
 
463
+ # Consultation CTA - Moved higher in the form
464
+ st.markdown('<div class="consultation-cta">', unsafe_allow_html=True)
465
+ st.markdown('<h4>💡 Want Expert Guidance?</h4>', unsafe_allow_html=True)
466
+ st.markdown('<p style="margin-bottom: 15px;">Get personalized recommendations from our learning design experts</p>', unsafe_allow_html=True)
467
+ if st.button("🤝 Schedule Free Consultation", use_container_width=True, type="primary"):
468
+ st.success("🎉 Perfect! A Motivation Technologies expert will contact you within 24 hours to discuss your training needs.")
469
+ st.markdown('</div>', unsafe_allow_html=True)
470
+
471
  # Examples for inspiration
472
  with st.expander("Need help? See example scenarios", expanded=False):
473
  st.markdown('<div class="examples-section">', unsafe_allow_html=True)
 
477
  "title": "New Employee Onboarding",
478
  "audience": "New hires",
479
  "budget": "Medium",
480
+ "objectives": ["Onboard & integrate new team members", "Enhance communication & interpersonal skills"],
481
+ "goals": ["Improve knowledge retention & skill application", "Accelerate training deployment & time-to-market"]
482
  },
483
  {
484
  "title": "Sales Team Product Training",
485
  "audience": "Sales teams",
486
  "budget": "High",
487
+ "objectives": ["Master product knowledge & service delivery", "Boost sales performance & customer relationships"],
488
+ "goals": ["Drive learner engagement & motivation", "Generate measurable business impact & results"]
489
  },
490
  {
491
  "title": "Compliance Training Rollout",
492
  "audience": "Corporate employees",
493
  "budget": "Low",
494
+ "objectives": ["Ensure compliance & meet regulatory requirements"],
495
+ "goals": ["Scale training across distributed teams", "Maximize training ROI & minimize costs"]
496
  }
497
  ]
498
 
 
513
  if not objectives:
514
  st.info("Please select at least one training objective")
515
  elif not goals:
516
+ st.info("Please select at least one strategic goal")
517
 
518
  # Display recommendations
519
  with col2:
 
584
  </div>
585
  """, unsafe_allow_html=True)
586
 
587
+ # Add "Get Custom Proposal" button for top recommendation with updated text
588
  if i == 0:
589
  st.markdown('<div style="margin-top: 15px;">', unsafe_allow_html=True)
590
+ if st.button(f"🎯 Get a custom proposal from the experts at Motivation Technologies today!", key=f"proposal_{format_id}", use_container_width=True, type="primary"):
591
  st.balloons()
592
+ st.success("🚀 Excellent choice! Our learning design experts at Motivation Technologies will be in touch within 24 hours to discuss your custom proposal.")
 
593
  st.markdown('</div>', unsafe_allow_html=True)
594
 
595
  st.markdown('</div>', unsafe_allow_html=True)
 
631
  st.write(f"- **Additional Context:** {recommendations['params']['context']}")
632
 
633
  # Action buttons
634
+ col_b1, col_b2 = st.columns(2)
635
 
636
  with col_b1:
637
  # Generate report
 
651
  )
652
 
653
  with col_b2:
 
 
 
 
 
 
654
  # New analysis button
655
  if st.button("🔄 New Analysis", use_container_width=True):
656
+ st.session_state["recommendations"] = None
657
+ st.rerun()
658
+
659
+ else:
660
+ # Placeholder content when no recommendations yet
661
+ st.markdown('<div class="placeholder-area">', unsafe_allow_html=True)
662
+ st.markdown('<h3>🎯 Your Recommendations Will Appear Here</h3>')
663
+ st.markdown('<p>Complete the form on the left and click "Get My Recommendations" to see your personalized training format suggestions.</p>')
664
+ st.markdown('</div>', unsafe_allow_html=True)
 
 
665
 
666
  # Footer
667
+ st.markdown('<div class="footnote">', unsafe_allow_html=True)
668
+ st.markdown('*This tool uses advanced algorithms to match your requirements with optimal training formats. Results are based on industry best practices and effectiveness data.*')
669
+ st.markdown('</div>', unsafe_allow_html=True)