AI assistant with ChatGPT
AI assistant makes it possible to use ChatGPT inside LibreOffice Writer.
latest release: 2024-03-21 22:22:22
Description
AI assistant using ChatGPT makes it possible to use ChatGPT inside LibreOffice. Available functionalities are:
- Chat
- Summarize the text
- Translate into English, German, Spanish and French
- Extracting keywords
- Edit the text
- Generate image based on description
Please note that generating image is not currently possible on Linux, because of the restrictions in Microsoft servers that provide the content.
To use the extension, you have to define environment variable OPENAI_API_KEY with the API key that you should obtain from openai.com yourself. ChatGPT users can use trial version of the API for 1-2 month.
In Linux, you should add this line to ~/.bashrc, and put your generated key instead of 3 dots:
export OPENAI_API_KEY="..."
On Windows, you should go to "System properties > Environment variables" to set the system-wide environment variable.
Furthermore, you have to install pip module and then openai module using pip. To do that, you should use PIP bootstrap. First, download this script:
https://bootstrap.pypa.io/get-pip.py
Then, use LibreOffice internal Python to run it:
program/python get-pip.py
After that, install openai module using pip:
program/python -m pip install openai
If the installation is successful, you should be able to use openai module inside LibreOffice internal Python, and run the AI assistant extension.
Homepage: https://wiki.documentfoundation.org/User:Reyhane
Repository: https://wiki.documentfoundation.org/User:Reyhane
★ ☆ ☆ ☆ ☆
Post your review
You cannot post reviews until you have logged in. Login Here.
Reviews
Steve Shaffer Mar 14, 2024, 10:58 PM (7 months ago)
☆ ☆ ☆ ☆ ☆
Is there some way to see where this extension might be throwing an error? I have it installed and the API key set. the menu is present and the window seems to churn for a while when any AI assistant option is selected but nothing happens.
Norman Mar 9, 2024, 2:39 PM (7 months ago)
☆ ☆ ☆ ☆ ☆
Please adapt to LibreOffice Portable Windows.
Clevere Eltern Jan 14, 2024, 9:52 AM (9 months ago)
☆ ☆ ☆ ☆ ☆
I am trying to use this great extension in LibreOffice with MacOS and get an error that corresponds to the problem, that openai is not installed. I also have no program/ folder in LibreOffice. Do you have any hints what I can do?
Clevere Eltern Jan 14, 2024, 9:54 AM (9 months ago)
I am getting the following error messages, if I try to enable the extension:
<class 'ModuleNotFoundError'>: No module named 'openai', traceback follows
File "/Applications/LibreOffice.app/Contents/Resources/pythonloader.py", line 147, in writeRegistryInfo
mod = self.getModuleFromUrl( locationUrl )
File "/Applications/LibreOffice.app/Contents/Resources/pythonloader.py", line 102, in getModuleFromUrl
exec(codeobject, mod.__dict__)
File "/Users/marc/Library/Application Support/LibreOffice/4/user/uno_packages/cache/uno_packages/lu567552snj5c.tmp_/extension.oxt/main.py", line 7, in <module>
import openai
File "/Applications/LibreOffice.app/Contents/Resources/uno.py", line 346, in _uno_import
return _builtin_import(name, *optargs, **kwargs)
(com.sun.star.uno.RuntimeException) { { Message = "<class 'ModuleNotFoundError'>: No module named 'openai', traceback follows\X000a File \"/Applications/LibreOffice.app/Contents/Resources/pythonloader.py\", line 147, in writeRegistryInfo\X000a mod = self.getModuleFromUrl( locationUrl )\X000a File \"/Applications/LibreOffice.app/Contents/Resources/pythonloader.py\", line 102, in getModuleFromUrl\X000a exec(codeobject, mod.__dict__)\X000a File \"/Users/marc/Library/Application Support/LibreOffice/4/user/uno_packages/cache/uno_packages/lu567552snj5c.tmp_/extension.oxt/main.py\", line 7, in <module>\X000a import openai\X000a File \"/Applications/LibreOffice.app/Contents/Resources/uno.py\", line 346, in _uno_import\X000a return _builtin_import(name, *optargs, **kwargs)\X000a\X000a", Context = (com.sun.star.uno.XInterface) @0 } }
Pascal Huisman Dec 10, 2023, 8:18 PM (10 months ago)
★ ★ ★ ☆ ☆
Just use your package manager:
sudo apt install pip
pip install openai
Check you have your local path in your environment.
.local/bin/
pascal@xps9560:~$ $PATH
bash: /home/pascal/.local/bin
Problems with OpenAI:
https://platform.openai.com/docs/quickstart?context=python
When using chatgpt longer than 5 months. The API doesn't work. You have to provide payment information
No one has commented on this page yet.
RSS feed for reviews on this page | RSS feed for all reviews