Skip to content

Generate a comprehensive summary and key points of the extracted text give a URL

License

Notifications You must be signed in to change notification settings

amscotti/page-summarizer

Repository files navigation

Page Summarizer

A wizard in a library - Leonardo AI

Page Summarizer is a Python application that extracts text from a given URL and uses OpenAI's GPT-4 model, interfaced through the LangChain library, to generate a comprehensive summary and key points of the extracted text. The application leverages the power of GPT-4's natural language understanding to provide concise and relevant summaries, making it easier to digest large amounts of information quickly.

asciicast

How to Run the Project

Running Locally

To run this project, you will need Python installed on your machine along with the necessary packages. Follow these steps:

  1. Clone the repository to your local machine.
  2. Install the required dependencies by running pip install -r requirements.txt.
  3. Set up your environment variables by creating a .env file with your OpenAI API key as OPENAI_API_KEY.
  4. Run the script using the command python app.py <URL>, where <URL> is the URL of the webpage you want to summarize.

Running with Docker

To build and run the project using Docker, follow these steps:

  1. Ensure you have Docker installed on your machine.
  2. Navigate to the directory containing the Dockerfile.
  3. Build the Docker image using the command:
    docker build -t page-summarizer .
    
  4. Once the image is built, run the container using the command:
    docker run -e OPENAI_API_KEY='your_openai_api_key' --rm page-summarizer <URL>
    
    Replace your_openai_api_key with your actual OpenAI API key and <URL> with the URL of the webpage you want to summarize.

References

About

Generate a comprehensive summary and key points of the extracted text give a URL

Topics

Resources

License

Stars

Watchers

Forks