This project provides a web application for summarizing the content of a given URL. It utilizes React for the frontend, Express with TypeScript for the backend, and integrates OpenAI API for summarization and Puppeteer for web scraping with Browserless for headless browsing.
- Web scraping to extract content from a given URL using Puppeteer with Browserless.
- Summarization of extracted content using OpenAI API.
- React-based frontend for user interaction.
- Express server with TypeScript for backend implementation.
Explore the live demo here.
Before running the project, make sure you have the following installed:
- Node.js
- npm
- Browserless account for Puppeteer.
-
Clone the repository:
git clone https://github.com/your-username/url-summarization-project.git
-
Install dependencies for both the frontend and backend:
cd url-summarization-project cd client && npm install cd ../server && npm install
-
Set up environment variables: Create a .env file in the server directory and add the following:
BLESS_TOKEN=your_browserless_token OPENAI_API_KEY=your_openai_api_key CORS_ORIGIN=your_frontend_url
- Start the backend server:
cd server && npm start
- Start the frontend:
cd client && npm start
- Visit http://localhost:5173 in your browser to access the application.
- Enter a URL in the input field.
- Click the "Summarize" button.
- The application will extract the content from the URL, summarize it using OpenAI, and display the result.