- Introduced Zod schemas for type-safe parsing of mentioned document information in chat messages.
- Updated the extractMentionedDocuments function to utilize the new schemas for better validation.
- Made the 'alt' property optional in image-related components for improved flexibility and fallback handling.
- Added a fallback mechanism using headless Chromium to fetch page content when standard HTTP requests fail.
- Introduced utility functions for unescaping HTML entities and converting relative URLs to absolute.
- Updated HTTP request headers to mimic a browser for better compatibility with web servers.
- Improved error handling and logging for better debugging and user feedback.
- Made various properties in Zod schemas nullable for better type safety and flexibility in handling optional data.