duckduckgo / zeroclickinfo-spice

DuckDuckGo Instant Answers based on JavaScript (JSON) APIs

Home Page:https://duckduckhack.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Location Sunrise/Sunset:

x-15a2 opened this issue · comments

Very few cities trigger this AI. Olso and London work, New York, Chicago, Boston, Los Angeles don't


IA Page: http://duck.co/ia/view/sun_rise_set
Maintainer: @iambibhas

Hey @x-15a2! This is actually expected. The IA is limited to triggering on capitals of countries, or if a location isn't specific (e.g. "sunrise", "sunrise nov 29,2020") it should trigger for anyone anywhere, as we calculate the sunrise/sunset based on the approximated geo-ip instead of using the TimeAndDate.com API.

Certainly room for improvement but with DuckDuckHack in maintenance mode I don't expect we'll be able to prioritize improvements here.

I'm going to mark this as tolerated and close it.

To explain why, IIRC we opted to limit the IA to a known set of locations because we wanted to avoid making an API call for every query that includes "sunrise/sunset for X". We don't know for sure if "X" is a specific location (city + country), and so to avoid maintaining a big database of all possible locations, or using another API to first verify the input is a known location, we opted to user a smaller list of capitals cities.