Llama 3.3 / 3.1by Meta
Llama Prompt Generator
Optimise prompts for Meta's open-source Llama models — self-hosted or via API.
Meta's Llama 3.3 (70B) and Llama 3.1 (405B) are the most capable open-source AI models available in 2026 — freely downloadable, self-hostable, and competitive with proprietary models on many benchmarks. Whether you're running Llama locally, via Ollama, or through a cloud API, well-structured prompts dramatically improve output quality. PromptIt crafts prompts optimised for Llama's instruction-tuned variants.
What makes a great Llama prompt?
1Instruction-tuned Llama models (chat variants) respond best to the [INST] prompt format — PromptIt structures prompts in the right template
2Llama 3.3 70B is a sweet spot model — capable enough for complex tasks, efficient enough to run locally on consumer hardware
3System prompt headers are critical for Llama — define the AI's role and behaviour at the start for consistent outputs
4For self-hosted Llama, shorter context prompts (under 2K tokens) run significantly faster — be concise without losing specificity
Before & after: how PromptIt improves your Llama prompts
Used Llama's [INST] chat template, defined a specific expert persona in the system prompt, specified word count, and structured 5 distinct output sections — matching Llama's training format for instruction-tuned models.
✗ Weak prompt
“Write a product review.”
✓ PromptIt-optimised
<|system|>You are a professional product reviewer with 10 years of experience writing honest, balanced consumer tech reviews. Your reviews are structured, evidence-based, and help readers make purchasing decisions. You do not accept PR speak or vague claims.</s><|user|>Write a 400-word product review for the [product name]. Structure: 1) Quick Verdict (2 sentences, include a 1-10 score). 2) What We Liked (3 bullet points with specifics). 3) What Could Be Better (2 bullet points). 4) Who Should Buy It (one paragraph). 5) Final Recommendation. Use specific details and concrete comparisons where possible.</s>
Ready-to-use Llama prompt starters
Local AI Tasks
<|system|>You are [expert role]. [Behaviour instructions].</s><|user|>[Specific task with format requirements]. [Constraints]. [Paste content if applicable].</s>
Code Generation
<|system|>You are an expert [language] developer. Write clean, well-commented code with proper error handling.</s><|user|>Write a [language] function that [does X]. Requirements: [list requirements]. Include: function, docstring, unit tests, usage example.</s>
Text Classification
<|system|>You are a text classification assistant. Respond with JSON only, no explanation.</s><|user|>Classify the following text into one of these categories: [list categories]. Text: '[paste text]'. Respond: {'category': '[category]', 'confidence': [0-1], 'reasoning': '[brief]'}</s>
RAG Applications
<|system|>Answer questions based only on the provided context. If the answer is not in the context, say 'Not found in context'.</s><|user|>Context: [paste retrieved documents]. Question: [user question]</s>
Llama prompting tips
→Use the correct chat template for your Llama variant — instruction-tuned models expect [INST]/[/INST] or <|system|>/<|user|> formatting
→Define behaviour in the system prompt — Llama's instruction-tuned models are highly responsive to system-level persona and constraint setting
→For locally hosted Llama, keep prompts concise — models run faster and produce better quality output with focused, specific prompts under 2K tokens
→For RAG (retrieval augmented generation) tasks, paste retrieved context before the question and instruct the model to answer from context only
Stop writing weak Llama prompts
PromptIt analyses your rough idea and builds a complete, structured prompt with role, context, constraints, and format — ready to paste into Llama in seconds.
✦ Try PromptIt free — no card needed