Skip to main content

Introduction

The Cognitive Learning Engine provides unprecedented insights into learning patterns by tracking not just what students know, but how they learn. This quickstart guide will help you integrate cognitive intelligence into your platform.

Installation

Using Python SDK

pip install cognition-engine-sdk

Basic Usage

Step 1: Initialize the Engine

from cognition_engine import CognitionEngine

# Initialize the engine
engine = CognitionEngine(
    supabase_url="your-supabase-url",
    supabase_key="your-supabase-key"
)

Step 2: Track Learning Events

Every time a student answers a question, track it with the engine:
# Track a learning event
result = await engine.track_answer(
    user_id="student_123",
    skill_id="algebra_001",
    is_correct=True,
    time_spent_seconds=45,
    confidence_score=4
)

print(f"New mastery: {result['mastery_after']}")
print(f"Learning velocity: {result['velocity']}")

Step 3: Get Predictive Insights

# Get predictive analytics
predictions = await engine.get_predictions("student_123")
print(f"Predicted SAT in 30 days: {predictions['predicted_total_in_30_days']}")

# Analyze learning patterns
velocity = await engine.get_learning_velocity("student_123")
print(f"Momentum score: {velocity['momentum_score']}")

What’s Next?