Commit
•
91d9c08
1
Parent(s):
80b4737
update
Browse files
src/app/server/actions/censorship.ts
CHANGED
@@ -19,6 +19,10 @@ const chickens = [
|
|
19 |
]
|
20 |
|
21 |
const ducks = [
|
|
|
|
|
|
|
|
|
22 |
"1c52cb20c0cbc76349fa63232b982bd394cf0850ebc17240dcf33c19fb15a26d",
|
23 |
"e1d4de9b8d464d7da07c276b63a42c1c9922224f0a6cab6b0826427ce4a7461a",
|
24 |
"0be3174bfb1a48a65875c2f035b1ae14fbc8f232f55785018de0cfe2132fa952",
|
@@ -49,10 +53,39 @@ const roasted = [
|
|
49 |
"76cdade0b3d4caf0888f60318a5cbca00f830a3b0bf37735fc64fdaeb67c34d3",
|
50 |
"1bf53c97869e1ea89bda19da64a9173d48fe4ec823e949e2c898f8abb3fbf457",
|
51 |
"1bf53c97869e1ea89bda19da64a9173d48fe4ec823e949e2c898f8abb3fbf457",
|
52 |
-
"3d7f973fab8f4a19c0a3e59efe970ed7bd55a1cb795752d9cbe3c19e8a7d81ec"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
53 |
]
|
54 |
|
55 |
const banned = [
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
56 |
"8a05d4869d9d6ce388c6cd2db13ca12b88097b90f9be027d5ffaaa467c7a6e5e",
|
57 |
"0c475212a608138244c5fc150b1563e5ef79c516234fd78dcd5993f726c359a0",
|
58 |
"df17388805f99f2ff3e5ae97a0f55e5c927eb47f17ca65822bf8c88f02bac3dd",
|
@@ -143,7 +176,11 @@ const encode = (list: string[]) => {
|
|
143 |
.map(item => getFingerprint(item)), null, 2))
|
144 |
}
|
145 |
|
146 |
-
|
|
|
|
|
|
|
|
|
147 |
|
148 |
export const filterOutBadWords = (sentence: string) => {
|
149 |
if (process.env.ENABLE_CENSORSHIP !== "true") { return sentence }
|
|
|
19 |
]
|
20 |
|
21 |
const ducks = [
|
22 |
+
"275123e48637924d00186a87c516116aa576dce3049460bceca691899f3cac90",
|
23 |
+
"9b7cec7230a2fcdeb8c97597865ca61f5e66ec55e37aaea85cbe934f593856c0",
|
24 |
+
"2812acc35c3aa389afb3054d36c69f5f9b6cb4ef76d45cf26d9318feee8489db",
|
25 |
+
"4a6d9b2bcf6e40c84e243861aa7df26773f442f75402e33094be15132eae87cf",
|
26 |
"1c52cb20c0cbc76349fa63232b982bd394cf0850ebc17240dcf33c19fb15a26d",
|
27 |
"e1d4de9b8d464d7da07c276b63a42c1c9922224f0a6cab6b0826427ce4a7461a",
|
28 |
"0be3174bfb1a48a65875c2f035b1ae14fbc8f232f55785018de0cfe2132fa952",
|
|
|
53 |
"76cdade0b3d4caf0888f60318a5cbca00f830a3b0bf37735fc64fdaeb67c34d3",
|
54 |
"1bf53c97869e1ea89bda19da64a9173d48fe4ec823e949e2c898f8abb3fbf457",
|
55 |
"1bf53c97869e1ea89bda19da64a9173d48fe4ec823e949e2c898f8abb3fbf457",
|
56 |
+
"3d7f973fab8f4a19c0a3e59efe970ed7bd55a1cb795752d9cbe3c19e8a7d81ec",
|
57 |
+
"62d6c28013b3852fd0b554f1f0d95dfcf6bfc9ce68e04b772aa748dddbe8afa0",
|
58 |
+
"37694dbebbb59f4289834a582b11db005c402e59ee9f8634772f3fc312ec8ea3",
|
59 |
+
"a024cb788656f9bda41d572c55e1a5e912a6067d99f2c8630eb0d44537692ec7",
|
60 |
+
"8175b29dc4d1c6d57b9d986f2f9ebbddf1d4ba597a35962ea246e4a5d4d0b850",
|
61 |
+
"148767417d2efc77acb2da36f93bc5015a6977ab449ac4fcf07855c3819bbc50",
|
62 |
+
"598e316d62873f658a35be0b2c00d30426033fa7110874488a0a3b6fb28fe055",
|
63 |
+
"2f285382bc482be84067745f99d1c0d50781f451823b62706c5b5676dbacbf89",
|
64 |
+
"8fdd4e08891194ff67e489c042ea08be24e436d97022e5c8241e8f90512bdde2",
|
65 |
+
"6a73e93289e6b05f767d1a980592588d4409c1c692365b06ad0b1981d183123f",
|
66 |
+
"42d5a173c8fb1926ea10410f4e4f8bc84dca971305ae7ccfe1c8a600343af89e",
|
67 |
+
"27f291178bfcdfdc90aaf220dcc4c4b976915fcd2700af6d203dd7405f81c695",
|
68 |
+
"f0e023194463f09a7ae09c476a5f9d50f62cc18381fcb5bde2185d93a24fe68d",
|
69 |
+
"6d273ae558f6be0fa67bbefe281b25d3312ad94e59972782557459e3dfd4e458",
|
70 |
+
"620e96eae4f3e88cbe0770292b33724c5df3866d83f39df6380441f7271c80e2"
|
71 |
]
|
72 |
|
73 |
const banned = [
|
74 |
+
"03398ec4bdce4de69c76caf151cf3e1db5454208e88da147d607327a56d9ec27",
|
75 |
+
"f27229416e1e11b9e7fe28f81fedff6cba2f6cd21eb8ac0d78e74908fbef1bd5",
|
76 |
+
"8175b29dc4d1c6d57b9d986f2f9ebbddf1d4ba597a35962ea246e4a5d4d0b850",
|
77 |
+
"e960effc886938d2668eb534853812e225b85155f7710eae26588de5b53ac021",
|
78 |
+
"d4610b2275d30ba419844fc84a6f2b5c0eafdd708395076f510e5e4503eec112",
|
79 |
+
"8b6cc149eb1ab3d92c43ba3bfa828e0b1ef943280b4eab4c5b9253766459a79e",
|
80 |
+
"cb345cd0e5c7126dfeca689e40cf4793af1d5af2a1aabd32013d30332b128fae",
|
81 |
+
"d13d07be3208feb83fb20c1d0a89c47d580fac3e1909a696bc07ecd419b22455",
|
82 |
+
"3c5c25b5b049f5d1bb1fcb32ad09f43c90d696f57bec456e53cde5a83e56bc06",
|
83 |
+
"68f4a683152587cd54990465d83b5701e57c63359c0f347cb1a81d60be3e3cd9",
|
84 |
+
"efd9c0a391ee93251046a58326d1b21b33fe21d71a3fb1855b9048ade53df77c",
|
85 |
+
"c82e151dd07b5ab5f3790c7e18f22d4fc81c339facd116fef4d21360fcfd21c5",
|
86 |
+
"f59a1abfa25e4cf546c31c81e94f9bae377c79b4e4b199179fa97a328b1a4847",
|
87 |
+
"1ae56aafb3a9c846294f842ca5a06c9e4fcb18f550878fbed1e7e10ae1af635e",
|
88 |
+
"8f160c6fd8ccc3fb2a371a4b52748f0bd030766627c4322e2911fe82f6b10497",
|
89 |
"8a05d4869d9d6ce388c6cd2db13ca12b88097b90f9be027d5ffaaa467c7a6e5e",
|
90 |
"0c475212a608138244c5fc150b1563e5ef79c516234fd78dcd5993f726c359a0",
|
91 |
"df17388805f99f2ff3e5ae97a0f55e5c927eb47f17ca65822bf8c88f02bac3dd",
|
|
|
176 |
.map(item => getFingerprint(item)), null, 2))
|
177 |
}
|
178 |
|
179 |
+
/*
|
180 |
+
encode([
|
181 |
+
])
|
182 |
+
*/
|
183 |
+
|
184 |
|
185 |
export const filterOutBadWords = (sentence: string) => {
|
186 |
if (process.env.ENABLE_CENSORSHIP !== "true") { return sentence }
|
src/app/server/actions/community.ts
CHANGED
@@ -28,16 +28,6 @@ export async function postToCommunity({
|
|
28 |
console.log(`user attempted to use bad words! their original prompt is: ${before}`)
|
29 |
}
|
30 |
|
31 |
-
if (prompt.includes("mastiff")
|
32 |
-
|| prompt.includes("anthro dog")
|
33 |
-
|| prompt.includes("open-legged")
|
34 |
-
|| prompt.includes("peeing")
|
35 |
-
|| prompt.includes("muscular")
|
36 |
-
|| prompt.includes("exposed")) {
|
37 |
-
// nope, there will be no "large muscular mastiff becoming bigger" on the community roll.
|
38 |
-
throw new Error(`error`)
|
39 |
-
}
|
40 |
-
|
41 |
// if the community API is disabled,
|
42 |
// we don't fail, we just mock
|
43 |
if (!apiUrl) {
|
|
|
28 |
console.log(`user attempted to use bad words! their original prompt is: ${before}`)
|
29 |
}
|
30 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
31 |
// if the community API is disabled,
|
32 |
// we don't fail, we just mock
|
33 |
if (!apiUrl) {
|