@moonjot/moon-ai-prompt-plugin
v0.0.8
Published
Moon sample plugin for Moon
Downloads
10
Maintainers
Readme
Moon Ai via Mention
Concept
Use :ai:
to trigger ai flows.
Build items property
In your settings you got this kind of item:
{
"title": "ChatGPT - 4", // You can change that as you want
"type": "openai", // openai | gemini | ollama | mistral
"model": "gpt-4", // depending on the type refer to official ai doc
"token": "", // token if needed (openai | gemini | mistral)
"prompt": "{{content}}", // you can customize that as you wish {{content}} is the content of the Launcher
"output": "---\nAI:\n${response}\n\n---\n" // you can customize how the answer will be formatted before be inserted in the text editor
}
output
Feel free to customize them, for example change the output
"output": "The GPT 4 AI answer with : \n${response}\n"
prompt
Feel free to customize them, for example change the prompt like
"prompt": "Answer to this prompt only in French: '{{content}}'",
You can also add context
"prompt": "Answer to this prompt only in French: 'Question : {{content}}\n Article content: {{source.text}}'",
There is only 3 type of AI integration available for now
Ask me if you want more
TODO
- [ ] Add shortcut maybe
Develop on Moon
Check the doc here https://github.com/castroCrea/moon/blob/main/doc/Plugin_Development.md
Check also the tutorial video https://youtu.be/dvoalnWBwv4 📹
Installation
yarn
Build before publishing
yarn build
For dev mode run
yarn watch
Publishing
First remove current git origin
git remote remove origin
Add you repo origin and change also credential iin package.json
Then
yarn pub