Commit Graph

962 Commits

Author SHA1 Message Date
BlipRanger
d25eca0f29 Cleanup from gen info stuff 2023-07-08 18:55:47 -04:00
BlipRanger
148966affe Fix some issues with displaying the gen info 2023-07-08 18:53:23 -04:00
BlipRanger
0f7dad7a5e I think that corrects the extras for swiping 2023-07-08 17:44:36 -04:00
BlipRanger
5128b75216 Fixed model acquisiton 2023-07-08 17:13:52 -04:00
BlipRanger
f72b055bfb Merge branch 'dev' of https://github.com/BlipRanger/SillyTavern into dev 2023-07-08 01:17:59 -04:00
BlipRanger
5a0c702f53 Handle swipes for extra info 2023-07-08 01:17:55 -04:00
BlipRanger
f2e4eb1696 Capture api/model to msgs 2023-07-08 00:40:29 -04:00
Cohee
8e5fd7938c Merge branch 'dev' of https://github.com/SillyLossy/TavernAI into dev 2023-07-08 04:12:20 +03:00
Cohee
46e1a25d83 Fix cross-tab file drag and drop 2023-07-08 04:12:17 +03:00
50h100a
1be05fa514 Always run extension interceptors. 2023-07-07 19:41:57 -04:00
50h100a
f3d8f4a7da Merge branch 'dev' of https://github.com/SillyTavern/SillyTavern into smartcontext-improvements 2023-07-07 13:03:00 -04:00
Cohee
3162cf0e29 Merge pull request #653 from BlipRanger/feature/chroma-wi
Chroma Newline Chunking Option
2023-07-07 12:35:48 +03:00
50h100a
b4830f2b67 Include Smart Context in prompt summary when possible. 2023-07-07 03:23:40 -04:00
Cohee
cc98a0bd01 Merge pull request #639 from phiharri/confirm_delete 2023-07-07 09:08:51 +03:00
Cohee
8fcc074ced Merge pull request #651 from BlipRanger/feature/count 2023-07-07 09:07:50 +03:00
BlipRanger
49745b2b35 Cleanup 2023-07-07 00:26:58 -04:00
BlipRanger
e595f83590 Merge branch 'dev' of https://github.com/BlipRanger/SillyTavern into feature/chroma-wi 2023-07-06 23:58:30 -04:00
BlipRanger
02fb1bc26f Revert to the not evals. 2023-07-06 23:06:44 -04:00
kingbri
82624ff55b Regex: fix multiple script bug
Multiple scripts were not running due to improper variable assingment.
For efficiency's sake, do not do a string comparison before returning
and instead do another variable assignment in the parent function.

Doing this reduces the length of regex hooks in the parent calls,
but also removes the need for unnecessary O(n) complexity of comparing
two string variables.

If there are errors, it would be advisable to add string comparison
and revert back to the old logic in parent function calls.

Signed-off-by: kingbri <bdashore3@proton.me>
2023-07-06 22:32:40 -04:00
Cohee
f93fb78bc7 Don't append System narrator name to Chat completion messages. 2023-07-06 21:04:51 +03:00
Cohee
48e9332db9 Merge branch 'dev' of https://github.com/SillyLossy/TavernAI into dev 2023-07-06 20:42:01 +03:00
Cohee
afea5d48f1 Add {{idle_duration}} macro 2023-07-06 20:41:58 +03:00
Cohee
afcd2b497d Merge branch 'dev' into confirm_delete 2023-07-06 18:25:27 +03:00
Cohee
7d9c346d25 Better visibility filter on counter 2023-07-06 18:21:14 +03:00
BlipRanger
bc52df493e Cleaned up code, relative font size 2023-07-06 11:07:38 -04:00
BlipRanger
bbe08ece84 Display total and dynamic character count 2023-07-06 00:42:04 -04:00
phiharri
1d640a2cbf Optional delete message confirmation 2023-07-06 01:43:57 +01:00
RossAscends
13ba5cec49 add help page for macros 2023-07-06 06:11:13 +09:00
Cohee
d7db7885e5 #24 Add Scale support 2023-07-05 23:34:40 +03:00
RossAscends
59f857262b seedrandom for {{random}} 2023-07-06 02:51:01 +09:00
Cohee
935a3d6c35 Clone WI entries before returning them to evaluator 2023-07-05 20:46:30 +03:00
Cohee
f3ebea6ad8 #629 Random list select substitution 2023-07-05 17:59:53 +03:00
Cohee
af6d9d48e0 Merge pull request #630 from bdashore3/dev
Add regex engine and other fixes
2023-07-05 17:30:17 +03:00
Cohee
04b5d73a85 Merge pull request #634 from BlipRanger/feature/spoilers
Add the ability to avoid spoilers
2023-07-05 17:24:43 +03:00
Cohee
15a2a61615 Merge pull request #633 from mweldon/dev
Add retroactive bookmarking
2023-07-05 17:21:09 +03:00
Cohee
5c39327450 Display Claude tokenizer in the UI if Claude model is used 2023-07-05 14:49:45 +03:00
Cohee
46330f0558 Skill issue in A/N persona positioning 2023-07-05 13:27:44 +03:00
kingbri
afdab4c5b6 Regex: Add character name override
Sendas uses a different character's name for messages, so allow
the use of a character name override in the regex match function.
This overrides substituteParams to use a different value.

Signed-off-by: kingbri <bdashore3@proton.me>
2023-07-05 01:35:52 -04:00
kingbri
fee801c2a4 Regex: Upgrade engine
If the extension is disabled, don't use any regex formatting. In
addition, wrap all foreach logic into its own function which
reduces the size of all regex injections.

This commit also removes the need for working around static imports
as UI is separate from the engine and is therefore imported at the
same time as other non-static extensions.

Signed-off-by: kingbri <bdashore3@proton.me>
2023-07-05 01:30:50 -04:00
kingbri
fb02c00402 Extensions: Workaround loading static extensions
Some extensions are statically imported inside script.js, bypassing
the extension load method. The true method to solve this is using
dynamic imports and undefined checks, but implementing this is
extremely time-consuming.

For now, add the extension_first_load event which fires when
first load is about to start. This changes loading priority to
static -> offline -> online/API.

In addition, initialize the event source earlier since it's more
important than most of the other imports.

Signed-off-by: kingbri <bdashore3@proton.me>
2023-07-05 01:30:50 -04:00
kingbri
b362dba726 Regex: Fix edit message hook
The only way to distinguish between a user and AI is if the is_user
property is changed.

Signed-off-by: kingbri <bdashore3@proton.me>
2023-07-05 01:30:50 -04:00
kingbri
ef7aa3941b Extensions: Add regex engine
Regex is a method that is commonly used to find and replace parts
of a string using a single pattern. Add support for using regex in
SillyTavern which allows users to dynamically change various aspects
of the chatting experience.

Users are able to choose where a given regex script should apply
(both invasive and non-invasive options!). Invasive options alter
chat history while non-invasive alters markdown display for the
entire chat.

A new variable called {{match}} is added in regex scripts which
substitutes in the found match from the original find regex script.

There is a lot more that can be added to this extension, but for now,
this is enough.

Signed-off-by: kingbri <bdashore3@proton.me>
2023-07-05 01:30:49 -04:00
kingbri
6bc9535040 Popups: Allow substitution of primary button
This allows for more flexible popups with options rather than
implementing a brand new popup just to change button text.

Signed-off-by: kingbri <bdashore3@proton.me>
2023-07-05 01:30:01 -04:00
BlipRanger
4e0cbdfbb3 Add the ability to avoid spoilers 2023-07-05 01:08:09 -04:00
Mike Weldon
7ceb936337 Fix bug with Save bookmark from menu 2023-07-04 18:35:05 -07:00
Mike Weldon
d3c3614147 Add retroactive bookmarking 2023-07-04 18:13:22 -07:00
Cohee
27ab509caf Split help command into pages 2023-07-05 01:06:24 +03:00
RossAscends
19502492c6 Merge branch 'dev' of https://github.com/Cohee1207/SillyTavern into dev 2023-07-04 23:00:13 +09:00
RossAscends
3426f80656 Impervious MovingUI 2023-07-04 23:00:10 +09:00
Cohee
c922f17f09 Fix main_api default value 2023-07-04 11:49:46 +03:00