Skip to main content

Module classify_helpers

Module classify_helpers 

Source
Expand description

Shared error classification helpers used by web_fetch, web_search, and defuddle_fetch.

Each tool produces a different response shape, so the helpers here focus on the lower-level primitives: pulling an HTTP status code out of a reqwest error string, mapping a status / keyword to a category, and decoding HTML entities in scraped text. The per-tool next_action text lives next to the tool’s own response builder.

Functions§

extract_http_status
Pull an HTTP status code out of a reqwest error string.