An AI-powered web application for detecting and acting on potential Disney IP piracy online.
- Authentication: Secure login with Google Firebase Auth
- Dashboard: Real-time monitoring of IP protection activities
- Content Analysis: AI-powered detection of potential IP violations
- DMCA Generator: Create legal takedown notices automatically
- Dark Mode: Full support for light/dark theme
- Frontend: React, TypeScript, Vite
- Styling: Tailwind CSS, shadcn/ui components
- State Management: React Context API, TanStack Query
- Authentication: Firebase Auth
- Database: Firestore
- Backend: Firebase Cloud Functions with Google Gemini AI
- Animations: Framer Motion
- Node.js & npm
- Firebase account
- Google Cloud account (for Gemini API access)
-
Clone the repository:
git clone https://github.com/yourusername/disneyshield-ai.git cd disneyshield-ai -
Install dependencies:
npm install -
Configure Firebase:
- Create a new Firebase project at firebase.google.com
- Enable Authentication with Google Sign-in
- Set up Firestore database
- Create two collections:
alertsanddmca_requests - Get your Firebase config and update
src/firebase/config.ts
-
Configure Gemini API:
- Create a Google Cloud project
- Enable Gemini API
- Generate an API key
- Add the key to your Firebase Functions environment
-
Deploy Firebase Functions:
- Set up Firebase CLI:
npm install -g firebase-tools - Log in:
firebase login - Deploy:
firebase deploy --only functions
- Set up Firebase CLI:
-
Start the development server:
npm run dev
The application uses two main Firebase functions:
This function uses Gemini AI to analyze content for potential IP violations:
exports.analyzeContent = functions.https.onCall(async (data, context) => {
// Verify authentication
if (!context.auth) {
throw new functions.https.HttpsError('unauthenticated', 'User must be logged in');
}
// Call Gemini API
const response = await genAI.generateContent(`
Analyze this content for Disney IP violations: ${data.url}
${data.description || ''}
`);
// Process response and store in Firestore
// ...
return {
// Analysis results
};
});This function generates DMCA takedown notices based on violation details:
exports.generateDMCA = functions.https.onCall(async (data, context) => {
// Verify authentication
if (!context.auth) {
throw new functions.https.HttpsError('unauthenticated', 'User must be logged in');
}
// Call Gemini API
const response = await genAI.generateContent(`
Generate a DMCA takedown notice for:
URL: ${data.infringingUrl}
IP Description: ${data.ipDescription}
Owner: ${data.ownerName}
Contact: ${data.ownerEmail}
`);
// Process response and store in Firestore
// ...
return {
// DMCA notice content
};
});To deploy the full application:
-
Build the React app:
npm run build -
Deploy to Firebase Hosting:
firebase deploy --only hosting
This project is licensed under the MIT License - see the LICENSE file for details.