A simple script to scrape an AI summarizer tool to summarize long text.
- 🚀 Asynchronous: Built on
asynciofor non-blocking, high-speed execution. - 🛡️ Stealthy: Utilizes
wreqwith strict browser emulation to bypass bot protections. - 🌐 Proxy Support: Easily route traffic through authenticated proxies via environment variables.
Clone the repository and install the required dependencies using uv for lightning-fast package resolution.
git clone https://github.com/dx-bear/python-ai-summarizer.git
cd ai-summarizer-scraper
# Create a virtual environment and install dependencies
uv venv
source .venv/bin/activate # On Windows use: .venv\Scripts\activate
uv pip install wreq python-dotenvCreate a .env file in the root directory of the project and set your PROXY_URL:
PROXY_URL=http://username:password@proxy-domain.com:portNote: If you are not using a proxy, you can leave this variable empty or comment it out.
Run the script directly from your terminal. Wrap the long text you want to summarize in quotes.
python ai_script.py "Artificial intelligence (AI) is a wide-ranging branch of computer science concerned with building smart machines capable of performing tasks that typically require human intelligence. While AI is an interdisciplinary science with multiple approaches, advancements in machine learning and deep learning are creating a paradigm shift in virtually every sector of the tech industry. Machine learning algorithms are fed massive amounts of data, allowing them to identify patterns and learn how to make predictions and decisions..."Output Example:
Artificial intelligence is a branch of computer science focused on creating smart machines. Through advancements in machine learning and deep learning, these systems use massive datasets to recognize patterns and make predictions, causing major shifts across the tech industry.
Distributed under the MIT License. See LICENSE for more information.
