Teacher's Pet Rotating Outer Nodes
PUPIL Mascot Inner Face
Teacher's Pet Software
System Architecture v2.0
Teacher's Pet Rotating Outer Nodes
PUPIL Mascot Inner Face

Neural Documentation
Engine Architecture

A deep-dive into the systems that power PUPIL IEP™ — from structured data injection through AI synthesis to compliance-grade LaTeX rendering and multi-stakeholder governance.

<90s
Generation Time
256-bit
Token Encryption
99.9%
Uptime Target
FERPA
Certified Flow
Core Engine

AI-Powered Document Pipeline

Every document passes through a deterministic pipeline where AI fills structured slots — never generating freeform documents.

AI Core

Structured Tool-Call Paradigm

The AI operates via constrained tool calls — fill_plaafp_section, fill_goal, fill_lre_justification — ensuring output maps precisely to LaTeX template slots. No hallucinated document structures.

Templates

Fixed LaTeX Template Architecture

Document structure is immutable. The AI never generates LaTeX commands — it fills plaintext content into pre-authored, compliance-verified IEP and PLAAFP templates with proper section hierarchy.

Streaming

Real-Time Section Streaming

As the AI synthesizes each section, content streams live into the workspace editor with section-level progress indicators. Educators see the document materialize in real-time.

Dual Mode

IEP + PLAAFP Dual Generation

A single student data graph can produce both a full IEP document and a standalone PLAAFP evaluation report. The convertToPLAAFP adapter seamlessly maps IEP slots to PLAAFP narrative fields.

Governance Protocol

Multi-Stakeholder Review Engine

A complete review-modify-finalize lifecycle with cryptographic access tokens and configurable deadline enforcement.

256-Bit Access Tokens

Every stakeholder invite generates a crypto.randomBytes(32) token granting scoped, single-document read access. No account required.

Review-Modify Loop

Documents cycle through Draft → Review → Modify → Finalized states with iteration counters, recall capability, and automatic status transitions.

Deadline Auto-Approval

A daily CRON job scans for expired review deadlines and auto-approves non-responsive stakeholders, sending deadline closure notifications via SES.

Inline Annotations

Stakeholders can highlight text and attach granular, section-level and inline comments. All annotations are time-stamped and author-attributed.

Team Assembly

Each student record supports a compiled IEP team roster with role assignments (case manager, specialist, general ed, parent) for accountability tracking.

Audit Trail

Every administrative action — district creation, campaign sends, configuration changes — is logged to an append-only audit ledger with IP attribution.

Data Architecture

Multi-Tenant Isolation Grid

District-level data isolation with role-based access control, encrypted storage, and compliance-grade retention policies.

Mongoose

Entity Domain Model

14 Mongoose models spanning Districts, Schools, Students, Reports, Goals, Service Logs, Compliance Events, Evaluations, and Audit Logs — all scoped by districtId and schoolId.

Encryption

AES-256 at Rest + TLS 1.2 In Transit

All persistent data is encrypted at rest via MongoDB Atlas managed encryption. Every API call, webhook, and stakeholder token exchange occurs over TLS 1.2+.

RBAC

Six-Tier Role Hierarchy

District Admin → School Admin → Case Manager → Specialist → General Ed → Parent. Each role has precisely scoped data visibility and action permissions.

Infrastructure

Serverless Edge Deployment

Deployed on Vercel's edge network with serverless API routes, automatic scaling, and global CDN distribution. MongoDB Atlas provides managed replication and failover.

Output Layer

Compliance-Grade Document Rendering

Professional PDF output via server-side LaTeX compilation with automatic escaping, annotation stripping, and FERPA-safe sanitization.

LaTeX Compilation

Server-side pdflatex compilation produces typeset-quality PDF documents with proper headers, footers, tabularx tables, and professional formatting.

Progress & Service Tracking

Integrated progress monitoring with quarterly benchmark tracking, service log reconciliation, and goal-aligned measurement data.

Live Workspace Editor

A dual-pane editor with native workspace view, true PDF preview, and LaTeX source view — with inline annotation overlays and real-time collaborative commenting.

Ready to deploy?

Provision your district node in under two minutes. No credit card required for trial access.