DebateAI is an AI-enhanced, real-time debating platform designed to sharpen communication skills. Whether competing against human opponents or LLM-powered AI challengers, users can participate in structured debates that mimic formal competitions.
-
User vs. User Debates
-
Real-time debates via WebSockets, WebRTC (audio/video/text)
-
Structured formats: opening, cross-exam, and closing
-
User vs. AI Debates
-
LLM-generated counterarguments that adapt to your input
-
Custom Debate Rooms
-
Create private, topic-specific debate spaces
- Create a file named
config.prod.yml
in thebackend/config/
directory.
Paste the following configuration:
server:
port: 1313 # The port number your backend server will run on
database:
uri: "mongodb+srv://<username>:<password>@<cluster-url>/<database-name>"
# Replace with your MongoDB Atlas connection string
# Get this from your MongoDB Atlas dashboard after creating a cluster and database
gemini:
apiKey: "<YOUR_GEMINI_API_KEY>"
# API key for OpenAI / Gemini model access
# Obtain from your OpenRouter.ai or OpenAI account dashboard
jwt:
secret: "<YOUR_JWT_SECRET>"
# A secret string used to sign JWT tokens
# Generate a strong random string (e.g. use `openssl rand -hex 32`)
expiry: 1440
# Token expiry time in minutes (e.g. 1440 = 24 hours)
smtp:
host: "smtp.gmail.com"
# SMTP server host for sending emails (example is Gmail SMTP)
port: 587
# SMTP server port (587 for TLS)
username: "<YOUR_EMAIL_ADDRESS>"
# Email username (your email address)
password: "<YOUR_EMAIL_PASSWORD_OR_APP_PASSWORD>"
# Password for the email or app-specific password if 2FA is enabled
senderEmail: "<YOUR_EMAIL_ADDRESS>"
# The 'from' email address used when sending mails
senderName: "DebateAI Team"
googleOAuth:
clientID: "<YOUR_GOOGLE_OAUTH_CLIENT_ID>"
# Google OAuth Client ID for OAuth login
# Obtain from Google Cloud Console (APIs & Services > Credentials > OAuth 2.0 Client IDs)
Note: Do not commit this file to a public repository. Use
.gitignore
.
-
Navigate to the backend folder:
cd backend
-
Initialize Go modules (if not already done):
go mod tidy
-
Run the server:
go run cmd/server/main.go
-
In the
frontend/
directory, create a file named.env
. -
Add the following environment variables to the
.env
file:
VITE_BASE_URL="http://localhost:1313"
VITE_GOOGLE_CLIENT_ID="<YOUR_GOOGLE_OAUTH_CLIENT_ID>"
- Replace
<YOUR_GOOGLE_OAUTH_CLIENT_ID>
with your actual Google OAuth Client ID from Google Cloud Console.
Note: Do not commit this file to a public repository. Add
.env
to your.gitignore
to keep it secure.
-
Open a new terminal and navigate to the frontend directory:
cd frontend
-
Install dependencies:
npm install
-
Create a
.env
file and add:VITE_BASE_URL="http://localhost:1313"
-
Start the development server:
npm run dev
Thank you for your interest in contributing to DebateAI! We appreciate your efforts in making this project better. Please follow these best practices to ensure smooth collaboration.
- Navigate to the DebateAI repository.
- Click the Fork button in the top right corner.
- Clone the forked repository to your local machine:
git clone https://github.com/your-username/DebateAI.git
cd DebateAI
- Always create a new branch for your contributions:
git checkout -b feature-name
- Follow coding best practices and maintain code consistency.
- Write clear commit messages:
git commit -m "Added [feature/fix]: Short description"
- Push your changes to your forked repository:
git push origin feature-name
- Navigate to the original repository and open a Pull Request (PR).
- Provide a detailed description of the changes in the PR.
- Code Quality: Ensure your code is clean, readable, and consistent with the existing codebase.
- Testing: Test your changes locally before submitting a PR.
- Security: Never commit sensitive information (e.g., API keys or passwords).
- Communication: Be responsive to reviews and update your PRs as requested.
To help maintainers understand your changes, consider submitting a short video showcasing the feature or fix:
- Record a short demo (you can use tools like Loom or OBS).
- Upload and include the video link in your Pull Request description.
If you find a bug or have a feature request:
- Open an issue here.
- Clearly describe the problem and, if possible, suggest solutions.
We look forward to your contributions!
MIT © AOSSIE