Skip to main content
This guide covers the most common high-stakes flow: a student submits an essay, the AI grades it, a teacher reviews, the gradebook updates.

1. Configure the assignment

2. Receive a submission

The student app sends the response:
If the assignment accepts files:

3. Trigger AI grading

This is async. Subscribe to the submission.graded webhook for production, or poll for prototypes:

4. Show the teacher

Render grading_rationale as markdown next to the student’s text. The teacher gets context, not a black box.

5. Teacher confirms or overrides

If the teacher accepts the AI’s grade verbatim:
Or, if you want to skip the override and trust the AI:

6. Read the final grade

The SDK abstracts the precedence rule:
final_grade is null while human_review_status === "pending" if the assignment requires human review. That’s what your student-facing UI should read.

At scale: grade a whole class

Tips

Pin the model. AI grades drift between model versions. If you need audit-grade reproducibility, pass model: "claude-sonnet-4-6" (or similar) in the assignment config.
Show the rubric to the student before they submit. A 30% increase in rubric-aligned answers is typical.
Never auto-publish AI grades on consequential assessments. The human_review: "required" flag exists for a reason. Use it.