CodeveilStudio

Engineering digital products with design precision.

All work
Case studymobiledesign

AI Student Assistant

A Java Swing desktop assistant with OTP-verified accounts and a Gemini-backed study chat

Visit live project
Java
100%
UI toolkit
Swing
AI model
Gemini
Distribution
Desktop
AI Student Assistant

Overview

AI Student Assistant puts a verified account system and an AI study companion into a single native desktop window. Students sign up with email verification, sign in, and ask study questions answered by Google's Gemini model through a purpose-built API client. No browser, no hosting, no backend to operate — the entire product ships as one runnable Java application.

The challenge

Java desktop applications look like Java desktop applications

The brief had two halves that pull in opposite directions. A native desktop app avoids the browser entirely — no hosting, no deployment, no connectivity assumptions beyond the two calls that need it — which is exactly right for a study tool used on a personal laptop. But Swing's stock component set is instantly recognisable and instantly dated, and a student assistant that looks like a 2004 enterprise form does not get opened twice.

Meanwhile the account flow needed genuine email verification, which means driving SMTP from an end-user machine, and the AI layer had to talk to a generative endpoint and survive whatever came back.

  • Stock Swing components signal "student project" before a user reads a single word
  • Email verification from a desktop client means owning SMTP, delivery failure and OTP lifecycle in-process
  • A generative API returns variable and occasionally malformed payloads — the UI cannot assume a happy path
  • No browser and no server: everything has to ship inside one runnable application

What we built

A custom Swing component layer, a page-swapping frame shell, and an isolated AI client

The interface is rebuilt on top of Swing rather than styled within it. A custom title bar replaces the operating system chrome, and rounded panels, buttons and borders are implemented as reusable components so every screen inherits the same visual language automatically — consistency enforced by the component set rather than by remembering to match the last screen.

A single full-screen frame acts as the shell. Each screen — email entry, OTP verification, signup, login, password recovery and the dashboard — is a separate class producing its own panel, swapped into that frame by the entry point. One frame, one navigation path, no orphaned windows.

Email delivery runs through Jakarta Mail with an HTML template, serving both signup verification and password recovery. The Gemini integration is isolated in a single client class that builds the request payload, posts to the generative endpoint and extracts the response candidate defensively — so a malformed or errored response becomes a readable message in the chat rather than an exception dialog on top of the app.

What we delivered

Custom Swing component layer

Rounded buttons, panels and borders plus a custom title bar, built as reusable components. The visual language is inherited by every screen instead of reapplied per screen.

Page-swapping frame shell

One full-screen frame owned by the entry class, with every screen implemented as a swappable panel. A single path in and out of each screen, so navigation state cannot fragment across windows.

OTP email verification

Jakarta Mail with an HTML template delivers one-time codes for both signup verification and password recovery, driven entirely from the client application.

Password recovery flow

A complete recovery path — identify, verify by emailed code, then reset — using the same verification machinery as signup rather than a parallel implementation.

AI study chat

The dashboard hosts a chat interface backed by the Gemini client, so study questions are answered in-app without leaving for a browser.

Session handling

The signed-in identity is held in a dedicated session object rather than threaded through constructors between screens, which keeps screen classes independent of one another.

Self-contained distribution

Mail and JSON dependencies ship with the application and the whole thing runs from a single entry class — no installer, no runtime service, no external state.

Engineering challenges

The problems that took real work to solve. Tap any one to read how.

Problem

Stock Swing components are the tell. Grey bevelled buttons and square panels date an application immediately, and styling them individually per screen produces drift the moment a second screen is added.

Solution

A small library of rounded panels, buttons and borders plus a custom title bar that replaces the OS chrome. Because the components carry the styling, consistency is structural — a new screen built from them cannot look different.

Results

Native

Desktop Delivery

No browser, no hosting, one runnable application

OTP

Verified Signup

Email verification and password recovery driven in-process

Gemini

AI Study Chat

Isolated API client with defensive response parsing

Custom UI

Component Layer

Rounded components and a custom title bar built over Swing

Outcomes

  • A self-contained desktop application covering the full loop: verified signup, sign-in, password recovery and AI-assisted study chat.
  • A reusable Swing component layer that gives a native Java application a modern, consistent interface without a third-party UI framework.
  • An AI integration isolated behind one client class, so the model or the endpoint can change without touching a single screen.
  • A defined next phase: Maven-managed dependencies in place of bundled jars, environment-supplied configuration validated at startup, an embedded database in place of file-based persistence, and unit tests behind a CI pipeline.

Related work

Want something like AI Student Assistant?

Share your goals and we will come back with a clear plan and estimate.

Start a project