/iblai-vibe:iblai-vibe-agent-graderfrom ibl.ai vibe
Adds a Grader tab to a Next.js app for writing grading instructions, building a points rubric, enabling auto-grading and lesson completion, and reviewing or overriding agent-issued grades.
Ships in ibl.ai vibe. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Add the agent Grader tab -- let the agent score work against a rubric you
define. Scope: per agent. The Grading switch at the top saves the
agent's capability_grading flag. Under it, the Lesson Completion row
saves capability_lesson_completion: the agent marks a lesson complete once
the user finishes it, in new chats with signed-in users, where the agent is
added to a course lesson. That row works with Grading on or off.
Three sub-tabs follow, all usable while Grading is off: Grading Setup
(what gets graded, how much feedback is shared, the grading instructions),
Rubric (criteria and points), and Results (every grade the agent
issued, with overrides pushed back to the LMS). This is one tab in the
agent-settings family indexed by /iblai-vibe-agent; it shares the
AgentSettingsProvider wrapper with every other tab.
Set up first, then switch on. While Grading is on with no setup or an empty rubric, the platform refuses every chat turn with the agent. So the Grading switch stays off and locked until the rubric has a criterion, with "Add at least one rubric criterion first, then turn Grading on." under it. The order is: save the setup, add a criterion, turn Grading on. Grades always show in Results; they reach a course only where the agent is added to a course lesson.
Grading Setup -- What Gets Graded (A Submission / The Conversation), Feedback Shared with the Person (Overall Feedback Only / Feedback per Criterion / Overall + per Criterion), and the required Grading Instructions. The first Save creates the setup; later saves update it. An amber warning shows while Grading is on but the setup or the rubric is missing (Grading turned on through the API, say): the agent can't answer anyone until both are in place or Grading is off.

Rubric -- one row per criterion (Name, Criteria, Points) with an Edit / Delete menu. The footer shows the total; the overall score is points earned out of that total. Add Criterion is enabled once the setup is saved; until then the rubric says "Save your grading setup first, then add rubric criteria here."

Add Criterion -- Name, Criteria (what earns the points), and Points (a positive number). Edit opens the same dialog filled in.

Delete Criterion -- asks for confirmation. The last criterion cannot be deleted (its Delete is disabled); add another first.

Results -- filter by user (the History tab's user list), status (Pending / Published / Failed) and date range; 10 rows per page with columns Learner, Score (percent), Status, Override and Graded. Each row has an Override button that opens Override Grade: the AI score, Override Points (0 up to the rubric total, capped at 100) and optional Override Feedback; Clear restores the AI score. (The shot shows the empty state: this agent had not graded anything yet.)

Common setup (brand, conventions, env files, verification): see docs/skill-setup.md.
/iblai-vibe-auth, or vibe-starter).AgentSettingsProvider wraps the route (/iblai-vibe-agent §1).@iblai/iblai-js@^3.6.0 (resolves @iblai/web-containers 2.6.0). Check with
pnpm why @iblai/web-containers.capability_* flags on the agent's settings
(API version 4.467.0 or later). On an older one the Grading switch stays
off and locked, and the Lesson Completion row does not render.Look for iblai.env in the project root with PLATFORM, DOMAIN, and
TOKEN. If it is missing, tell the user:
"You need an iblai.env with your platform configuration. Download the
template and fill in your values:
curl -o iblai.env https://raw.githubusercontent.com/iblai/vibe/refs/heads/main/iblai.env"
AgentGraderTab// app/(app)/agents/[mentorId]/grader/page.tsx
"use client";
import { AgentGraderTab } from "@iblai/iblai-js/web-containers/next";
export default function AgentGraderPage() {
return (
<div className="flex h-full flex-col bg-white">
<AgentGraderTab />
</div>
);
}
The tab reads tenantKey, mentorId, username, enableRBAC and
rbacPermissions from AgentSettingsProvider; each can be passed as a prop
instead. With enableRBAC={false} (the /iblai-vibe-agent layout) every
grader action (setup, rubric, results) shows and the server's 403s are the
only gate -- no grants need loading. The two switches ignore enableRBAC:
they follow permissions.field on the agent's settings. A switch whose flag
the person may not change is locked; if they may not read capability_grading
the Grading switch is locked too, and if they may not read
capability_lesson_completion its row does not render. A 403 on the setup or
rubric replaces the tab body (the header stays) with "No Access to Grading
Settings".
With enableRBAC on, each action is checked as /mentors/<agent db id>/#<action>:
read_grader_config, create_grader_config, write_grader_config,
view_grader_criteria, create_grader_criteria, write_grader_criteria,
delete_grader_criteria, view_grade_results, override_grade_results.
Load them with useGetRbacPermissionsMutation (requestBody: { platform_key, resources: ["/mentors/<agent db id>/"] }; the db id is mentor_id on the
agent's settings) and pass the result as rbacPermissions, on the provider or
as the tab's prop. The tab reads only that, never the store's state.rbac.
If the grants hold no entry for the agent, every action stays visible.
How the two switches behave. Each one saves on the click and toasts "Grading turned on" / "Grading turned off — your rubric is kept for next time" (Lesson Completion: "Lesson Completion turned on" / "Lesson Completion turned off"). A switch is locked, with the reason under it, when the person may not change its flag ("You don't have permission to change this.") or the agent's model can't use it ("Doesn't work with the model this agent uses. Pick another model in the LLM tab to turn it on."). A refused save turns the switch back and shows one sentence under it, never a toast.
The tab renders with the default agent-facing copy
(AGENT_GRADER_TAB_LABELS, localized through the SDK's i18n). Pass a partial
labels object to change any string:
import { AgentGraderTab } from "@iblai/iblai-js/web-containers/next";
<AgentGraderTab
labels={{
header: { title: "Auto-grading" },
subTabs: { rubric: "Scoring rubric" },
}}
/>;
Label groups (GraderTabLabels): header (title, description),
capability (the Grading switch: title, description, offHint,
needsCriterion), subTabs
(setup, rubric, results), denied (the no-access notice), warnings
(noConfig, noCriteria), config (the setup form: gradingMode,
feedbackMode, instructions, save buttons), criteria (the rubric table,
totalPoints, scoreHint, lastCriterionHint, modal, deleteModal),
results (filters, statusValues, columns, empty states,
overrideModal, toasts), and toasts (switch, setup and criterion
toasts; toggleError is no longer shown). The Lesson Completion row's name
and sentence come from the SDK's own catalogue, not from labels.
get_component_info("AgentGraderTab")
get_component_info("AgentSettingsProvider")
<AgentGraderTab> PropsImport from @iblai/iblai-js/web-containers/next.
| Prop | Type | Required | Description |
|---|---|---|---|
labels | DeepPartial<GraderTabLabels> | No | Override user-visible strings |
tenantKey | string | No | Organization key; defaults to AgentSettingsProvider |
mentorId | string | No | Agent UUID; defaults to AgentSettingsProvider |
username | string | No | Signed-in username; defaults to AgentSettingsProvider |
enableRBAC | boolean | No | Check each grader action against rbacPermissions; defaults to AgentSettingsProvider |
rbacPermissions | object | No | Permission tree; defaults to AgentSettingsProvider |
From @iblai/iblai-js/web-containers/next:
AGENT_GRADER_TAB_LABELS -- the default label bundle.AgentGraderTabProps, GraderTabLabels -- types.GRADING_TOOL_NAME was removed in @iblai/web-containers 2.0.0: the tab
reads capability_grading now. Delete any import of it.
From @iblai/iblai-js/data-layer, for a custom UI on the same endpoints:
the hooks under Platform data, plus the types MentorGraderConfiguration,
GradingMode (submission | conversation), FeedbackMode (overall |
per_criteria | both), GradeResult, GradeResultPublishStatus
(pending | published | failed), CreateMentorGraderConfigurationRequest,
CreateGraderCriterionRequest, UpdateGraderCriterionRequest.
Paths are under https://api.iblai.app/dm/api/ai-mentor/orgs/{org}/. The
grader paths use the canonical agents/ prefix; the tab calls the
mentors/ alias for the setup and rubric, and both are served.
| Action | Request |
|---|---|
| Grading switch | PUT users/{username}/mentors/{uuid}/settings/ with capability_grading only (plus can_use_tools: true when turning it on for an agent that could not use tools yet; false is never sent) |
| Lesson Completion switch | The same PUT with capability_lesson_completion only (same can_use_tools rule) |
| Save the setup | POST agents/{uuid}/grader-config/ when the setup's GET answers 404, PATCH otherwise, with grading_mode, feedback_mode, grader_instructions (a POST when one exists returns 400 "already exists") |
| Add / edit / delete a criterion | POST agents/{uuid}/grader-config/criteria/; PATCH / DELETE …/criteria/{id}/ (name, criteria, points) |
| Results | GET agents/{uuid}/grader-results/?email=&status=&graded_at_after=&graded_at_before=&page=&page_size=10 |
| Override / Clear | PATCH agents/{uuid}/grader-results/{id}/ with override_points (or null to clear) and override_feedback |
A custom UI saves the setup, adds at least one criterion, and only then sets
capability_grading: true. Turning grading off keeps the setup and rubric;
there is no way to delete the setup.
| Hook | Purpose |
|---|---|
useGetMentorSettingsQuery / useEditMentorMutation | Read and save the two flags |
useGetToolsQuery | Which capabilities the agent's model can use (capability_field, is_allowed): a "no" locks the switch |
useGetMentorGraderConfigurationQuery, useCreateMentorGraderConfigurationMutation, useUpdateMentorGraderConfigurationMutation | The setup |
useListGraderCriteriaQuery, useCreateGraderCriterionMutation, useUpdateGraderCriterionMutation, useDeleteGraderCriterionMutation | The rubric |
useListGradeResultsQuery, useGetGradeResultQuery, useOverrideGradeResultMutation | Results and overrides |
useGetChatHistoryFilterQuery | The Results user filter |
There is no iblai-api-* REST twin for the grader yet; the endpoints above
are in the live schema.
Run /iblai-vibe-ops-test before telling the user the work is ready, and give
every page, control and state this skill added its own checkpoint — one Playwright
test titled <ID> · … in e2e/journeys/, listed in e2e/coverage.json;
pnpm e2e:coverage must pass:
pnpm build -- must pass with zero errors.pnpm test -- vitest must pass./agents/<uuid>/grader in the browser as /iblai-vibe-ops-test says, signed
in as an org admin: the Grading switch, the Lesson Completion row and the three
sub-tabs render; on a fresh agent the Grading switch is locked with the
needs-criterion sentence; save the setup, add a criterion, turn Grading on -- "Grading
turned on"; flip Lesson Completion; read the console; check the phone width.capability_grading (plus
can_use_tools: true when turning it on for an agent that could not use
tools yet); it never sends the agent's tool list (tool_slugs). The SDK's
Tools tab is gone (AgentToolsTab was removed in @iblai/web-containers
2.0.0).mentorReducer /
mentorMiddleware, which vibe-starter's store already includes.AgentSettingsProvider once at the layout
level (/iblai-vibe-agent §1); do not wrap each tab.sonner and @iblai/iblai-web-mentor
(pnpm add sonner @iblai/iblai-web-mentor).iblai-vibe-agent-grader-1-setup.png (opens in a new tab)iblai-vibe-agent-grader-2-rubric.png (opens in a new tab)iblai-vibe-agent-grader-3-criterion-add.png (opens in a new tab)iblai-vibe-agent-grader-4-criterion-delete.png (opens in a new tab)iblai-vibe-agent-grader-5-results.png (opens in a new tab)iblai-vibe-agent-grader-criterion-add.png (opens in a new tab)iblai-vibe-agent-grader-criterion-delete.png (opens in a new tab)iblai-vibe-agent-grader-criterion-edit.png (opens in a new tab)iblai-vibe-agent-grader-result-override.png (opens in a new tab)iblai-vibe-agent-grader-results.png (opens in a new tab)iblai-vibe-agent-grader-rubric-actions.png (opens in a new tab)iblai-vibe-agent-grader-rubric.png (opens in a new tab)iblai-vibe-agent-grader-setup.png (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
auto-grading, rubric, lesson-completion, lms-sync, agent-grader
npx claudepluginhub iblai/base --plugin iblai-vibe166 skills in this plugin
/iblai-api-agent-accessManage role-based access to an ibl.ai agent via the platform API — list role policies, search users/groups, and grant/revoke editor, chat, or analytics_viewer roles for users, groups, and emails. Use when controlling who can edit, chat with, or view analytics for an agent./iblai-api-agent-auditRead an ibl.ai agent's audit log via the platform API — a who-changed-what trail filterable by action, actor email, and date range. Read-only. Use when investigating configuration changes to an agent./iblai-api-agent-chatSet up live chat with a deployed ibl.ai agent by wiring the hosted iblai-api-agent-chat MCP server into the project (.mcp.json / claude mcp add) using the .env Api-Token and a chosen agent's unique id, or by signing in from claude.ai, ChatGPT or Claude Desktop with only the URL. Use to enable runtime conversations with an agent, and to list or disconnect the apps a user has connected. The actual chatting then happens through the MCP server's tools.Other plugins' skills for the same job