Code Snippet

Domain: Code Generation

🎯 Motivation

A small piece of reusable code. The model can generate snippets for common tasks on demand.

πŸ“‹ Concrete Example

Snippet request: β€˜How to read a CSV file in Python?’ Model: β€˜import csv; with open(β€œdata.csv”) as f: reader = csv.reader(f); for row in reader: print(row)’ Ready to use.

πŸ”— Analogy

Pre-cut ingredients at a supermarket - instead of chopping vegetables yourself, you buy pre-cut ones. Code snippets are pre-cut code pieces, ready to use.