edutap.ai developers
Exam Feedback and Weakness Reports

SDK Integration

Install the Chatbot SDK in EXAM mode to show grading results to learners

Feedback produced by the grading API is shown to learners through the Chatbot SDK.

Installation is the same as Chatbot Installation. Adding just one thing — chat-mode="EXAM" opens the feedback experience instead.

What differs from a standard install

ItemStandard learningExam feedback
InstallationCDN or npmSame
Required valuesapiKey, userId, courseIdSame (+ clipId pointing at the question)
chat-modeNot set"EXAM" required
First screenLearning home (streak, quiz, study notes)Feedback home (explanations, hints, weakness report)
Video syncvideoTarget syncs the lecture videoNot used

Omitting chat-mode still installs successfully — it just opens the standard learning screen, so no feedback appears. If the symptom is "it installed but I see no feedback", check this value first.

Matching the values

The three values you pass to the SDK must be exactly the same as the ones used in the grading request. That combination is what locates the feedback.

Feedback API fieldCDN attributenpm optionValue
exam_idcourse-idcourseIdExam ID
items[].problem_idclip-idclipIdProblem ID of the question the learner is currently viewing
user_iduser-iduserIdTest taker ID

If any value differs, or that question has not reached DONE yet, the feedback screen appears empty.

Installation

CDN (HTML)

<!DOCTYPE html>
<html>
  <body>
    <!-- 1. Load from CDN -->
    <script src="https://files.edutap.ai/tap-sdk/loader.js"></script>

    <!-- 2. Add the TapKit element with chat-mode="EXAM" -->
    <tap-kit
      chat-mode="EXAM"
      user-id="u-1001"
      course-id="I100000760_1"
      clip-id="w11"
    ></tap-kit>

    <!-- 3. Inject the API key -->
    <script>
      document.querySelector('tap-kit').apiKey = 'your-api-key';
    </script>
  </body>
</html>

Set the API key as a property only, never as an api-key attribute — an attribute exposes it in the HTML.

npm (React)

npm install @coxwave/tap-kit@^4.3.3
'use client';

import { TapKit, useTapKit } from '@coxwave/tap-kit/react';

function ExamReviewPanel({ examId, problemId, userId }) {
  const tapkit = useTapKit({
    apiKey: 'your-api-key',
    chatMode: 'EXAM',   // open the feedback experience
    userId,             // user_id from the grading request
    courseId: examId,   // exam_id from the grading request
    clipId: problemId,  // problem_id from the grading request
    onReady: () => console.log('Ready!'),
  });

  return <TapKit control={tapkit.control} style={{ height: '600px' }} />;
}

The chatMode option reaches the element from @coxwave/tap-kit 4.3.3 onward. 4.3.2 and earlier silently ignore it and open the standard learning screen, so upgrade. The CDN path is unaffected — its loader always fetches the latest SDK.

npm (Non-React)

import { createTapKit } from '@coxwave/tap-kit';

const tapkit = createTapKit({
  apiKey: 'your-api-key',
  chatMode: 'EXAM',
  userId: 'u-1001',
  courseId: 'I100000760_1',
  clipId: 'w11',
});

tapkit.mount();
await tapkit.ready;

Moving between questions

When the learner moves to another question, update only the problem ID. Leave chat-mode as it is.

// CDN / Non-React
document.querySelector('tap-kit').clipId = 'w12';
// React — passing it as state applies automatically
const [problemId, setProblemId] = useState('w11');
const tapkit = useTapKit({ /* ... */ chatMode: 'EXAM', clipId: problemId });

Screens in EXAM mode

ScreenContents
HomeExplanation and hint buttons, plus AI-suggested questions
ChatConversation that keeps the current question's feedback context
Weakness reportWeaknesses per attempt with cumulative counts

Quizzes, study notes, chat history, and settings do not exist in this mode.

Requesting feature activation

chat-mode="EXAM" alone does not open the feedback screen — exam feedback must be enabled on your API key. It is off by default, so ask your contact to turn it on.

Integration checklist

CheckHow to verify
Is the SDK loaded?Confirm the loader.js request returns 200
Did it open in EXAM mode?Confirm the home screen shows explanation and hint buttons
Do the values match?Confirm course-id / clip-id / user-id equal the grading request values
Is grading finished?Confirm the question's status is DONE via the result lookup API

Next Steps