-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
110 lines (87 loc) · 3.28 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Ask Alfred</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<div class="form-container">
<form id="buildCourseForm">
<h1>Build a New Course</h1>
<br><br>
<label for="buildCourse">What do you want the course to be about?</label>
<input type="text" id="buildCourse" name="buildCourse" required>
<button type="submit">BuildCourse</button>
</form>
<h2>Build Course Answer:</h2>
<div id="buildCourse-response"></div>
<br><br>
<br><br>
<hr>
<form id="uploadForm">
<h1>Upload a Word Document</h1>
<label for="fileInput">Choose a .docx OR .txt file:</label>
<input type="file" id="fileInput" accept=".docx, .txt" required>
<button type="button" onclick="uploadFile()">Upload</button>
</form>
<h2>File Upload Response:</h2>
<div id="uploadResponse"></div>
<br><br>
<form id="icdsForm">
<h1>Ask ICDS</h1>
<label for="course">Course:</label>
<select id="icds-course" name="icds-course" required>
<option value="">Select a course</option>
</select>
<button type="button" id="fetchButtonICDS">Fetch Courses from ICDS</button>
<br>
<br><br>
<label for="icds-question">Ask ICDS:</label>
<input type="text" id="icds-question" name="icds-question" required>
<button type="submit">Submit</button>
</form>
<h2>ICDS Answer:</h2>
<div id="icds-response"></div>
<br><br>
<br><br>
<hr>
<br><br>
<form id="apiForm">
<h1>Ask Alfred</h1>
<label for="course">Course:</label>
<select id="course" name="course" required>
<option value="">Select a course</option>
</select>
<button type="button" id="fetchButton">Fetch Courses</button>
<br>
<label for="question">Ask Alfred:</label>
<input type="text" id="question" name="question" required>
<label for="engine">Engine:</label>
<select id="engine" name="engine" required>
<option value="Alfred">Alfred - OpenAI</option>
<!--<option value="Robin">Robin - Anthropic</option>-->
<option value="Catwoman">Catwoman - ChatGPT only</option>
</select>
<button type="submit">Submit</button>
</form>
<div id="spinner" class="spinner" style="display: none;"></div>
<h2>Answer:</h2>
<div id="response"></div>
</div>
<!--
<div class="form-container">
<h1>Create Course</h1>
<form id="courseForm">
<label for="course">Course - Paste URL:</label>
<input type="text" id="courseCreate" name="courseCreate" required>
<button type="submit">Submit</button>
</form>
<h2>Response:</h2>
<div id="responseAdd"></div>
</div>
-->
<script src="script.js"></script>
</body>
</html>