josephrocca / OpenCharacters

Simple little web interface for creating characters and chatting with them. It's basically a single HTML file - no server. Share characters using a link (character data is stored within the URL itself). All chat data is stored in your browser using IndexedDB. Currently supports OpenAI APIs and ~any Hugging Face model.
https://josephrocca.github.io/OpenCharacters
MIT License
367 stars 63 forks source link

Feature request: frequency_penalty, presence_penalty, max_tokens and context limit #5

Open notfood opened 1 year ago

notfood commented 1 year ago

The frequency_penalty, presence_penalty, max_tokens are useful to tinker with the responses further, should be per character to allow maximum flexibility. Context limit would be how many tokens at most must be sent at max instead of using the limit of 4096, setting it at half helps to save on $$$ at the cost of some memory.

josephrocca commented 1 year ago

Thanks! I'll add these as character settings for sure

josephrocca commented 1 year ago

It's now possible to chance presence penalty, frequency penalty, and other stuff, but not yet max_tokens. You gotta do it via custom code for now though. Quoting the custom code documentation:


Note that currently only the temperature setting is available in the character editor, so if you e.g. wanted to add a stop sequence for your character so it stops whenever it writes ":)" and also set presence pentalty to 1, then you could do it by adding this text to the custom code text box in the character editor:

oc.character.stopSequences = [":)"];
oc.character.presencePenalty = 1;