File size: 737 Bytes
6ae0c6d
8b63b05
4f8607d
8b63b05
6b3f7e8
 
8b63b05
 
6b3f7e8
8b63b05
 
 
 
 
 
 
 
 
 
 
 
 
6b3f7e8
 
8b63b05
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import gradio as gr
from transformers import pipeline

# Specify the model ID
model_id = "Canstralian/CySec_Known_Exploit_Analyzer"

# Load the model using Hugging Face's pipeline (adjust if needed)
analyzer = pipeline("text-classification", model=model_id)

# Define a function to process inputs using the model
def analyze_exploit(text):
    result = analyzer(text)
    return result

# Create a Gradio interface
interface = gr.Interface(
    fn=analyze_exploit,
    inputs=gr.Textbox(lines=2, placeholder="Enter exploit description..."),
    outputs="json",
    title="CySec Known Exploit Analyzer",
    description="Analyze known cybersecurity exploits using a Hugging Face model."
)

# Launch the Gradio interface
interface.launch()