Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -61,9 +61,9 @@ def extract_tone(text):
|
|
| 61 |
# Categorize frames based on importance
|
| 62 |
def categorize_frame_importance(text, keywords):
|
| 63 |
keyword_count = sum(text.lower().count(keyword) for keyword in keywords)
|
| 64 |
-
if keyword_count >
|
| 65 |
return "Major Focus"
|
| 66 |
-
elif keyword_count ==
|
| 67 |
return "Significant Focus"
|
| 68 |
else:
|
| 69 |
return "Minor Mention"
|
|
|
|
| 61 |
# Categorize frames based on importance
|
| 62 |
def categorize_frame_importance(text, keywords):
|
| 63 |
keyword_count = sum(text.lower().count(keyword) for keyword in keywords)
|
| 64 |
+
if keyword_count > 3:
|
| 65 |
return "Major Focus"
|
| 66 |
+
elif keyword_count == 2 or keyword_count == 3:
|
| 67 |
return "Significant Focus"
|
| 68 |
else:
|
| 69 |
return "Minor Mention"
|