Originally posted by **robstumborg** October 29, 2023
What do you think about having pre-configured "personalities" that could be used with the plugin?
Sometimes I think it would be nice to use this plugin/neovim for general OpenAI use and not necessarily just for assistance with programming, but switching the config every time would be too cumbersome.
Here's an example of what a configuration could look like:
```lua
local conf = {
chat_personalities = {
programmer = {
chat_model = { model = "gpt-3.5-turbo-16k", temperature = 1.1, top_p = 1 },
chat_system_prompt = "You are a general AI assistant for a computer programmer.",
chat_custom_instructions = "The user provided the additional info about how they would like you to respond:\n\n"
.. "- If you're unsure don't guess and say you don't know instead.\n"
.. "- Ask question if you need clarification to provide better answer.\n"
.. "- Think deeply and carefully from first principles step by step.\n"
.. "- Zoom out first to see the big picture and then zoom in to details.\n"
.. "- Use Socratic method to improve your thinking and coding skills.\n"
.. "- Don't elide any code from your output if the answer requires coding.\n"
.. "- Take a deep breath; You've got this!\n",
},
writer = {
chat_model = { model = "gpt-3.5-turbo-16k", temperature = 1.1, top_p = 1 },
chat_system_prompt = "You are a general AI assistant for a writer.",
chat_custom_instructions = "Some specific instructions that are useful for somebody writing a novel:\n\n"
.. " - blah\n"
.. " - blah\n"
.. " - blah\n"
},
technical_writer = {
chat_model = { model = "gpt-3.5-turbo-16k", temperature = 1.1, top_p = 1 },
chat_system_prompt = "You are a general AI assistant for somebody writing technical documentation for computer software.",
chat_custom_instructions = "Some specific instructions that are useful for somebody writing technical docs:\n\n"
.. " - blah\n"
.. " - blah\n"
.. " - blah\n"
}
},
default_chat_personality = "programmer",
}
```
Switching between personalities could be a command like `:GpChatPersonality writer`.
I'd be willing to put in the time to create this functionality if you think it's something you want in the plugin.
Discussed in https://github.com/Robitx/gp.nvim/discussions/40