DeepMount00 commited on
Commit
dd65707
ยท
verified ยท
1 Parent(s): 43c73ce

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -66
app.py CHANGED
@@ -19,7 +19,7 @@ DESCRIPTION = """\
19
  # Lexora 3B ITA ๐Ÿ’ฌ ๐Ÿ‡ฎ๐Ÿ‡น
20
  """
21
 
22
- # Updated CSS to ensure full height and proper markdown rendering
23
  CUSTOM_CSS = """
24
  .gradio-container {
25
  height: 100vh !important;
@@ -67,68 +67,6 @@ CUSTOM_CSS = """
67
  .examples-container {
68
  margin-top: auto;
69
  }
70
- /* Markdown styling */
71
- .bot-message p {
72
- margin-bottom: 0.5rem;
73
- }
74
- .bot-message h1, .bot-message h2, .bot-message h3,
75
- .bot-message h4, .bot-message h5, .bot-message h6 {
76
- margin-top: 1rem;
77
- margin-bottom: 0.5rem;
78
- }
79
- .bot-message code {
80
- background-color: #2d2d2d;
81
- padding: 0.2rem 0.4rem;
82
- border-radius: 0.2rem;
83
- font-family: monospace;
84
- }
85
- .bot-message pre {
86
- background-color: #2d2d2d;
87
- padding: 1rem;
88
- border-radius: 0.5rem;
89
- overflow-x: auto;
90
- margin: 1rem 0;
91
- }
92
- .bot-message pre code {
93
- background-color: transparent;
94
- padding: 0;
95
- border-radius: 0;
96
- }
97
- .bot-message ul, .bot-message ol {
98
- padding-left: 1.5rem;
99
- margin-bottom: 0.5rem;
100
- }
101
- .bot-message blockquote {
102
- border-left: 3px solid #4a4a4a;
103
- padding-left: 1rem;
104
- margin: 0.5rem 0;
105
- color: #a0a0a0;
106
- }
107
- .bot-message table {
108
- border-collapse: collapse;
109
- width: 100%;
110
- margin: 1rem 0;
111
- }
112
- .bot-message th, .bot-message td {
113
- border: 1px solid #4a4a4a;
114
- padding: 0.5rem;
115
- text-align: left;
116
- }
117
- .bot-message th {
118
- background-color: #2a2a2a;
119
- }
120
- .bot-message img {
121
- max-width: 100%;
122
- height: auto;
123
- margin: 1rem 0;
124
- }
125
- .bot-message a {
126
- color: #3291ff;
127
- text-decoration: none;
128
- }
129
- .bot-message a:hover {
130
- text-decoration: underline;
131
- }
132
  """
133
 
134
  MAX_MAX_NEW_TOKENS = 2048
@@ -245,11 +183,8 @@ chat_interface = gr.ChatInterface(
245
  stop_btn=None,
246
  examples=[
247
  ["Ciao! Come stai?"],
248
- ["Puoi scrivere una lista markdown?"],
249
- ["Scrivi un esempio di codice Python"],
250
  ],
251
  cache_examples=False,
252
- render_markdown=True, # Enable Markdown rendering
253
  )
254
 
255
  with gr.Blocks(css=CUSTOM_CSS, fill_height=True, theme=gr.themes.Base()) as demo:
 
19
  # Lexora 3B ITA ๐Ÿ’ฌ ๐Ÿ‡ฎ๐Ÿ‡น
20
  """
21
 
22
+ # Updated CSS to ensure full height and proper scrolling
23
  CUSTOM_CSS = """
24
  .gradio-container {
25
  height: 100vh !important;
 
67
  .examples-container {
68
  margin-top: auto;
69
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
70
  """
71
 
72
  MAX_MAX_NEW_TOKENS = 2048
 
183
  stop_btn=None,
184
  examples=[
185
  ["Ciao! Come stai?"],
 
 
186
  ],
187
  cache_examples=False,
 
188
  )
189
 
190
  with gr.Blocks(css=CUSTOM_CSS, fill_height=True, theme=gr.themes.Base()) as demo: