12 Commits

Author SHA1 Message Date
copilot-swe-agent[bot] db23c83fc1 style: move import to module level per PEP 8
Co-authored-by: magicseek <446252+magicseek@users.noreply.github.com>
2026-01-30 13:59:36 +00:00
copilot-swe-agent[bot] 6a8d08b7ec fix: address PR review feedback for Windows compatibility and path normalization
Co-authored-by: magicseek <446252+magicseek@users.noreply.github.com>
2026-01-30 13:57:24 +00:00
Deheng Huang c5f398a08f feat(sync): add folder auto-routing and notebook auto-activation
- source_manager: auto-route folder uploads to sync command
- notebook_manager: add notebook_id parameter to add_notebook()
- Both: auto-activate newly created notebooks
2026-01-30 15:07:59 +08:00
Deheng Huang edcfa5d16e feat(sync): integrate sync command with CLI 2026-01-30 13:55:10 +08:00
Deheng Huang 2d5d47673e feat(upload): replace interactive prompt with CLI flags
Problem: AI agents run scripts non-interactively, so input() gets EOF.

Solution: Add explicit CLI flags for notebook selection:
- --use-active: Upload to currently active notebook
- --create-new: Create new notebook named after the file
- --notebook-id: Upload to specific notebook (existing)

The AI agent should ask the user BEFORE running the script, then
pass the appropriate flag. Script now exits with clear error
message if no target is specified.

Updated SKILL.md to instruct agents to ask user first.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-26 18:51:22 +08:00
Deheng Huang eb5ed2869e fix(source): fix prompt buffering issue for notebook choice
- Changed all prints from stderr to stdout for consistent buffering
- Added sys.stdout.flush() before input() to ensure proper ordering
- Fixes issue where input prompt appeared before options were displayed

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-26 17:30:08 +08:00
Deheng Huang ef16e6f2e7 feat(source): prompt for notebook choice on upload
When no --notebook-id is specified, prompt user to choose:
- Upload to active notebook (if one exists)
- Create a new notebook
- Select from existing notebooks (if no active)

Adds interactive parameter to disable prompting for programmatic use.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-26 10:27:26 +08:00
Deheng Huang 15ed577f20 fix(browser): add wait after navigation in set_storage_state to prevent context destruction 2026-01-25 20:16:16 +08:00
Deheng Huang c55c8c8bf3 refactor: migrate source_manager to async with notebooklm-py
Replace NotebookLMKitClient with NotebookLMWrapper async API.
All public methods (add_from_file, add_from_zlibrary, add_from_url)
are now async and main() uses asyncio.run().

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-25 20:16:16 +08:00
Deheng Huang 35dec2e09a feat: add browser-based uploads with text fallback 2026-01-25 20:16:15 +08:00
Deheng Huang be55572471 feat: use notebooklm-kit client for uploads 2026-01-25 20:16:15 +08:00
Deheng Huang ef0bdf5815 feat: expand agent-browser automation and source ingestion 2026-01-25 20:16:15 +08:00