File tree 2 files changed +2
-2
lines changed
2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -972,7 +972,7 @@ export class MessageManager {
972
972
) ;
973
973
974
974
// strip all special characters
975
- messageContent = messageContent . replace ( / [ ^ \p { L } \p { N } \s \- _ . / : ? = & ] / gu , "" ) ;
975
+ messageContent = messageContent . replace ( / [ ^ a - z A - Z 0 - 9 \s ] / g , "" ) ;
976
976
977
977
// short responses where eliza should stop talking and disengage unless mentioned again
978
978
if (
Original file line number Diff line number Diff line change @@ -141,7 +141,7 @@ export function preprocess(content: string): string {
141
141
// Remove multiple newlines
142
142
. replace ( / \n { 3 , } / g, "\n\n" )
143
143
// Remove special characters except those common in URLs
144
- . replace ( / [ ^ \p { L } \p { N } \ s\- _ . / : ? = & ] / gu , "" )
144
+ . replace ( / [ ^ a - z A - Z 0 - 9 \ s\- _ . / : ? = & ] / g , "" )
145
145
. trim ( )
146
146
. toLowerCase ( )
147
147
) ;
You can’t perform that action at this time.
0 commit comments