Initial work to remove unbounded queries, old code, and addint type-ahead to widget.