osborn 0.5.3 → 0.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/.claude/settings.local.json +9 -0
  2. package/.claude/skills/markdown-to-pdf/SKILL.md +29 -0
  3. package/.claude/skills/pdf-to-markdown/SKILL.md +28 -0
  4. package/.claude/skills/playwright-browser/SKILL.md +75 -0
  5. package/.claude/skills/youtube-transcript/SKILL.md +24 -0
  6. package/dist/claude-llm.d.ts +29 -1
  7. package/dist/claude-llm.js +334 -78
  8. package/dist/config.d.ts +5 -1
  9. package/dist/config.js +4 -1
  10. package/dist/fast-brain.d.ts +70 -16
  11. package/dist/fast-brain.js +662 -99
  12. package/dist/index-3-2-26-legacy.d.ts +1 -0
  13. package/dist/index-3-2-26-legacy.js +2233 -0
  14. package/dist/index.js +752 -423
  15. package/dist/jsonl-search.d.ts +66 -0
  16. package/dist/jsonl-search.js +274 -0
  17. package/dist/leagcyprompts2.d.ts +0 -0
  18. package/dist/leagcyprompts2.js +573 -0
  19. package/dist/pipeline-direct-llm.d.ts +77 -0
  20. package/dist/pipeline-direct-llm.js +216 -0
  21. package/dist/pipeline-fastbrain.d.ts +45 -0
  22. package/dist/pipeline-fastbrain.js +367 -0
  23. package/dist/prompts-2-25-26.d.ts +0 -0
  24. package/dist/prompts-2-25-26.js +518 -0
  25. package/dist/prompts-3-2-26.d.ts +78 -0
  26. package/dist/prompts-3-2-26.js +1319 -0
  27. package/dist/prompts.d.ts +83 -12
  28. package/dist/prompts.js +1991 -588
  29. package/dist/session-access.d.ts +24 -0
  30. package/dist/session-access.js +74 -0
  31. package/dist/summary-index.d.ts +87 -0
  32. package/dist/summary-index.js +570 -0
  33. package/dist/turn-detector-shim.d.ts +24 -0
  34. package/dist/turn-detector-shim.js +83 -0
  35. package/dist/voice-io.d.ts +9 -3
  36. package/dist/voice-io.js +39 -20
  37. package/package.json +13 -10
@@ -0,0 +1,9 @@
1
+ {
2
+ "permissions": {
3
+ "allow": [
4
+ "Bash(ps:*)",
5
+ "Bash(osascript:*)",
6
+ "Bash(curl -s http://localhost:3000)"
7
+ ]
8
+ }
9
+ }
@@ -0,0 +1,29 @@
1
+ # Skill: Markdown to PDF
2
+
3
+ Export Markdown documents as formatted PDF files.
4
+
5
+ ## When to use
6
+ When the user wants to create a PDF from a Markdown file, spec, or research findings.
7
+
8
+ ## How to execute
9
+
10
+ Option 1 — Using md-to-pdf (best quality):
11
+ ```bash
12
+ npx --yes md-to-pdf "<MARKDOWN_PATH>"
13
+ ```
14
+ This creates a PDF alongside the source file with the same name.
15
+
16
+ Option 2 — Using pandoc (if available):
17
+ ```bash
18
+ pandoc "<MARKDOWN_PATH>" -o "<OUTPUT_PATH>.pdf" --pdf-engine=wkhtmltopdf
19
+ ```
20
+
21
+ Option 3 — Using markdown-pdf:
22
+ ```bash
23
+ npx --yes markdown-pdf "<MARKDOWN_PATH>" -o "<OUTPUT_PATH>.pdf"
24
+ ```
25
+
26
+ ## Output
27
+ - Save the PDF to the session workspace (e.g., `library/{name}.pdf`)
28
+ - Confirm the output path and file size to the user
29
+ - If the source is spec.md, name the output `spec-export.pdf`
@@ -0,0 +1,28 @@
1
+ # Skill: PDF to Markdown
2
+
3
+ Convert PDF documents to readable Markdown text.
4
+
5
+ ## When to use
6
+ When the user provides a PDF file path and wants to read, search, or work with its contents.
7
+
8
+ ## How to execute
9
+
10
+ Option 1 — Using the built-in Read tool:
11
+ The Read tool can directly read PDF files. Use `pages` parameter for large PDFs (max 20 pages per request).
12
+
13
+ Option 2 — Full extraction via CLI (for better formatting or batch processing):
14
+ ```bash
15
+ npx --yes pdf-parse-cli "<PDF_PATH>"
16
+ ```
17
+
18
+ Option 3 — Using pdftotext (if available):
19
+ ```bash
20
+ pdftotext -layout "<PDF_PATH>" -
21
+ ```
22
+
23
+ ## Output
24
+ Save the converted content to the session workspace as `library/{filename}.md` with:
25
+ - Document title and source path at the top
26
+ - Preserved heading structure where detectable
27
+ - Tables converted to Markdown tables where possible
28
+ - Page numbers as section markers
@@ -0,0 +1,75 @@
1
+ # Skill: Playwright Browser Automation
2
+
3
+ Automate web browser interactions — navigate pages, click buttons, fill forms, take screenshots, and extract content.
4
+
5
+ ## When to use
6
+ - Navigate to a URL and interact with it
7
+ - Click buttons or links by their text or role
8
+ - Fill form fields and submit data
9
+ - Take screenshots of web pages
10
+ - Extract text or structured data from pages
11
+ - Automate multi-step web workflows (e.g. join a room, test a UI flow)
12
+
13
+ ## How to execute
14
+
15
+ Uses `@playwright/cli` via npx — no global install needed. Token-efficient: uses element references (e.g. `e15`) instead of pixel coordinates.
16
+
17
+ ### First time only — install browser binaries
18
+ ```bash
19
+ npx playwright install chromium
20
+ ```
21
+
22
+ ### Step 1 — Open a URL
23
+ ```bash
24
+ npx @playwright/cli open https://localhost:3000
25
+ ```
26
+
27
+ ### Step 2 — Get page structure and element references
28
+ ```bash
29
+ npx @playwright/cli snapshot
30
+ ```
31
+ Returns an accessibility tree with element IDs like e1, e2, e15. Use these in subsequent commands.
32
+
33
+ ### Step 3 — Interact with elements
34
+ ```bash
35
+ npx @playwright/cli click e15
36
+ npx @playwright/cli fill e3 "some text"
37
+ npx @playwright/cli press e3 Enter
38
+ npx @playwright/cli select e7 "optionValue"
39
+ npx @playwright/cli check e9
40
+ npx @playwright/cli hover e12
41
+ ```
42
+
43
+ ### Take a screenshot
44
+ ```bash
45
+ npx @playwright/cli screenshot --path=/tmp/page.png
46
+ ```
47
+
48
+ ### Close the browser
49
+ ```bash
50
+ npx @playwright/cli close
51
+ ```
52
+
53
+ ### Named sessions (persistent state across commands)
54
+ ```bash
55
+ npx @playwright/cli -s=myflow open https://localhost:3000
56
+ npx @playwright/cli -s=myflow snapshot
57
+ npx @playwright/cli -s=myflow fill e3 "abc123"
58
+ npx @playwright/cli -s=myflow click e5
59
+ npx @playwright/cli -s=myflow close
60
+ ```
61
+
62
+ ## Complete example — join Osborn voice room
63
+ ```bash
64
+ npx @playwright/cli open http://localhost:3000
65
+ npx @playwright/cli snapshot
66
+ npx @playwright/cli fill e3 "abc123"
67
+ npx @playwright/cli click e4
68
+ npx @playwright/cli screenshot --path=/tmp/osborn-joined.png
69
+ npx @playwright/cli close
70
+ ```
71
+
72
+ ## Notes
73
+ - Runs headless by default. Add --headed to see the browser window.
74
+ - Install browsers first if needed: npx playwright install chromium
75
+ - Element IDs are session-scoped — run snapshot again after page changes
@@ -0,0 +1,24 @@
1
+ # Skill: YouTube Transcript
2
+
3
+ Fetch and save transcripts from YouTube videos.
4
+
5
+ ## When to use
6
+ When the user asks to get a transcript, subtitles, captions, or summary from a YouTube video URL.
7
+
8
+ ## How to execute
9
+
10
+ yt-dlp is installed on this system. Use this exact command:
11
+
12
+ ```bash
13
+ yt-dlp --skip-download --write-auto-sub --sub-lang en --convert-subs srt -o "/tmp/yt-%(id)s" "<VIDEO_URL>"
14
+ ```
15
+
16
+ This downloads auto-generated English subtitles as an SRT file to /tmp/yt-{video-id}.en.srt
17
+
18
+ Then read the SRT file and strip the timing markers to get clean transcript text.
19
+
20
+ ## Output
21
+ Save the cleaned transcript to the session workspace as `library/youtube-{video-id}-transcript.md` with:
22
+ - Video title and URL at the top
23
+ - Cleaned transcript text (strip SRT timing markers and duplicate lines)
24
+ - Key timestamps preserved as section markers if meaningful breaks exist
@@ -11,6 +11,7 @@ import { type McpServerConfig } from '@anthropic-ai/claude-agent-sdk';
11
11
  import { EventEmitter } from 'events';
12
12
  export interface ClaudeLLMOptions {
13
13
  workingDirectory?: string;
14
+ sessionBaseDir?: string;
14
15
  permissionMode?: 'default' | 'acceptEdits' | 'bypassPermissions';
15
16
  allowedTools?: string[];
16
17
  eventEmitter?: EventEmitter;
@@ -18,6 +19,8 @@ export interface ClaudeLLMOptions {
18
19
  continueSession?: boolean;
19
20
  mcpServers?: Record<string, McpServerConfig>;
20
21
  model?: string;
22
+ voiceMode?: 'direct' | 'realtime';
23
+ skipTTSQueue?: boolean;
21
24
  }
22
25
  /**
23
26
  * Claude LLM - Wraps Claude Agent SDK for LiveKit
@@ -113,13 +116,38 @@ export declare class ClaudeLLM extends llm.LLM {
113
116
  * Check if checkpoints are available
114
117
  */
115
118
  hasCheckpoints(): boolean;
116
- chat({ chatCtx, toolCtx, connOptions, }: {
119
+ /**
120
+ * Interrupt the current Claude query gracefully (like pressing Esc).
121
+ * Stops current tool execution but keeps the process alive.
122
+ * Returns true if interrupted, false if no active query.
123
+ */
124
+ interruptQuery(): Promise<boolean>;
125
+ /**
126
+ * Hard abort all active queries (like Ctrl+C).
127
+ * Kills subprocesses. Next message will spawn new processes.
128
+ */
129
+ abortQuery(): void;
130
+ /**
131
+ * Rewind file changes to a specific checkpoint.
132
+ * Uses the most recently added query (most likely to have the rewind capability).
133
+ */
134
+ rewindToCheckpoint(checkpointId?: string): Promise<boolean>;
135
+ /**
136
+ * Check if there are active queries that can be interrupted
137
+ */
138
+ hasActiveQuery(): boolean;
139
+ /** Add an active query (called from ClaudeLLMStream when query starts) */
140
+ setActiveQuery(q: any): void;
141
+ /** Remove an active query (called from ClaudeLLMStream when query completes) */
142
+ removeActiveQuery(q: any): void;
143
+ chat({ chatCtx, toolCtx, connOptions, abortController, }: {
117
144
  chatCtx: llm.ChatContext;
118
145
  toolCtx?: llm.ToolContext;
119
146
  connOptions?: APIConnectOptions;
120
147
  parallelToolCalls?: boolean;
121
148
  toolChoice?: llm.ToolChoice;
122
149
  extraKwargs?: Record<string, unknown>;
150
+ abortController?: AbortController;
123
151
  }): llm.LLMStream;
124
152
  }
125
153
  /**