DEV Community

Saksham Setia
Saksham Setia

Posted on

VivaSensei

This is a submission for the Hacktoberfest Weekend Challenge: Build for a Friend

What I Built

I built VivaSensei, a personal AI viva examiner designed to help students practise for oral examinations.

The idea came from a simple problem: knowing a topic and being able to explain it clearly while someone keeps questioning you are two very different skills.

Notes, PDFs, and question banks are great for revision, but they usually cannot recreate the pressure and flow of an actual viva. In a real viva, the examiner listens to your answer, points out gaps, and immediately asks a follow-up question.

VivaSensei tries to recreate that experience.

A student can choose:

their subject

the topic they are currently studying

the difficulty level

specific weak areas they want to practise

The AI examiner then asks one question at a time, evaluates the student's response, provides concise feedback, and continues with a relevant follow-up question.

The conversation history is preserved throughout the session, so the examiner can use earlier answers as context instead of treating every question independently.

Students can either type their answers or record them using the voice interface. Recorded answers are transcribed first so that the student can review and edit the transcript before submitting it.

Examiner responses can also be converted to speech, making the whole experience feel much closer to an actual oral examination.

I originally built it for students like my friends and me who often prepare technical subjects alone and don't always have someone available to conduct a mock viva.

Demo

Code

GitHub logo S4K50M / VivaSensei

Your Personal AI Viva Examiner

๐ŸŽ“ VivaSensei

Your personal AI viva examiner

A Streamlit app that turns viva preparation into a conversation: one question, your answer, concise feedback, and a follow-up.

Built for students preparing for oral examinations, VivaSensei combines a locally running Qwen language model with optional ElevenLabs speech to help students practise explaining what they know.

Hackathon focus: Education ยท Conversational AI ยท Voice interaction

Status: Working local prototype


The problem

Knowing a topic and explaining it under questioning are different skills. Notes and question banks help students revise, but offer limited practice with follow-up questions. A mock viva usually depends on another person being available to listen, assess an answer, and keep the discussion going.

Our solution

VivaSensei gives students an on-demand practice examiner. Choose a subject, topic, difficulty, and areas you want to improve. The examiner asks a question, uses the conversation to respond to your answer, and continues with aโ€ฆ

How I Built It

The application is built primarily with Python and Streamlit.

For the AI examiner, I used the open-weight model:

Qwen/Qwen2.5-7B-Instruct

The model runs locally using:

Hugging Face Transformers

PyTorch

Accelerate

bitsandbytes

On CUDA systems, the model can run using 4-bit NF4 quantization with double quantization, which reduces GPU memory usage and makes local inference much more practical on consumer hardware.

The app builds an instruction prompt containing the student's subject, topic, difficulty, weaknesses, and viva behaviour rules. The entire conversation history is then sent along with each request so the model can maintain context throughout the viva.

The examiner is specifically instructed to:

ask one question at a time,

read the student's answer,

provide short feedback,

identify gaps where relevant,

continue with a follow-up question.

Streamlit's session state stores the active settings and conversation history for each session.

For voice interaction, I added optional ElevenLabs integration.

Students can record an answer, transcribe it using ElevenLabs Scribe, review the generated transcript, and only then submit it to the examiner.

AI responses can also be converted into speech so the student can listen to the examiner instead of only reading the response.

The overall flow is roughly:

Student โ†’ Streamlit โ†’ Conversation Context โ†’ Local Qwen Model โ†’ Examiner Response

For voice answers:

Student Recording โ†’ ElevenLabs Transcription โ†’ Transcript Review โ†’ Qwen

And for spoken examiner responses:

Qwen Response โ†’ ElevenLabs Text-to-Speech โ†’ Audio Playback

One important design choice was keeping the core viva functionality independent of external AI APIs.

Even without an ElevenLabs API key, the complete text-based viva experience still works locally.

Why Does Open Innovation Matter?

Open innovation is what made the core idea behind VivaSensei possible.

Instead of sending every student's conversation to a hosted language-model API, VivaSensei can run the main examiner model directly on the user's machine.

Using an open-weight model such as Qwen2.5-7B-Instruct gives developers much more control over how inference works.

For example, I could control:

how the model is loaded,

the precision used during inference,

GPU quantization,

conversation formatting,

token limits,

prompt behaviour,

and how session context is provided to the model.

It also means that once the model weights are downloaded, the text-based examiner can work without depending on a hosted LLM service.

That matters for an educational tool.

Students may want to practise using their own answers, weaknesses, course topics, and eventually even private course material. Local inference provides a path toward building those experiences while keeping much more of the processing under the user's control.

Open-source libraries such as Transformers, PyTorch, Accelerate, bitsandbytes, and Streamlit also made it possible to build an entire conversational AI application without needing to create every infrastructure component from scratch.

More importantly, open innovation makes experimentation easier.

Prize Categories

Best Use of GitHub Copilot
Best Use of ElevenLabs

Top comments (0)