Text Generation
Transformers
Safetensors
qwen2
conversational
cannabis
budtender
rag
text-generation-inference
Instructions to use Kartoon93/stoner-bud-e with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Kartoon93/stoner-bud-e with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Kartoon93/stoner-bud-e") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Kartoon93/stoner-bud-e") model = AutoModelForCausalLM.from_pretrained("Kartoon93/stoner-bud-e", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Kartoon93/stoner-bud-e with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Kartoon93/stoner-bud-e" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Kartoon93/stoner-bud-e", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Kartoon93/stoner-bud-e
- SGLang
How to use Kartoon93/stoner-bud-e with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Kartoon93/stoner-bud-e" \ --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": "Kartoon93/stoner-bud-e", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
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 "Kartoon93/stoner-bud-e" \ --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": "Kartoon93/stoner-bud-e", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Kartoon93/stoner-bud-e with Docker Model Runner:
docker model run hf.co/Kartoon93/stoner-bud-e
πΏ Stoner Bud-E (Kartoon93/stoner-bud-e)
Stoner Bud-E is a 7.62B-parameter conversational language model (Qwen2ForCausalLM, bfloat16) tailored for cannabis culture, strain genetics, terpene pharmacology, vaporizer temperature guidance, and responsible edible dosing education.
- π Live Interactive Space & Sommelier Suite: spaces/Kartoon93/stoner-bud-e
- π Direct Web App URL: https://kartoon93-stoner-bud-e.static.hf.space/index.html
π Model Specifications
| Property | Value |
|---|---|
| Architecture | Qwen2ForCausalLM (Qwen/Qwen2.5-7B-Instruct family) |
| Total Parameters | 7,615,616,512 (7.62B) |
| Tensor Precision | BF16 (safetensors, 4 shards, ~15.24 GB) |
| Context Length | 32,768 tokens |
| Hidden Size / Layers | 3584 hidden dim / 28 transformer layers |
| Attention Heads (GQA) | 28 Query heads / 4 Key-Value heads |
| Vocabulary Size | 152,064 |
π» Quickstart (transformers)
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
MODEL_ID = "Kartoon93/stoner-bud-e"
tokenizer = AutoTokenizer.from_pretrained(MODEL_ID)
model = AutoModelForCausalLM.from_pretrained(
MODEL_ID,
dtype=torch.bfloat16,
attn_implementation="sdpa",
device_map="auto",
).eval()
messages = [
{
"role": "system",
"content": (
"You are Stoner Bud-E, a chill, friendly, and knowledgeable AI budtender "
"and cannabis sommelier."
),
},
{
"role": "user",
"content": "Compare Blue Dream and Gelato β terpene profiles, lineage, and effects.",
},
]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer([prompt], return_tensors="pt").to(model.device)
with torch.no_grad():
output_ids = model.generate(
**inputs,
max_new_tokens=512,
temperature=0.7,
top_p=0.8,
repetition_penalty=1.05,
)
response = tokenizer.decode(output_ids[0][inputs.input_ids.shape[1]:], skip_special_tokens=True)
print(response)
- Downloads last month
- -