rmdhirr commited on
Commit
26ce0ac
1 Parent(s): 3d7830a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -62,7 +62,7 @@ model.compile(optimizer=tf.keras.optimizers.Adam(learning_rate=0.0005),
62
  metrics=['accuracy', tf.keras.metrics.Precision(), tf.keras.metrics.Recall()])
63
 
64
  # Chatbot setup
65
- access_token = 'your_pro_gpt_access_token'
66
  chatbot = Conversation(access_token)
67
 
68
  # Function to preprocess input
@@ -116,13 +116,13 @@ def interface(input_text, input_type):
116
  iface = gr.Interface(
117
  fn=interface,
118
  inputs=[
119
- gr.inputs.Textbox(lines=5, placeholder="Enter URL or HTML code"),
120
- gr.inputs.Radio(["URL", "HTML"], type="value", label="Input Type")
121
  ],
122
  outputs=[
123
- "text",
124
- gr.outputs.Textbox(label="Latest Phishing Sites"),
125
- gr.outputs.Textbox(label="Chatbot Response")
126
  ],
127
  title="Phishing Detection with Enhanced EWC Model",
128
  description="Check if a URL or HTML is Phishing. Latest phishing sites from PhishTank and a chatbot assistant for phishing issues.",
 
62
  metrics=['accuracy', tf.keras.metrics.Precision(), tf.keras.metrics.Recall()])
63
 
64
  # Chatbot setup
65
+ access_token = 'eyh-bc'
66
  chatbot = Conversation(access_token)
67
 
68
  # Function to preprocess input
 
116
  iface = gr.Interface(
117
  fn=interface,
118
  inputs=[
119
+ gr.components.Textbox(lines=5, placeholder="Enter URL or HTML code"),
120
+ gr.components.Radio(["URL", "HTML"], type="value", label="Input Type")
121
  ],
122
  outputs=[
123
+ gr.components.Textbox(label="Phishing Detection Result"),
124
+ gr.components.Textbox(label="Latest Phishing Sites"),
125
+ gr.components.Textbox(label="Chatbot Response")
126
  ],
127
  title="Phishing Detection with Enhanced EWC Model",
128
  description="Check if a URL or HTML is Phishing. Latest phishing sites from PhishTank and a chatbot assistant for phishing issues.",