Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
N
News Hub Skills
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Back End
News Hub Skills
Commits
a5e2bf93
Commit
a5e2bf93
authored
Sep 08, 2026
by
谢宇轩
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: add ft source
parent
89df597f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
0 deletions
+16
-0
ft.nhsource.json
skills/news-harvester/bundles/ft.nhsource.json
+16
-0
No files found.
skills/news-harvester/bundles/ft.nhsource.json
0 → 100644
View file @
a5e2bf93
{
"format"
:
"news-harvester-source"
,
"version"
:
1
,
"exportedAt"
:
"2026-09-08T07:28:27.604Z"
,
"source"
:
{
"id"
:
"ft"
,
"name"
:
"金融时报"
,
"homepageUrl"
:
"https://www.ft.com/news-feed"
,
"method"
:
"browser"
,
"vaultFolder"
:
"金融时报"
},
"files"
:
{
"helpers/ft.md"
:
"---
\n
source: ft
\n
listSelector:
\"
div.o-teaser__heading
\"\n
linkSelector: 'a[href]'
\n
urlPattern: 'www
\\
.ft
\\
.com/content/.+'
\n
excludeUrlPattern: null
\n
scrollSteps: 3
\n
scrollWaitMs: 2000
\n
waitMs: 15000
\n
# ── 翻页(可选)── 站点把文章列表分多页时启用。两种模式互斥,最多配一个。
\n
# 配了翻页字段后还需在 config.json 该 source 下设 paginate: true 才生效。
\n
pageUrlTemplate: 'https://www.ft.com/news-feed?page={page}'
\n
pageStart: 2
\n
maxPages: 5
\n
pageWaitMs: null
\n
bodySelectors:
\n
- '[data-testid^=
\"
paragraph
\"
]'
\n
- '[class*=
\"
articleBodyContent
\"
] p'
\n
- '[class*=
\"
article-body
\"
] p'
\n
- 'article p'
\n
bodyMinParagraphs: 3
\n
dateSelector: 'time[datetime]'
\n
authorSelector: '[rel=
\"
author
\"
], [class*=
\"
author
\"
] a'
\n
# Scope to the article-body container (e.g. '[class*=
\"
ArticleBody
\"
] img, article img')
\n
# so bottom-of-page
\"
recommended articles
\"
thumbnails aren't downloaded into assets/.
\n
imageSelector: 'img'
\n
imageMinWidth: 200
\n
excludeImage:
\n
- logo
\n
- icon
\n
- avatar
\n
- profile
\n
# excludeImageSelector drops imgs whose ancestor matches — use for
\n
#
\"
recommended/related articles
\"
thumbnails sharing the hero image's CDN host.
\n
# excludeImageSelector: '[class*=
\"
RelatedArticle
\"
], [class*=
\"
RecommendedArticle
\"
]'
\n
titleStripSuffix: ''
\n
maxBodyChars: 15000
\n
---
\n
# 金融时报 抓取备忘
\n\n
- 主文章流容器 `div.o-teaser__heading` 实测 25 个候选链接(inspect 自动生成)。
\n
- urlPattern `www
\\
.ft
\\
.com/content/.+` 由样本 URL 推断,如 preview 漏抓/误抓请手编收紧。
\n
- 首屏可能不全,scrollSteps=3 触发懒加载;反爬严重时调高 waitMs。
\n
- 验证: node scripts/preview.js --url https://www.ft.com/news-feed --recipe helpers/ft.md --count 3(链接为真实文章且 charCount>500 即通过)"
,
"helpers/ft.fixtures.json"
:
"{
\n
\"
articles
\"
: [
\n
\"
https://www.ft.com/content/0815cd34-bf4c-4771-8bf5-710eff286763
\"
,
\n
\"
https://www.ft.com/content/1f71d2d0-d2e2-46da-a96f-99d20936223e
\"
,
\n
\"
https://www.ft.com/content/0bdd8292-efaa-4329-b41e-d81a5063c4c0
\"\n
],
\n
\"
sections
\"
: [
\n
\"
https://www.ft.com/world
\"
,
\n
\"
https://www.ft.com/technology
\"\n
],
\n
\"
minLinks
\"
: 15
\n
}
\n
"
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment