fix(gmail): sanitize HTML entities and tags in tool output
Gmail API returns snippets with HTML entities (&, ', <br>, etc.) that leaked into LLM responses as raw HTML. Added shared sanitizeHtml() utility in src/utils/html.ts and applied it to gmail tool snippets, HTML body fallback, and gmail watcher snippets.
This commit is contained in:
@@ -947,6 +947,21 @@
|
||||
"config/default.yaml"
|
||||
]
|
||||
},
|
||||
"gmail-html-sanitization": {
|
||||
"status": "completed",
|
||||
"date": "2026-02-10",
|
||||
"summary": "Sanitize HTML entities and tags in Gmail tool output. Gmail API returns snippets with HTML entities (&, ', <br>, etc.) that leaked into LLM responses. Added shared sanitizeHtml() utility and applied to both gmail tool and gmail watcher.",
|
||||
"files_created": [
|
||||
"src/utils/html.ts",
|
||||
"src/utils/html.test.ts"
|
||||
],
|
||||
"files_modified": [
|
||||
"src/tools/builtin/gmail.ts",
|
||||
"src/tools/builtin/gmail.test.ts",
|
||||
"src/automation/gmail.ts"
|
||||
],
|
||||
"test_status": "21/21 passing (html.test) + 18/18 passing (gmail.test) + 16/16 passing (automation/gmail.test)"
|
||||
},
|
||||
"tui-fullscreen-improvements": {
|
||||
"status": "completed",
|
||||
"date": "2026-02-10",
|
||||
|
||||
Reference in New Issue
Block a user