Commit Graph

3124 Commits

Author SHA1 Message Date
a8ee723853 Always add impersonate prompt last 2023-08-12 18:40:39 +02:00
dd89009ecd Use tokenizer-specific token cache 2023-08-12 18:40:39 +02:00
55cc559fd0 Render promptmanager when chatcompletion model or source change 2023-08-12 18:40:39 +02:00
2805a684a8 Emit events on changing chatcompletion source or model 2023-08-12 18:40:39 +02:00
1281417a97 Render prompt manager when chat history is altered
Recounts tokens
2023-08-12 18:40:39 +02:00
d9e7eba617 Emit event when a single chat message is deleted 2023-08-12 18:40:39 +02:00
d82ea66664 Refactor addItem method of MessageCollection 2023-08-12 18:40:39 +02:00
4100ae9e0b Do not insert authors note into main
Since it is already present in the chat history
2023-08-12 18:40:39 +02:00
d2ee6e9a12 Append quietPrompt last 2023-08-12 18:40:39 +02:00
463f01d2a6 #870 Fix Claude in prompt manager 2023-08-12 18:40:39 +02:00
29552ecfcf Sanitize completion names. Only send names in msg texts if names in completion is disabled 2023-08-12 18:40:39 +02:00
5f43121e15 Expand quick edits rows 2023-08-12 18:40:39 +02:00
e7b29babe9 Remove obsolete characterSelected event 2023-08-12 18:40:39 +02:00
fd10eaf037 Close and clear popup on preset change 2023-08-12 18:40:39 +02:00
db8624cefe Move quick edits on top of prompt manager 2023-08-12 18:40:39 +02:00
992af2b4fa Reduce font size on mobile 2023-08-12 18:40:39 +02:00
1b7a1cbc4a Add quick edit drawer and fields for main and jailbreak 2023-08-12 18:40:39 +02:00
bd3136e114 Improve wording for prompt insertion 2023-08-12 18:40:39 +02:00
6e4689ba39 Add theme tint and blur to prompt manager popup drawer 2023-08-12 18:40:39 +02:00
f5aa891962 Fix prompt manager not being draggable on mobile
Updates jquery ui touch punch with a maintained version, fixes other instances of jquery ui sortable as well (kobold, ...)
2023-08-12 18:40:39 +02:00
38bfcf5324 Remove advanced options toggle 2023-08-12 18:40:39 +02:00
af81915ff3 Update existing prompts during migration
Instead of adding new prompts for main, jailbreak and nsfw
2023-08-12 18:40:39 +02:00
222fd3429d Center globe icon 2023-08-12 18:40:39 +02:00
f0830e7bb4 Fix in-code documentation typo 2023-08-12 18:40:39 +02:00
59afac08da Add missing in-code documentation 2023-08-12 18:40:39 +02:00
e8c7e40c54 Fix prompt name not being greyed out when prompt disabled 2023-08-12 18:40:39 +02:00
05a080849c Fix edit button being shown for chat history and examples 2023-08-12 18:40:39 +02:00
1e43108e5a Move inspect functionality to prompt name click 2023-08-12 18:40:39 +02:00
fc44a02323 Set utility prompt text area size to 3 rows 2023-08-12 18:40:39 +02:00
405a680059 Add user icon for user prompts
To be consistent with global and marker icons
2023-08-12 18:40:39 +02:00
bc4befeb22 Rename prompt lists to prompt order
Includes renaming of configuration, no functional changes
2023-08-12 18:40:39 +02:00
63d224d8af Refactor and simplify setup method for prompt manager. 2023-08-12 18:40:39 +02:00
ad6575887a Remove obsolete function getGroupMembers 2023-08-12 18:40:39 +02:00
b58ce0370d Refactor token counting after completion. Simplify code. 2023-08-12 18:40:39 +02:00
57fd04b974 Refactor token counting after completion. Simplify code. 2023-08-12 18:40:39 +02:00
dfd49813af Refactor naming scheme for default promptmanager defaults 2023-08-12 18:40:39 +02:00
4f734d12ab Use configured prefix for prompt manager classes instead of constant 2023-08-12 18:40:39 +02:00
9d6cf017d2 Move main and jailbreak override from manager into openai script.
Makes the code clearer and easier to understand
2023-08-12 18:40:39 +02:00
075c0c29f0 Refactor prepareOpenAiMessages, move prompt preparation in its own function 2023-08-12 18:40:39 +02:00
ec806db9f7 Initialize prompt manager on selecting openrouter, scale 2023-08-12 18:40:39 +02:00
fc555c1be5 When a prompt is reset, also reset name and role 2023-08-12 18:40:39 +02:00
a921a26af5 Do not show reset button for user prompts 2023-08-12 18:40:39 +02:00
7ea6e89b05 Add reset prompt support for enhance definitions 2023-08-12 18:40:39 +02:00
b2acc9eb0f Refactor documentation and make code more readable
No functional changes
2023-08-12 18:40:39 +02:00
19ee831d82 Prevent prompt manager initialization more than once 2023-08-12 18:40:39 +02:00
67ef713826 Better visibility of prompt manager popup on mobile 2023-08-12 18:40:39 +02:00
76154fd8ee Fix authors note position not being considered 2023-08-12 18:40:39 +02:00
41aae57f05 Do not send empty scenario and personality prompts 2023-08-12 18:40:39 +02:00
6a52d6febd Fix invalid character name error not being handled 2023-08-12 18:40:39 +02:00
00e9987fb7 Fix character reset not available in basic mode 2023-08-12 18:40:39 +02:00