class

Waypoints::Describer

Inherits Reference < Object

Coordinates a page fetch and a model (or heuristic) description, then saves the resulting bookmark. Kept separate from the CLI so both are testable.

Constructors

new(fetcher : PageFetcher, model : DescriptionModel, diagnostics : IO = STDERR)

Builds a describer over a fetcher, a model seam, and diagnostic IO.

Source

Class methods

heuristic(page : PageContent) : BookmarkDescription

Builds a description from the page itself: host-derived tag, title summary.

Source

Instance methods

describe_and_save(url : String, store : Store) : Bookmark

Fetches url, describes it (model when real, heuristic otherwise), and persists the bookmark in store, returning the saved record.

Source