Prompt Library (JSONL)
A reusable prompt library in JSON Lines — 20 templated prompts for summarization, translation, extraction, code, and more, each with a task label, tags, and {curly-brace} placeholders. A fixture for prompt-management tools and JSONL parsers.
{"id": "pl-000", "task": "summarize", "prompt": "Summarize the following text in three concise bullet points:\n\n{text}", "tags": ["summarization"]}
{"id": "pl-001", "task": "translate", "prompt": "Translate the text below into {target_language}. Preserve tone and formatting.\n\n{text}", "tags": ["translation"]}
{"id": "pl-002", "task": "classify", "prompt": "Classify the sentiment of this review as positive, negative, or neutral. Reply with one word.\n\n{text}", "tags": ["classification"]}
{"id": "pl-003", "task": "extract", "prompt": "Extract every email address and phone number from the text as a JSON object.\n\n{text}", "tags": ["extraction"]}
{"id": "pl-004", "task": "rewrite", "prompt": "Rewrite the passage below in plain, friendly language for a general audience.\n\n{text}", "tags": ["rewriting"]}
{"id": "pl-005", "task": "codegen", "prompt": "Write a {language} function that {task}. Include a short docstring and one example.", "tags": ["code"]}
{"id": "pl-006", "task": "explain", "prompt": "Explain the following code to a junior developer, step by step.\n\n{code}", "tags": ["code", "explanation"]}
{"id": "pl-007", "task": "sql", "prompt": "Given this schema:\n{schema}\nWrite a SQL query that {request}.", "tags": ["sql", "code"]}
{"id": "pl-008", "task": "qa", "prompt": "Answer the question using only the context. If the answer isn't present, say 'not found'.\n\nContext: {context}\nQuestion: {question}", "tags": ["qa"]}
{"id": "pl-009", "task": "title", "prompt": "Suggest five concise, engaging titles for an article about {topic}.", "tags": ["brainstorm"]}
{"id": "pl-010", "task": "keywords", "prompt": "List the 8 most important keywords in the text, comma-separated.\n\n{text}", "tags": ["extraction"]}
{"id": "pl-011", "task": "tone", "prompt": "Rewrite this message to sound more {tone} while keeping the meaning.\n\n{text}", "tags": ["rewriting"]}
{"id": "pl-012", "task": "outline", "prompt": "Create a structured outline for a {length}-minute talk about {topic}.", "tags": ["brainstorm"]}
{"id": "pl-013", "task": "json-fix", "prompt": "The following JSON is invalid. Return only the corrected, valid JSON.\n\n{json}", "tags": ["code", "repair"]}
{"id": "pl-014", "task": "steps", "prompt": "Break the goal below into a numbered, actionable checklist.\n\nGoal: {goal}", "tags": ["planning"]}
{"id": "pl-015", "task": "compare", "prompt": "Compare {a} and {b} across cost, speed, and ease of use in a small table.", "tags": ["analysis"]}
{"id": "pl-016", "task": "regex", "prompt": "Write a regular expression that matches {pattern_description}. Explain each part.", "tags": ["code"]}
{"id": "pl-017", "task": "email", "prompt": "Draft a polite, {length}-sentence email that {purpose}.", "tags": ["writing"]}
{"id": "pl-018", "task": "faq", "prompt": "From the document below, generate five FAQ question-and-answer pairs.\n\n{document}", "tags": ["generation"]}
{"id": "pl-019", "task": "sentiment-batch", "prompt": "For each line of input, output the line number and its sentiment label.\n\n{lines}", "tags": ["classification"]}
Specifications
- Prompts
- 20
- Schema
- id, task, prompt, tags[]
- Placeholders
- {curly_brace}
What is a .jsonl file?
JSONL (JSON Lines) is a text format where each line is a complete, independent JSON value, allowing records to be streamed and appended without parsing the whole file. It is not itself a JSON array and each line must stand alone. It is common in logging, machine learning datasets, and data pipelines.
How to use this file
Use an example JSONL to test line-by-line streaming parsers, append-and-resume ingestion, and batch pipelines that process one record per line.
Code examples
import json
with open("prompt-library.jsonl") as f:
rows = [json.loads(line) for line in f]
print(len(rows), rows[0])Related files
- jsonlChat Fine-tuning Dataset — Anthropic Format (JSONL)The same synthetic conversations in the Anthropic Messages JSONL shape — a top-level system prompt plus a messages array of user and assistant turns. The format twin of the OpenAI file, for testing chat-format conversion.

- jsonlChat Fine-tuning Dataset — OpenAI Format (JSONL)A chat fine-tuning dataset in the OpenAI JSONL format — one conversation per line as a messages array with system, user, and assistant turns. Synthetic Q&A content. Paired with an Anthropic-format twin for testing format converters.

- jsonExtractive QA Dataset — SQuAD v2 Format (JSON)An extractive question-answering dataset in the SQuAD v2.0 JSON structure — titled articles with context paragraphs, questions, character-offset answers, and one deliberately unanswerable question. Synthetic content; a fixture for QA model training and SQuAD-format loaders.

- jsonlInstruction-tuning Dataset — Alpaca Format (JSONL)An instruction-tuning dataset in the Alpaca JSONL format — 20 instruction / input / output triples covering small transformations, extraction, and factual answers. Fully synthetic; a fixture for supervised fine-tuning pipelines.

- jsonlNamed-Entity Recognition Dataset — BIO Tags (JSONL)A token-classification dataset in JSON Lines — 16 tokenized sentences with aligned BIO tags for person, organisation, and location entities. All names, companies, and places are fictional. A fixture for NER model training and sequence-labelling tooling.

- jsonlParallel Translation Corpus — EN↔ES (JSONL)An English↔Spanish parallel corpus in JSON Lines — 20 aligned sentence pairs of everyday phrases. A fixture for training and evaluating machine-translation models and for testing UTF-8 handling of accented characters.

Generated by generation/ai_datasets.py. Free for any use, no attribution required — license.