Python SDK for AskNews
Project description
AskNews Python SDK
Python SDK for the AskNews API.
Installation
pip install asknews
Usage
from asknews_sdk import AskNewsSDK
ask = AskNewsSDK(
api_key="<YOUR API KEY>"
scopes=["news", "chat", "stories", "analytics"]
)
query = "Effect of fed policy on tech sector"
# prompt-optimized string ready to go for any LLM:
news_context = ask.news.search_news(query).as_string
And you will have a prompt-optimized string ready to go for any LLM. The API doesn't stop there, explore a wide range of endpoints:
- /stories, high level event tracking and state of the art article clustering
- /forecasts, industry leading forecasting on any real-time event
- /analytics, time-series data on finance and politics
- /deepnews, a deep research agent that can explore the new knowledge graph, X, Reddit, Google, Wikipedia and more to build forecasts, reports, analytics, and anything else your system may need.
- /graph, build any news knowledge graph imaginable from the largest news graph on the planet
- /websearch, search the web and get back an LLM distillation of all the relevant web pages
Find full details at the AskNews API documentation.
Support
Join our Discord to see what other people are building, and to get support with your projects.
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 Distributions
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 asknews-0.13.19-py3-none-any.whl.
File metadata
- Download URL: asknews-0.13.19-py3-none-any.whl
- Upload date:
- Size: 48.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
52022f830d6494508208b6fe9719e046d6313d2226d4a603ee160d3ecfef99fe
|
|
| MD5 |
0c063f69d1e16ce196cedcbaa392edf0
|
|
| BLAKE2b-256 |
f2017773acb7ba03cef5dbffb233b908392a9a5ee24355a2df11164b5ca776e0
|
Provenance
The following attestation bundles were made for asknews-0.13.19-py3-none-any.whl:
Publisher:
release.yml on emergentmethods/asknews-python-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
asknews-0.13.19-py3-none-any.whl -
Subject digest:
52022f830d6494508208b6fe9719e046d6313d2226d4a603ee160d3ecfef99fe - Sigstore transparency entry: 981296355
- Sigstore integration time:
-
Permalink:
emergentmethods/asknews-python-sdk@20a166a7633a12fd0558769210fbd60efbf23497 -
Branch / Tag:
refs/tags/0.13.19 - Owner: https://github.com/emergentmethods
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@20a166a7633a12fd0558769210fbd60efbf23497 -
Trigger Event:
push
-
Statement type: