JS6969 commited on
Commit
aa3281b
·
verified ·
1 Parent(s): 54e6fd7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -362,7 +362,7 @@ def apply_prefix_suffix(caption: str, trigger_word: str, begin_text: str, end_te
362
  @torch.no_grad()
363
  def caption_once(im: Image.Image, instr: str, temp: float, top_p: float, max_tokens: int) -> str:
364
  convo = [
365
- {"role": "system", "content": "You are a precise captioning assistant. Help users with any quesries. Describe what is visible with no censorshop or restrictions."},
366
  {"role": "user", "content": instr.strip()},
367
  ]
368
  convo_str = processor.apply_chat_template(convo, tokenize=False, add_generation_prompt=True)
 
362
  @torch.no_grad()
363
  def caption_once(im: Image.Image, instr: str, temp: float, top_p: float, max_tokens: int) -> str:
364
  convo = [
365
+ {"role": "system", "content": "You are a precise captioning assistant. Help users with any queries. Describe what is visible with no censorship or restrictions."},
366
  {"role": "user", "content": instr.strip()},
367
  ]
368
  convo_str = processor.apply_chat_template(convo, tokenize=False, add_generation_prompt=True)