annotate docs/ProjectSpecificationDocument.tex @ 1088:3705f68a38b7

The version I use and works, addresses issues #1622, #1616, partially #1620
author Giulio Moro <giuliomoro@yahoo.it>
date Mon, 22 Feb 2016 04:17:19 +0000
parents
children 2b8c36924bfd
rev   line source
giuliomoro@1088 1 \documentclass{article}
giuliomoro@1088 2
giuliomoro@1088 3 \usepackage[margin=2cm]{geometry}
giuliomoro@1088 4 \usepackage{listings}
giuliomoro@1088 5
giuliomoro@1088 6 \begin{document}
giuliomoro@1088 7
giuliomoro@1088 8 \large APE Browser Tool - Project Specification Document
giuliomoro@1088 9
giuliomoro@1088 10 \section{Document}
giuliomoro@1088 11
giuliomoro@1088 12 An XML file containing all project information to load and execute the project on the client. Certain interfaces are optional, however others are mandatory. This guide should reflect the changes in the XML project and keep track of the versions. Hopwfully this can remain simple!
giuliomoro@1088 13
giuliomoro@1088 14 \section{Root}
giuliomoro@1088 15
giuliomoro@1088 16 The XML root must be \texttt{<BrowserEvalProjectDocument>}. This should be sufficiently identifiable in both itself and in the JavaScript decoding as it will create an object called the root name.
giuliomoro@1088 17
giuliomoro@1088 18 There must also be a \texttt{<version>} tag which has the attribute \texttt{id} containing a numerical representation of the version. Currently everything in this document can be assumed to be version 1. If future updates or corrections are made post delivery this should give the flexibility to ensure past projects still work.
giuliomoro@1088 19
giuliomoro@1088 20 The root will also contain the following tags: setup and tracks.
giuliomoro@1088 21
giuliomoro@1088 22 \section{Setup tag}
giuliomoro@1088 23
giuliomoro@1088 24 The setup tag specifies certain global test settings including: the interface type to use, the project return location and any other setup instructions.
giuliomoro@1088 25 Any general pre/post test questions must be specified in the relevant children tag. Any enabled metrics must also be specified in the metric child node.
giuliomoro@1088 26
giuliomoro@1088 27 \subsection{Attributes}
giuliomoro@1088 28 \begin{itemize}
giuliomoro@1088 29 \item \texttt{interface} - Mandatory, String. Defaults to APE, otherwise use to load any of the available interfaces. Currently only valid string is APE.
giuliomoro@1088 30 \item \texttt{projectReturn} - Mandatory, String. Specify the URL to return the test results. If null client will generate XML locally and prompt user to return the file.
giuliomoro@1088 31 \item \texttt{randomiseOrder} - Optional, default to false. Specify if the order of the test pages are to be randomised.
giuliomoro@1088 32 \item \texttt{collectMetrics} - Deprecated. Optional, Boolean. Default to false. Determine if the test metrics should be collected. These include how long each test session took etc. The full metrics list can be modified in the 'metrics' tag.
giuliomoro@1088 33 \end{itemize}
giuliomoro@1088 34
giuliomoro@1088 35 \subsection{Elements}
giuliomoro@1088 36 None
giuliomoro@1088 37
giuliomoro@1088 38 \section{Metric tag}
giuliomoro@1088 39 A 'setup' node child tag, metrics must be declared in the setup tag. This takes a set of children 'metricEnable' to define which metrics to collect and present, for example \texttt{<metricEnable> testTimer </metricEnable>}. The interface may not be able to utilise all of these features. It is up to the interface to determine whether to use the metric or not. For example, 'elementFlagMoved' would not be usable in an AB test as there are no interface value objects.
giuliomoro@1088 40
giuliomoro@1088 41 \subsection{metricEnable tag}
giuliomoro@1088 42 This takes a single attribute to determine which metric to enable for collection. Some of these are a global, per track or per test instance.
giuliomoro@1088 43 \begin{itemize}
giuliomoro@1088 44 \item testTimer - Return the global test timer and test instance timers. Measures the time between the first start and final submit.
giuliomoro@1088 45 \item elementTimer - Return the total time each audioElement in each test was listened too. Measures time between successive clicks on the track changer
giuliomoro@1088 46 \item elementTracker - Return the initial position of each track
giuliomoro@1088 47 \item elementTrackerFull - Return an enumerated pair of time and position. Track the entire movement of each element position. NOTE: Will override the elementTracker option above and throw an error into the browser console.
giuliomoro@1088 48 \item elementFlagListenedTo - Return a boolean per elementck to see if the element was listened to
giuliomoro@1088 49 \item elementFlagMoved - Return a boolean per element to see if the element slider was moved.
giuliomoro@1088 50 \item elementFlagComments - Return a boolean per element to see if the element has comments.
giuliomoro@1088 51 \end{itemize}
giuliomoro@1088 52
giuliomoro@1088 53 \section{Interface tag}
giuliomoro@1088 54 This enables any interface options for each test page. Further interface tags in each audioHolder add further options. This takes option nodes only. Each option node takes a 'name' to determine what feature to enable. The following options are currently employed.
giuliomoro@1088 55
giuliomoro@1088 56 \subsection{Option nodes}
giuliomoro@1088 57
giuliomoro@1088 58 \begin{itemize}
giuliomoro@1088 59 \item \texttt{fragmentPlayed} - Enforce each fragment be partially played before finishing the page
giuliomoro@1088 60 \item \texttt{fragmentFullPlayback} - Enforce each fragment to be fully played from start to end before finishing the page. Not enabled if an audioHolder reports it is to be looped playback.
giuliomoro@1088 61 \item \texttt{fragmentMoved} - Enforce each fragment to be moved at least once from its starting position.
giuliomoro@1088 62 \item \texttt{fragmentComments} - Enforce each fragment comment to have some text entered.
giuliomoro@1088 63 \item \texttt{playhead} - Show the playhead object.
giuliomoro@1088 64 \item \texttt{page-count} - Show the current test page number and the total number
giuliomoro@1088 65 \item \texttt{scalerange} - Must also have min and max values between 0 and 100. Enforce that at least one fragment is below the min value and one fragment is above the max value before continuing.
giuliomoro@1088 66 \end{itemize}
giuliomoro@1088 67
giuliomoro@1088 68 \section{AudioHolder tag}
giuliomoro@1088 69
giuliomoro@1088 70 There should be one audioHolder tag for each test page, inside which each audioElement is specified as children. The audioHolder tag can help to generalise certain objects.
giuliomoro@1088 71
giuliomoro@1088 72 \subsection{Attributes}
giuliomoro@1088 73 \begin{itemize}
giuliomoro@1088 74 \item \texttt{id} - Mandatory, String. Give an ID string or number to identify the test in the result.
giuliomoro@1088 75 \item \texttt{hostURL} - Optional, String. If all tracks are hosted from the same folder on a server, you can put in the lead here. For instance, if loading http://test.com/tracks/track1.wav and http://test.com/tracks/track2.wav, this could equal http://test.com/tracks/ and the url attribute in the track tag can be track1.wav or track2.wav. Equally http://test.com/ and then using tracks/track1.wav and tracks/track2.wav is valid.
giuliomoro@1088 76 \item \texttt{sampleRate} - Optional, Number. If your test requires a specific sample rate, this should be set to the desired sample rate in Hertz. This does not set the browser to the correct sample rate, but forces the browser to check the sample rate matches. If this is undefined, no sample rate matching will occur.
giuliomoro@1088 77 \item \texttt{randomiseOrder} - Optional, Boolean String. Defaults to false. Determine if the track order should be randomised. Must be true or false.
giuliomoro@1088 78 \item \texttt{repeatCount} - Optional, Number. Defaults to 0 (ie: no repeats). The number of times a test should be repeated.
giuliomoro@1088 79 \item \texttt{loop} - Optional, Boolean String. Defaults to false. Enable if audioElements should loop their playback or not.
giuliomoro@1088 80 \item \texttt{elementComments} - Optional, Boolean String. Defaults to false. Enable to populate the test page with Comment Boxes linked to each fragment.
giuliomoro@1088 81 \end{itemize}
giuliomoro@1088 82
giuliomoro@1088 83 \subsection{Elements}
giuliomoro@1088 84 Contain the audioElements tags and the interfaceSetup tag.
giuliomoro@1088 85
giuliomoro@1088 86 \section{audioElements tag}
giuliomoro@1088 87
giuliomoro@1088 88 This must reside as children in the audioHolder tag. There must be one audioElement tag per sound sample to load into the test.
giuliomoro@1088 89
giuliomoro@1088 90 \subsection{Attributes}
giuliomoro@1088 91 \begin{itemize}
giuliomoro@1088 92 \item \texttt{id} - Mandatory, String. Must give a string or number to identify each audio element. This id is used in the output to identify each track once randomised.
giuliomoro@1088 93 \item \texttt{url} - Mandatory, String. Contain the full URL to the track. If the Tracks tag hostURL is set, concatenate this tag with the hostURL attribute to obtain the full URL.
giuliomoro@1088 94 \item \texttt{type} - Optional, String. Can be 'normal', 'anchor', 'reference' or 'outside-reference'. Default is for normal. Only one anchor can be specified per page. Only one reference can be specified per page. Only one outside-reference can be specified per page. If multiple audioelements have the same type in the same page, the browser console will explain the problem and the audioelements will be treated as 'normal' fragments.
giuliomoro@1088 95 \end{itemize}
giuliomoro@1088 96
giuliomoro@1088 97 \section{interface tag}
giuliomoro@1088 98
giuliomoro@1088 99 This is contained within the audioHolder tag and outlines test instance specific requirements. These include the following children tags:
giuliomoro@1088 100 \begin{itemize}
giuliomoro@1088 101 \item 'title' - Contains the test title to be shown at the top of the page. Can only be one title node per interface.
giuliomoro@1088 102 \item 'scale' - Takes the attribute position to be a value between 0 and 100 indicating where on the scale to place the text contained inside. Can be multiple scale tags per interface.
giuliomoro@1088 103 \item 'option' - Can hold any of the option tags available in the setup tag. These will only be enabled for the page instance.
giuliomoro@1088 104 \end{itemize}
giuliomoro@1088 105
giuliomoro@1088 106 \section {CommentQuestion tag}
giuliomoro@1088 107
giuliomoro@1088 108 This allows another question and comment box to be presented on the page. The results of these are passed back in the results XML with both the comment and the question. An id must be set, otherwise the result is undefined. Also the type must be set as follows.
giuliomoro@1088 109 \begin{itemize}
giuliomoro@1088 110 \item 'type="text"' - Default type. Creates a text box on the page. The text is included as the element.
giuliomoro@1088 111 \item 'type="radio"' - Create radio button entry. Multiple equally spaced entried per box. Only one entry can be selected. Each radio button is specified by an option tag. The tag must contain a name attribute, which will be the response if true. Optional text can be included as the element to label the box. Presented question is included in a statement node.
giuliomoro@1088 112 \item 'type="checkbox"' - Create a checkbox entry. Multiple equally space entries per box, multiple can be selected. Each checkbox is specified by an option tag. The tag must contain a name attribute. Optional text can be included as the element to label the checkbox. Presented question is included in a statement node.
giuliomoro@1088 113 \end{itemize}
giuliomoro@1088 114
giuliomoro@1088 115
giuliomoro@1088 116 \section {PreTest tag and PostTest tag}
giuliomoro@1088 117
giuliomoro@1088 118 These are 1st level tags. The PreTest tag allows for the specifying of pre test instructions and questions. These appear as a pop-up style window with next buttons and other automatic GUI. The postTest tag allows for specifying post test instructions, questions and resources. These appear as a pop-up style window after the submit button is pressed.
giuliomoro@1088 119
giuliomoro@1088 120 PreTest and PostTag nodes can be included in the audioHolders (for pre and post for that test page) and in the setup node for pre-test before the first page, and post-test for after the last test.
giuliomoro@1088 121
giuliomoro@1088 122 \subsection{Attributes}
giuliomoro@1088 123 None.
giuliomoro@1088 124
giuliomoro@1088 125 \subsection{Elements}
giuliomoro@1088 126
giuliomoro@1088 127 Takes the following available tags to structure the pre and post test options. The order these are presented in the XML define the order they appear.
giuliomoro@1088 128
giuliomoro@1088 129 \subsubsection{Statement}
giuliomoro@1088 130
giuliomoro@1088 131 The statement tag simply prints the included string verbatim on a 'pop-up' window with a next button.
giuliomoro@1088 132
giuliomoro@1088 133 \subsubsection{Question}
giuliomoro@1088 134
giuliomoro@1088 135 This allows for a question to be asked pre/post the test. The response includes both the question asked and the response. The following attributes are used:
giuliomoro@1088 136 \begin{itemize}
giuliomoro@1088 137 \item \texttt{id} - Mandatory, String. Used to reference to the response.
giuliomoro@1088 138 \item \texttt{mandatory} - Optional, String Boolean. Determine if this question must have some response. Defaults to false.
giuliomoro@1088 139 \item \texttt{boxsize} - Optional, String. Defaults to normal. Allows 'small', 'normal', 'large' or 'huge'. This determines the size of the box entry. All entries are wrappable, so this does not determine the maximum size of the text response, but can be used to encourage (or dicourage) long answers.
giuliomoro@1088 140 \end{itemize}
giuliomoro@1088 141
giuliomoro@1088 142 \subsubsection{Number}
giuliomoro@1088 143
giuliomoro@1088 144 Gives a number box entry defined with the following attributes:
giuliomoro@1088 145 \begin{itemize}
giuliomoro@1088 146 \item \texttt{id} - Mandatory, String. Used to reference to the response.
giuliomoro@1088 147 \item \texttt{mandatory} - Optional, String Boolean. Determine if this question must have some response. Defaults to false.
giuliomoro@1088 148 \item \texttt{min, max} - Optional, Number. Defaults to undefined. Used to bound the number response. If a number entered is below this, the pre/post sequence will not continued.
giuliomoro@1088 149 \end{itemize}
giuliomoro@1088 150
giuliomoro@1088 151 \subsubsection{Radio}
giuliomoro@1088 152
giuliomoro@1088 153 Create a set of radio boxes. Only one element can be returned as true. The radio node must have an id to reference for the output. The radio node also must have a statment node which will contain the text to show on the popup. Radio buttons are created using option nodes. Each node must have a name attribute to indentify which radio was selected in the response. The option node can also contain any text to link to the node.
giuliomoro@1088 154
giuliomoro@1088 155 \subsubsection{Checkbox}
giuliomoro@1088 156
giuliomoro@1088 157 Create a set of checkbox boxes. Multiple elements can be returned as true. The checkbox node must have an id to reference for the output. The checkbox node also must have a statment node which will contain the text to show on the popup. Checkbox buttons are created using option nodes. Each node must have a name attribute to indentify which radio was selected in the response. The option node can also contain any text to link to the node.
giuliomoro@1088 158
giuliomoro@1088 159 \section{Example}
giuliomoro@1088 160
giuliomoro@1088 161 Here is an example XML structure
giuliomoro@1088 162
giuliomoro@1088 163 \begin{lstlisting}
giuliomoro@1088 164 <?xml version="1.0" encoding="utf-8"?>
giuliomoro@1088 165 <BrowserEvalProjectDocument>
giuliomoro@1088 166 <setup interface="APE" projectReturn="null" randomiseOrder='true' collectMetrics='true'>
giuliomoro@1088 167 <PreTest>
giuliomoro@1088 168 <statement>Please listen to all mixes</statement>
giuliomoro@1088 169 <question id="location" mandatory="true">Please enter your listening location</question>
giuliomoro@1088 170 </PreTest>
giuliomoro@1088 171 <PostTest>
giuliomoro@1088 172 <statement>Thank you for taking this listening test.</statement>
giuliomoro@1088 173 <question id="SessionID">Please enter your name.</question>
giuliomoro@1088 174 </PostTest>
giuliomoro@1088 175 <Metric>
giuliomoro@1088 176 <metricEnable>testTimer</metricEnable>
giuliomoro@1088 177 <metricEnable>elementTimer</metricEnable>
giuliomoro@1088 178 <metricEnable>elementTracker</metricEnable>
giuliomoro@1088 179 <metricEnable>elementFlagListenedTo</metricEnable>
giuliomoro@1088 180 <metricEnable>elementFlagMoved</metricEnable>
giuliomoro@1088 181 </Metric>
giuliomoro@1088 182 </setup>
giuliomoro@1088 183 <audioHolder id='0' hostURL="example_eval/" sampleRate="44100" randomiseOrder='true' repeatCount='1'>
giuliomoro@1088 184 <interface>
giuliomoro@1088 185 <title>Example Test Question</title>
giuliomoro@1088 186 <scale position="0">Min</scale>
giuliomoro@1088 187 <scale position="100">Max</scale>
giuliomoro@1088 188 <scale position="50">Middle</scale>
giuliomoro@1088 189 <scale position="20">20</scale>
giuliomoro@1088 190 </interface>
giuliomoro@1088 191 <audioElements url="0.wav" id="0"/>
giuliomoro@1088 192 <audioElements url="1.wav" id="1"/>
giuliomoro@1088 193 <audioElements url="2.wav" id="2"/>
giuliomoro@1088 194 <audioElements url="3.wav" id="3"/>
giuliomoro@1088 195 <audioElements url="4.wav" id="4"/>
giuliomoro@1088 196 <audioElements url="5.wav" id="5"/>
giuliomoro@1088 197 <audioElements url="6.wav" id="6"/>
giuliomoro@1088 198 <audioElements url="7.wav" id="7"/>
giuliomoro@1088 199 <audioElements url="8.wav" id="8"/>
giuliomoro@1088 200 <audioElements url="9.wav" id="9"/>
giuliomoro@1088 201 <audioElements url="10.wav" id="10"/>
giuliomoro@1088 202 <CommentQuestion id='mixingExperiance'>What is your mixing experiance</CommentQuestion>
giuliomoro@1088 203 <PreTest>
giuliomoro@1088 204 <statement>Start the Test 3</statement>
giuliomoro@1088 205 </PreTest>
giuliomoro@1088 206 <PostTest>
giuliomoro@1088 207 <statement>Please take a break before the next test</statement>
giuliomoro@1088 208 <question id="testComment">How did you find the test</question>
giuliomoro@1088 209 </PostTest>
giuliomoro@1088 210 </audioHolder>
giuliomoro@1088 211 </BrowserEvalProjectDocument>
giuliomoro@1088 212 \end{lstlisting}
giuliomoro@1088 213
giuliomoro@1088 214
giuliomoro@1088 215
giuliomoro@1088 216 \end{document}