Commit Graph
2 Commits
Author SHA1 Message Date
SuppaiNeko b229f5816e Changed get_wikipedia_article to be more robust
Will now fall back to wiki if local copy isn't avail
2026-03-26 12:17:06 -07:00
SuppaiNeko f01728adb7 - Added dex_info_writer.py with a full pipeline for
generating Pokédex-style species descriptions
  - Loads species from portland_wildlife.csv (taxon_id,
  common_name, wikipedia_url)
  - Fetches Wikipedia articles from a self-hosted Kiwix mirror
  (WIKI_LINK env var); falls back to live Wikipedia if unset
  - Spaces in Wikipedia URLs are normalized to underscores
  before fetching
  - LiteLLM instance prompted via OpenAI-compatible client
  (LITELLM_URL, LITELLM_API_KEY, LITELLM_MODEL env vars)
  - LLM has tool-calling access to fetch_wikipedia_article with
   an agentic loop
  - Output descriptions are sanitized — only alphanumerics and
  . , ! ? ' - : allowed
  - Writes results to portland_wildlife_dex_entries.csv in
  append mode with resume support (skips already-processed
  taxon_ids)
  - Live [i/total] progress counter printed each iteration
  along with the generated description
2026-03-25 21:02:30 -07:00