π§ Outlook Add-in User Guide
1. Overviewβ
This add-in provides two unified operation modes in Outlook reading/new/reply scenarios:
- Selection Mode: You select text in the body β the "Selection Tools" button is displayed.
- Mail Mode: No text is selected β the "Whole Mail Tools" button is displayed.
Only when replying to an email is the "Generate Reply" button additionally displayed. Other functions are consistent with Word / PPT logic (distinguished by selection/whole mail).
A Close button is provided in the upper right corner to clear the current session.
2. Feature Overview (by mode)β
2.1 Selection Mode (when text is selected)β
- Translate Selection
Translates the selected text into the target language and automatically writes back to replace the original text (using
addHtmlTextToSelection, preserving HTML structure). - Rewrite & Optimize
Stylizes the selected text: rewrite / simplify / expand / listify / outline, and automatically writes back to replace the original text (
addHtmlTextToSelection). - Explain Selection Outputs a clear explanation of the selected text (only outputs the result, does not write back automatically).
- Proofread Selection Only corrects spelling and grammar errors without changing the original meaning (only outputs the corrected text, does not write back automatically).
2.2 Mail Mode (when no text is selected)β
- Translate Whole Mail
Reads the content from the current email body (
getCurrentBody), translates it into the target language (by default only outputs the result, does not write back automatically). - Explain Whole Mail Reads the entire content and outputs a concise explanation (only outputs).
- Summarize Whole Mail Generates a concise summary retaining key points (only outputs).
2.3 Only displayed in "Reply Email" scenarioβ
- Generate Reply
Automatically reads the replied email (
getRepliedBody), generates a complete reply in the selected tone (formal/friendly/concise, etc.), and writes back to the body (setBodyHtmlContent).
3. Typical Operationsβ
A. Translate selected text and write backβ
- Select a segment of text in the email body
- Click Translate β Select Language
- The system will directly replace the original text with the translation (preserving HTML structure and style)
B. Summarize the whole emailβ
- Do not select any text
- Click Summarize
- The panel displays the summary (does not modify the body)
C. One-click reply generation when replying to an emailβ
- Click Outlook's Reply/Reply All
- Open the add-in and click Generate Reply β Select Tone
- The system automatically reads the original email and writes the generated reply into the body
D. Rewrite selection as "Listify"β
- Select a long segment of text
- Click Rewrite & Optimize β Listify
- The original text is replaced with an itemized list (write-back takes effect)
4. Button Display Rules (Important)β
- Whether text is selected determines whether "Selection Tools" or "Whole Mail Tools" are displayed.
- When in the reply window (Reply/Reply All), additionally displays "Generate Reply".
- The same button logic is used for reading, composing, and replying scenarios (based on whether text is selected).
5. Notes & Known Behaviorsβ
-
Write-back behavior:
- "Translate/Rewrite" for selection will write back to replace the original text;
- "Explain/Summarize/Whole Mail Translate/Proofread" by default only outputs the result, does not write back to the body;
- "Generate Reply" will write back to the body (reply scenario only).
-
Format retention: Selection write-back uses
addHtmlTextToSelection, preserving the original HTML structure and style as much as possible. -
Pre-send check: Auto-generated/translated content is for assistance; manual confirmation is recommended before sending.
-
If the body is restricted (read-only/encrypted), write-back will fail and a prompt should be given.