Prompt Compression

Domain: Prompt Engineering

🎯 Motivation

Long prompts cost more. Compression techniques (shorter phrasing, removing redundancy, using abbreviations) reduce cost while preserving meaning.

πŸ“‹ Concrete Example

Original: β€˜Please write a summary of the following text. Make it concise and capture the main points. The summary should be no more than 3 sentences.’ Compressed: β€˜Summarize in 3 sentences: [text]’ Same meaning, fewer tokens.

πŸ”— Analogy

Packing a suitcase efficiently - instead of stuffing everything in loosely (verbose prompt), you roll clothes and remove unnecessary items (compress). Same contents, smaller space (fewer tokens).