ginipick commited on
Commit
30890c3
·
verified ·
1 Parent(s): 85fa94e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -0
app.py CHANGED
@@ -621,6 +621,17 @@ Stay with me forever, let our love just flow"""
621
  """
622
  )
623
 
 
 
 
 
 
 
 
 
 
 
 
624
  # 이벤트 핸들러 설정
625
  lyrics_txt.change(
626
  fn=update_info,
 
621
  """
622
  )
623
 
624
+ def update_info(lyrics):
625
+ if not lyrics:
626
+ return "No lyrics entered", "No sections detected"
627
+ params = calculate_generation_params(lyrics)
628
+ duration = params['estimated_duration']
629
+ sections = params['sections']
630
+ return (
631
+ f"⏱️ Duration: {duration:.1f} seconds",
632
+ f"📊 Verses: {sections['verse']}, Chorus: {sections['chorus']}"
633
+ )
634
+
635
  # 이벤트 핸들러 설정
636
  lyrics_txt.change(
637
  fn=update_info,