Skip to content

In-line AI operations based on text selection #258

Description

@philxb

Is your feature request related to a problem?

Current text generation functions either append new text to the end of the chapter or rewrite the entire chapter, but it would be great to be able to isolate the rewrite or extension to only a selected portion of text anywhere within the chapter. Additionally, the AI chat could have access to the selected portion of text for other operations.

For example, this would be useful in a scenario where I'm happy with 95% of the chapter, don't want to rewrite the entire thing or extend it, but there are specific passages in the middle that I would like AI's help on.

Describe the solution you'd like

When selecting text, an AI icon could show beside the hi-lighted text that, when clicked / toggled, limits AI operations to the selected text.

Here's a mockup:
Image

Modified operations

Extend: Adds additional prose after the selected text.
Rewrite: Works a bit differently than a full chapter rewrite. It takes the current chapter into context, including the highlighted text, to rewrite just the selected portion.
AI Chat: Adds the selected text into its context, with fields for the selected string and from/to character indices in the chat message to the ai.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions