manus-skills/.kortix/opencode/skills/data/scrapling/templates/parse_only.py
zhukang 1c7abd81d1 All 310 Manus skill-hub community skills as a Kortix marketplace registry
- 310 registry:skill items, 1528 files, 7 categories (hub tags)
- registry.json generated by @kortix/registry buildRegistry
- nested SKILL.md in sn-da-* renamed SUBSKILL.md (no phantom skills)
- provenance + licenses: SOURCES.md
2026-09-15 13:37:20 +08:00

16 lines
488 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/usr/bin/env python3
"""纯 HTML 解析模板(不需要 fetchers 依赖)
用途: 已有 HTML 内容(来自 WebFetch/文件/API),只需解析提取
替换: HTML_SOURCE, BASE_URL, CSS_SELECTOR
"""
from scrapling.parser import Selector
HTML_SOURCE = """{{HTML}}"""
# 或从文件读取: HTML_SOURCE = open('page.html').read()
page = Selector(HTML_SOURCE, url='{{BASE_URL}}')
results = page.css('{{CSS_SELECTOR}}')
for item in results:
print(item.get_all_text(strip=True))