How this skill is triggered — by the user, by Claude, or both
Slash command
/latex-moodle:latex-to-giftThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Convert the LaTeX quiz file at `$ARGUMENTS` to Moodle GIFT format and write the result to the same directory with a `.gift` extension.
Convert the LaTeX quiz file at $ARGUMENTS to Moodle GIFT format and write the result to the same directory with a .gift extension.
Read the file at $ARGUMENTS. If the path is missing or the file does not exist, tell the user and stop.
From the file extract:
N: from \setcounter{number}{N}.\item inside the outer \begin{enumerate} (the one with label=\arabic*). Number them 1, 2, 3, … in order.\item entries inside each inner \begin{enumerate} (the one with label=(\alph*)). Map them in order to letters: first item = (a), second = (b), etc.\begin{solution}...\end{solution}. The correct letters are those wrapped in \textbf{(x)} inside the solution text.\textbf{(x)} letter.\textbf{(x)} letters.Apply these transformations to all question text and answer text before writing GIFT output:
$...$ with \( ... \) and display math $$...$$ with \[ ... \]. Keep the LaTeX commands inside unchanged.\textbf{x} → x, \emph{x} → x, \text{x} → x, \textrm{x} → x.\rightarrow → →, \leftarrow → ←, \ldots → …, \dots → ….\(...\) and \[...\]), prefix each occurrence of ~, =, #, {, }, : with a backslash so they are not misread as GIFT syntax.Use the question number i (1-based) and quiz number N from Step 2.
Title line (same for all types):
::Quiz N, Q<i>::
::Quiz N, Q<i>:: <question text>
{TRUE}
Use {FALSE} if False is the correct answer.
::Quiz N, Q<i>:: <question text>
{
=<correct answer text>
~<wrong answer text>
~<wrong answer text>
~<wrong answer text>
}
List the correct answer first (prefixed =), then all wrong answers (prefixed ~), preserving their original order among the wrong ones.
Let K = number of correct answers. Each correct answer gets %P% partial credit where:
Wrong answers get %-100% to prevent guessing by selecting all.
::Quiz N, Q<i>:: <question text>
{
~%50%<correct answer 1>
~%50%<correct answer 2>
~%-100%<wrong answer 1>
~%-100%<wrong answer 2>
}
List correct answers first (in their original order), then wrong answers (in their original order).
.gift extension (e.g. iase26_quiz04.tex → iase26_quiz04.gift).// Generated from <input filename>After writing, confirm to the user: the output path and how many questions were converted, noting the type of each (single, multi, true/false).
Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub schneggera/latex-moodle-skill --plugin latex-moodle