basic prompting を超える advanced techniques、例えば few-shot、chain-of-thought、structured output、system prompts などは、complex task で LLM result を大きく改善します。これらを理解すると LLM をより効果的に使えます。
key advanced techniques
text
✓ FEW-SHOT → prompt に input/output examples を入れる → model が pattern に従う
(specific formats/behaviors に有効)。ZERO-SHOT = examples なし
✓ CHAIN-OF-THOUGHT (CoT) → step by step に REASON させる
→ complex reasoning/math で改善することがある
✓ STRUCTURED OUTPUT → JSON など specific format を要求 → app integration で parse しやすい
✓ SYSTEM PROMPTS → overall behavior/role/rules を設定
✓ ROLE/persona → 'You are an expert X' で response を frame
more techniques
text
✓ DECOMPOSITION → complex task を smaller prompts/steps に分解 (prompt chaining)
✓ SELF-CONSISTENCY → multiple answers を生成し majority を取る
✓ CONTEXT/data を prompt に入れる (grounding); RAG
✓ CONSTRAINTS → what to do と NOT do、format/length/tone を指定
✓ ITERATE and refine; prompts を systematically test する
