Spaces:
Running
Running
elibrowne
commited on
Commit
·
91dd53f
1
Parent(s):
d225a9c
Attempt upload to dataset
Browse files- study.html +14 -0
study.html
CHANGED
@@ -17,6 +17,7 @@
|
|
17 |
<p> We really appreciate your participation in our study, which will help us better understand how to best evaluate and use legal retrieval models. </p>
|
18 |
</body>
|
19 |
<script>
|
|
|
20 |
var url = window.location.href;
|
21 |
var username = url.split("?id=");
|
22 |
if (username.length == 1) {
|
@@ -24,5 +25,18 @@
|
|
24 |
} else {
|
25 |
document.getElementById("username").innerHTML = "Logged in as " + username[1] + "!";
|
26 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
27 |
</script>
|
28 |
</html>
|
|
|
17 |
<p> We really appreciate your participation in our study, which will help us better understand how to best evaluate and use legal retrieval models. </p>
|
18 |
</body>
|
19 |
<script>
|
20 |
+
// Make sure user information is available before the app serves questions.
|
21 |
var url = window.location.href;
|
22 |
var username = url.split("?id=");
|
23 |
if (username.length == 1) {
|
|
|
25 |
} else {
|
26 |
document.getElementById("username").innerHTML = "Logged in as " + username[1] + "!";
|
27 |
}
|
28 |
+
var user = username[1];
|
29 |
+
</script>
|
30 |
+
<script type="module">
|
31 |
+
// Load dataset information.
|
32 |
+
import { uploadFile } from "https://cdn.jsdelivr.net/npm/@huggingface/[email protected]/+esm";
|
33 |
+
await uploadFile({
|
34 |
+
repo: "ebrowne/test-data",
|
35 |
+
// Can work with native File in browsers
|
36 |
+
file: {
|
37 |
+
path: "response.json",
|
38 |
+
content: {"email": user, "numerical_data": 1, "datetime": Date.now().toString()}
|
39 |
+
}
|
40 |
+
});
|
41 |
</script>
|
42 |
</html>
|