mirror of
https://github.com/pewdiepie-archdaemon/odysseus.git
synced 2026-06-15 17:25:26 -04:00
The agent tool-RAG force-includes a keyword hint's tools whenever any of its keywords appears in the query (word-boundary match). The email-intent hint listed "tell", which matches a huge fraction of requests — e.g. "visit <url> and tell me the title" — so the whole email toolset was force-included and crowded out the relevant tools. The model then saw a prompt dominated by email tools and reported it had no web search / could not visit the URL. Remove "tell" from the email keyword set. Genuine email intent still fires on email/mail/gmail/inbox/unread/message/send/reply. Test drives get_tools_for_query directly with retrieval stubbed (the keyword hints are deterministic, no embeddings needed): a "...tell me..." web query no longer pulls in email tools, a real email request still does. Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
+5
-1
@@ -293,7 +293,11 @@ class ToolIndex:
|
||||
|
||||
# Keyword hints: if the query mentions these words, force-include the tools.
|
||||
_KEYWORD_HINTS = {
|
||||
frozenset({"email", "mail", "gmail", "googlemail", "message", "send", "reply", "inbox", "unread", "tell"}):
|
||||
# NOTE: "tell" was removed from this set. It fired on any "tell me ..."
|
||||
# request (e.g. "visit <url> and tell me the title"), force-including the
|
||||
# whole email toolset and crowding out the relevant tools — the model then
|
||||
# believed it had only email tools and refused web/other tasks (#1707).
|
||||
frozenset({"email", "mail", "gmail", "googlemail", "message", "send", "reply", "inbox", "unread"}):
|
||||
{"list_email_accounts", "list_emails", "read_email", "send_email", "reply_to_email", "bulk_email", "delete_email", "archive_email", "mark_email_read", "resolve_contact", "ui_control"},
|
||||
frozenset({"calendar", "event", "meeting", "schedule", "appointment"}):
|
||||
{"manage_calendar"},
|
||||
|
||||
Reference in New Issue
Block a user