An activity is a plain-text document. The platform reads it to build the student view, configure the AI feedback, and record the epistemic trace. Tags start with a backslash, take arguments in braces, and blocks are closed with a matching \end… tag.
These go at the top of the document, before any question group.
| Tag | What it does |
|---|---|
\title{...} | Title shown to students. |
\name{...} | Unique internal identifier. |
\studentlevel{...} | Who the students are, e.g. CS1 Python, week 5. Calibrates the AI’s language. |
\activitycontext{...} | Topic scope and teaching goals for the AI (activity-level guidance). |
\aicodeguidance{...} | Activity-wide rules for the AI: follow-ups, scope limits, how strict to be with code. |
\aimode{...} | How accepted answers are shown. See Feedback style. |
\language{...} | Language the AI must respond in, e.g. \language{Swedish}. Default English. |
\mode{group} | Normal collaborative activity (the default). Each group of questions must be submitted before the next opens. |
\mode{test} | Graded assessment. \test is an older spelling of the same thing. |
\mode{demo} | Every question group is open at once, there is no submit button, and each student works in their own saved copy. |
| Tag | What it does |
|---|---|
\section{Title} | A heading. Structural only: nothing to answer. |
\questiongroup{Title} … \endquestiongroup | A set of related questions the group answers and submits together. Everything students answer must be inside a question group. |
| Tag | What it does |
|---|---|
\question{...} … \endquestion | A question. The closing \endquestion is required. |
\textresponse{n} | An answer box n lines tall. |
\sampleresponses{...} | A model answer. Hidden from students; helps the AI recognise good answers. |
\feedbackprompt{...} | Your instructions to the AI for judging this question. Hidden from students. This is the most important thing you write. |
\followupprompt{...} | Optional follow-up the AI can use, e.g. Why might greedy fail? |
\questiontype{...} | Optional research label: what kind of thinking the question asks for, so the trace can be analyzed by question type. One of code_writing, code_reading, output_prediction, debugging, conceptual_explanation, application_problem_solving, reflection, other. Hidden from students; never changes how the question works. |
\responsemode{questions} | Students write questions rather than answers (e.g. interview questions). The default, answer, never needs to be written. |
\multiplechoice{key} … \endmultiplechoice | Single-answer multiple choice; the argument is the correct choice. Each option is a \choice{...}. |
\multiplechoice{multiple} | Ungraded “select all that apply” survey. |
\aimode{...} | Overrides the activity’s feedback style for this one question. |
\aimodeThe AI makes one of two decisions about each submission: accepted (the group moves on) or revise (yellow guidance asking them to think again). After the allowed number of tries the group can choose to continue anyway. \aimode takes a comma-separated list:
| Value | Meaning |
|---|---|
no-positive | Default. Accepted answers advance without a praise message. |
positive | Accepted answers get a short affirmative message in green. |
brief | With positive, keep that message to one sentence. |
lenient | Accept relevant, on-track work without demanding small refinements. Incorrect work still gets revise. |
An \ai block puts a small AI assistant between questions. It is a learning tool, not a question: it creates no answer and is never graded. Your guardrail keeps it from handing over the worksheet answers.
| Tag | What it does |
|---|---|
\ai{mode} … \endai | Mode is explain, critique, testgen or generate. Place directly inside a question group. |
\aititle{...} | Card title students see. |
\aiprompt{...} | Instructions students see. |
\aiguardrail{...} | Hidden limits on what the AI may do. |
\aicontext{...} | What the AI can see: current-question, current-code, student-response, nearby-text. |
\aiinput{n} | Height of the student’s input box. |
\aimodel{...} | Optional: gpt-5-mini (default) or gpt-4o-mini. |
\info{target,seconds}{message} shows a short coaching tip near part of the page, e.g. \info{textresponse,10}{The active student types here.}. Targets: questiongroup, question, textresponse, coderesponse, submitbutton, aifeedback. Keep the message to a handful of words.
The text between the tags is the starter code students see. Each block can run; an optional argument sets a timeout in milliseconds.
| Tag | What it does |
|---|---|
\python … \endpython | Python that runs in the browser. \python{50000} sets a timeout. |
\pythonremote … \endpythonremote | Python that runs on the server (for libraries such as pandas). |
\pythonturtle{WxH,timeout} … \endpythonturtle | Python Turtle with a drawing canvas, e.g. \pythonturtle{900x600,50000}. |
\cpp … \endcpp | C++, compiled and run on the server. |
| Tag | What it does |
|---|---|
\text{...} | A paragraph. |
\textbf{...}, \textit{...} | Bold and italic. |
\begin{itemize} … \end{itemize} | Bulleted list; each line starts with \item. Use enumerate for a numbered list. |
\table{caption} … \endtable | A table. Each row is \row a & b & c; put \tresponse in a cell students fill in. |
\image{URL}{Caption}{Width} | An image; caption and width (e.g. 50%) are optional. |
\link{URL}{Text} | A hyperlink. |
In \mode{test}, a \score{points,type} … \endscore block inside a question holds the rubric. Type is response, code or output.
\questiongroup.\question ends with \endquestion.\score blocks grade; feedback prompts guide, they don’t score.