CollectedPost
Documentation for eth_defi.feed.database.CollectedPost Python class.
- class CollectedPost
Bases:
objectA single normalised post ready for database insertion.
Attributes summary
Stable external identifier derived from the feed entry or a deterministic fallback.
Entry title when the feed provides one.
Canonical link to the source post when available.
Original post publication timestamp in naive UTC.
Timestamp when the collector fetched this post in naive UTC.
Short preview text stored alongside the post.
Best available full text extracted from the feed entry.
Optional future AI-generated summary, null in the current version.
JSON-serialised raw payload from the source API (e.g.
Methods summary
__init__(external_post_id, title, post_url, ...)- external_post_id: str
Stable external identifier derived from the feed entry or a deterministic fallback.
- title: Optional[str]
Entry title when the feed provides one.
- post_url: Optional[str]
Canonical link to the source post when available.
- published_at: Optional[datetime.datetime]
Original post publication timestamp in naive UTC.
- fetched_at: datetime.datetime
Timestamp when the collector fetched this post in naive UTC.
- short_description: str
Short preview text stored alongside the post.
Capped at 200 characters for compact listings; this is not the complete post body. See
full_textfor the full content.
- full_text: str
Best available full text extracted from the feed entry.
For X/Twitter this is the complete note tweet body for tweets longer than 280 characters, populated via
eth_defi.feed.twitter_api._extract_full_tweet_text(). Seeshort_descriptionfor the truncated preview.
- ai_summary: Optional[str]
Optional future AI-generated summary, null in the current version.
- raw_payload: Optional[str]
JSON-serialised raw payload from the source API (e.g. full tweet object from X API).
- __init__(external_post_id, title, post_url, published_at, fetched_at, short_description, full_text, ai_summary=None, raw_payload=None)