fix(skills): improve summarize selection
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: summarize
|
name: summarize
|
||||||
description: Summarize URLs or files with the summarize CLI (web, PDFs, images, audio, YouTube).
|
description: Summarize or extract text/transcripts from URLs, podcasts, and local files (great fallback for “transcribe this YouTube/video”).
|
||||||
homepage: https://summarize.sh
|
homepage: https://summarize.sh
|
||||||
metadata: {"clawdbot":{"emoji":"🧾","requires":{"bins":["summarize"]},"install":[{"id":"brew","kind":"brew","formula":"steipete/tap/summarize","bins":["summarize"],"label":"Install summarize (brew)"}]}}
|
metadata: {"clawdbot":{"emoji":"🧾","requires":{"bins":["summarize"]},"install":[{"id":"brew","kind":"brew","formula":"steipete/tap/summarize","bins":["summarize"],"label":"Install summarize (brew)"}]}}
|
||||||
---
|
---
|
||||||
@@ -9,6 +9,14 @@ metadata: {"clawdbot":{"emoji":"🧾","requires":{"bins":["summarize"]},"install
|
|||||||
|
|
||||||
Fast CLI to summarize URLs, local files, and YouTube links.
|
Fast CLI to summarize URLs, local files, and YouTube links.
|
||||||
|
|
||||||
|
## When to use (trigger phrases)
|
||||||
|
|
||||||
|
Use this skill immediately when the user asks any of:
|
||||||
|
- “use summarize.sh”
|
||||||
|
- “what’s this link/video about?”
|
||||||
|
- “summarize this URL/article”
|
||||||
|
- “transcribe this YouTube/video” (best-effort transcript extraction; no `yt-dlp` needed)
|
||||||
|
|
||||||
## Quick start
|
## Quick start
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@@ -17,6 +25,16 @@ summarize "/path/to/file.pdf" --model google/gemini-3-flash-preview
|
|||||||
summarize "https://youtu.be/dQw4w9WgXcQ" --youtube auto
|
summarize "https://youtu.be/dQw4w9WgXcQ" --youtube auto
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## YouTube: summary vs transcript
|
||||||
|
|
||||||
|
Best-effort transcript (URLs only):
|
||||||
|
|
||||||
|
```bash
|
||||||
|
summarize "https://youtu.be/dQw4w9WgXcQ" --youtube auto --extract-only
|
||||||
|
```
|
||||||
|
|
||||||
|
If the user asked for a transcript but it’s huge, return a tight summary first, then ask which section/time range to expand.
|
||||||
|
|
||||||
## Model + keys
|
## Model + keys
|
||||||
|
|
||||||
Set the API key for your chosen provider:
|
Set the API key for your chosen provider:
|
||||||
|
|||||||
19
src/agents/skills.summarize-skill-description.test.ts
Normal file
19
src/agents/skills.summarize-skill-description.test.ts
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
import fs from "node:fs";
|
||||||
|
import path from "node:path";
|
||||||
|
|
||||||
|
import { describe, expect, it } from "vitest";
|
||||||
|
|
||||||
|
import { parseFrontmatter } from "./skills/frontmatter.js";
|
||||||
|
|
||||||
|
describe("skills/summarize frontmatter", () => {
|
||||||
|
it("mentions podcasts, local files, and transcription use cases", () => {
|
||||||
|
const skillPath = path.join(process.cwd(), "skills", "summarize", "SKILL.md");
|
||||||
|
const raw = fs.readFileSync(skillPath, "utf-8");
|
||||||
|
const frontmatter = parseFrontmatter(raw);
|
||||||
|
const description = frontmatter.description ?? "";
|
||||||
|
expect(description.toLowerCase()).toContain("transcrib");
|
||||||
|
expect(description.toLowerCase()).toContain("podcast");
|
||||||
|
expect(description.toLowerCase()).toContain("local files");
|
||||||
|
expect(description).not.toContain("summarize.sh");
|
||||||
|
});
|
||||||
|
});
|
||||||
Reference in New Issue
Block a user