Skip to main content

adanos

PyPI version

adanos is the public Python SDK for the Adanos Market Sentiment API.

This SDK targets API 1.55.0.

It gives you typed access to:

  • Reddit stock sentiment
  • News sentiment and source-filtered rankings
  • X/Twitter stock sentiment
  • Polymarket stock activity and market attention
  • Reddit crypto sentiment
  • Direct finance text sentiment analysis

Links:

Package and import:

  • PyPI package: adanos
  • Python import: adanos

Install

python3 -m pip install adanos

Quick Start

from adanos import AdanosClient

client = AdanosClient(api_key="sk_live_...")

trending = client.reddit.trending(limit=10)
tsla = client.reddit.stock("TSLA")
explanation = client.reddit.explain("TSLA")
direct = client.sentiment.analyze("TSLA looks like a short squeeze setup")

print(trending[0].ticker)
print(tsla.buzz_score)
print(explanation.explanation)
print(direct["sentiment_label"])

What You Can Do

  • Rank trending stocks across Reddit, News, X, and Polymarket
  • Pull service-level market sentiment snapshots across every public namespace
  • Pull detailed ticker reports for a fixed lookback window
  • Search and compare tickers across datasets
  • Generate AI-written explanations for Reddit and News stock trends
  • Track Reddit crypto tokens via the same client
  • Use sync or async methods without changing the namespace structure

Namespaces

  • client.reddit.* for Reddit Stocks
  • client.news.* for News Stocks
  • client.x.* for X/Twitter Stocks
  • client.polymarket.* for Polymarket Stocks
  • client.crypto.* for Reddit Crypto
  • client.reddit_crypto.* is an alias for client.crypto.*
  • client.sentiment.* for direct finance text sentiment
  • client.health() for root API health aggregated across services

Examples

Reddit Stocks

from adanos import AdanosClient

client = AdanosClient(api_key="sk_live_...")

root_health = client.health()
trending = client.reddit.trending(limit=10)
sectors = client.reddit.trending_sectors(limit=10)
countries = client.reddit.trending_countries(limit=10)
tsla = client.reddit.stock("TSLA")
explanation = client.reddit.explain("TSLA")
results = client.reddit.search("Tesla", limit=10)
comparison = client.reddit.compare(["TSLA", "AAPL", "MSFT"])
market = client.reddit.market_sentiment()

News

from adanos import AdanosClient

client = AdanosClient(api_key="sk_live_...")

news_trending = client.news.trending(source="reuters")
sectors = client.news.trending_sectors(source="reuters")
countries = client.news.trending_countries(source="reuters")
nvda = client.news.stock("NVDA")
explanation = client.news.explain("NVDA")
results = client.news.search("Nvidia", limit=10)
comparison = client.news.compare(["NVDA", "AAPL"])
market = client.news.market_sentiment()
stats = client.news.stats()
health = client.news.health()

News ticker arguments identify one company. Exchange suffixes such as ABX.DE are supported. The API rejects share classes and malformed tickers.

X/Twitter

from adanos import AdanosClient

client = AdanosClient(api_key="sk_live_...")

x_trending = client.x.trending(limit=20)
sectors = client.x.trending_sectors(limit=10)
countries = client.x.trending_countries(limit=10)
nvda = client.x.stock("NVDA")
explanation = client.x.explain("NVDA")
results = client.x.search("Nvidia", limit=10)
comparison = client.x.compare(["NVDA", "AMD"])
market = client.x.market_sentiment()
stats = client.x.stats()
health = client.x.health()

Polymarket

from adanos import AdanosClient

client = AdanosClient(api_key="sk_live_...")

pm_trending = client.polymarket.trending(limit=20, type="stock")
sectors = client.polymarket.trending_sectors(limit=10)
countries = client.polymarket.trending_countries(limit=10)
aapl = client.polymarket.stock("AAPL")
results = client.polymarket.search("Apple", limit=10)
comparison = client.polymarket.compare(["AAPL", "TSLA"])
market = client.polymarket.market_sentiment()
stats = client.polymarket.stats()
health = client.polymarket.health()

Polymarket history starts on 2025-10-11. Earlier requested windows return an availability error.

Polymarket uses Instrument Graph keys in API 1.55.0: stocks, ADRs, and share classes of one company share a key; ETFs keep their own keys. Use BRK, BNY, or EWG, and keep venue suffixes returned by Search, such as SAP.DE. Find replacement keys with Search. For example, BK is now BNY and DAX is EWG. Stock detail and raw mentions return 404 for unknown keys and 503 when identity lookup is unavailable. Share classes such as BRK.B or BRK-B, cashtags, and unknown suffixes return 422. Compare keeps unknown keys as zero-activity rows without a company name and does not rewrite aliases. A null compare buzz_score means unavailable data, not zero; trend_history can be absent. Raw strike_price is null for company-value or reported-figure thresholds, such as market capitalization or capex.

Polymarket semantics:

  • buzz_score is activity-first and optimized for current market attention
  • total_liquidity is a windowed signal over the selected period
  • current_market_count is the live-only active-market breadth; market_count remains the selected-window breadth
  • unique_traders can be None when retained wallet-level trades do not fully cover the requested window
  • pulse on stock() provides a compact current interpretation; use its evidence and warnings as data-quality context
  • top_mentions on stock() are representative sentiment evidence, with directional markets prioritized

Across platforms, each trend_history value represents its own UTC calendar day. The final value for a live window describes the current partial UTC day and is not expected to equal the top-level period buzz_score.

Reddit Crypto

from adanos import AdanosClient

client = AdanosClient(api_key="sk_live_...")

trending = client.crypto.trending(limit=20)
btc = client.crypto.token("BTC")
mentions = client.crypto.mentions("BTC", from_="2026-05-01", to="2026-05-07", limit=10, offset=10)
results = client.crypto.search("bitcoin", limit=10)
comparison = client.crypto.compare(["BTC", "ETH"])
market = client.crypto.market_sentiment()
stats = client.crypto.stats()
health = client.crypto.health()

Reddit crypto total_upvotes and mention upvotes are signed Reddit scores and can be negative. Raw mention created_utc UTC timestamps parse into timezone-aware datetime values.

Available Methods

client.*

Method Description
health() Root API health aggregated across services

client.reddit.*

Method Description
trending(from_, to, days, limit, offset, type) Trending stocks by buzz score
trending_sectors(from_, to, days, limit, offset) Trending sectors
trending_countries(from_, to, days, limit, offset) Trending countries
stock(ticker, from_, to, days) Detailed sentiment for a ticker
mentions(ticker, from_, to, days, limit, offset, include_inherited) Raw Reddit mention rows
explain(ticker) AI-generated trend explanation
search(query, limit) Search stocks by name or ticker with an API-managed recent summary block
compare(tickers, from_, to, days) Compare up to 10 stocks
market_sentiment(from_, to, days) Service-level Reddit market sentiment snapshot
stats() Dataset statistics
health() Public service health

Period options: use from_ and to as YYYY-MM-DD inclusive UTC dates for reproducible windows. The SDK serializes from_ as query parameter from. days remains available as a legacy v1-compatible shorthand. The API returns 422 if from, to, and days are all sent together. Responses keep period_days; retain requested dates client-side if you need them later. Search endpoints are the exception: they accept only limit and use the API-managed recent summary window.

client.news.*

Method Description
trending(from_, to, days, limit, offset, type, source) Trending stocks from news
trending_sectors(from_, to, days, limit, offset, source) Trending sectors from news
trending_countries(from_, to, days, limit, offset, source) Trending countries from news
stock(ticker, from_, to, days) Detailed news sentiment for a ticker
mentions(ticker, from_, to, days, limit, offset) Raw news mention rows
explain(ticker) AI-generated explanation from news context
search(query, limit) Search stocks in the news dataset with an API-managed recent summary block
compare(tickers, from_, to, days) Compare up to 10 stocks in news
market_sentiment(from_, to, days) Service-level News market sentiment snapshot
stats() News dataset statistics
health() Public news service health

client.x.*

Method Description
trending(from_, to, days, limit, offset, type) Trending stocks on X/Twitter
trending_sectors(from_, to, days, limit, offset) Trending sectors
trending_countries(from_, to, days, limit, offset) Trending countries
stock(ticker, from_, to, days) Detailed X/Twitter sentiment
mentions(ticker, from_, to, days, limit, offset) Raw X/Twitter mention rows
explain(ticker) AI-generated explanation from X/Twitter context
search(query, limit) Search stocks with an API-managed recent summary block
compare(tickers, from_, to, days) Compare stocks
market_sentiment(from_, to, days) Service-level X/Twitter market sentiment snapshot
stats() Dataset statistics
health() Public service health

client.polymarket.*

Method Description
trending(from_, to, days, limit, offset, type) Trending stocks on Polymarket with activity-first buzz and windowed liquidity
trending_sectors(from_, to, days, limit, offset) Trending sectors
trending_countries(from_, to, days, limit, offset) Trending countries
stock(ticker, from_, to, days) Detailed Polymarket activity, sentiment, and relevance-sorted market questions
mentions(ticker, from_, to, days, limit, offset) Raw Polymarket market snapshots
search(query, limit) Search stocks with an API-managed recent summary block
compare(tickers, from_, to, days) Compare stocks with windowed Polymarket activity signals
market_sentiment(from_, to, days) Service-level Polymarket market sentiment snapshot
stats() Dataset statistics
health() Public service health

client.crypto.*

Method Description
trending(from_, to, days, limit, offset) Trending Reddit crypto tokens
token(symbol, from_, to, days) Detailed token sentiment and buzz
mentions(symbol, from_, to, days, limit, offset, include_inherited) Raw Reddit crypto mention rows
search(query, limit) Search tokens by symbol or name with an API-managed recent summary block
compare(symbols, from_, to, days) Compare multiple tokens
market_sentiment(from_, to, days) Service-level Reddit Crypto market sentiment snapshot
stats() Dataset statistics
health() Public service health

client.sentiment.*

Method Description
analyze(text, target=None) / analyze_async(text, target=None) Analyze one finance or trading text, optionally for a target company. Requires a Professional account.

target is keyword-only and accepts up to 100 characters. Omitting it or passing None sends text-only analysis. The API validates the target.

result = client.sentiment.analyze("Tesla gained while Ford fell", target="Tesla")

Sentiment responses are JSON dictionaries. components.model_score can be absent or None. Legacy component fields remain in responses but are deprecated.

Async Usage

Every namespace method also has an _async variant.

import asyncio

from adanos import AdanosClient


async def main() -> None:
    async with AdanosClient(api_key="sk_live_...") as client:
        trending = await client.reddit.trending_async(limit=10)
        tsla = await client.reddit.stock_async("TSLA")
        explanation = await client.news.explain_async("NVDA")
        print(trending[0].ticker)
        print(tsla.trend)
        print(explanation.explanation)


asyncio.run(main())

Authentication and Configuration

Get an API key at https://api.adanos.com/docs

from adanos import AdanosClient

client = AdanosClient(
    api_key="sk_live_...",
    base_url="https://api.adanos.com",
    timeout=60.0,
)

Notes:

  • api_key is required for protected endpoints
  • base_url defaults to https://api.adanos.com. Explicit https://api.adanos.org and custom deployments remain supported
  • timeout is passed through to the underlying httpx client
  • the SDK does not auto-load local CLI profiles or env-specific config files

Context management:

from adanos import AdanosClient

with AdanosClient(api_key="sk_live_...") as client:
    print(client.reddit.health())

Errors and Responses

  • Most SDK methods return typed models from the generated OpenAPI client
  • market_sentiment() methods return the live JSON payload directly so the new endpoint family is available before the next full generated refresh
  • Documented API errors are returned as typed error models
  • Undocumented statuses raise UnexpectedStatus
  • For long-lived processes, use with, async with, close(), or aclose() to release HTTP resources

Rate Limits

Typical platform limits:

Tier Monthly Requests Burst Limit
Free 250 100/min
Hobby 250,000 1000/min
Professional/Premium 2,500,000 1000/min

See the live API docs for the current contract and plan details.

Migration from social-stock-sentiment

Version 1.0.0 starts the new adanos package line and renames both the PyPI package and the Python import path.

Old:

python3 -m pip install social-stock-sentiment
from stocksentiment import StockSentimentClient

New:

python3 -m pip install adanos
from adanos import AdanosClient

The client API and namespace layout stay the same. Most upgrades only need a dependency rename and an import rewrite.

AdanosClient is now the primary public client name. StockSentimentClient remains available as a compatibility alias.

If you adopted the pre-release adanos-python-sdk naming locally, switch that install/import pair too:

python3 -m pip uninstall adanos-python-sdk
python3 -m pip install adanos
from adanos import AdanosClient

Development

python3 -m pip install -e ".[dev]"
python3 -m pytest tests -q
python3 -m build

License

MIT

Metadata

Release files for adanos 2.8.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for adanos 2.8.1
File Size Uploaded Provenance Actions
adanos-2.8.1.tar.gz 117.6 kB With provenance Details for adanos-2.8.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for adanos 2.8.1
File Interpreter ABI Platform Actions
adanos-2.8.1-py3-none-any.whl Python 3 none any Details for adanos-2.8.1-py3-none-any.whl

Total release size: 408.5 kB

Release files / adanos-2.8.1.tar.gz

Download URL adanos-2.8.1.tar.gz
Size 117.6 kB
Tags Source
SHA-256 checksum
How to use checksums
eb2ec02a6429b1d2c5160da59d72d99d238060cd67dbea0772270ed7588a2fc2
BLAKE2b-256 checksum
How to use checksums
ddced22d159c6a185c60e5cbc7358eeeff2720eb3f3b7d73e478d66ef4f34727
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Release files / adanos-2.8.1-py3-none-any.whl

Download URL adanos-2.8.1-py3-none-any.whl
Size 290.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a4bb802e2be82dd4fc017d7f41c98b98d91b144192aaa2cfc7f74d7b6ad85b31
BLAKE2b-256 checksum
How to use checksums
cc2ba7f2e14a8a6b0a14d342526926781d819715ddd54e1b6c19335ec2108883
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Security for adanos 2.8.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for adanos-2.8.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page