Views
No views yet
In an era where truth was as elusive as a shadow cast by a passing cloud, humanity found itself at the mercy of an unprecedented technology…
The tool didn't invent fakery; it let a lie inherit the credibility of the real map underneath it. On Monday, August 1, Google's…
1from transformers import AutoModelForCausalLM, AutoTokenizer
2from peft import PeftModel
3import torch
4
5base = "Qwen/Qwen2.5-1.5B-Instruct"
6tok = AutoTokenizer.from_pretrained(base)
7model = AutoModelForCausalLM.from_pretrained(base, dtype=torch.bfloat16, device_map="auto")
8model = PeftModel.from_pretrained(model, "MrPIck/pickbits-voice-daily-v1")
9
10messages = [
11 {"role": "system", "content": "You are the PickBits staff writer. Write in the house voice."},
12 {"role": "user", "content": "Engine: daily-signal\nTask: tldr bullet\nSeed: EU AI Act enforcement began today with..."},
13]
14ids = tok.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt", return_dict=False).to(model.device)
15out = model.generate(ids, max_new_tokens=400, temperature=0.7, top_p=0.9, do_sample=True)
16print(tok.decode(out[0, ids.shape[1]:], skip_special_tokens=True))Engine: daily-signal, Task: story section | tldr bullet | edition standfirst); other prompt shapes are out of distribution.