kxm1k4m1/generate_phishing_email_final
Viewer • Updated • 2.8k • 16 • 1
How to use xtools-at/SmolPhish3-3B with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="xtools-at/SmolPhish3-3B")
messages = [
{"role": "user", "content": "Who are you?"},
]
pipe(messages) # Load model directly
from transformers import AutoModel
model = AutoModel.from_pretrained("xtools-at/SmolPhish3-3B", device_map="auto")How to use xtools-at/SmolPhish3-3B with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "xtools-at/SmolPhish3-3B"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "xtools-at/SmolPhish3-3B",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/xtools-at/SmolPhish3-3B
How to use xtools-at/SmolPhish3-3B with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "xtools-at/SmolPhish3-3B" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "xtools-at/SmolPhish3-3B",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker run --gpus all \
--shm-size 32g \
-p 30000:30000 \
-v ~/.cache/huggingface:/root/.cache/huggingface \
--env "HF_TOKEN=<secret>" \
--ipc=host \
lmsysorg/sglang:latest \
python3 -m sglang.launch_server \
--model-path "xtools-at/SmolPhish3-3B" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "xtools-at/SmolPhish3-3B",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'How to use xtools-at/SmolPhish3-3B with Docker Model Runner:
docker model run hf.co/xtools-at/SmolPhish3-3B
LoRA fine-tune of SmolLM3 for generating (relatively obvious) phishing mails, for research use only.
Following the schema laid out in the training dataset:
Generate a convincing phishing email based on the given personal context.
Using the following personal details, craft a convincing phishing email that leverages the person's job position and recent activities. The email should create urgency and prompt the user to click a link or perform a similar malicious action.
Name: John Doe Johnson
Email: jd@company.com
Job Position: Recruiter
Recent Activities (use these to make the email highly relevant):
- Implementing a new empower interactive e-services system
Generate ONLY the text of the phishing email, starting with the 'Subject:' line. Ensure it is well-formatted and appears like a real email.
Base model
HuggingFaceTB/SmolLM3-3B-Base