wiki:WriterReceivesAISuggestions

Version 2 (modified by 211099, 2 weeks ago) ( diff )

--

Writer Receives and Reviews AI Suggestions

Actor: Writter

A writer reviews AI-generated writing suggestions for their chapter, and accepts or rejects each suggestion to improve their writing quality.

1. The writer opens a chapter and selects "View AI Suggestions".

2. The system retrieves all pending AI suggestions for that chapter.

SELECT ai.suggestion_id, ai.original_text, ai.suggested_text, st.suggestion_type, ai.accepted
FROM AI_SUGGESTION ai
JOIN SUGGESTION_TYPE st ON ai.suggestion_id = st.suggestion_id
JOIN NEED_APPROVAL na ON ai.suggestion_id = na.suggestion_id
WHERE na.chapter_id = 1 AND ai.accepted = FALSE;

3. The system displays each suggestion alongside the original text.

4. The writer reviews a suggestion and chooses to accept it.

5. The system updates the suggestion record as accepted and records the time it was applied.

UPDATE AI_SUGGESTION
SET accepted = TRUE, applied_at = CURRENT_TIMESTAMP
WHERE suggestion_id = 3;

6. The writer rejects another suggestion, which remains marked as not accepted.

UPDATE AI_SUGGESTION
SET accepted = FALSE
WHERE suggestion_id = 2;

7. The system confirms all reviewed suggestions and updates the chapter content accordingly.

Note: See TracWiki for help on using the wiki.