Skip to main content

Anniversary starting prices are live.

See Pricing
ZENERA LABS
Zenera Labs Engineering PortfolioInternally developed · MVP

AI EduMark

AI-powered answer sheet scanning and marks card automation — upload, evaluate, review, and publish results in minutes.

AI AutomationEdTechDocument Processing

Built by subhraneel · AI Engineer

AI EduMark login page with email/password authentication
01See It In Action

The system, up close

Real captures from the running system — the demo, screenshots and architecture come first, then the deep dive.

Demo

Walkthrough of the full pipeline: exam creation, answer sheet upload, AI evaluation, teacher review, and student marksheet view.

AI EduMark — complete walkthrough

Demo covers exam creation, student enrollment, sheet upload, preprocessing, AI marking, review, and marksheet generation.

Screenshots

1 / 8

AI EduMark login page with email/password authentication
AI EduMark login page with email/password authentication

Architecture

System architecture of AI EduMark: web app → image processor worker → AI evaluation worker → PostgreSQL
Turborepo monorepo: Next.js web app → img-processor-worker (sharp + OpenCV.js) → ai-evals-worker (OpenAI vision) → Neon PostgreSQL.
02The Problem

Why this needed to be built

Manual answer sheet evaluation is slow, inconsistent, and error-prone — teachers spend hours scanning, reading, and tallying marks for hundreds of students per exam.

Schools need a way to automate marking while keeping a human in the loop for verification, with full RBAC so students only see their own results and teachers manage their own exams.

03The Zenera Solution

What we built, and how it changes the workflow

We built a Turborepo monorepo platform that rasterizes uploaded answer sheets, preprocesses images with OpenCV.js, evaluates answers with an OpenAI vision model, and presents a review UI for teachers to verify and finalize marks — with role-based access at every step.

A teacher uploads a multi-page PDF answer sheet for a selected student and exam. The server rasterizes it into per-page PNGs, then a background image-preprocessing worker cleans, deskews, and quality-checks every page using sharp and OpenCV.js (WASM).

An AI evaluation worker picks up processed pages, sends them to an OpenAI vision model via Vercel AI SDK with a constrained Zod schema, and produces structured candidate marks with confidence scores. Teachers review, edit, and finalize results through a dedicated review UI — students see only their own published marksheets.

Core design principle

  • Human-in-the-loop: AI produces candidate marks, but a teacher must review and approve before any result is published.
  • Defense in depth for access: Better Auth + RBAC (owner/admin/teacher/student) enforced at middleware, API, and UI layers.
  • No fabrication: the AI model is instructed to return null for uncertain answers rather than guessing.
04Key Capabilities

What it can do

A focused set of capabilities that define the system — no marketable filler, only what actually runs.

01

Answer sheet upload

Single-PDF upload per student per exam, rasterized into per-page PNGs at upload time.

02

Image preprocessing

Background worker: EXIF rotate → perspective correction (OpenCV.js) → denoise → normalize → sharpen → quality checks.

03

AI evaluation

OpenAI vision model reads preprocessed pages and produces per-question marks with confidence scores via constrained output.

04

Human review UI

Teachers see detected student, source images, candidate marks with confidence, and can edit before finalizing.

05

Exam management

Create exams with question papers, generate join links, and enroll students via RBAC-gated workflows.

06

Question paper extraction

Upload a scanned question paper PDF and extract questions automatically with OpenAI vision.

07

Student marksheet view

Students see only their own published marksheets with per-question breakdowns.

08

Multi-tenant RBAC

Four roles (owner/admin/teacher/student) with org-scoped data isolation via Better Auth.

05How It Works

The end-to-end workflow

The system processing path, in order.

  1. 1

    Teacher creates exam

    Defines exam name, subject, questions (manual or extracted from a PDF), and publishes.

  2. 2

    Student joins exam

    Uses a join link to enroll as a student in the organization.

  3. 3

    Teacher uploads sheet

    Picks exam + student, uploads one multi-page PDF. Server rasterizes to PNGs.

  4. 4

    Image preprocessing

    Background worker deskews, denoises, sharpens, and quality-checks every page.

  5. 5

    AI evaluation

    Vision model reads pages and produces per-question marks with confidence scores.

  6. 6

    Teacher reviews

    Reviews detected student, source images, and candidate marks. Edits if needed.

  7. 7

    Finalize & publish

    Approves the sheet — marks become visible to the student on their marksheet.

06Technology

Stack & tech choices

Framework
Next.js 16 (App Router), React 19, TypeScript
Monorepo
Turborepo
Auth
Better Auth, email/password + organizations, custom RBAC
Database
PostgreSQL (Neon), Drizzle ORM
Styling
Tailwind CSS v4, shadcn/ui
Image processing
sharp (denoise/normalize), OpenCV.js (WASM perspective correction), pdf-to-img (rasterization)
AI marking
OpenAI vision model, Vercel AI SDK (generateObject), Zod constrained output
Workers
img-processor-worker (poll loop), ai-evals-worker (poll loop)
07Validation

Tested, verified and honestly scoped

Validation & tests

End-to-end tested across upload, preprocessing, AI evaluation, review, and finalization flows with RBAC enforcement at every layer.

  • Upload — PDF rasterization, per-page PNG generation, file storage, and sheet/page record creation
  • Preprocessing — perspective correction, denoise, sharpen, quality checks with issue tagging
  • AI evaluation — structured mark extraction with confidence scoring and needsReview flagging
  • Review — teacher can view source images, edit marks, and finalize sheets
  • Student view — ownership-checked reads, only completed sheets visible
  • RBAC — unauthorized access blocked at middleware, API, and UI layers

Security & hardening

  • Better Auth with org-scoped sessions and role-based permissions
  • Middleware redirects unauthenticated users; server helpers guard pages
  • API routes check permissions via auth.api.hasPermission
  • Student reads gated to their own student rows only
  • No secrets in code — all credentials in environment variables

Honest limitations

AI EduMark is an internally developed engineering prototype. We state limitations rather than overclaim production readiness.

  • Single-PDF upload per sheet (no batch upload yet)
  • Local filesystem storage (not cloud-backed in MVP)
  • AI marking accuracy depends on scan quality
  • No mobile app — web only
08Documentation

Deep-dive references

Documentation

Technical documentation covering system design, database schema, and permission model.

09Future Extensions

Where this can go next

Realistic next steps we've scoped — not aspirational marketing copy.

  • Batch upload — multiple students per exam in one upload
  • Cloud storage (S3/R2) for uploaded sheets
  • Configurable AI marking rubrics per subject
  • Parent/guardian portal for marksheet access
  • Mobile app for teachers and students
  • Analytics dashboard for exam performance trends
  • Integration with school management systems

Have a similar workflow?
Zenera Labs can build a custom version for your business.

This is one of subhraneel's internally developed systems. Tell us about your requirement and we'll scope a tailored build around it.