-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcreateForm.js
executable file
·51 lines (41 loc) · 3.2 KB
/
createForm.js
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
function createForm() {
// Access the active spreadsheet
var ss = SpreadsheetApp.getActiveSpreadsheet();
var sheet = ss.getSheets()[0];
// Create a new form
var form = FormApp.create('GPT-4 for LED Annotation Evaluation - Yellow Group');
// Introduction and guidelines
form.setTitle('GPT-4 for LED Annotation Evaluation');
form.setDescription('The purpose of this evaluation is to assess the accuracy, relevance, and coherence of ChatGPT\'s Annotation in comparison to a Curators Annotation”. As evaluators, your feedback will be instrumental in understanding the effectiveness and performance of GPT-4 in LED Annotation tasks.\n\n' +
'General Guidelines:\n' +
'- Time: It will take approximately 40 minutes to complete this task. There are 20 items. Each item is expected to take 2 minutes\n' +
'- Confidentiality: All responses and data shared in this evaluation are confidential. Do not share, reproduce, or discuss the content outside of this evaluation process.\n' +
'- Bias and Fairness: Approach each item objectively, without any preconceived bias. It is essential to provide a fair assessment based on the content provided, rather than personal beliefs or preferences.\n' +
'- Avoid Rushing: Take your time with each item to ensure accurate evaluation. It\'s not a race; accuracy is more valuable than speed.\n\n' +
'Steps for Evaluation:\n' +
'1. Review the ChatGPT Annotation and Curators Annotation: For each item, you will see the submitted evidence, annotation generated by ChatGPT 4.0 and the corresponding curators annotation. Read both thoroughly.\n' +
'2. Move to the Next Item: Once you\'ve evaluated all aspects of the item, click on Next, and proceed to the next item.\n' +
'3. Completion: After evaluating all the 20 items, submit the form.');
// Loop through each row in the spreadsheet
var rows = sheet.getDataRange().getValues();
// Skip the header row
for (var i = 1; i < rows.length; i++) {
var rowData = rows[i];
// Create a new page for each item
var page = form.addPageBreakItem().setTitle('Item ' + i + ' of ' + (rows.length-1));
// Section 1: Display results
var description = "SUBMITTED EVIDENCE:\n " + rowData[1] + "\n\nGPT-4 ANNOTATION:\n " + rowData[2] + "\n\nCURATORS ANNOTATION:\n " + rowData[3];
form.addMultipleChoiceItem().setTitle(description).setChoiceValues([' ']);
// Section 2: Add the evaluation questions
// Set up the tick box grid question
var gridItem = form.addCheckboxGridItem();
gridItem.setTitle('Note: Tick = Yes, Untick = No')
.setRows(['Listeners', 'Listening to', 'Performed by', 'Date/Time', 'Medium', 'Listening Environment', 'Location'])
.setColumns(['LLM has new valid info', 'LLM has new invalid info', 'LLM is missing info from the text', 'LLM is missing external knowledge']);
// Optional: If you want to make it a required question
gridItem.setRequired(true);
}
// Log the URL of the form
Logger.log('Published URL: ' + form.getPublishedUrl());
Logger.log('Editor URL: ' + form.getEditUrl());
}