如何通过Google搜索抓取特定域的链接?
我有一个印度歌曲的歌词语料库,需要用发行年份来标记它们,以进行我正在进行的实验。
有一个网站(lyricsindia.net),其中有这些歌词的详尽数据库,但遗憾的是无法在该网站上搜索歌词。相反,当我使用部分歌词作为搜索字符串进行谷歌搜索时,lyricindia.net 上该歌曲的链接始终位于前 10 个结果中。
现在,我想知道是否可以使用像 scrapy 这样的网络爬行框架来使用搜索字符串作为爬行的起点。我遇到的每个 Scrapy 教程都以起始 URL 开头。
I have a corpus of lyrics of Indian songs and need to tag them with their year of release for an experiment I am working on.
There is a website(lyricsindia.net), which has an exhaustive database of these lyrics with years, but unfortunately the lyrics cannot be searched on the website. Instead, when I google with part of lyrics as the search string, the link to the song on lyricsindia.net is always in the top-10 results.
Now, I was wondering if it was possible using web-crawling frameworks like scrapy to use a search-string as a starting point for crawling. Every Scrapy tutorial, I have come across starts with a starting URL.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您的搜索字符串可能是 Scrapy 网址的一部分。类似 google.com?q=my+string
或者,您可以检索搜索表单,并用您的字符串填充它,例如:
我确信 Scrapy 可能会做您想做的事情。
Your search string could be a part of the url with Scrapy. something like google.com?q=my+string
Or, you can retrieve the search form, and fill it with your string, something like :
I'm sure Scrapy might do what you want to do.