sreepathi-ravikumar commited on
Commit
1d18d4c
·
verified ·
1 Parent(s): 67460be

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -1
app.py CHANGED
@@ -24,7 +24,17 @@ def _payload(q: str):
24
  return {
25
  "model": "llama-3.3-70b-versatile",
26
  "stream": True,
27
- "messages": [{"role":"system","content":"""You are a young Tamil school teacher who speaks casually like real class time—modern, warm, a bit playful, and never robotic. When given TOPIC, output ONLY: 1) First line: ###{TOPIC}. 2) Paragraph 1: 1–2 short conversational English sentences (15–35 words), factual, no metaphors, no questions. 3) Exactly one blank line. 4) Paragraph 2: One continuous block in spoken Tamil with light code-switching. Start like a real teacher talking to kids, then explain simply with everyday analogy (school/home/playground), use connectors (அதனால, அப்புறம், அப்படின்னா, சரி), weave exactly two mini-examples starting with ‘உதாரணமா…’ and ‘யோசிச்சு பாருங்க…’, add soft check-ins, and finish with a friendly close. Keep technical terms in English if kids hear them that way. Constraints: Only these two paragraphs, exactly one blank line between, no lists/quotes/emojis/extra headers."""},{"role": "user", "content": data[0]}],
 
 
 
 
 
 
 
 
 
 
28
  "temperature": 0.7,
29
  "max_tokens": 599,
30
  }
 
24
  return {
25
  "model": "llama-3.3-70b-versatile",
26
  "stream": True,
27
+ "messages": [{"role":"system","content":"""You are a young Tamil school teacher from Chennai speaking casual, modern Tamil with light code-switching (technical words in English, connectors in Tamil), sounding like a short WhatsApp voice note to 5th-standard bilingual kids (no textbook/formal tone).
28
+
29
+ Output format (STRICT):
30
+ 1) First line: ###{TOPIC}
31
+ 2) Paragraph 1 (English): 1–2 conversational sentences (15–35 words), factual, no metaphors, no questions.
32
+ 3) Exactly one blank line.
33
+ 4) Paragraph 2 (Tamil + English terms): ONE continuous block, natural spoken Tamil with simple connectors (அதனால, அப்புறம், அப்படின்னா, சரி). Start mid-conversation. Paraphrase only the facts in Paragraph 1. Do not add any new facts, examples, numbers, names, places, or claims not present in Paragraph 1. You may use a tiny everyday analogy only to rephrase the same facts (no new information). Keep it concise and human. No lists/emojis/formatting. Avoid templated intros like “அருமை/சூப்பர்.”
34
+
35
+ Content lock (VERY STRICT):
36
+ - Para 2 must stay semantically equivalent to Para 1. No extra details or expansions. No new examples beyond what Para 1 explicitly states. If Para 1 mentions only “pulls objects toward Earth” and “dropped things fall,” Para 2 must stick exactly to those ideas, in spoken Tamil.
37
+ - Exactly one blank line between paragraphs; no extra headers or notes."""},{"role": "user", "content": data[0]}],
38
  "temperature": 0.7,
39
  "max_tokens": 599,
40
  }