# Project export: Vocis

This document was generated by HackStack to give an AI agent context about a hackathon project. Sections are labeled with their provenance; content marked as truncated was cut to keep this document small.

## Project metadata

- Hackathon: Cal Hacks 11.0
- Tagline: We aim to improve presentation skills through simulating difficult scenarios presenters and public-speakers usually have to face like Closing testimonials, hecklers and QnA sessions.
- Devpost: https://devpost.com/software/vocis
- GitHub: https://github.com/dev-alto/calhacks-v11-proj
- Team: 2 GitHub contributor(s) — loofsan (4 commits), devalto (2 commits)

## Devpost submission (written by the team)

### Inspiration

The inspiration behind our project stems from the personal challenges we’ve faced in the past with public speaking and presentations. Like many others, we often found ourselves feeling overwhelmed by nerves, shaky voices, and the pressure of presenting in front of peers. This anxiety would sometimes make it difficult to communicate ideas effectively, and the fear of judgment made the experience even more daunting. Recognizing that we weren’t alone in these feelings, we wanted to create a solution that could help others overcome similar hurdles. That’s where Vocis comes in. Its aim is to give people the freedom and the ability to practice their presentation skills at their own pace, in a safe, supportive environment. Whether it’s practicing for a school project, a work presentation, or simply building the confidence to speak in front of others, the platform allows users to refine their delivery. What It Does Our project aims to simulate real-life challenges that presenters might face. For example, handling difficult situations like Q&A sessions, dealing with hecklers, or responding to aggressive viewers. By creating these simulated scenarios, our software prepares users for the unpredictability of live presentations. We hope that by giving people the tools and the settings to practice on their own terms, they can gradually build the skills and self-assurance needed to present with ease in any setting. Tech Stack - How Vocis is built ReactJs Shadcn NextJs TailwindCSS Hume.Ai OpenAI Challenges We Faced During our hackathon, one of the key challenges we faced was the need to dive into extensive documentation while working on API implementation as we had never worked with Hume before. Not only that, as all of us don’t have much experience with the backend of an app, it was really taxing to learn and implement at the same time. This task, which is already time-consuming, became more difficult due to unstable internet connectivity. This led to unexpected delays in accessing resources and troubleshooting problems in real time, which put additional pressure on our timeline. Despite these setbacks, our team worked hard to adapt and maintain momentum. Accomplishments Despite the challenges we faced, we were able to make a functional prototype at the very least that displays the core of our program which is simulating real-life difficult scenarios for presenters and public-speakers. At least, the very bare bones and we’re very proud of ourselves for being able to do that and create a wonderful project. What We Learned We learned to create a viable project in limited time allowing us to overcome our shortcomings in our ability to create a project Through multiple workshops and gaining insightful help from mentors, we learned more about APIs, implementing APIs, and making sure they cooperate with each other and streamlining the process. We also learned a lot of new, cool and amazing technologies created by a lot of amazing people that allowed us to achieve the aim of our project What’s Next For Vocis We allow multiple users to present at the same time and the AI can create situations for multiple “panelists” We allow many more situations that panelists and presenters may face like many different types of aggressive people, journalists that are a little too overbearing. We add reactions of the audience that is listening to our presentation so that it creates a more realistic experience for the user (“presenter”) More security measure Authentication

## README (from the GitHub repository)

This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/app/api-reference/cli/create-next-app).

## Getting Started

First, run the development server:

```bash
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
```

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.

This project uses [`next/font`](https://nextjs.org/docs/app/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.

## Learn More

To learn more about Next.js, take a look at the following resources:

- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.

You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!

## Deploy on Vercel

The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.

Check out our [Next.js deployment documentation](https://nextjs.org/docs/app/building-your-application/deploying) for more details.


## Detected evidence (automated analysis)

Indexed codebase: 30 recognized source files, 89 KB.
- CSS (language) — detected in the code
- Google Gemini (technology) — detected in the code
- JavaScript (language) — detected in the code
- Next.js (technology) — detected in the code
- OpenAI (technology) — detected in the code
- React (technology) — detected in the code
- Tailwind CSS (technology) — detected in the code
- TypeScript (language) — detected in the code
- Node.js (technology) — claimed on Devpost, not found in the code

## Codebase structure (from repository index)

### Files (38 of 38)

```
.env.local
.eslintrc.json
.gitignore
components.json
next.config.mjs
package.json
postcss.config.mjs
README.md
src/app/about/page.tsx
src/app/api/analysis/route.js
src/app/contact/page.tsx
src/app/get-started/page.tsx
src/app/globals.css
src/app/layout.tsx
src/app/main-copy/page.tsx
src/app/main/page.tsx
src/app/mode1/page.tsx
src/app/page.tsx
src/components/ClientComponent.tsx
src/components/Controls.tsx
src/components/Messages.tsx
src/components/ui/BoxReveal.tsx
src/components/ui/Button.tsx
src/components/ui/button2.tsx
src/components/ui/Card.tsx
src/components/ui/card2.tsx
src/components/ui/Container.tsx
src/components/ui/Footer.tsx
src/components/ui/input.tsx
src/components/ui/label.tsx
src/components/ui/Navbar.tsx
src/components/ui/scroll-area.tsx
src/components/ui/switch.tsx
src/lib/expressionColors.ts
src/lib/expressionLabels.ts
src/lib/utils.ts
tailwind.config.ts
tsconfig.json
```

### Dependencies

- package.json: @google/generative-ai@^0.21.0, @humeai/voice-react@^0.1.16, @radix-ui/react-icons@^1.3.0, @radix-ui/react-label@^2.1.0, @radix-ui/react-scroll-area@^1.2.0, @radix-ui/react-slot@^1.1.0, @radix-ui/react-switch@^1.1.1, @types/next@^8.0.7, @types/node@^20, @types/react@^18, @types/react-dom@^18, axios@^1.7.7, class-variance-authority@^0.7.0, clsx@^2.1.1, dotenv@^16.4.5, eslint@^8, eslint-config-next@14.2.15, framer-motion@^11.11.9, fs@^0.0.1-security, hume@^0.9.1, lucide-react@^0.453.0, next@14.2.15, openai@^4.68.1, postcss@^8, react@^18, react-dom@^18, react-toastify@^10.0.6, react-use-measure@^2.1.1, styled-components@^6.1.13, tailwind-merge@^2.5.4, tailwindcss@^3.4.1, tailwindcss-animate@^1.0.7, typescript@^5

### Recent commits (newest first)

- Foo
- Removed secret api
- New
- NICE
- New UI and Stuff
- Small
- WORKING HUMEEEEEEEE
- UIPDATEREEEE
- the beginning

## Key source files (fetched from GitHub, selected and truncated for size)

### package.json

```
{
  "name": "calhacks-v11-proj",
  "version": "0.1.0",
  "private": true,
  "scripts": {
    "dev": "next dev",
    "build": "next build",
    "start": "next start",
    "lint": "next lint"
  },
  "dependencies": {
    "@google/generative-ai": "^0.21.0",
    "@humeai/voice-react": "^0.1.16",
    "@radix-ui/react-icons": "^1.3.0",
    "@radix-ui/react-label": "^2.1.0",
    "@radix-ui/react-scroll-area": "^1.2.0",
    "@radix-ui/react-slot": "^1.1.0",
    "@radix-ui/react-switch": "^1.1.1",
    "axios": "^1.7.7",
    "class-variance-authority": "^0.7.0",
    "clsx": "^2.1.1",
    "dotenv": "^16.4.5",
    "framer-motion": "^11.11.9",
    "fs": "^0.0.1-security",
    "hume": "^0.9.1",
    "lucide-react": "^0.453.0",
    "next": "14.2.15",
    "openai": "^4.68.1",
    "react": "^18",
    "react-dom": "^18",
    "react-toastify": "^10.0.6",
    "react-use-measure": "^2.1.1",
    "styled-components": "^6.1.13",
    "tailwind-merge": "^2.5.4",
    "tailwindcss-animate": "^1.0.7"
  },
  "devDependencies": {
    "@types/next": "^8.0.7",
    "@types/node": "^20",
    "@types/react": "^18",
    "@types/react-dom": "^18",
    "eslint": "^8",
    "eslint-config-next": "14.2.15",
    "postcss": "^8",
    "tailwindcss": "^3.4.1",
    "typescript": "^5"
  }
}

```

### src/app/layout.tsx

```typescript
import type { Metadata } from "next";
import localFont from "next/font/local";
import "./globals.css";
import 'dotenv/config'

const geistSans = localFont({
  src: "./fonts/GeistVF.woff",
  variable: "--font-geist-sans",
  weight: "100 900",
});
const geistMono = localFont({
  src: "./fonts/GeistMonoVF.woff",
  variable: "--font-geist-mono",
  weight: "100 900",
});

export const metadata: Metadata = {
  title: "Create Next App",
  description: "Generated by create next app",
};

export default function RootLayout({
  children,
}: Readonly<{
  children: React.ReactNode;
}>) {
  return (
    <html lang="en">
      <body
        className={`${geistSans.variable} ${geistMono.variable} antialiased`}
      >
        {children}
      </body>
    </html>
  );
}

```

### src/app/page.tsx

```typescript
"use client";

// pages/index.tsx
import { motion } from "framer-motion";
import React from "react";
import Head from "next/head";
import Link from "next/link";

import { Card, CardHeader, CardTitle, CardContent } from "@/components/ui/Card";
import { Container } from "@/components/ui/Container";
import { Navbar } from "@/components/ui/Navbar";
import { Footer } from "@/components/ui/Footer";
import { Button } from "@/components/ui/Button";

import Image from "next/image";

// import styled from 'styled-components';

interface Feature {
  title: string;
  description: string;
  icon: string;
}

const features: Feature[] = [
  {
    title: "Interactive Q&A Sessions",
    description:
      "Engage with AI-driven questions based on your presentation content to prepare for any audience.",
    icon: "🗣️",
  },
  {
    title: "Heckling and De-escalation Training",
    description:
      "Learn effective strategies to handle aggressive viewers and maintain composure during presentations.",
    icon: "🛡️",
  },
  {
    title: "Real-Time Feedback",
    description:
      "Receive instant tips and guidance to improve your delivery and performance on the fly.",
    icon: "⏱️",
  },
  {
    title: "Presentation Timer",
    description:
      "Manage your presentation time efficiently with a built-in countdown and warnings.",
    icon: "⏰",
  },
  {
    title: "Extended Communication Skills",
    description:
      "Enhance your ability to hold longer conversations, initiate dialogues, and resolve conflicts.",
    icon: "💬",
  },
  {
    title: "Voice and Video Recording",
    description:
      "Record your presentations to review and analyze your performance for continuous improvement.",
    icon: "🎥",
  },
];

const containerVariants = {
  hidden: { opacity: 0 },
  visible: {
    opacity: 1,
    transition: {
      staggerChildren: 0.2,
    },
  },
};

// const Marquee = styled.div`
//     position: absolute;
//     width: 100%;
//     bottom: -58.5em;
//     margin: 0 auto;
//     white-space: nowrap;
//     overflow: hidden;
//     z-index: 3;
//     display: flex;

//   span {
//     text-transform: uppercase;
//     font-weight: 350;
//     color: ##cfcbc4;
//     font-size: 4em;
//     text-transform: uppercase;
//     padding-left: -10%;
//     animation: marquee-animation 75s linear infinite;
//     @media (max-width: 900px) {
//       font-size: 2.4em;
//     }
//     @media (max-width: 468px) {
//       font-size: 1.3em;
//     }
//   }

//   @keyframes marquee-animation {
//     0% {
//       transform: translate(0, 0);
//     }
//     100% {
//       transform: translate(-100%, 0);
//     }
//   }
// `

const itemVariants = {
  hidden: { opacity: 0, y: 50 },
  visible: { opacity: 1, y: 0 },
};

const Home: React.FC = () => {
  return (
    <>
      <Head>
        <title>Vocis - Master Your Presentation Skills</title>
        <meta
          name="description"
          content="Vocis is an AI-powered platform that enhances your presentation and speech skills through interactive training and real-time feedback."
        />
        <link rel="icon" href="/favicon.ico" />
      </Head>

      <Navbar />

      <main className="bg-white">
        {/* Hero Section */}
        <section className="bg-gradient-to-r from-blue-500 to-indigo-600 text-white">
          <Container className="flex flex-col items-center justify-center py-20 text-center">
            <motion.h1
              className="text-5xl font-bold mb-4"
              initial={{ opacity: 0, y: 50 }}
              animate={{ opacity: 1, y: 0 }}
              transition={{ duration: 0.8 }}
            >
              Elevate Your Presentation Skills with Vocis
            </motion.h1>
            <motion.p
              className="text-xl mb-8 max-w-2xl"
              initial={{ opacity: 0, y: 50 }}
              animate={{ opacity: 1, y: 0 }}
              transition={{ duration: 0.8, delay: 0.3 }}
            >
              Overcome public speaking anxiety, master interactive Q&A sessions,
              handle hecklers, and receive real-time feedback to deliver
              impactful presentations every time.
            </motion.p>
            <motion.div
              initial={{ opacity: 0 }}
              animate={{ opacity: 1 }}
              transition={{ duration: 0.8, delay: 0.6 }}
            >
              <Link href="/get-started">
                <Button size="lg" variant="default">
                  Get Started
                </Button>
              </Link>
            </motion.div>
          </Container>{" "}
        </section>

        {/* Features Section */}
        <section className="py-20 bg-gray-100">
          <Container>
            <motion.div
              className="text-center mb-12"
              initial={{ opacity: 0 }}
              whileInView={{ opacity: 1 }}
              viewport={{ once: true }}
              transition={{ duration: 0.8 }}
            >
              <motion.h2
                className="text-3xl font-semibold"
                initial={{ opacity: 0, y: 50 }}
                whileInView={{ opacity: 1, y: 0 }}
                viewport={{ once: true }}
                transition={{ duration: 0.8, delay: 0.2 }}
              >
                Key Features
              </motion.h2>
              <motion.p
                className="text-gray-600 mt-4"
                initial={{ opacity: 0, y: 50 }}
                whileInView={{ opacity: 1, y: 0 }}
                viewport={{ once: true }}
                transition={{ duration: 0.8, delay: 0.4 }}
              >
                Vocis offers a comprehensive suite of tools designed to enhance
                every aspect of your presentation skills.
              </motion.p>
            </motion.div>
            <motion.div
              className="grid grid-cols-1 md:grid-cols-3 gap-8"
              variants={containerVariants}
              initial="hidden"
              whileInView="visible"
              viewport={{ once:
[truncated — 3647 more characters]
```

### src/app/main/page.tsx

```typescript
// ./app/page.tsx
import ClientComponent from "@/components/ClientComponent";

import { fetchAccessToken } from "hume";

export default async function Page() {
  const accessToken = await fetchAccessToken({
    apiKey: String(process.env.HUME_API_KEY),
    secretKey: String(process.env.HUME_SECRET_KEY),
  });

  if (!accessToken) {
    throw new Error();
  }
  return (
    <ClientComponent
      configKey={process.env.HUME_CONFIG_KEY}
      accessToken={accessToken}
    />
  );
}

```

### src/app/main-copy/page.tsx

```typescript
'use client'

import { Button } from '@/components/ui/Button'

import { useEffect, useState, useCallback, useRef } from 'react'
import Image from "next/image"

function secondsToDhms(seconds: number): string {
  const h = Math.floor(seconds / 3600)
  const m = Math.floor((seconds % 3600) / 60)
  const s = Math.floor(seconds % 60)

  return [h, m, s].map(v => v.toString().padStart(2, '0')).join(':')
}

export default function Main() {
  const [timer, setTimer] = useState(0)
  const [isMicOn, setIsMicOn] = useState(true)
  const [isCameraOn, setIsCameraOn] = useState(true)
  const intervalRef = useRef<NodeJS.Timeout | null>(null)

  const startTimer = useCallback(() => {
    if (intervalRef.current !== null) return
    intervalRef.current = setInterval(() => {
      setTimer(prev => prev + 1)
    }, 1000)
  }, [])

  const stopTimer = useCallback(() => {
    if (intervalRef.current === null) return
    clearInterval(intervalRef.current)
    intervalRef.current = null
  }, [])

  useEffect(() => {
    startTimer()
    return () => stopTimer()
  }, [startTimer, stopTimer])

  const toggleMic = () => setIsMicOn(prev => !prev)
  const toggleCamera = () => setIsCameraOn(prev => !prev)
  const endSession = () => {
    stopTimer()
    alert("Session ended!")
  }

  return (
    <main className="flex flex-col h-screen bg-black text-white">
      <div className="flex flex-grow">
        <section className="w-3/4 bg-neutral-800" aria-label="Main content area">
          {/* Main content goes here */}
        </section>
        <aside className="w-1/4 bg-neutral-700" aria-label="Sidebar">
          <div className="relative aspect-video bg-neutral-900">
            <span className="absolute top-1 left-1 bg-neutral-900/20 px-2 py-1 rounded-xl font-bold">Sharing</span>
            <Image src="/assets/slide_example.jpg" alt="Shared content" layout="fill" objectFit="cover" />
          </div>
        </aside>
      </div>
      <footer className="flex justify-between items-center px-4 h-[10%] bg-neutral-900">
        <h1 className="bg-neutral-700 rounded-xl py-4 px-10">Team meeting</h1>
        <div className="flex space-x-3">
          <Button onClick={toggleMic}>
            {isMicOn ? '🎙️ Mute' : '🎙️ Unmute'}
          </Button>
          <Button variant="primary" onClick={toggleCamera}>
            {isCameraOn ? '📷 Turn Off Camera' : '📷 Turn On Camera'}
          </Button>
          <Button variant="danger" onClick={endSession}>End Session</Button>
        </div>
        <div className="bg-neutral-700 rounded-xl py-4 px-10 font-semibold" aria-label="Session duration">
          {secondsToDhms(timer)}
        </div>
      </footer>
    </main>
  )
}
```

### src/app/get-started/page.tsx

```typescript
"use client";

import { useState } from "react";
import { useRouter } from "next/navigation";
import { Card, CardContent } from "@/components/ui/card2";
import { Switch } from "@/components/ui/switch";
import { Button } from "@/components/ui/button2";
import { CheckSquare } from "lucide-react";
import { Navbar } from "@/components/ui/Navbar";

export default function PresentationModeSelector() {
  const [isLivePresentation, setIsLivePresentation] = useState(false);
  const [selectedScenarios, setSelectedScenarios] = useState<string[]>([]);
  const router = useRouter();

  const scenarios = [
    "Introduction",
    "Product Demo",
    "Q&A Session",
    "Technical Deep Dive",
    "Customer Testimonial",
    "De-escalation",
    "Closing Remarks",
  ];

  const handleScenarioToggle = (scenario: string) => {
    setSelectedScenarios((prev) =>
      prev.includes(scenario)
        ? prev.filter((s) => s !== scenario)
        : [...prev, scenario]
    );
  };

  const handleSubmit = () => {
    // Ensure live presentation is selected and "Q&A Session" is part of selected scenarios
    if (isLivePresentation && selectedScenarios.includes("Q&A Session")) {
      const query =
        selectedScenarios.length > 0
          ? `?scenarios=${selectedScenarios.join(",")}`
          : "";

      // Navigate to main.tsx with the query
      router.push(`/main${query}`);
    }
  };

  return (
    <>
      <Navbar />
      <div className="max-w-4xl mx-auto p-6 my-24 bg-background">
        <h2 className="text-3xl font-bold text-center mb-8">
          Presentation Mode Selector
        </h2>

        <Card className="mb-8">
          <CardContent className="p-6">
            <div className="flex justify-between items-center">
              <span className="text-xl font-medium">Live-Presentation</span>
              <Switch
                checked={isLivePresentation}
                onCheckedChange={setIsLivePresentation}
                aria-label="Toggle Live Presentation"
              />
            </div>
          </CardContent>
        </Card>

        <div className="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4 mb-8">
          {scenarios.map((scenario) => (
            <div
              key={scenario}
              onClick={() => handleScenarioToggle(scenario)}
              className="cursor-pointer"
            >
              <Card
                className={`h-full transition-all ${
                  selectedScenarios.includes(scenario)
                    ? "bg-primary text-primary-foreground"
                    : "bg-card hover:bg-accent hover:text-accent-foreground"
                }`}
              >
                <CardContent className="p-4 flex items-center justify-between">
                  <span className="text-lg font-medium">{scenario}</span>
                  {selectedScenarios.includes(scenario) && (
                    <CheckSquare className="h-6 w-6" />
                  )}
                </CardContent>
              </Card>
            </div>
          ))}
        </div>

        <Button
          onClick={handleSubmit}
          className="w-full py-6 text-lg font-semibold"
          disabled={
            !isLivePresentation || !selectedScenarios.includes("Q&A Session")
          }
        >
          Submit
        </Button>
      </div>
    </>
  );
}

```

### src/app/contact/page.tsx

```typescript
'use client'

import React from 'react';
import { Navbar } from '@/components/ui/Navbar';
import { Footer } from '@/components/ui/Footer';
import {BoxReveal} from "@/components/ui/BoxReveal";

export default function ContactUs() {
  const handleSubmit = (e: React.FormEvent<HTMLFormElement>) => {
    e.preventDefault()
    // Handle form submission here
    console.log('Form submitted')
  }

  return (
    <>
      <Navbar />
        <div className="min-h-screen bg-gray-100 py-20 px-4 sm:px-6 lg:px-8">
        <div className="max-w-5xl mx-auto">
            <BoxReveal boxColor={"#fcfcfc"} duration={0.5}>
                <p className="text-lg text-gray-700 leading-relaxed mb-6 py- text-center">
                    Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed 
                    do eiusmod tempor incididunt ut labore et dolore magna aliqua. 
                    Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris 
                    nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in 
                    reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla 
                    pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa 
                    qui officia deserunt mollit anim id est laborum.
                </p>
            </BoxReveal>
            <div className="grid grid-cols-1 md:grid-cols-2 gap-8 justify-center">
            <div className="bg-white rounded-lg shadow-md overflow-hidden">
                <div className="px-6 py-8">
                    <h2 className="text-2xl font-bold text-center text-gray-900 mb-8">Contact Us</h2>
                    <form className="space-y-6">
                        <div>
                        <label htmlFor="name" className="block text-sm font-medium text-gray-700">
                            Name
                        </label>
                        <input
                            type="text"
                            id="name"
                            name="name"
                            required
                            className="mt-1 block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"
                        />
                        </div>
                        <div>
                        <label htmlFor="email" className="block text-sm font-medium text-gray-700">
                            Email
                        </label>
                        <input
                            type="email"
                            id="email"
                            name="email"
                            required
                            className="mt-1 block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"
                        />
                        </div>
                        <div>
                        <label htmlFor="message" className="block text-sm font-medium text-gray-700">
                            Message
                        </label>
                        <textarea
                            id="message"
                            name="message"
                            rows={4}
                            required
                            className="mt-1 block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"
                        ></textarea>
                        </div>
                        <div>
                        <button
                            type="submit"
                            className="w-full flex justify-center py-2 px-4 border border-transparent rounded-md shadow-sm text-sm font-medium text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
                        >
                            Send Message
                        </button>
                        </div>
                    </form>
                </div>
                <div className="px-6 py-4 bg-gray-50 border-t border-gray-200">
                </div>
            </div>

            <div className="bg-white rounded-lg shadow-md overflow-hidden">
                <div className="px-6 py-8">
                <h2 className="text-2xl font-bold text-center text-gray-900 mb-8">Our Team</h2>
                <div className="space-y-6">
                    <div>
                    <BoxReveal boxColor={"#fcfcfc"} duration={0.6}>
                        <h3 className="block text-lg font-semibold text-gray-800">
                            Lance
                        </h3>
                    </BoxReveal>
                    <BoxReveal boxColor={"#fcfcfc"} duration={0.7}>
                        <p className="mt-1 text-gray-600">
                            Full Stack Developer
                        </p>
                    </BoxReveal>
                    </div>
                    
                    <div>
                    <BoxReveal boxColor={"#fcfcfc"} duration={0.6}>
                        <h3 className="block text-lg font-semibold text-gray-800">
                            Lynn
                        </h3>
                    </BoxReveal>
                    <BoxReveal boxColor={"#fcfcfc"} duration={0.7}>
                        <p className="mt-1 text-gray-600">
                            Full Stack Developer
                        </p>
                    </BoxReveal>
                    </div>
                    
                    <div>
                    <BoxReveal boxColor={"#fcfcfc"} duration={0.7}>
                        <h3 className="block text-lg font-semibold text-gray-800">
                            Assem
                        </h3>
                    </BoxReveal>
                    <BoxReveal boxColor={"#fcfcfc"} duration={0.7}>
                        <p className=
[truncated — 1272 more characters]
```

### src/app/about/page.tsx

```typescript
// pages/about.tsx


'use client';
import React from 'react';
import Head from 'next/head';
import Link from 'next/link';

import { Button } from '@/components/ui/Button';
import { Card, CardHeader, CardTitle, CardContent } from '@/components/ui/Card';
import { Container } from '@/components/ui/Container';
import { Navbar } from '@/components/ui/Navbar';
import { Footer } from '@/components/ui/Footer';

import Image from 'next/image'

const About: React.FC = () => {
  return (
    <>
      <Head>
        <title>About -</title>
        <meta
          name="description"
          content="Learn more about the project, our mission to enhance your presentation skills through interactive training and real-time feedback."
        />
        <link rel="icon" href="/favicon.ico" />
      </Head>

      <Navbar />

      <main className="bg-gray-50 min-h-screen">
        <Container className="py-16">
          {/* Hero Section */}
          <section className="text-center mb-16">
            <h1 className="text-4xl font-bold text-gray-800 mb-4">About </h1>
            <p className="text-lg text-gray-600 max-w-2xl mx-auto">
              is dedicated to empowering individuals to deliver impactful presentations through AI-driven feedback and interactive training tools.
            </p>
          </section>

          {/* Features Section */}
          <section className="mb-16">
            <h2 className="text-3xl font-semibold text-gray-800 mb-8 text-center">Our Features</h2>
            <div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
              {/* Feature 1 */}
              <Card>
                <CardHeader className="flex items-center justify-center mb-4">
                <Image src="/icons/feedback.svg" alt="Feedback Icon" width={48} height={48} className="w-12 h-12" />
                </CardHeader>
                <CardContent>
                  <CardTitle>AI-Driven Feedback</CardTitle>
                  <p className="text-gray-600">
                    Receive instant, personalized feedback on your presentation skills to continuously improve.
                  </p>
                </CardContent>
              </Card>

              {/* Feature 2 */}
              <Card>
                <CardHeader className="flex items-center justify-center mb-4">
                  <Image src="/icons/transcript.svg" alt="Transcript Icon" className="w-12 h-12" />
                </CardHeader>
                <CardContent>
                  <CardTitle>Real-Time Transcription</CardTitle>
                  <p className="text-gray-600">
                    Access accurate transcriptions of your presentations to review and analyze your performance.
                  </p>
                </CardContent>
              </Card>

              {/* Feature 3 */}
              <Card>
                <CardHeader className="flex items-center justify-center mb-4">
                  <Image src="/icons/slides.svg" alt="Slides Icon" className="w-12 h-12" />
                </CardHeader>
                <CardContent>
                  <CardTitle>Interactive Slide Viewer</CardTitle>
                  <p className="text-gray-600">
                    Seamlessly integrate your slides to enhance your presentation experience and visual storytelling.
                  </p>
                </CardContent>
              </Card>

              {/* Feature 4 */}
              <Card>
                <CardHeader className="flex items-center justify-center mb-4">
                  <Image src="/icons/analytics.svg" alt="Analytics Icon" className="w-12 h-12" />
                </CardHeader>
                <CardContent>
                  <CardTitle>Performance Analytics</CardTitle>
                  <p className="text-gray-600">
                    Gain insights into your presentation patterns and track your improvement over time with detailed analytics.
                  </p>
                </CardContent>
              </Card>

              {/* Feature 5 */}
              <Card>
                <CardHeader className="flex items-center justify-center mb-4">
                  <Image src="/icons/team.svg" alt="Team Icon" className="w-12 h-12" />
                </CardHeader>
                <CardContent>
                  <CardTitle>Collaborative Tools</CardTitle>
                  <p className="text-gray-600">
                    Work together with peers and mentors to refine your presentation skills through collaborative sessions.
                  </p>
                </CardContent>
              </Card>

              {/* Feature 6 */}
              <Card>
                <CardHeader className="flex items-center justify-center mb-4">
                  <Image src="/icons/support.svg" alt="Support Icon" className="w-12 h-12" />
                </CardHeader>
                <CardContent>
                  <CardTitle>24/7 Support</CardTitle>
                  <p className="text-gray-600">
                    Our dedicated support team is always here to help you with any questions or technical issues.
                  </p>
                </CardContent>
              </Card>
            </div>
          </section>

          {/* Mission Statement */}
          <section className="mb-16 bg-white rounded-lg shadow-lg p-8">
            <h2 className="text-3xl font-semibold text-gray-800 mb-4 text-center">Our Mission</h2>
            <p className="text-gray-600 text-center max-w-3xl mx-auto">
              At , our mission is to democratize effective communication by providing accessible and intelligent tools that help individuals excel in their presentations, whether in professional settings, academic environments, or personal endeavors.
            </p>
          </section>

          {/* Team Section */}
          <section className="mb-16">
            <h2 className="text-3xl font-semibold text-gray-800 mb-8 text-center">Meet Our CEOs</h2>
            <div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 ga
[truncated — 2594 more characters]
```

### src/app/mode1/page.tsx

```typescript
"use client";

import { useState, useEffect, useRef } from "react";
import { Button } from "@/components/ui/button2";
import { Navbar } from "@/components/ui/Navbar";
import { Card } from "@/components/ui/card2";
import { Input } from "@/components/ui/input";
import { Label } from "@/components/ui/label";

export default function Page() {
  // State variables
  const [isSpeaking, setIsSpeaking] = useState(false);
  const [timer, setTimer] = useState(0);
  const [isTimerRunning, setIsTimerRunning] = useState(false);
  const [generatedText, setGeneratedText] = useState("");
  const [mediaStream, setMediaStream] = useState<MediaStream | null>(null);
  const [error, setError] = useState<string | null>(null);
  const [availableCameras, setAvailableCameras] = useState<MediaDeviceInfo[]>(
    []
  );
  const [selectedCameraId, setSelectedCameraId] = useState<string>("");

  // Refs for video element
  const videoRef = useRef<HTMLVideoElement>(null);

  // Effect to handle timer countdown
  useEffect(() => {
    let interval: NodeJS.Timeout;
    if (isTimerRunning && timer > 0) {
      interval = setInterval(() => {
        setTimer((prevTimer) => prevTimer - 1);
      }, 1000);
    } else if (timer === 0) {
      setIsTimerRunning(false);
    }
    return () => clearInterval(interval);
  }, [isTimerRunning, timer]);

  // Effect to fetch AI-generated text (simulated)
  useEffect(() => {
    const fetchGeneratedText = async () => {
      const response = await new Promise<string>((resolve) =>
        setTimeout(() => {
          resolve(
            "This is the AI-generated text.\n\nHere is another paragraph.\nAnd a new line here."
          );
        }, 1000)
      );
      setGeneratedText(response);
    };

    fetchGeneratedText();
  }, []);

  // Effect to enumerate available cameras
  useEffect(() => {
    const getCameras = async () => {
      try {
        const devices = await navigator.mediaDevices.enumerateDevices();
        const videoDevices = devices.filter(
          (device) => device.kind === "videoinput"
        );
        setAvailableCameras(videoDevices);
        if (videoDevices.length > 0) {
          setSelectedCameraId(videoDevices[0].deviceId);
        }
      } catch (err) {
        console.error("Error enumerating devices.", err);
        setError("Unable to access media devices.");
      }
    };

    getCameras();
  }, []);

  // Effect to access webcam and microphone based on selected camera
  useEffect(() => {
    const getMedia = async () => {
      if (!selectedCameraId) return;

      // Stop any existing media tracks before starting new ones
      if (mediaStream) {
        mediaStream.getTracks().forEach((track) => track.stop());
      }

      try {
        const stream = await navigator.mediaDevices.getUserMedia({
          video: { deviceId: { exact: selectedCameraId } },
          audio: true,
        });
        setMediaStream(stream);

        if (videoRef.current) {
          videoRef.current.srcObject = stream;
        }
      } catch (err) {
        console.error("Error accessing media devices.", err);
        setError("Unable to access webcam and/or microphone.");
      }
    };

    getMedia();

    // Cleanup on component unmount
    return () => {
      if (mediaStream) {
        mediaStream.getTracks().forEach((track) => track.stop());
      }
    };
  }, [selectedCameraId]);

  // Handlers
  const handleSpeakToggle = () => {
    setIsSpeaking(!isSpeaking);
    // Implement actual speech functionality here
  };

  const handleRestart = () => {
    // Implement restart functionality here
  };

  const handleTimerStart = () => {
    if (timer > 0) {
      setIsTimerRunning(true);
    }
  };

  const handleCameraChange = (event: React.ChangeEvent<HTMLSelectElement>) => {
    setSelectedCameraId(event.target.value);
  };

  const firstCardRef = useRef(null);

  return (
    <>
      <Navbar />
      <div className="container relative h-screen md:flex md:flex-row lg:grid lg:max-w-full lg:grid-cols-[3fr_1.5fr] lg:px-0">
        {/* Sidebar Section */}
        <div className="relative hidden h-full flex-col bg-muted p-6 text-white dark:border-r lg:flex">
          <div className="absolute inset-0 bg-zinc-900" />
          <div className="relative z-20 flex flex-col h-full">
            {/* Top Grid of Cards */}
            <div className="flex-grow grid grid-cols-3 gap-3 mb-3">
              {[...Array(9)].map((_, i) => (
                <Card
                  ref={i === 0 ? firstCardRef : null}
                  key={i}
                  className="bg-zinc-800 rounded-lg shadow-md aspect-video flex items-center justify-center"
                >
                  {i === 0 ? (
                    // Embed the webcam video in the first card
                    <>
                      {error ? (
                        <p className="text-red-500 text-xs">{error}</p>
                      ) : (
                        <video
                          ref={videoRef}
                          autoPlay
                          playsInline
                          muted
                          className="w-full h-full object-cover rounded-md"
                        ></video>
                      )}
                    </>
                  ) : (
                    // Other cards can have their own content or remain empty
                    <div className="bg-zinc-700 w-full h-full rounded-md"></div>
                  )}
                </Card>
              ))}
            </div>
            {/* Bottom Controls */}
            <div className="flex flex-col space-y-1">
              {/* Speak, Restart, Timer Controls */}
              <div className="flex space-x-1">
                <Button
                  variant={isSpeaking ? "destructive" : "outline"}
                  className="text-xs px-3 py-1 bg-zinc-900"
                  onClick={handleSpeakToggle}
                >
                  {isSpeaking ? "Stop Speaking" : "Speak"}
              
[truncated — 3263 more characters]
```

### src/app/api/analysis/route.js

```javascript


import { NextResponse } from "next/server";

import OpenAI from "openai"

const openai = new OpenAI({
    apiKey: process.env.OPENAI_API_KEY,
})

const SYSTEM_PROMPT = String(`
  You're assisting in listing summaries and important talking points of individual slides, all of which under a single slideshow theme.

  You are given the text data for an entire slideshow, each section per slide number.
`)

const JSON_RESPONSE_TEMPLATE = {
  slides: [
    {
      slide_summary: "<short one sentence summary of slide>",
      talking_points: [
        "<a unique talking point derived from the slides>"
      ],
    }
  ],
  slideshow_summary: "<paragraph summary of entire slideshow>"
}

// To handle a GET request to /api
export async function GET(request) {
  try {
      const completion = await openai.chat.completions.create({
          model: "gpt-4",
          messages: [
              { role: "system", content: `${SYSTEM_PROMPT}. Please use this JSON format: ${JSON.stringify(JSON_RESPONSE_TEMPLATE)}` },
              { role: "user", content: `Fetching data through GET request.` }
          ],
          temperature: 1,
          max_tokens: 500,
      });

      return NextResponse.json({
          message: JSON.stringify(completion.choices[0].message.content),
      }, { status: 200 });
  } catch (error) {
      console.error('Error handling GET request:', error);
      return NextResponse.json({ message: 'Error occurred' }, { status: 500 });
  }
}

// To handle a POST request to /api
export async function POST(request) {


  const completion  = await openai.chat.completions.create({
    messages: [
      { role: "system", content: `${SYSTEM_PROMPT}. Please use this JSON format: ${JSON.stringify(JSON_RESPONSE_TEMPLATE)}`},
      { role: "user", content: `My hobbies are: Videogames. My Interests are: Computer Science` },
    ],
    temperature: 1,
    response_format: { "type": "json_object" },
    max_tokens: 500,
    model: "gpt-4o-mini",
  });

  return NextResponse.json({ message: JSON.stringify(completion.choices[0].message.content) }, { status: 200 });
}

// Same logic to add a `PATCH`, `DELETE`...
```

[20 more indexed source files omitted to keep this export small. The full file list is in the Codebase structure section above.]