news-summizr extracts structured summaries from headlines, labeling key points like announcement, products, region for quick insight.
Project description
news_summizr
Simplify extracting structured summaries from news articles with this package.
Overview
A new package designed to simplify extracting structured summaries from news articles. It takes a headline or brief input about recent events and generates a concise, labeled summary emphasizing key points such as the main announcement, affected products, and regional focus.
Installation
pip install news_summizr
Usage
from news_summizr import news_summizr
response = news_summizr(user_input="Some news article headline", llm=None, api_key=None)
Input parameters:
user_input: str - the user input text to processllm: Optional[BaseChatModel] - the langchain llm instance to use, if not provided the default ChatLLM7 will be used.api_key: Optional[str] - the api key for llm7, if not provided.
By default, it uses the ChatLLM7 from langchain_llm7: https://pypi.org/project/langchain-llm7/.
You can safely pass your own llm instance (based on https://docs.langchain.com/) if you want to use another LLM, via passing it like news_summizr(user_input, llm=your_llm_instance).
Here are some examples of other LLMs you can use:
from langchain_openai import ChatOpenAI
from news_summizr import news_summizr
llm = ChatOpenAI()
response = news_summizr(user_input, llm=llm)
from langchain_anthropic import ChatAnthropic
from news_summizr import news_summizr
llm = ChatAnthropic()
response = news_summizr(user_input, llm=llm)
from langchain_google_genai import ChatGoogleGenerativeAI
from news_summizr import news_summizr
llm = ChatGoogleGenerativeAI()
response = news_summizr(user_input, llm=llm)
The default rate limits for LLM7 free tier are sufficient for most use cases of this package. If you want higher rate limits for LLM7, you can pass your own api key via environment variable LLM7_API_KEY or via passing it directly like news_summizr(user_input, api_key="your_api_key"). You can get a free api key by registering at https://token.llm7.io/.
GitHub Issues
https://github.com/chigwell/news-summizr
Author
Eugene Evstafev hi@euegne.plus
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file news_summizr-2025.12.21232733.tar.gz.
File metadata
- Download URL: news_summizr-2025.12.21232733.tar.gz
- Upload date:
- Size: 4.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
aa33c986cd79111d2b787cd411036ee09088f4825459026d90bce60925f4d319
|
|
| MD5 |
89ba702e8b4500d6b072df924c460cd7
|
|
| BLAKE2b-256 |
96d3a9daa94606e5e614068f4c389923a6ef930cc5161af903cdc48164c6926a
|
File details
Details for the file news_summizr-2025.12.21232733-py3-none-any.whl.
File metadata
- Download URL: news_summizr-2025.12.21232733-py3-none-any.whl
- Upload date:
- Size: 5.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ef264924e00ef5a17c9645dd6a644d16199440c1a40816a6a1fa7ba266912ef5
|
|
| MD5 |
4296cc31e823762c7f4d3216a7cebb9d
|
|
| BLAKE2b-256 |
74dbb0b0495b97c2624559b280acc6921d0160f30c21af12be78913957763d41
|