🎓 הקורס הדיגיטלי המקיף בישראל ל-Claude — לעבוד חכם יותר עם Claude
פפרומפטים.AIחיפוש
🤖

Skill Few-shot Prompting — דוגמאות בהנחיה ל-Claude

שיטת Prompting המספקת דוגמאות ספורות למודל להדגמת הפלט הרצוי.

few-shot-prompting · v1.0.0💾 3KB · חינם🧩 חלק מחבילת מומחה AI לעסקים
מה זה Skill ואיך מתקינים?

Skill הוא יכולת קבועה ש-Claude טוען אוטומטית כשהיא רלוונטית לבקשה שלך — בניגוד לפרומפט רגיל שצריך להעתיק מחדש בכל שיחה. מתקינים פעם אחת (מעבירים תיקייה אל ~/.claude/skills/ או מעלים דרך הגדרות האפליקציה), ומאז הוא עובד לבד — ללא כל פעולה נוספת.

חדש ל-Claude? התחל כאן ←

⬇️ הורדת ה-Skill (3KB)

ZIP · ללא הרשמה · רישיון שימוש כלול בקובץ

📖 מה ה-Skill הזה כולל

מתי להשתמש

"Few-shot", "One-shot", "Examples in prompt", "In-context learning".

הוראות עבודה

1. What is Few-shot

Provide examples of input → output in the prompt. AI learns the pattern.

2. Performance Boost

  • Zero-shot (no examples): baseline.
  • 1-shot: +10-30% accuracy on classification.
  • 3-shot: +20-50% on complex tasks.
  • 5-10-shot: marginal improvement after.

3. When to Use

✅ Best For

  • Classification (categorize text).
  • Extraction (extract structured data).
  • Style matching (match brand voice).
  • Format consistency (JSON output).
  • Edge cases that AI might miss.

❌ Skip For

  • Simple Q&A.
  • Creative tasks (limits creativity).
  • One-off tasks (overhead).

4. Few-shot Template

Task: Classify customer emails into categories.

Categories: billing, technical, general, complaint

Examples:

Email: "I can't login to my account, getting error 500."
Category: technical

Email: "Charged twice this month, need refund."
Category: billing

Email: "What are your business hours?"
Category: general

Email: "Service has been down for 3 days, awful experience!"
Category: complaint

Now classify:

Email: "{{actual email}}"
Category:

5. Choosing Examples

Good Examples

  • Diverse — cover different cases.
  • Edge cases — tricky boundaries.
  • Real-world — from actual data.
  • Balanced — across categories.

Bad Examples

  • All same type.
  • Trivial cases only.
  • Made-up data unlike reality.

6. Example Count — Trade-offs

Count Pros Cons
1-shot Fast, cheap Less learning
3-shot Sweet spot Balanced
5+ shot Best accuracy Costly, slow
10+ shot Marginal gain Expensive

7. Format Matters

Consistent Format

Q: ... 
A: ...

Q: ...
A: ...

Or

Input: ... → Output: ...

Or JSON

[
  {"input": "...", "output": "..."},
  {"input": "...", "output": "..."}
]

8. Few-shot + CoT

Combine for hard tasks:

Example:
Input: ...
Reasoning: First I notice X, then Y leads to Z.
Output: ...

Now solve:
Input: ...
Reasoning:
Output:

9. Dynamic Few-shot (RAG-like)

For production:

  • Store many examples in DB.
  • Retrieve most similar to current input.
  • Insert as few-shot examples.
  • Best of both worlds.

10. Common Mistakes

Too many examples — diminishing returns + cost. ❌ Examples too similar — narrow learning. ❌ Examples contradict instructions. ❌ Bad examples — AI learns wrong patterns.

11. Cost

  • Few-shot adds tokens to every call.
  • Long examples × many calls = expensive.
  • Prompt caching (Anthropic) — caches examples = 90% cheaper.

12. אסיים בהמלצה.

פרומפט לדוגמה

3-shot prompt for sentiment classification.

Few-shot or fine-tuning? Decision criteria.

Examples for extracting data from invoices.


© 2026 AI Expert Pro | גרסה 1.0.0

📥 התקנה בחצי דקה

  1. 1. הורד ופתח את קובץ ה-ZIP — תקבל תיקייה בשם few-shot-prompting.
  2. 2. ב-Claude Code: העבר את התיקייה אל ~/.claude/skills/.
    באפליקציה (Claude / Cowork): הגדרות ← Capabilities ← Skills ← העלאה.
  3. 3. בקש מ-Claude את מה שצריך בעברית — הוא יפעיל את ה-skill לבד כשזה רלוונטי.

רוצה skill כזה, אבל מותאם בדיוק לעסק שלך?

בקורס Claude לעסקים תלמד לבנות skills משלך — לתהליכים הספציפיים שלך, בעברית, בלי תלות באף אחד.

לפרטים על לעבוד חכם יותר עם Claude ←

🧩 עוד skills מחבילת מומחה AI לעסקים

📚 פרומפטים באותו תחום

קהילה