dkavalapara commited on
Commit
411fe95
·
verified ·
1 Parent(s): 31affcc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +37 -15
app.py CHANGED
@@ -4,21 +4,43 @@ from huggingface_hub import InferenceClient
4
  from sentence_transformers import SentenceTransformer
5
  import torch
6
 
7
- theme = gr.themes.Ocean(
8
- **primary_hue="teal", # Rich teal for buttons and accents**
9
- **secondary_hue="blue", # Deeper blue highlights**
10
- neutral_hue="sky", # Softer background elements
11
- ).set(
12
- **body_background_fill="#e0f7f7", # Soft teal background**
13
- **button_primary_background_fill="#00796b", # Deep teal for primary buttons**
14
- **button_secondary_background_fill="#0288d1", # Vibrant blue for secondary buttons**
15
- **button_primary_text_color="#ffffff", # White text for contrast**
16
- **button_secondary_text_color="#ffffff",**
17
- **input_background_fill="#b2ebf2", # Soft input background**
18
- card_background_fill="#ffffff", # White chat bubbles for contrast
19
- **card_shadow="0px 4px 20px rgba(0, 0, 0, 0.15)" # Soft shadow for depth**
20
- )
21
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
22
 
23
 
24
  # SEMANTIC SEARCH STEP 2
 
4
  from sentence_transformers import SentenceTransformer
5
  import torch
6
 
7
+ theme = gr.themes.Base() # use a simple base theme, we'll add custom CSS
8
+
9
+ # --- Custom CSS ---
10
+ custom_css = """
11
+ body {
12
+ background-color: #e0f7f7 !important; /* soft teal background */
13
+ }
14
+
15
+ .gradio-container {
16
+ font-family: "Helvetica", sans-serif;
17
+ }
18
+
19
+ .gr-button-primary {
20
+ background: linear-gradient(145deg, #00796b, #004d40) !important; /* deep teal gradient */
21
+ color: white !important;
22
+ box-shadow: 0px 4px 12px rgba(0,0,0,0.2) !important;
23
+ border-radius: 12px !important;
24
+ }
25
+
26
+ .gr-button-secondary {
27
+ background: linear-gradient(145deg, #0288d1, #01579b) !important; /* vibrant blue gradient */
28
+ color: white !important;
29
+ box-shadow: 0px 4px 12px rgba(0,0,0,0.2) !important;
30
+ border-radius: 12px !important;
31
+ }
32
+
33
+ .gr-chat-message {
34
+ background: #ffffff !important;
35
+ box-shadow: 0px 4px 15px rgba(0,0,0,0.15) !important;
36
+ border-radius: 15px !important;
37
+ padding: 10px !important;
38
+ }
39
+
40
+ img {
41
+ border-radius: 15px;
42
+ box-shadow: 0px 8px 20px rgba(0,0,0,0.25);
43
+ }
44
 
45
 
46
  # SEMANTIC SEARCH STEP 2