https://github.com/simonefelici/newspy
A new way to read news articles online!
https://github.com/simonefelici/newspy
news newspy python python3 scraping
Last synced: 19 days ago
JSON representation
A new way to read news articles online!
- Host: GitHub
- URL: https://github.com/simonefelici/newspy
- Owner: SimoneFelici
- License: gpl-3.0
- Created: 2024-02-02T10:17:00.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-08-05T19:53:11.000Z (almost 2 years ago)
- Last Synced: 2024-08-05T23:06:30.131Z (almost 2 years ago)
- Topics: news, newspy, python, python3, scraping
- Language: Python
- Homepage:
- Size: 34.2 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: newspy.py
- License: LICENSE
Awesome Lists containing this project
README
Cute image made with DALL·E
# Newspy
Newspy is a console-based news scraping and summarization tool designed to provide a streamlined and informative reading experience.
## Description
Newspy allows users to browse and read articles from various websites directly from the console, with the capability to generate AI summaries of the articles.
The application is designed to be lightweight, fast, and respectful of user privacy.
## Key Features
- **News Scraping**: Extracts content from predefined websites or manually entered URLs.
- **Privacy**: Offers a clean reading experience without ads or tracking.
- **Image Rendering**: Supports image display directly in the terminal (only with Kitty).
- **AI Summaries**: Generates concise summaries of articles using the OpenAI API.
- **Modularity**: Flexible structure that allows easy addition of new websites and features.
- **Cool**: Terminal ui>>>
## Requirements
- Python 3.x
- Kitty terminal (for displaying images)
- OpenAI API key (for AI summaries)
## Installation
1. Clone the repository: ```git clone https://github.com/SimoneFelici/Newspy.git```
2. Install dependencies: ```pip install -r requirements.txt```
3. Edit the `.env` file in the directory and add your OpenAI API key, or choose if you want to display images:
## Usage
Edit the file ```sites.json``` and add the name and url of the site you want to read articles form, then add the xpath that has the articles.
Here is an example of xpath:


Run the main script: ```python3 main.py```.
## License
GNU v3.0