Workflow — Award Applicant

ModuleRegistration + AI
ActorsGuest → Applicant, LinkedIn, AI (MiniMax m3), System
SRS refsUC-04, FR-0302–0308, FR-0400, BR-001/002/007/010
StatusPlanned — ships with v0.4.0 (interview completes in v0.5.0)

Purpose

Register an award candidate, run their AI category interview, and hand them a personal share link + "I have applied" card to start collecting public votes.

Preconditions

  • Event type award (or ai), registration open, ≥1 active category.
  • Toggle registration.award on.
  • Applicant has no registration of any type in this event (BR-001) — including GoH (BR-002).

Main flow

  1. Guest taps Apply for an Award (/register/award).
  2. Chooses one category (active only). "One person, one category" notice shown.
  3. Continue with LinkedIn → profile imported (id, name, email, picture) — the system may verify the LinkedIn profile exists (BR-008). Basic fallback available with reduced trust badge.
  4. Basic info form: name (prefilled), email, WhatsApp number (required, BR-007), optional title/company.
  5. Photo upload (jpg/png/webp, min 400×400) — preview + confirm.
  6. AI interview:
    • System draws N (default 5) random active questions from question_bank for the category (BR-010).
    • Applicant answers one by one (text).
    • Each answer → AI marks: score 0–100 + short feedback → ai_answers.
    • Session total + summary → ai_sessions, registration status=ai_scored.
  7. Success page:
    • Personal share link https://event.production1.jugaar.ai/v/{public_token},
    • "I have applied for {event}" card (name + text from admin campaign settings),
    • tip: post link + card on LinkedIn/Facebook to gather votes.
  8. Notification to applicant (dashboard + email/WhatsApp placeholder).

Alternate / error flows

  • A1 Event type = normal → steps 6 skipped entirely — normal registration OK (FR-0405).
  • A2 AI unavailable → interview postponed: registration saved status=submitted, "continue later" link on dashboard; retry notice sent when AI recovers.
  • A3 Duplicate category attempt → error "You already applied in a category" (BR-001).
  • A4 Applicant also tries GoH (or reverse) → blocked with explanation (BR-002).
  • A5 Invalid photo → rejection message, upload again (no data lost).

Rules applied

BR-001, BR-002, BR-007, BR-008, BR-010.

Data touched

TableChange
usersINSERT/lookup
registrationsINSERT (type=award, public_token, photo)
question_bankSELECT random active
ai_sessions / ai_answersINSERT session + marked answers
audit_logregistration.created, ai.session.completed
notificationswelcome + share-link reminder

Sequence

sequenceDiagram
    participant A as Applicant
    participant W as Website
    participant LI as LinkedIn
    participant AI as AI (MiniMax m3)
    participant DB as MariaDB
    A->>W: /register/award → pick category
    W->>LI: OAuth
    LI-->>W: verified profile
    A->>W: info + WhatsApp + photo
    W->>DB: registration (award)
    loop N random questions
        W->>A: question
        A->>W: answer
        W->>AI: mark answer
        AI-->>W: score + feedback
        W->>DB: ai_answers
    end
    W->>DB: session total, status=ai_scored
    W-->>A: share link + "I have applied" card