XThomasBU commited on
Commit
adc4b88
·
1 Parent(s): ac3c353
apps/ai_tutor/.chainlit/config.toml CHANGED
@@ -20,10 +20,10 @@ allow_origins = ["*"]
20
 
21
  [features]
22
  # Process and display HTML in messages. This can be a security risk (see https://stackoverflow.com/questions/19603097/why-is-it-dangerous-to-render-user-generated-html-or-javascript)
23
- unsafe_allow_html = false
24
 
25
  # Process and display mathematical expressions. This can clash with "$" characters in messages.
26
- latex = false
27
 
28
  # Automatically tag threads with the current chat profile (if a chat profile is used)
29
  auto_tag_thread = true
@@ -53,7 +53,7 @@ edit_message = true
53
 
54
  [UI]
55
  # Name of the assistant.
56
- name = "Assistant"
57
 
58
  # Description of the assistant. This is used for HTML tags.
59
  # description = ""
@@ -62,14 +62,14 @@ name = "Assistant"
62
  default_collapse_content = true
63
 
64
  # Chain of Thought (CoT) display mode. Can be "hidden", "tool_call" or "full".
65
- cot = "full"
66
 
67
  # Link to your github repo. This will add a github button in the UI's header.
68
- # github = ""
69
 
70
  # Specify a CSS file that can be used to customize the user interface.
71
  # The CSS file can be served from the public directory or via an external link.
72
- # custom_css = "/public/test.css"
73
 
74
  # Specify a Javascript file that can be used to customize the user interface.
75
  # The Javascript file can be served from the public directory.
@@ -79,7 +79,7 @@ cot = "full"
79
  # custom_font = "https://fonts.googleapis.com/css2?family=Inter:wght@400;500;700&display=swap"
80
 
81
  # Specify a custom meta image url.
82
- # custom_meta_image_url = "https://chainlit-cloud.s3.eu-west-3.amazonaws.com/logo/chainlit_banner.png"
83
 
84
  # Specify a custom build directory for the frontend.
85
  # This can be used to customize the frontend code.
@@ -87,7 +87,7 @@ cot = "full"
87
  # custom_build = "./public/build"
88
 
89
  [UI.theme]
90
- default = "dark"
91
  #layout = "wide"
92
  #font_family = "Inter, sans-serif"
93
  # Override default MUI light theme. (Check theme.ts)
 
20
 
21
  [features]
22
  # Process and display HTML in messages. This can be a security risk (see https://stackoverflow.com/questions/19603097/why-is-it-dangerous-to-render-user-generated-html-or-javascript)
23
+ unsafe_allow_html = true
24
 
25
  # Process and display mathematical expressions. This can clash with "$" characters in messages.
26
+ latex = true
27
 
28
  # Automatically tag threads with the current chat profile (if a chat profile is used)
29
  auto_tag_thread = true
 
53
 
54
  [UI]
55
  # Name of the assistant.
56
+ name = "AI Tutor"
57
 
58
  # Description of the assistant. This is used for HTML tags.
59
  # description = ""
 
62
  default_collapse_content = true
63
 
64
  # Chain of Thought (CoT) display mode. Can be "hidden", "tool_call" or "full".
65
+ cot = "hidden"
66
 
67
  # Link to your github repo. This will add a github button in the UI's header.
68
+ github = "https://github.com/DL4DS/dl4ds_tutor"
69
 
70
  # Specify a CSS file that can be used to customize the user interface.
71
  # The CSS file can be served from the public directory or via an external link.
72
+ custom_css = "/public/test.css"
73
 
74
  # Specify a Javascript file that can be used to customize the user interface.
75
  # The Javascript file can be served from the public directory.
 
79
  # custom_font = "https://fonts.googleapis.com/css2?family=Inter:wght@400;500;700&display=swap"
80
 
81
  # Specify a custom meta image url.
82
+ custom_meta_image_url = "https://upload.wikimedia.org/wikipedia/commons/thumb/f/f5/Boston_University_seal.svg/1200px-Boston_University_seal.svg.png"
83
 
84
  # Specify a custom build directory for the frontend.
85
  # This can be used to customize the frontend code.
 
87
  # custom_build = "./public/build"
88
 
89
  [UI.theme]
90
+ default = "light"
91
  #layout = "wide"
92
  #font_family = "Inter, sans-serif"
93
  # Override default MUI light theme. (Check theme.ts)
apps/ai_tutor/public/avatars/{ai_tutor.png → ai-tutor.png} RENAMED
File without changes
apps/ai_tutor/public/test.css CHANGED
@@ -2,6 +2,11 @@ a[href*='https://github.com/Chainlit/chainlit'] {
2
  visibility: hidden;
3
  }
4
 
 
 
 
 
 
5
 
6
  /* Target the container of the image and set a custom background image */
7
  .MuiAvatar-root.MuiAvatar-circular.css-m2icte {
@@ -13,12 +18,11 @@ a[href*='https://github.com/Chainlit/chainlit'] {
13
  border-radius: 50%; /* Maintain circular shape */
14
  }
15
 
16
-
17
- .MuiAvatar-root.MuiAvatar-circular.css-v72an7 {
18
  background-image: url('/public/avatars/ai-tutor.png'); /* Replace with your custom image URL */
19
- background-size: cover; /* Ensure the image covers the entire container */
20
- background-position: center; /* Center the image */
21
- width: 40px; /* Ensure the dimensions match the original */
22
- height: 40px; /* Ensure the dimensions match the original */
23
- border-radius: 50%; /* Maintain circular shape */
24
- }
 
2
  visibility: hidden;
3
  }
4
 
5
+ /* TODO: Default image is still shown in the starter questions */
6
+ /* Hide the default avatar image */
7
+ .MuiAvatar-root.MuiAvatar-circular {
8
+ background-image: none; /* Remove default image */
9
+ }
10
 
11
  /* Target the container of the image and set a custom background image */
12
  .MuiAvatar-root.MuiAvatar-circular.css-m2icte {
 
18
  border-radius: 50%; /* Maintain circular shape */
19
  }
20
 
21
+ /* .MuiAvatar-root.MuiAvatar-circular.css-v72an7 {
 
22
  background-image: url('/public/avatars/ai-tutor.png'); /* Replace with your custom image URL */
23
+ /* background-size: cover; /* Ensure the image covers the entire container */
24
+ /* background-position: center; /* Center the image */
25
+ /* width: 40px; /* Ensure the dimensions match the original */
26
+ /* height: 40px; /* Ensure the dimensions match the original */
27
+ /* border-radius: 50%; /* Maintain circular shape */
28
+ /* } */
apps/ai_tutor/templates/cooldown.html CHANGED
@@ -121,7 +121,7 @@
121
  </head>
122
  <body>
123
  <div class="container">
124
- <img src="/public/avatars/ai_tutor.png" alt="AI Tutor Avatar" class="avatar">
125
  <h1>Hello, {{ username }}</h1>
126
  <p>It seems like you need to wait a bit before starting a new session.</p>
127
  <p class="cooldown-message">Time remaining until the cooldown period ends:</p>
 
121
  </head>
122
  <body>
123
  <div class="container">
124
+ <img src="/public/avatars/ai-tutor.png" alt="AI Tutor Avatar" class="avatar">
125
  <h1>Hello, {{ username }}</h1>
126
  <p>It seems like you need to wait a bit before starting a new session.</p>
127
  <p class="cooldown-message">Time remaining until the cooldown period ends:</p>
apps/ai_tutor/templates/dashboard.html CHANGED
@@ -123,7 +123,7 @@
123
  </head>
124
  <body>
125
  <div class="container">
126
- <img src="/public/avatars/ai_tutor.png" alt="AI Tutor Avatar" class="avatar">
127
  <h1>Welcome, {{ username }}</h1>
128
  <p>Ready to start your AI tutoring session?</p>
129
  <p class="tokens-left">Tokens Left: {{ tokens_left }}</p>
 
123
  </head>
124
  <body>
125
  <div class="container">
126
+ <img src="/public/avatars/ai-tutor.png" alt="AI Tutor Avatar" class="avatar">
127
  <h1>Welcome, {{ username }}</h1>
128
  <p>Ready to start your AI tutoring session?</p>
129
  <p class="tokens-left">Tokens Left: {{ tokens_left }}</p>
apps/ai_tutor/templates/login.html CHANGED
@@ -107,7 +107,7 @@
107
  </head>
108
  <body>
109
  <div class="container">
110
- <img src="/public/avatars/ai_tutor.png" alt="AI Tutor Avatar" class="avatar">
111
  <h1>Terrier Tutor</h1>
112
  <p>Welcome to the DS598 AI Tutor. Please sign in to continue.</p>
113
  <form action="/login/google" method="get">
 
107
  </head>
108
  <body>
109
  <div class="container">
110
+ <img src="/public/avatars/ai-tutor.png" alt="AI Tutor Avatar" class="avatar">
111
  <h1>Terrier Tutor</h1>
112
  <p>Welcome to the DS598 AI Tutor. Please sign in to continue.</p>
113
  <form action="/login/google" method="get">