Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -34,9 +34,9 @@ def full_adjective_replacement(input_text):
|
|
| 34 |
text = input_text
|
| 35 |
print(text)
|
| 36 |
|
| 37 |
-
for adjective in adjectives
|
| 38 |
adjective_biased = determine_biased_adjective(input_text, adjective)
|
| 39 |
-
if adjective_biased
|
| 40 |
new_adjective = replace_biased_adjective(adjective)
|
| 41 |
text = replace_adjective_in_text(text, adjective, new_adjective)
|
| 42 |
print(text)
|
|
@@ -63,9 +63,9 @@ def determine_biased_adjective(input_text, adjective):
|
|
| 63 |
|
| 64 |
answer = insideRespond(processed_text, system_message)
|
| 65 |
|
| 66 |
-
if answer == "yes"
|
| 67 |
return true
|
| 68 |
-
if answer == "no"
|
| 69 |
return false
|
| 70 |
|
| 71 |
|
|
|
|
| 34 |
text = input_text
|
| 35 |
print(text)
|
| 36 |
|
| 37 |
+
for adjective in adjectives:
|
| 38 |
adjective_biased = determine_biased_adjective(input_text, adjective)
|
| 39 |
+
if adjective_biased:
|
| 40 |
new_adjective = replace_biased_adjective(adjective)
|
| 41 |
text = replace_adjective_in_text(text, adjective, new_adjective)
|
| 42 |
print(text)
|
|
|
|
| 63 |
|
| 64 |
answer = insideRespond(processed_text, system_message)
|
| 65 |
|
| 66 |
+
if answer == "yes":
|
| 67 |
return true
|
| 68 |
+
if answer == "no":
|
| 69 |
return false
|
| 70 |
|
| 71 |
|