Xuexitong Course Automation Script
xuexitongScript · JavaScript Userscript
Course-workflow automation built around module recognition and state management.
Project introduction
A JavaScript userscript for Chaoxing Xuexitong web courses, assisting with repetitive operations and different types of learning tasks.
Beyond simple video autoplay, the project uses a modular, task-aware, state-driven design. It identifies the course directory, lessons, internal task types and completion states to establish an execution order and select the appropriate processing flow.
One lesson may contain several videos, audio items, documents or other tasks. The script does not assume every task is a video, nor equate local playback or reading with platform-confirmed completion. Within supported workflows, task state and completion evidence determine whether it can continue.
Unsupported, unverified or ambiguous content is handled conservatively: pending states are retained to avoid incorrect navigation, repeated execution or treating unknown tasks as complete. The modular structure also leaves room for adapting additional content types.
Modular workflow
- Identify the course structure and current lesson
- Build the task inventory and execution order
- Determine task types and completion states
- Dispatch to the corresponding processing module
- Validate the result and decide whether to continue
Completed, loading, deferred, unsupported and executable tasks remain distinct; unknown content does not automatically trigger navigation.
Core features and design
Multimedia task processing
Supported video, audio and document tasks use type-specific workflows. Multiple items in a lesson follow the identified task order, with recognition of confirmed completion and playback/reading monitoring. Video defaults to fixed 1.0x speed; audio uses separately configured logic. Document/PDF flows scroll the actual reading area incrementally, handling nested frames and loading states where supported. Reaching the bottom does not guarantee platform completion. Player recovery and audio compatibility remain under development and refinement.
Course navigation and state management
Chapter directories, lessons and task states organize execution, including within-lesson sequencing and navigation between lessons and chapters. Continuation requires sufficiently clear completion evidence, next-target identity and navigation conditions, reducing duplicate processing, concurrent transitions and actions based on stale page state.
Live streams, replays and special tasks
Some live-entry types, replay pages and chapter assessments are recognized, with cross-window session coordination where supported. An optional companion userscript supports specific live/replay scenarios. Eligible tasks may wait, defer or proceed to later navigation; pairing, verification and manual-interaction requirements remain in place. The project does not answer or submit quizzes, or promise that every live session or mandatory assessment can be skipped or completed unattended.
Recovery and extensible architecture
Interruption, pause and stall monitoring, bounded recovery attempts, task identity/state checks, configurable execution delays and periodic rest reduce duplicate scheduling and incorrect operations. Scheduled actions can be cancelled. Unknown, unsupported or not-yet-executable modules retain their recognized and pending state, with compatibility expanded using actual page evidence. Browser autoplay restrictions and universal compatibility are not overcome or guaranteed.
Usage and limitations
The project depends on actual Chaoxing Xuexitong page structures and does not guarantee compatibility with every course, task type or browser environment. Some features are still being adapted and verified; task completion must be checked against the learning platform’s actual records. Chapter quizzes are not automatically answered or submitted.