Spaces:
Runtime error
Runtime error
phenomenon1981
commited on
Commit
ยท
146c0b4
1
Parent(s):
edf9f05
Update app.py
Browse files
app.py
CHANGED
@@ -36,7 +36,7 @@ def add_random_noise(prompt, noise_level=0.07):
|
|
36 |
noise_indices = random.sample(range(len(prompt)), num_noise_chars)
|
37 |
prompt_list = list(prompt)
|
38 |
noise_chars = list(string.ascii_letters + string.punctuation + ' ' + string.digits)
|
39 |
-
noise_chars.extend(['๐', '๐ฉ', '๐', '๐ค', '๐', '๐ค', '๐ญ', '๐', '๐ท', '
|
40 |
for index in noise_indices:
|
41 |
prompt_list[index] = random.choice(noise_chars)
|
42 |
return "".join(prompt_list)
|
|
|
36 |
noise_indices = random.sample(range(len(prompt)), num_noise_chars)
|
37 |
prompt_list = list(prompt)
|
38 |
noise_chars = list(string.ascii_letters + string.punctuation + ' ' + string.digits)
|
39 |
+
noise_chars.extend(['๐', '๐ฉ', '๐', '๐ค', '๐', '๐ค', '๐ญ', '๐', '๐ท', '๐คฏ', '๐คซ', '๐ฅด', '๐ด', '๐คฉ', '๐ฅณ', '๐', '๐ฉ', '๐คช', '๐', '๐คข', '๐', '๐น', '๐ป', '๐ค', '๐ฝ', '๐', '๐', '๐
', '๐', '๐', '๐', '๐', '๐', '๐', '๐ฎ', 'โค๏ธ', '๐', '๐', '๐', '๐', '๐ถ', '๐ฑ', '๐ญ', '๐น', '๐ฆ', '๐ป', '๐จ', '๐ฏ', '๐ฆ', '๐', '๐ฅ', '๐ง๏ธ', '๐', '๐', '๐ฅ', '๐ด', '๐', '๐บ', '๐ป', '๐ธ', '๐จ', '๐
', '๐', 'โ๏ธ', 'โ๏ธ', 'โ๏ธ', 'โ๏ธ', '๐ค๏ธ', 'โ
๏ธ', '๐ฅ๏ธ', '๐ฆ๏ธ', '๐ง๏ธ', '๐ฉ๏ธ', '๐จ๏ธ', '๐ซ๏ธ', 'โ๏ธ', '๐ฌ๏ธ', '๐จ', '๐ช๏ธ', '๐'])
|
40 |
for index in noise_indices:
|
41 |
prompt_list[index] = random.choice(noise_chars)
|
42 |
return "".join(prompt_list)
|