Skip to content

fix(tutor): let serial-output be learned without an int variable - #4

Merged
ttbombadil merged 1 commit into
mainfrom
fix/serial-output-without-int-prerequisite
Oct 3, 2026
Merged

ttbombadil merged 1 commit into
mainfrom
fix/serial-output-without-int-prerequisite

Conversation

@ttbombadil

Copy link
Copy Markdown
Owner

Problem

variables-and-serial is activated by any Serial.print* call. Its Concept serial-output required variable-values, and all questions of variable-values apply only to sketches that use int.

On sketches that print via Serial but have no int, three things followed:

  • serial-output could never be selected;
  • the Topic was unresolved from the first turn;
  • UnoSim blocked the Topic-driven Tutor with content-exhausted for the whole session (LearningQuestions SSOT 2.3).

This affected 16 of 35 Examples:
it01-02-konstante, it02-03-boolesche-operatoren, it02-04-bitoperatoren, it03-01-serielle-ausgabe, it03-02-serielles-zeichen-einlesen, it03-05-millis (after long-values), it05-03-switch, it06-01-while, it06-02-do-while, it06-03-for, it06-04-verschachtelte-schleifen, it07-01-funktion-ohne-rueckgabe, it08-01-struct, it08-02-array-aus-structs, it08-03-struct-als-parameter, it08-04-funktion-auslagern.

The existing quality gate did not see it, because it only checks Topics that a quality case expects.

Change

serial-output.prerequisites: [variable-values] → [], plus the Topic's SHA-256 in tutor/manifest.yaml. Nothing else changes.

Why this is the right fix and not a test workaround:

  • The Concept's objective, indicator, misconception and scaffold depend only on Serial output.
  • Both of its questions (concept, transfer) require only serial-call: print; none mentions an int.
  • Activation, Concepts, questions and mastery are unchanged.
  • preferredOrder: [variable-values, serial-output] still teaches variable-values first wherever the sketch has an int.

Evidence

All checks are deterministic: the real UnoSim TutorService, CurriculumTutorAdapter, matcher and planner, with a fake provider standing in for the model. No provider calls.

before (2ac716f) after
Topic activations unresolved from the first turn 16 / 36 0 / 36
it06-03-for (strong learner) no planned question, blocked from turn 0 serial-output-concept → serial-output-transfer → mastery
it03-05-millis blocked after long-values mastery long-values and variables-and-serial both mastered
it01-01-variable-speichern unchanged unchanged
validator at the pinned UnoSim commit (aaa52fad, this repo's CI) pass pass
new catalog-wide UnoSim authoring gate (MoDevIO/UnoSim, open PR) 16 × unmasterable-example-activation pass

Known and out of scope: after mastery, post-mastery content is thin. Serial-only Examples have no DEEPEN question left and continue with the blocked free fallback. That is legitimate per the runtime contract and a separate authoring task (more DEEPEN questions, Topic v2 extensions).

Follow-up

Once the UnoSim gate PR is merged, bump .unosim-compatible-commit so that this repository's CI enforces the catalog-wide check.

🤖 Generated with Claude Code

The Concept serial-output required variable-values, whose questions apply
only when the sketch uses int. On sketches that print via Serial but have no
int (16 of 35 Examples), serial-output could therefore never be selected:
variables-and-serial was activated but unresolved from the first turn, and
UnoSim blocked the Topic-driven Tutor with content-exhausted for the whole
session.

Serial output does not depend on an int: the Concept's objective, indicator,
misconception, scaffold and both questions require only a Serial print call.
The prerequisite is removed; activation, Concepts, questions and mastery
stay unchanged, and preferredOrder still teaches variable-values first where
the sketch has an int. The manifest hash of the Topic is updated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ttbombadil
ttbombadil merged commit 7db5a92 into main Oct 3, 2026
1 check passed
@ttbombadil
ttbombadil deleted the fix/serial-output-without-int-prerequisite branch October 3, 2026 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant