mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-11-30 20:06:22 -05:00
ai: ground the librarian — collection links, retry hints, no source URLs
Live testing surfaced three ways small models went wrong summarizing a library: they gave up after one empty search (misspelled channel names found nothing), so zero-result searches now carry a retry hint and the Research prompt requires list_collections before channel/site questions and search_videos(channel_id) before claiming a channel is summarized; they presented the familiar YouTube source URL instead of the WROLPi link, so listings omit the source URL (archive detail keeps it); and they invented links for channels, so channel collections now carry their real /videos/channel page link. Search descriptions state that search_str is optional for browsing the newest items. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
08888a3d8f
commit
1ee35c6bda
4 changed files with 40 additions and 17 deletions
|
|
@ -30,9 +30,18 @@ MODES = {
|
|||
f'{COMMON_PROMPT}'
|
||||
' Your job is to be the librarian: find and summarize content from the user\'s library.'
|
||||
' Search first, then read captions, page text, or entries when the user wants detail.'
|
||||
' When the user asks about a channel, website, or their whole library, call'
|
||||
' list_collections first to learn the exact names (spellings often differ).'
|
||||
' list_collections only gives names — it never tells you what content exists. You have'
|
||||
' not summarized a channel until you have called search_videos with its channel_id (and'
|
||||
' NO search_str) and read the resulting titles.'
|
||||
' To browse everything of one kind (e.g. "summarize my archives"), call the search tool'
|
||||
' WITHOUT search_str — that lists the newest items.'
|
||||
' When a search finds nothing, do not give up: retry with fewer or different words, or'
|
||||
' browse with list_collections.'
|
||||
' ALWAYS include the WROLPi link for every item you mention, exactly as the tools return it.'
|
||||
' Never give external URLs. When a search returns a large total, narrow the query instead'
|
||||
' of paging. If nothing matches, say so.'
|
||||
' of paging.'
|
||||
),
|
||||
tools=(
|
||||
'search_all',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue