Orchestrate the full pipeline: NotebookLM source ingestion → structured SKILL.md extraction → write to skills directory → validate → test → iterate.
Before the pipeline, verify NotebookLM is authenticated:
notebooklm status || notebooklm login
If notebooklm login opens a browser, tell user to complete Google OAuth and press ENTER in their terminal.
```bash
notebooklm create "Skill: {skill-name}" --json
```
Parse the notebook id from JSON output.
> "What sources should this skill be based on? Give me URLs, local file paths, YouTube links — anything high-quality and specific to this domain."
If the user doesn't have sources ready, suggest:
-n for all subsequent commands):```bash
notebooklm source add "https://..." -n
notebooklm source add ./local-file.pdf -n
```
Capture each source_id.
```bash
notebooklm source wait
```
For multiple sources, wait them all. If any source fails indexing (exit code 1), log a warning but continue with remaining sources.
Read references/skill-extraction-prompt.md. Replace {USER_INTENT} with the user's original request.
```bash
notebooklm ask "{extraction_prompt}" -n
```
```bash
echo '
```
Or save the JSON to a temp file first, then pipe.
--- YAML frontmattername: and description: fieldsIf validation fails, re-prompt NotebookLM with more specific instructions.
```bash
mkdir -p ~/.claude/skills/{skill-name}
```
Move the parsed output to ~/.claude/skills/{skill-name}/SKILL.md
Invoke skill-creator with: "Validate the skill at ~/.claude/skills/{skill-name}/ and fix any issues found. Run package_skill.py to check for errors."
Invoke skill-vetter with: "Review the skill at ~/.claude/skills/{skill-name}/ for security issues."
```bash
notebooklm ask "The SKILL.md generated earlier has this issue: {failure}. Based on the sources, rewrite it to fix this. Output complete corrected SKILL.md in a markdown code block." -n
```
| Situation | Action |
|---|---|
| ----------- | -------- |
| NotebookLM auth expired | Run notebooklm login, retry |
| Source indexing failed | Skip that source, warn user, continue |
| Extraction prompt returned empty | Check if sources are indexed (status=ready), re-query with --new flag |
| Generated SKILL.md fails validation | Send failure description back to NB for rewrite (Phase 4 iteration) |
| NB rate limited | Wait 5-10 min, retry once |
Remind users:
When the skill passes testing, report:
~/.claude/skills/{name}/)共 1 个版本
暂无安全检测报告