‹ 首页

reddit-competitor-analysis-api-skill

@browser-act · 收录于 1 周前 · 上游提交 2 天前

This skill helps users extract structured data from Reddit posts and comments via BrowserAct API. Agent should proactively apply this skill when users express needs like analyzing competitor mentions on Reddit, tracking brand sentiment in Reddit comments, extracting Reddit discussions for market research, finding popular Reddit posts by keywords, monitoring community feedback on specific topics, gathering user reviews from Reddit threads, searching for Reddit posts within a specific date range, sorting Reddit discussions by relevance or hotness, compiling nested Reddit comments for deep analysis, building a structured dataset of Reddit conversations, discovering trending topics in specific subreddits, or monitoring social media activity for specific brands on Reddit.

适合你,如果需要在 Reddit 上追踪竞品和品牌讨论。

/ 下载安装
reddit-competitor-analysis-api-skill.skill双击,或拖进 Claude 桌面版 / Cowork,即完成安装↓ .skill↓ .zip
用别的 agent?下载 .zip 解压,把文件夹放进它的技能目录
Claude Code~/.claude/skills/(项目级 .claude/skills/)
Codex CLI~/.codex/skills/
Cursor自动读取上面两处目录
其他工具见其文档的「skills」目录;两个下载是同一份文件,只是名字不同
/ 通过 npx 安装 校验哈希
npx oh-my-skill add browser-act/skills/reddit-competitor-analysis-api-skill
/ 通过 bash 安装
curl -fsSL https://oh-my-skill.com/install.sh | bash -s -- browser-act/skills/reddit-competitor-analysis-api-skill
/ 已经装过?验证本机副本,不用重装
npx oh-my-skill verify browser-act/skills/reddit-competitor-analysis-api-skill
安装目标可用 --agent / --scope 或 --to 明确指定;省略时只会在唯一已存在的 agent 目录上自动选择,零命中或多命中会停止并提示。content_hash 缺失或不一致均拒装。
4386GitHub stars
~1.4K最小装载
~2.3K含声明引用
~2.3K文本包总量
镜像托管

怎么用

商店整理自技能原文 · 版本 51daea1 · 表述以原文为准
它做什么

安装后,Claude 能通过 BrowserAct API 从 Reddit 提取帖子标题、评论、点赞数等结构化数据,并输出为表格。

什么时候触发

当用户要求分析 Reddit 上的竞品讨论、追踪品牌评论、收集市场调研数据,或指定关键词、日期范围、排序方式时触发。

装好后可以这样说
Claude 会调用 API 提取相关帖子及评论。
Claude 会按参数过滤并输出结构化数据。
技能原文 SKILL.md作者撰写 · MIT · 51daea1

Reddit Competitor Analysis API Skill

📖 Introduction

This skill uses the BrowserAct Reddit Competitor Analysis API template to provide users with a one-stop Reddit data collection service. It can extract full post details and comments from Reddit search results. Just input search keywords and filtering conditions to directly get clean and usable Reddit data.

✨ Features
  1. No hallucinations, ensuring stable and precise data extraction: Pre-set workflows avoid AI generative hallucinations.
  2. No CAPTCHA issues: No need to handle reCAPTCHA or other verification challenges.
  3. No IP access restrictions or geofencing: No need to handle regional IP limitations.
  4. Faster execution: Compared to pure AI-driven browser automation solutions, task execution is faster.
  5. Extremely high cost-effectiveness: Significantly reduces data acquisition costs compared to highly token-consuming AI solutions.
🔑 API Key Guide

Before running, you must check the BROWSERACT_API_KEY environment variable. If it is not set, do not take any other actions; you should request and wait for the user to provide it collaboratively. The Agent must inform the user at this time:

"Since you have not configured the BrowserAct API Key, please go to the BrowserAct Console to get your Key first."
🛠️ Input Parameters

When calling the script, the Agent should flexibly configure the following parameters based on user needs:

  1. Keywords (Search keywords)
  2. Type: string
  3. Description: Search keywords for Reddit posts.
  4. Example: openclaw
  1. Publication_date (Publication date)
  2. Type: string
  3. Description: Filter posts by publication date range.
  4. Options: All time, Past year, Past month, Past week, Today, Past hour
  5. Default: Past week
  1. Post_sort_by (Search sort)
  2. Type: string
  3. Description: Sort Reddit post search results by selected criteria.
  4. Options: Relevance, Hot, Top, New, Comment count
  5. Default: Relevance
  1. Comment_sort_by (Comment sort)
  2. Type: string
  3. Description: Sort extracted comments by.
  4. Options: Best, Top, New, Controversial, Q&A
  5. Default: Best
  1. Data_limit (Comments per post)
  2. Type: number
  3. Description: Maximum number of comments to extract per post.
  4. Default: 10
🚀 Usage (Recommended)

The Agent should execute the following independent script to achieve "one-line command to get results". Note that the script path ./scripts/... is relative to this skill's directory:

# Example invocation
python3 -u ./scripts/reddit_competitor_analysis_api.py "keywords" "publication_date" "post_sort_by" "comment_sort_by" data_limit
⏳ Task Status Monitoring

Since this task involves automated browser operations, it may take a long time (several minutes). The script will continuously output status logs with timestamps (e.g., [14:30:05] Task Status: running) while running. Agent Must Know:

  • While waiting for the script to return results, please keep an eye on the terminal output.
  • As long as the terminal is still outputting new status logs, it means the task is running normally. Please do not mistakenly judge it as a deadlock or unresponsiveness.
  • Only if the status remains unchanged for a long time or the script stops outputting and no result is returned, you can consider triggering the retry mechanism.
🔧 OpenClaw Adaptation Guide

Since BrowserAct tasks may take a long time to run (5-20 minutes), when the Agent executes in the OpenClaw environment, it needs to:

  1. Run in background mode (using JSON parameters for exec tool):
  2. command: "python3 -u ./scripts/reddit_competitor_analysis_api.py ..."
  3. background: true
  4. timeout: 1800
  1. Or increase yieldMs:
  2. command: "python3 -u ./scripts/reddit_competitor_analysis_api.py ..."
  3. yieldMs: 600000
  4. timeout: 1800
  1. Use process poll to monitor:
  2. action: "poll"
  3. sessionId: "xxx"
  4. timeout: 300000
📊 Data Output Description

After successful execution, the script will directly parse and print the results from the API response. The results include:

  • post_title: Full post title
  • publish_time: Post publication time
  • like_count: Number of upvotes on the post
  • comment_count: Total number of comments
  • publish_channel: Subreddit where the post was published
  • comment_author: Username of the commenter
  • comment_time_utc: Comment timestamp
  • comments: Full comment text
  • comment_upvotes: Number of upvotes on the comment
  • comment_level: Nesting level of the comment
  • comment_author_url: Link to the commenter's profile
  • reply_to: Parent comment or post being replied to
⚠️ Error Handling & Retry

During the execution of the script, if an error occurs (such as network fluctuation or task failure), the Agent should follow this logic:

  1. Check the output content:
  2. If the output contains "Invalid authorization", it means the API Key is invalid or expired. At this time, do not retry, but guide the user to recheck and provide the correct API Key.
  3. If the output does not contain "Invalid authorization" but the task execution fails (for example, the output starts with Error: or the returned result is empty), the Agent should automatically try to execute the script again.
  1. Retry limit:
  2. Automatic retry is limited to one time. If the second attempt still fails, stop retrying and report the specific error message to the user.
按 MIT 许可原样转载,未经改动 · 在 GitHub 查看 →

评论

登录即可评论;带「已验证安装」的,是发布者名下有本店的安装或持有记录。