跳转到主要内容

SE::Brave - Brave 搜索结果爬虫工具

Brave

爬虫工具概览

Brave 搜索结果爬虫工具允许从这个快速增长且注重隐私的搜索引擎中采集数据。通过它,您可以获取准备好供后续使用的链接库。您可以按在 Brave 中输入的原样使用查询,包括搜索运算符。

得益于 A-Parser 的多线程工作,查询处理速度可以非常快,从而在短时间内处理大量数据。

A-Parser 的功能允许保存数据抓取设置以供后续使用(预设)、设置数据抓取计划等等。 您可以使用查询扩展、从文件替换子查询、遍历数字字母组合和列表,以获取尽可能多的结果。

由于内置了强大的 Template Toolkit 模板引擎,可以将结果保存为您需要的任何形式和结构,这允许对结果应用额外的逻辑并以各种格式输出数据,包括 JSON、SQL 和 CSV

采集的数据

  • 搜索结果中的链接、锚点和摘要,以及摘要中的日期(如果有)
  • 相关关键词列表 (Related keywords)

功能

  • 支持所有 Brave 搜索运算符 (site:, inurl: 等)
  • 指定页数(1 到 10),Brave 平均每页显示约 10 条结果
  • 指定获取页面的搜索区域界面语言
  • 可以获取精确的本地搜索结果,支持通过 IP 自动定位或手动指定精确位置
  • 可以选择搜索结果类型,除了主要的有机搜索结果外,Brave 爬虫工具还可以采集新闻或视频搜索结果
  • 支持指定发布时间(不限时间或 24 小时到一年之间的特定间隔)
  • 支持会话 (Sessions)

应用场景

  • 采集链接库 - 用于 XRumer, AllSubmitter, GSA Ranker 等。
  • SERP 导出,包括链接、锚点和摘要,允许 SEO 专家与营销人员进行深度分析。
  • 查找反向链接和网站提及
  • 任何其他涉及通过无限数量查询获取搜索结果的场景

查询

在查询中需要指定搜索短语,就像直接在 Brave 搜索框中输入一样,例如:

购买汽车
基辅的窗户
site:https://lenta.ru
inurl:guestbook

查询替换

您可以使用内置宏来扩展查询,例如我们想要获取一个非常大的论坛数据库,为此我们指定几个不同语言的基础查询:

forum
论坛
foro
论坛

在查询格式中指定从 a 到 zzzz 的字符遍历,此方法可以最大程度地轮换搜索结果并获得许多新的唯一结果:

$query {az:a:zzzz}

该宏将为每个原始搜索查询创建 475254 个额外查询,总计将产生 4 x 475254 = 1901016 个搜索查询,这个数字令人印象深刻,但对于 A-Parser 来说完全不是问题。在每分钟 2000 个查询的速度下,这样的任务只需 16 小时即可处理完毕。

使用运算符

您可以在查询格式中使用搜索运算符,这样它将自动添加到列表中的每个查询,例如:

inurl:$query

结果输出示例

得益于内置的 Template Toolkit 模板引擎,A-Parser 支持灵活的结果格式化,这使其能够以任意形式以及结构化形式(如 CSV 或 JSON)输出结果。

导出链接列表

结果格式:

$serp.format('$link\n')

结果示例:

https://www.mobile.de/ru
https://auto.drom.ru/
https://autospot.ru/brands/
https://www.destacar.de/
https://www.autoscout24.de/auto/gebrauchtwagen/bayern/falkenstein/
https://www-autoservice-falkenstein.skoda-auto.de/?e=7
https://auto.ru/
https://www.autohaus-schueler.de/
https://www.avtogermes.ru/sale/
https://falkenstein.seat.de/
...

结果格式:

[% FOREACH item IN serp;
loop.count _ ' - ' _ item.link _ ' - ' _ item.anchor _ ' - ' _ item.snippet _ "\n";
END %]

结果示例:

1 - https://www.mobile.de/ru - mobile.de: 二手车 — 广告 ... - mobile.de/ru 是 mobile.de 的一部分,mobile.de 是德国最大的汽车市场。mobile.de 简化了购车过程。通过简单的搜索和几次点击,您就可以获得市场的全面概览。
2 - https://auto.drom.ru/ - 俄罗斯汽车销售。二手... - 775 361 条汽车销售广告。10,000 卢布起售的新车和二手车。汽车展厅和私人广告。
3 - https://www.destacar.de/ - 按需从德国订购汽车 | ... - Destacar 公司随时准备帮助您在德国寻找、选择、检查和购买汽车。我们将帮助您在德国购买二手车,进行检查和试驾,以便您对汽车状况完全放心。
4 - https://autospot.ru/brands/ - 在莫斯科买车:价格在 ... - ✸ 在莫斯科按参数选车:Autospot 汽车目录中的价格。 ✸ 包含价格和技术特性的汽车目录 - 官方经销商销售。
5 - https://www.autoscout24.de/auto/gebrauchtwagen/bayern/falkenstein/ - Gebrauchtwagen Falkenstein: Auto günstig kaufen - Gebrauchtwagen & Jahreswagen in Falkenstein kaufen und verkaufen bei AutoScout24.de - Europas großem Automarkt » Jetzt finden oder inserieren!
6 - https://www-autoservice-falkenstein.skoda-auto.de/?e=7 - ŠKODA Gebrauchtwagen in Falkenstein | Auto-Service Falkenstein GmbH - ŠKODA Gebrauchtwagen in Falkenstein | Auto-Service Falkenstein GmbH ✔ Günstig finanzieren ✔ Beste ŠKODA Vorführwagen und Jahreswagen ✔ ŠKODA gebraucht kaufen ✔ Probefahrt vereinbaren
7 - https://auto.ru/ - Auto.ru:购买、出售和交换 ... - 本网站根据俄罗斯联邦法律运行,不适用于您所在的地区。继续使用本网站,...
8 - https://www.autohaus-schueler.de/ - Ihr Audi und VW Autohaus Schüler in Falkenstein - Ihr Autohaus Schüler in Falkenstein, Oelsnitz, Plauen & Wilkau-Hasslau - Wir bieten ein großes Angebot an Neu- und Gebrauchtwagen, Audi & VW Service.
...

内置工具 $tools.CSVLine 允许创建正确的表格文档,以便导入 Excel 或 Google 表格。

通用结果格式:

[%  FOREACH item IN p1.serp;
tools.CSVline(item.link, item.anchor, item.snippet);
END %]

文件名:

$datefile.format().csv

起始文本:

链接,锚点,摘要

结果示例:

链接,锚点,摘要
https://www.mobile.de/ru,"mobile.de: 二手车 — 广告...","mobile.de/ru 是 mobile.de 的一部分,mobile.de 是德国最大的汽车市场。mobile.de 简化了购车过程。通过简单的搜索和几次点击,您就可以获得市场的全面概览。"
https://auto.drom.ru/,"俄罗斯汽车销售。二手...","775 361 条汽车销售广告。10,000 卢布起售的新车和二手车。汽车展厅和私人广告。"
https://www.destacar.de/,"按需从德国订购汽车 | ...","Destacar 公司随时准备帮助您在德国寻找、选择、检查和购买汽车。我们将帮助您在德国购买二手车,进行检查和试驾,以便您对汽车状况完全放心。"
https://autospot.ru/brands/,"在莫斯科买车:价格在 ...","✸ 在莫斯科按参数选车:Autospot 汽车目录中的价格。 ✸ 包含价格和技术特性的汽车目录 - 官方经销商销售。"
https://www.autoscout24.de/auto/gebrauchtwagen/bayern/falkenstein/,"Gebrauchtwagen Falkenstein: Auto günstig kaufen","Gebrauchtwagen & Jahreswagen in Falkenstein kaufen und verkaufen bei AutoScout24.de - Europas großem Automarkt » Jetzt finden oder inserieren!"
https://www-autoservice-falkenstein.skoda-auto.de/?e=7,"ŠKODA Gebrauchtwagen in Falkenstein | Auto-Service Falkenstein GmbH","ŠKODA Gebrauchtwagen in Falkenstein | Auto-Service Falkenstein GmbH ✔ Günstig finanzieren ✔ Beste ŠKODA Vorführwagen und Jahreswagen ✔ ŠKODA gebraucht kaufen ✔ Probefahrt vereinbaren"
https://auto.ru/,"Auto.ru:购买、出售和交换 ...","本网站根据俄罗斯联邦法律运行,不适用于您所在的地区。继续使用本网站,..."
https://www.autohaus-schueler.de/,"Ihr Audi und VW Autohaus Schüler in Falkenstein","Ihr Autohaus Schüler in Falkenstein, Oelsnitz, Plauen & Wilkau-Hasslau - Wir bieten ein großes Angebot an Neu- und Gebrauchtwagen, Audi & VW Service."
...
提示

通用结果格式中,使用 Template Toolkit 模板引擎FOREACH 循环中输出 $serp 数组。

在结果文件名中,只需将文件扩展名更改为 csv。

为了使“Prepend text”选项在任务编辑器中可用,需要激活“More options”。 在“Prepend text”中按逗号分隔记录列名,并将第二行留空。

结果格式:

$related.format('$key\n')

结果示例:

test speed
ookla speed test
speed test wifi
internet speed test
run speed test
fast speed test
mbps test
test 2
test match
google speed test
...

以 SQL 格式保存

结果格式:

[%  FOREACH serp;
"INSERT INTO serp VALUES('" _ query _ "', '";
link _ "', '";
anchor _ "')\n";
END %]

结果示例:

    
INSERT INTO serp VALUES('test', 'https://www.speedtest.net/', 'Speedtest by Ookla - The Global Broadband Speed Test')
INSERT INTO serp VALUES('test', 'https://www.merriam-webster.com/dictionary/test', 'TEST Definition & Meaning - Merriam-Webster')
INSERT INTO serp VALUES('test', 'https://englishtest.duolingo.com/', 'Duolingo English Test')
INSERT INTO serp VALUES('test', 'https://link.springer.com/journal/11749', 'Home | TEST | Springer Nature Link')
INSERT INTO serp VALUES('test', 'https://test.io/', 'Home | Test IO')
INSERT INTO serp VALUES('test', 'https://www.spectrum.com/internet/speed-test', 'Spectrum Internet Speed Test: Broadband Internet Speed Check')
INSERT INTO serp VALUES('test', 'https://fast.com/', 'Internet Speed Test | Fast.com')
INSERT INTO serp VALUES('test', 'https://en.wikipedia.org/wiki/Test', 'Test - Wikipedia')
...

将结果导出为 JSON

通用结果格式:

[% IF notFirst;
",\n";
ELSE;
notFirst = 1;
END;

obj = {};
obj.results = [];

FOREACH item IN p1.serp;
obj.results.push({
link = item.link
anchor = item.anchor
snippet = item.snippet
});
END;

obj.json %]

起始文本:

[

结束文本:

]

结果示例:

{"results":[{"link":"https://www.speedtest.net/","snippet":"Use Speed<strong>test</strong> on all your devices with our free desktop and mobile apps.","anchor":"Speedtest by Ookla - The Global Broadband Speed Test"},{"link":"https://www.merriam-webster.com/dictionary/test","snippet":"The meaning of TEST is <strong>a means of testing</strong>. How to use test in a sentence.","anchor":"TEST Definition & Meaning - Merriam-Webster"},{"link":"https://englishtest.duolingo.com/","snippet":"The Duolingo English Test is a fast, affordable online English exam accepted by institutions worldwide. Take it anytime and get results in 2 days","anchor":"Duolingo English Test"},{"link":"https://link.springer.com/journal/11749","snippet":"Journal TEST <strong>focuses on cutting-edge research in all areas of Statistics and Probability with significant theoretical, methodological, and applied impact</strong>. ...","anchor":"Home | TEST | Springer Nature Link"},{"link":"https://test.io/","snippet":"Test IO delivers a full range of web, mobile, and IoT <strong>test</strong>ing, delivered as a service.","anchor":"Home | Test IO"},{"link":"https://www.spectrum.com/internet/speed-test","snippet":"Test your broadband Internet and WiFi speed with the Internet Speed Test. Check your upload and download speeds for your home Internet network.","anchor":"Spectrum Internet Speed Test: Broadband Internet Speed Check"},{"link":"https://fast.com/","snippet":"FAST.com will <strong>test</strong> Internet speed globally on any device (phone, laptop, or smart TV with browser).","anchor":"Internet Speed Test | Fast.com"},{"link":"https://en.wikipedia.org/wiki/Test","snippet":"Look up test, testing, Test, or TEST in Wiktionary, the free dictionary. ... Test (assessment), <strong>an educational assessment intended to measure the respondents&#x27; knowledge or other abilities</strong> ... Test., abbreviation for Testament, referring to the Old Testament and New Testament of the Christian Bible.","anchor":"Test - Wikipedia"},{"link":"https://speed.cloudflare.com/","snippet":"Test your Internet connection. Check your network performance with our Internet speed <strong>test</strong>. Powered by Cloudflare&#x27;s global edge network.","anchor":"Internet Speed Test - Measure Network Performance | Cloudflare"},{"link":"https://testmy.net/","snippet":"TestMy.net is a powerful broadband speed <strong>test</strong> that will <strong>test</strong> your Internet, calculate your transfer rate and output accurate, reliable and easy to understand results. TestMy.net is an independent third party and is not affiliated with your Internet service provider.","anchor":"Internet Speed Test"},{"link":"https://www.livechat.com/typing-speed-test/","snippet":"The faster you type, the faster you communicate with others. With our free typing speed <strong>test</strong>, you can check your WPM and CPM typing scores in a flash!","anchor":"Free Typing Test - Check Your Typing Speed in 60 Seconds | LiveChat ..."},{"link":"https://fiber.google.com/speedtest/","snippet":"Test your current internet speed, and find out how fast your broadband wi-fi handles uploads and downloads. See Google Fiber plan options for faster internet.","anchor":"Internet Speed Test | Check Broadband Speed | Google Fiber"},{"link":"https://zoom.us/test","snippet":"Preview your next Zoom Meeting using out <strong>test</strong> meeting tool to check your settings and display.","anchor":"Join a Test Meeting | Zoom"},{"link":"https://implicit.harvard.edu/implicit/takeatest.html","snippet":"On the next page, you&#x27;ll be asked to select an Implicit Association Test (IAT) from a list of possible topics. We&#x27;ll also ask you (optionally) to report your attitudes or beliefs about these topics and give you some information about yourself. We ask these questions because the IAT can be more valuable if you also describe your own self-understanding of the attitude or stereotype that the IAT measures.","anchor":"Take a Test"},{"link":"https://www.act.org/content/act/en/products-and-services/the-act.html","snippet":"The ACT <strong>test</strong> is a curriculum-based education and career planning tool for high school students that assesses the mastery of college readiness standards","anchor":"The ACT Test for Students | ACT"},{"link":"https://play.google.com/store/apps/details?id=org.zwanoo.android.speedtest&hl=en_US","snippet":"Test your download and upload speeds as well as three measures of latency to check a slow connection or use the app to make sure your network is ready for a gaming session. Use real-world data to find out where mobile network coverage is strong and weak for providers in your area with the Speed<strong>test</strong> Maps tab.","anchor":"Speedtest by Ookla - Apps on Google Play"},{"link":"https://speedtest.xfinity.com/","snippet":"Xfinity Speed Test – You need to enable JavaScript to run this app","anchor":"Xfinity Speed Test - Check Your Internet Speed"},{"link":"https://www.ada.org/education/testing/exams/dental-admission-test-dat","snippet":"Find out how to apply for, prepare for, take, and receive scores for the Dental Admission Test (DAT).","anchor":"Dental Admission Test (DAT) | American Dental Association"},{"link":"https://www.16personalities.com/free-personality-test","snippet":"Take our free personality <strong>test</strong> and discover your personality type in 10 minutes. Get a ‘freakishly accurate’ description of who you are and why you do things the way you do.","anchor":"Free personality test | 16Personalities"},{"link":"https://www.faa.gov/uas/recreational_flyers/knowledge_test_updates","snippet":"The law requires that all recreational flyers pass an aeronautical knowledge and safety <strong>test</strong> and provide proof of passage if asked by law enforcement or FAA personnel. The Recreational UAS Safety Test (TRUST) was developed to meet this requirement. TRUST provides education and <strong>test</strong>ing on important safety and regulatory information.","anchor":"The Recreational UAS Safety Test (TRUST) | Federal Aviation ..."}]}
提示

为了使“Prepend text”和“Append text”选项在任务编辑器中可用,需要激活“More options”。

可选设置

参数名称默认值描述
Serp typeAll决定抓取通用结果 (All)、新闻 (News) 还是视频 (Videos)
Pages count5要抓取的页数(1 到 10)
RegionAll regions选择进行搜索的国家
Display languageEnglish (United States)可以选择搜索结果页面的界面语言,以使爬虫工具中的结果与浏览器中的结果最大程度保持一致
Safe searchModerate可以开启“Safe search”
Search timeAny搜索结果时间(时间相关搜索)
Local resultsOn (auto, from IP)本地搜索,可选值:Off - 关闭,Auto - 根据请求 IP 自动定位,Manual - 使用在 Manual location 中指定的位置
Manual location用于输入精确位置的字段,仅在 Local results = Manual 时使用。位置应以逗号分隔的坐标对形式指定,格式为 纬度,经度,例如:55.780844,37.6572693