Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -86,7 +86,8 @@ def get_prediction(input_text, input_type):
|
|
86 |
|
87 |
def phishing_detection(input_text, input_type):
|
88 |
prediction = get_prediction(input_text, input_type)
|
89 |
-
|
|
|
90 |
return f"Warning: This site is likely a phishing site! ({prediction:.2f})"
|
91 |
else:
|
92 |
return f"Safe: This site is not likely a phishing site. ({prediction:.2f})"
|
@@ -103,4 +104,4 @@ iface = gr.Interface(
|
|
103 |
theme="default"
|
104 |
)
|
105 |
|
106 |
-
iface.launch()
|
|
|
86 |
|
87 |
def phishing_detection(input_text, input_type):
|
88 |
prediction = get_prediction(input_text, input_type)
|
89 |
+
threshold = 0.7 # Adjusted threshold
|
90 |
+
if prediction > threshold:
|
91 |
return f"Warning: This site is likely a phishing site! ({prediction:.2f})"
|
92 |
else:
|
93 |
return f"Safe: This site is not likely a phishing site. ({prediction:.2f})"
|
|
|
104 |
theme="default"
|
105 |
)
|
106 |
|
107 |
+
iface.launch()
|