The Dual N-back trainer is built as a focused HTML5 application with a two-column layout that mirrors the flashcards workflow. The left column hosts the 3x3 visual grid, progress bar, and response buttons, while the right column contains session controls and metrics.
Dual n-back tasks are used in neuropsychological training as structured working-memory paradigms that blend monitoring, updating, and response inhibition across two sensory channels. The format is grounded in classic cognitive load models: a stream of visual positions and audio cues requires continuous comparison against the N-back target, with performance reflecting the ability to hold, refresh, and suppress interference over time. In clinical and research settings, this produces repeatable trials where accuracy, streaks, and error types can be tracked consistently across sessions, making it a practical framework for observing changes in attentional control and processing efficiency. Adjustable timing and N level support graded protocols, while optional biasing can raise match frequency to emphasize response calibration without changing the underlying task structure.
A live version of the app is available here.
Each round selects a visual grid cell and an audio token. If bias is enabled, the generator increases the chance of matching the N-back position.
const nLevel = state.nLevel;
const canMatch = roundIndex >= nLevel;
if (state.biasEnabled && canMatch) {
const targetVisual = Math.random() < state.biasRate;
const lastVisual = visualSequence[roundIndex - nLevel];
visualIndex = targetVisual ? lastVisual : getNonMatchIndex(lastVisual);
}
Session settings are persisted locally so the N level, timing, and bias preferences remain consistent across reloads.
dualNBackNLeveldualNBackSessionSecondsdualNBackIntervalSecondsdualNBackShowCorrectiondualNBackBiasEnabled