import ReactPlayer from 'react-player'

# Using AI

Writeopia integrates seamlessly with AI agents to supercharge your writing process — whether you're brainstorming, editing, or exploring new ideas. You stay in control while AI works alongside you, completely offline if you choose.

*Key Features* 
Choose Your AI Agent: Pick from a list of available AI agents, or plug in your own.

Context-Aware Assistance: AI understands the current document context and provides tailored suggestions.

Offline Mode: AI works locally for full privacy — no internet connection needed.

Customizable Behavior: Configure how the AI should respond (e.g., tone, creativity, length).

## Generate Content
**Note: This is only available in the Desktop apps** 

To generate content with AI, you can click in the button "Prompt". It will take the selected messages and generate a reply based on it. If you don't select any message, it will create a the content of the line that your cursor is currently on. 

Generating using text selection:

<ReactPlayer 
    playing={false} 
    controls url="https://storage.googleapis.com/writeopia-resources/docusaurus/generate_ai_text_selected.mov" 
    width="100%"       
    height="600px" />

<br/>
<br/>

It is possible to generate content without selecting lines of text, just by putting the cursor in a specific line. 

<ReactPlayer 
    playing={false} 
    controls url="https://storage.googleapis.com/writeopia-resources/docusaurus/generate_ai_by_line.mov" 
    width="100%"       
    height="600px" />

## Document AI commands
There are many commands that generate content based on the whole text of the document. It is not necessary select a text to interact with it. You can just click in the button and the action will be triggered. 

There are many options like: Generate a summary of the text, FAQ, tags, etc.

<ReactPlayer 
    playing={false} 
    controls url="https://storage.googleapis.com/writeopia-resources/docusaurus/ai_summarize.mov" 
    width="100%"       
    height="600px" />