Learning the structure of the web