iamkdp commited on
Commit
1644285
·
verified ·
1 Parent(s): 9c6953b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +21 -3
app.py CHANGED
@@ -13,12 +13,30 @@ CACHE_TTL = 3600 # 1 hour cache
13
  response_cache = TTLCache(maxsize=100, ttl=CACHE_TTL)
14
 
15
  # Spiritual theme configuration
16
- SPIRITUAL_THEME = gr.themes.Default(
17
- primary_hue=gr.themes.Color("#2c786c"), # Emerald
18
- secondary_hue=gr.themes.Color("#FFD700"), # Gold
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
19
  font=[gr.themes.GoogleFont("Hind Siliguri")]
20
  )
21
 
 
 
 
22
 
23
  def format_krishna_prompt(message, history):
24
  """Create proper Mistral instruction prompt with Krishna context"""
 
13
  response_cache = TTLCache(maxsize=100, ttl=CACHE_TTL)
14
 
15
  # Spiritual theme configuration
16
+ from gradio.themes import Default, Color, utils
17
+
18
+ # Emerald color palette (from dark to light)
19
+ emerald = Color(
20
+ "#2c786c", # Base color
21
+ *utils.series("#2c786c", 10) # Auto-generate 10 shades
22
+ )
23
+
24
+ # Gold color palette
25
+ gold = Color(
26
+ "#ffd700", # Base color
27
+ *utils.series("#ffd700", 10)
28
+ )
29
+
30
+ # Create theme with custom colors
31
+ SPIRITUAL_THEME = Default(
32
+ primary_hue=emerald,
33
+ secondary_hue=gold,
34
  font=[gr.themes.GoogleFont("Hind Siliguri")]
35
  )
36
 
37
+ # Rest of your app code...
38
+
39
+
40
 
41
  def format_krishna_prompt(message, history):
42
  """Create proper Mistral instruction prompt with Krishna context"""