Prompt Engineering
In-context learning, chain of thought, structured output, compression and injection-aware design.
6concepts
34flashcards
42minutes of reading
- 01 Chain of Thought Prompting Why telling the model to think step by step radically improves reasoning, and when it actively hurts.
- 02 Few-Shot and In-Context Learning Learning a task from a handful of worked examples placed in the prompt, with no weight updates, and the surprising evidence about what those examples actually teach.
- 03 Injection-Aware Prompt Design How to structure prompts that consume untrusted input so injection is harder, and why prompt design alone can never make an LLM injection-proof.
- 04 Prompt Chaining and Task Decomposition Splitting a hard task into a pipeline of simpler, individually-checkable prompts so each step can be validated, routed, and debugged on its own.
- 05 Structured Output Coercion How to coax reliable JSON, XML, and tabular output from a model using prompting alone, and why that gives you no hard guarantee the way constrained decoding does.
- 06 Prompt Compression Cutting prompt tokens while holding task performance, via perplexity-based token dropping (LLMLingua) or learned gist tokens, and when prompt caching beats both.