Skip to content

Jur/1.x/add html support to content scope#117

Open
jjroelofs wants to merge 6 commits into1.xfrom
jur/1.x/add-html-support-to-contentScope
Open

Jur/1.x/add html support to content scope#117
jjroelofs wants to merge 6 commits into1.xfrom
jur/1.x/add-html-support-to-contentScope

Conversation

@jjroelofs
Copy link
Copy Markdown
Contributor

@jjroelofs jjroelofs commented Feb 11, 2025

Adds HTML cleanup service to sanitize content before AI processing to help AI understand its content in broader context, e.g. landing pages and forms. Handles inline-slash commands, cursor markers, and preserves essential HTML attributes while removing unwanted elements.

Jurriaan Roelofs added 3 commits February 11, 2025 09:55
- Change innerText to innerHTML for HTML content capture
- Add HTML-aware content processing in extractEditorContent
- Add CDATA sections to preserve HTML in final prompt
- Add detailed debug logging for HTML content flow
- Improve code formatting and readability
- Add HtmlCleanupService for cleaning HTML content

- Add configuration types for HTML cleanup

- Integrate HTML cleanup into PromptHelper

- Handle inline-slash tags while preserving cursor markers
@jjroelofs jjroelofs force-pushed the jur/1.x/add-html-support-to-contentScope branch from f496c84 to 1ac1c44 Compare February 11, 2025 10:07
@jjroelofs jjroelofs requested a review from syuzanvs February 11, 2025 10:58
- Add direct editor content retrieval when contentScope is not configured

- Maintain HTML cleanup for both contentScope and direct editor scenarios

- Update debug logging messages for clarity
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants