Example of a JSON Prompt Representation
A prompt defining a task can be formatted as a JSON object to represent its components as key-value pairs clearly. For example, a JSON structure for translation might define keys such as 'Task' as 'Translation', 'Source language' as 'English', 'Target language' as 'Chinese', 'Style' as 'Formal text', and 'Template' as 'Translate the following sentence: '. This attribute-based approach helps organize complex instructions systematically.
0
1
Tags
Foundations of Large Language Models
Ch.3 Prompting - Foundations of Large Language Models
Computing Sciences
Related
Structuring a Prompt for an AI System
A developer is building an application that generates personalized story summaries. The system needs three distinct pieces of information to create a summary: the
book_title, theuser_name, and the desiredsummary_length(e.g., 'short', 'medium', 'detailed'). To ensure the system can reliably and efficiently handle thousands of these requests, which of the following data structures is the most appropriate for representing the information for a single request?Restructuring a Prompt into JSON
Example of a JSON Prompt Representation