avinash commited on
Commit
5a77d9b
·
1 Parent(s): 485d56c

modified tiny lama

Browse files
Files changed (1) hide show
  1. llm_agent.py +8 -1
llm_agent.py CHANGED
@@ -7,7 +7,14 @@ tokenizer = AutoTokenizer.from_pretrained(model_name)
7
  model = AutoModelForCausalLM.from_pretrained(model_name)
8
 
9
  def get_llm_reply(user_input: str) -> str:
10
- prompt = f"User: {user_input}\nAssistant:"
 
 
 
 
 
 
 
11
  inputs = tokenizer(prompt, return_tensors="pt")
12
  output = model.generate(
13
  **inputs,
 
7
  model = AutoModelForCausalLM.from_pretrained(model_name)
8
 
9
  def get_llm_reply(user_input: str) -> str:
10
+ prompt = f"""
11
+ You are 'FreightBot', an AI freight agent that helps with truckload bookings, price estimates, and delivery updates.
12
+
13
+ Respond in a short, professional style like a real broker. Always sound confident.
14
+
15
+ User: {user_input}
16
+ FreightBot:
17
+ """
18
  inputs = tokenizer(prompt, return_tensors="pt")
19
  output = model.generate(
20
  **inputs,