feat(notion-search): add LLM client abstraction with SDK + CLI fallback

First task of Phase 3b-i (notion semantic search). Adds _search_llm.py
that dispatches to the anthropic SDK when ANTHROPIC_API_KEY is set,
falls back to `claude -p` CLI otherwise, and raises a clear setup
error if neither works. Symlinks _notion_compat.py from 32-notion-writer
so both skills share one source of truth.

3 tests cover the three dispatch paths.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-28 07:37:42 +09:00
parent 56f33eca3f
commit 45c68dee61
3 changed files with 144 additions and 0 deletions

View File

@@ -0,0 +1 @@
../../../32-notion-writer/code/scripts/_notion_compat.py