Communitygithub.com

Varnan-Tech/opendirectory

聚合 RSS 订阅源,使用 Gemini 综合生成上周热门文章,并将新闻摘要发布到 Ghost CMS。可选输出格式化 Markdown,适用于 Substack 或其他平台。

opendirectory 是什么?

该技能是一种 AI 代理工具,专为自动化新闻摘要生成和发布而设计。它从配置的 RSS 订阅源中提取文章,过滤过去一周的内容,然后利用 Google 的 Gemini 模型合成一篇连贯的摘要。用户可以通过 Ghost CMS 的 API 直接发布为草稿或已发布状态,也可以仅输出 HTML、Markdown 或纯文本格式,用于 Substack、Hashnode 或其他平台。该技能内置了严格的写作风格指南,禁止使用某些流行语,并要求所有声明都必须有来源依据,以确保摘要内容准确、简洁,适合专业受众。它主要支持 Claude Code、Cursor 或 Codex 等 AI 代理平台,作为文件系统上的本地技能,通过执行 Node.js 脚本来获取订阅源、进行格式验证和发布操作。

兼容平台✓Claude Code~Codex CLI~Cursor✓Gemini CLI
npx skills add https://github.com/Varnan-Tech/opendirectory/tree/main/skills/newsletter-digest

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

新闻摘要

从 RSS 订阅源聚合内容,使用 Gemini 综合生成一周热门文章,并将摘要发布到 Ghost CMS。支持每周摘要、主题聚焦和精选推荐三种格式。

写作风格

适用于所有生成的摘要内容:

  • 仅使用主动语态
  • 短句,每句只表达一个观点
  • 不要使用长破折号 —— 改用句号或逗号
  • 不要使用分号
  • 不要在最终新闻正文中使用 Markdown 或星号
  • 不要使用标签

禁用词汇 —— 摘要中不得使用以下任何词汇: incredible, amazing, leveraging, synergize, game-changing, game changer, delve, harness, unlock, groundbreaking, cutting-edge, remarkable, paradigm, revolutionize, disruptive, transformative, thrilled, excited to share, powerful, innovative, comprehensive, actionable, crucial, vital, pivotal, elucidate, utilize, dive deep, tapestry, illuminate, revolutionize

关键规则

摘要中的每一个声明、统计数据和总结都必须来自获取的文章。切勿编造数据点、引用或事实。如果源文章没有有意义的内容,请跳过它。


步骤 1:检查设置

1a. 验证订阅源已配置

检查技能目录中是否存在 feeds.json:

ls /Users/ksd/Desktop/Varnan_skills/newsletter-digest/feeds.json 2>/dev/null

如果缺失,询问用户:“我应该监控哪些 RSS 订阅源?请分享一个 URL 列表,我将为您创建 feeds.json。”

格式如下:

[
  { "url": "https://example.com/feed", "name": "Source Name" },
  { "url": "https://another.com/rss", "name": "Another Source" }
]

1b. 验证所需的环境变量

检查以下变量是否已设置:

  • GEMINI_API_KEY(必需):用于合成
  • GHOST_URL 和 GHOST_ADMIN_KEY(发布到 Ghost 时需要,仅输出时可省略)

如果缺少 GEMINI_API_KEY,请停止并让用户设置它。

GHOST 配置是可选的。如果未设置,该技能将只输出格式化的 Markdown,而不进行发布。

1c. 验证脚本依赖项

ls /Users/ksd/Desktop/Varnan_skills/newsletter-digest/node_modules 2>/dev/null | head -1

如果缺失:

cd /Users/ksd/Desktop/Varnan_skills/newsletter-digest && npm install

步骤 2:获取并解析订阅源

运行获取脚本:

node /Users/ksd/Desktop/Varnan_skills/newsletter-digest/scripts/fetch-feeds.js

该脚本:

  • 读取 feeds.json 中的订阅源列表
  • 使用 rss-parser 获取每个订阅源
  • 过滤过去 7 天内发布的项目
  • 按 URL 去重
  • 按发布日期从新到旧排序
  • 将结果保存到 /tmp/newsletter-digest-articles.json

如果脚本在特定订阅源上出错,它将记录一条警告并继续。一个坏掉的订阅源不会停止整个运行。

脚本完成后,验证输出:

node -e "
const fs = require('fs');
const data = JSON.parse(fs.readFileSync('/tmp/newsletter-digest-articles.json', 'utf8'));
console.log('文章总数:', data.articles.length);
console.log('来自订阅源:', data.feedsSummary.map(f => f.name + ': ' + f.count).join(', '));
console.log('日期范围:', data.dateRange.from, '至', data.dateRange.to);
"

如果找到的文章少于 3 篇,请警告用户,并询问是否要将日期范围扩展到 14 天。将 --days=14 参数传递给脚本以扩大窗口。


步骤 3:阅读格式规则

在生成任何内容之前,请完整阅读 references/digest-format.md。记住:

  • 三种摘要格式(每周摘要、主题深入分析、精选推荐)以及何时使用每种格式
  • 每种格式的章节结构和长度要求
  • 归属规则(每个声明都链接到来源)
  • 语气和风格指南

阅读 references/output-template.md,并选择与所请求格式相匹配的模板。

如果用户未指定格式,默认为“每周摘要”。


步骤 4:使用 Gemini 合成

读取 /tmp/newsletter-digest-articles.json 并构建合成提示。

提示结构:

你是一位新闻编辑,正在撰写本周热门文章的摘要。

来源(仅使用这些——不要编造事实):
[对于每篇文章:标题 | 来源 | 日期 | 摘要]

任务:
撰写一篇 [格式] 摘要,遵循以下结构:
[粘贴来自 references/output-template.md 的选中模板]

规则:
- 每一个声明、统计数据和引用都必须来自上述来源
- 使用主动语态、短句,允许使用缩写
- 不要使用:incredible, amazing, leveraging, game-changing, delve, groundbreaking, cutting-edge, revolutionize
- 不要使用长破折号,不要使用分号,不要使用标签
- 在每个主要声明后包含 [Source: Name](URL) 归属
- 输出纯文本,仅使用 HTML 标题标签(不要使用 Markdown 星号)

使用此提示调用 Gemini。目标模型:gemini-2.0-flash 或最新的可用版本。

如果响应包含任何禁用词汇或源文章中不存在的编造统计数据,请使用更严格的提示重新生成。


步骤 5:自我质量检查

在展示之前,运行每项检查。首先修复违规项。

  • 每一个声明、统计数据和引用都能追溯到源文章
  • 任何部分中都没有禁用词汇
  • 文本中没有长破折号
  • 文本中没有分号
  • 每个部分至少包含一个带 URL 的来源归属
  • 字数在格式的目标范围内(参见 references/digest-format.md)
  • 没有部分重复讲述同一个故事
  • 标题是具体的(包含日期范围或期号,而不仅仅是“每周摘要”)
  • HTML 输出是有效的(如果发布到 Ghost,则没有未闭合的标签)

在向用户展示之前,修复所有违规项。


步骤 6:格式化并预览

按以下顺序向用户呈现摘要:

  1. 标题 —— 期号日期范围或主题
  2. 摘要内容 —— 完整的格式化文本
  3. 来源列表 —— 使用的所有文章及其 URL
  4. 字数和文章数

询问:“准备以草稿形式发布到 Ghost,还是想先编辑?”


步骤 7:发布到 Ghost 或输出

如果设置了 GHOST_URL 和 GHOST_ADMIN_KEY 且用户确认:

运行发布脚本:

node /Users/ksd/Desktop/Varnan_skills/newsletter-digest/scripts/ghost-publish.js \
  --title "摘要标题" \
  --status "draft"

该脚本读取 /tmp/newsletter-digest-output.json(由代理在步骤 6 中写入)并发布到 Ghost。

发布后,脚本返回 Ghost 管理面板中草稿的 URL。向用户呈现:“草稿已保存至:[URL]。请在 Ghost 控制面板中查看并发布。”

如果用户希望立即发布,请将 --status "published" 传递给脚本。

如果未配置 Ghost 或用户要求“仅输出”:

以三种格式输出摘要:

  1. HTML —— 可直接粘贴到任何 CMS 中
  2. Markdown —— 适用于 Substack、Notion 或 Hashnode
  3. 纯文本 —— 适用于电子邮件客户端

添加:“Substack 不提供公共 API。请直接将 Markdown 版本复制到您的 Substack 编辑器中。”


关于 Substack 的说明

Substack 没有公共 API。在没有逆向工程其内部端点的情况下无法实现程序化发布,而这违反了他们的使用条款。本技能输出一份格式化的 Markdown 摘要,可直接粘贴到 Substack 编辑器中。这是正确的方法。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

Varnan-Tech/opendirectory

Use when the user asks to generate a blog cover image, thumbnail, or article header. Automatically uses modern typography, brand logos, and Google Search grounding to create beautiful 16:9 images with Gemini 3.1 Flash Image Preview.

Varnan-Tech/opendirectory

World-class brand strategist and naming expert. Uses an interrogation-led discovery phase to extract your brand's DNA, then applies scientific naming frameworks (Phonosemantics) and automated multi-TLD domain checking.

Varnan-Tech/opendirectory

Use when the user asks to generate or update a project's CLAUDE or AGENTS context file from a codebase scan. Writes a focused file under 100 lines containing only the non-obvious build commands, conventions, and gotchas Claude Code needs.

Varnan-Tech/opendirectory

Use when the user wants to verify cold emails, enrich a lead list, or autonomously guess email addresses from a CSV using ValidEmail.co or the open-source Reacher engine.

Varnan-Tech/opendirectory

Competitive intelligence orchestrator tracking companies across 8+ platforms (GitHub, Twitter, Reddit, HN, PH, YC Jobs) with heat scores and AI briefings.

Varnan-Tech/opendirectory

Give it your product URL or description. It finds your top 5 competitors, runs three-track PR research across all of them (editorial, podcasts, communities), identifies which channels appear most frequently, looks up the journalist or host for each, and returns a tiered outreach list with story angles and ready-to-send cold pitch drafts tailored to your product. Use when asked to find PR opportunities, discover where competitors got featured, build a media outreach list, find which journalists cover my space, or get pitch templates for press coverage.

Varnan-Tech/opendirectory

Generate high-converting, deep-dive growth case studies in MDX format. Use this skill when asked to write a case study or blog post about a company's growth, tech stack, or product-led strategy. It handles the full pipeline (researching the company via Tavily, generating a 16:9 cover image, quality checking the draft, uploading assets to cloud storage, and pushing directly to the target repository).

Varnan-Tech/opendirectory

Scans your project for outdated npm, pip, Cargo, Go, or Ruby packages. Runs a CVE security audit. Fetches changelogs, summarizes breaking changes with Gemini, and opens one PR per risk group (patch, minor, major). Includes Diagnosis Mode for install conflicts. Use when asked to update dependencies, check for outdated packages, open dependency PRs, scan for package updates, audit for CVEs, or flag breaking changes in upgrades. Trigger when a user says "check for outdated packages", "update my dependencies", "open PRs for dependency updates", "scan for CVEs", or "which packages need upgrading".

Varnan-Tech/opendirectory

Generates and updates README.md and API reference docs by reading your codebase's functions, routes, types, schemas, and architecture. Uses graphify to build a knowledge graph first, then writes accurate docs from it. Use when asked to write docs, generate a README, document an API, update stale docs, create an API reference from code, add an architecture section, or document a project in any language. Trigger when a user says their docs are missing, outdated, or wants to document their codebase without writing it manually.

Varnan-Tech/opendirectory

Evaluates expired domain candidates against a target niche, scores them by topical relevance, historical activity level, and history cleanliness, then outputs a ranked shortlist with explainable reasoning and risk flags.

Varnan-Tech/opendirectory

Brutally honest developer-experience audit for a GitHub repo. Scores 10 DX dimensions (time-to-first-success, README clarity, visual proof, install, quick-start, docs, examples, community, trust, marketing), writes a shareable roast in the requested tone (brutal/honest/kind), produces a prioritized action plan ranked by impact × effort, and sketches an ideal README. Trigger when user says "roast my repo", "audit my README", "dx audit", "developer experience review", "score my GitHub project", "before launch checklist", or "make my repo shareable".

Varnan-Tech/opendirectory

Drafts and designs a complete HTML email newsletter from a topic or content brief. Outputs paste-ready HTML for Loops, Mailchimp, Beehiiv, Resend, or any standard email platform. Includes subject line options and plain-text fallback. Trigger when a user says "write a newsletter", "draft an email newsletter", "create an HTML email", "design an email for my subscribers", or "write a newsletter about [topic]".

Varnan-Tech/opendirectory

Takes a GitHub PR URL or the current branch and writes a plain-English explanation of what it does and why, then posts it as a PR comment. Use when asked to explain a PR, summarize a pull request, write a plain-English description of a PR, add a summary comment to a PR, or understand what a PR changes. Trigger when a user says "explain this PR", "summarize this pull request", "what does this PR do", "add a comment explaining the PR", or shares a GitHub PR URL and asks what it does.

Varnan-Tech/opendirectory

Audit how often LLMs recommend your brand vs competitors and generate a GEO action plan.

Varnan-Tech/opendirectory

Takes a competitor's public GitHub repo URL, fetches their open issues via the GitHub REST API, filters noise locally, clusters issues into 6 demand categories, computes a demand score per issue and per cluster, and outputs a ranked demand gap report with a GTM messaging brief. Use when asked to scan a competitor's GitHub issues, find what their users are begging for, turn GitHub complaints into product positioning, identify competitor feature gaps, or generate messaging from real user demand. Trigger when a user says "scan competitor issues", "what are users asking for on X repo", "find demand gaps in Y", "turn GitHub issues into messaging", or "what should I build based on competitor complaints".

Varnan-Tech/opendirectory

Find recurring confusion in your repo's GitHub Discussions, rank it by urgency, and draft the actual docs fixes and content angles — with verbatim community quotes and source links as evidence.

Varnan-Tech/opendirectory

SEO keyword research workflow for blog generation using Google Trends data. Use when writing blog posts, planning content calendars, or optimizing articles for search engines. Finds breakout keywords, builds content structure, and generates SEO-optimized blog outlines targeting tech and developer audiences.

Varnan-Tech/opendirectory

Generates a professionally designed case study PDF for B2B SaaS sales and marketing. Supports 7 page layouts, 9 style presets, 1-4 page output. Trigger when user says "create a case study", "write a customer story", "make a case study PDF", "design a success story", "turn this customer win into a PDF".

Varnan-Tech/opendirectory

Generates data visualization charts (bar, line, area, pie, doughnut, scatter, radar, treemap) as PNG using Apache ECharts v6. 1080×1080px default, 5 style presets, highlight annotations. Trigger when user says "create a chart", "visualize data", "make a bar chart", "line graph", "pie chart", "data visualization", "chart this data", "plot", "graph", or "visualize these numbers".

Varnan-Tech/opendirectory

Fetches low-star App Store and Google Play reviews, clusters them into broken-promise patterns, and generates a ranked copy brief with positioning opportunities.

相关技能