What is Retrieval-Augmented Generation (RAG)?
David Colaursso
Co-director, Suffolk's Legal Innovation & Tech Lab
This is the 43rd post in my series 50 Days of LIT Prompts.
If you're only here to ask an AI about the Roman Empire, be my guest, but consider reading the following first.If you've been with us since the beginning, you know I think most folks are looking through the wrong end of the telescope when it comes to using large language models (LLMs). That is, too many folks want to feed in 5 words and get out 500 (e.g., write an essay for me). LLMs are sentence completion machines, searching only to find the next most plausible set of words. The larger the prompt you give them the more constrained their output. Conversely, sparse prompts seeking large outputs are asking for trouble. It's like setting off a rocket without any fins. Things might start off "okay," but small changes in direction can lead to problems very quickly. Sometimes this is what you want. It can be good to have in improv partner, but a lot of the time, folks like to avoid hallucinations. So, I tend to say more folks should be feeding in 500 words and expecting 5. That's a wordy way of saing these tools are pretty good at summariztion and entity extraction. I wouldn't, however, trust LLMs to produce answers any different than an average internet user, and we need to remember that the average internet user and LLMs are the products of society at large, biases et al. included.
So what are we to do about the dream of an AI-powered FAQ? Can we find a way to use LLMs to help answer question the average internet user wouldn't know? We'll as we observed back in that first post, " If you want an LLM, or the man on the street, to summarize a text, have them read it first." That is, you can turn things around and look through the right end of the telescope by making the "article" you want to question AND your question part of the same prompt. We've seen this work with short articles and webpages. However, as you may have noticed, there is a limit to how much information we can place in a prompt. Also, how are we supposed to include both a question and the answer to that question in the same prompt. If we have the answer, why are we asking the question? Enter retrieval-augmented generation (RAG), a phrase you may have heard some "AI folks" throwing around.
Use your question to perform a search over a set of text in which you expect the answer will be found and prepend the "trusted text" of your search results to your prompt, sandwiching some instructions between it and your question. That is, you augment your text generation by retrieving some set of text to help build a better prompt and get a better answer. The search does most of the heavy lifting. Most of the time, this all happens behind the scenes. Here's what things might look like under the hood:
It shouldn't surprise you to discover that a lot depends on how you do the search. There's also a real problem with failure states. That is, when it works it works great, but when it fails, it's hard to know. Most folks have taken to searching for that trusted text with a vector database. What, you may ask is that? Well it's a database were you can find text similar to that of your question by looking for texts with similar word vectors. If that doesn't many anything to you, the following micro lessons should get you up to speed. However, you can skip over all of them if you like, because we won't be using a vector database here.
- Logistic Regression
- Artificial Neurons
- Artificial Neural Nets
- Micro-Lesson: Word2vec (Part 1)
- Micro-Lesson: Word2vec (Part 2)
- Micro-Lesson: Document Classification
Instead of a vector database, we'll use an LLM. As you'll see below I've taken the full text of this Wikipedia page on the Roman Empire, placing it into a set of prompts, each coresponding to a section of the page (i.e., "History", "Geography and demography", "Languages", "Society", "Government and military", "Economy", "Architecture and engineering", "Daily life", "Arts", "Literacy, books, and education", "Religion", "Legacy").
“The output of an LLM is a secondary source, and just like any secondary source, it doesn't remove the need to check primary sources.”The first template takes in a question and asks an LLM to return the section most likely to contain the answer. The LLM's matchs are then used to retrieve a section of the page which we prepend to the prompt, just like we described above. The result is a system that can field individual questions of the Wikipedia page. It's not perfect; if it's hard to place your question in one of the above categories, it will error. However, it does let us do things we couldn't otherwise. Mostly, the model we're using couldn't do this if we tried to feed in the whole page because it's too big. By breaking things up, we've found a way to look through the right end of the telescope. Does this make LLM's 100% reliable? No, and don't believe anyone who tells you otherwise. The output of an LLM is a secondary source, and just like any secondary source, it doesn't remove the need to check primary sources. That being said, secondary sources, like Wikipedia, exist for a reason. They're a useful, and often more accessable, starting place.
Let's build something!
We'll do our building in the LIT Prompts extension. If you aren't familiar with the LIT Prompts extension, don't worry. We'll walk you through setting things up before we start building. If you have used the LIT Prompts extension before, skip to The Prompt Pattern (Template).
Up Next
Questions or comments? I'm on Mastodon @Colarusso@mastodon.social
Setup LIT Prompts
LIT Prompts is a browser extension built at Suffolk University Law School's Legal Innovation and Technology Lab to help folks explore the use of Large Language Models (LLMs) and prompt engineering. LLMs are sentence completion machines, and prompts are the text upon which they build. Feed an LLM a prompt, and it will return a plausible-sounding follow-up (e.g., "Four score and seven..." might return "years ago our fathers brought forth..."). LIT Prompts lets users create and save prompt templates based on data from an active browser window (e.g., selected text or the whole text of a webpage) along with text from a user. Below we'll walk through a specific example.
To get started, follow the first four minutes of the intro video or the steps outlined below. Note: The video only shows Firefox, but once you've installed the extension, the steps are the same.
Install the extension
Follow the links for your browser.
- Firefox: (1) visit the extension's add-ons page; (2) click "Add to Firefox;" and (3) grant permissions.
- Chrome: (1) visit the extension's web store page; (2) click "Add to Chrome;" and (3) review permissions / "Add extension."
If you don't have Firefox, you can download it here. Would you rather use Chrome? Download it here.
Point it at an API
Here we'll walk through how to use an LLM provided by OpenAI, but you don't have to use their offering. If you're interested in alternatives, you can find them here. You can even run your LLM locally, avoiding the need to share your prompts with a third-party. If you need an OpenAI account, you can create one here. Note: when you create a new OpenAI account you are given a limited amount of free API credits. If you created an account some time ago, however, these may have expired. If your credits have expired, you will need to enter a billing method before you can use the API. You can check the state of any credits here.
Login to OpenAI, and navigate to the API documentation.
Once you are looking at the API docs, follow the steps outlined in the image above. That is:
- Select "API keys" from the left menu
- Click "+ Create new secret key"
On LIT Prompt's Templates & Settings screen, set your API Base to https://api.openai.com/v1/chat/completions
and your API Key equal to the value you got above after clicking "+ Create new secret key". You get there by clicking the Templates & Settings button in the extension's popup:
- open the extension
- click on Templates & Settings
- enter the API Base and Key (under the section OpenAI-Compatible API Integration)
Once those two bits of information (the API Base and Key) are in place, you're good to go. Now you can edit, create, and run prompt templates. Just open the LIT Prompts extension, and click one of the options. I suggest, however, that you read through the Templates and Settings screen to get oriented. You might even try out a few of the preloaded prompt templates. This will let you jump right in and get your hands dirty in the next section.
If you receive an error when trying to run a template after entering your Base and Key, and you are using OpenAI, make sure to check the state of any credits here. If you don't have any credits, you will need a billing method on file.
If you found this hard to follow, consider following along with the first four minutes of the video above. It covers the same content. It focuses on Firefox, but once you've installed the extension, the steps are the same.
The Prompt Patterns (Templates)
When crafting a LIT Prompts template, we use a mix of plain language and variable placeholders. Specifically, you can use double curly brackets to encase predefined variables. If the text between the brackets matches one of our predefined variable names, that section of text will be replaced with the variable's value. Today we'll be using {{passThrough["info"]}}
. See the extension's documentation.
If the text within brackets is not the name of a predefined variable, like {{What do you want to know about the Roman Empire?}}
, it will trigger a prompt for your user that echo's the placeholder (e.g., a text bubble containing, "What do you want to know about the Roman Empire?"). After the user answers, their reply will replace this placeholder. A list of predefined variables can be found in the extension's documentation.
To use these templates, trigger the first one and ask away.
Here's the template's title.
Ask about the Roman Empire
Here's the template's text.
In a moment I will provide you with a question about the Roman Empire. Your job is to match the question to the category most likely to contain the answer. Here's a list of categories:
categories = ["History", "Geography and demography", "Languages", "Society", "Government and military", "Economy", "Architecture and engineering", "Daily life", "Arts", "Literacy, books, and education", "Religion", "Legacy"]
And here's the question: {{What do you want to know about the Roman Empire?}}
---
Provide your answer in the form of a JSON object with two key-value pairs. The first key-value pair has the key "question" and a value equal to the above question. If the question contains double quotes escape them like so `\\"`. The second key-value pair had the key is "next" and the value of the category most likely to contain the questions answer.
And here are the template's parameters:
- Output Type:
LLM
. This choice means that we'll "run" the template through an LLM (i.e., this will ping an LLM and return a result). Alternatively, we could have chosen "Prompt," in which case the extension would return the text of the completed template. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Since we're seeking fidelity to a text, I went with the least "creative" setting—0. - Max Tokens:
500
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
DYNAMIC
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger the promt named in thepassThrough["next"]
variable. - Hide Button:
unchecked
. This determines if a button is displayed for this template in the extension's popup window.
Here's the template's title.
Output answer to question
Here's the template's text.
I'm going to provide you with some information about the Roman Empire followed by a question which you will answer using only the information I provide.
---
INFORMATION:
The Roman Empire[a] was the post-Republican state of ancient Rome. It is generally understood to mean the period and territory ruled by the Romans following Octavian's assumption of sole rule under the Principate in 27 BC. It included territories in Europe, North Africa, and Western Asia and was ruled by emperors. The fall of the Western Roman Empire in 476 AD conventionally marks the end of classical antiquity and the beginning of the Middle Ages.
Rome had expanded its rule to most of the Mediterranean and beyond. However, it was severely destabilized in civil wars and political conflicts which culminated in the victory of Octavian over Mark Antony, Cleopatra at the Battle of Actium in 31 BC, and the subsequent conquest of the Ptolemaic Kingdom in Egypt. In 27 BC, the Roman Senate granted Octavian overarching power (imperium) and the new title of Augustus, marking his accession as the first Roman emperor of a monarchy with Rome as its sole capital. The vast Roman territories were organized in senatorial and imperial provinces.
The first two centuries of the Empire saw a period of unprecedented stability and prosperity known as the Pax Romana (lit. 'Roman Peace'). Rome reached its greatest territorial expanse under Trajan (r.98–117 AD); a period of increasing trouble and decline began under Commodus (180–192). In the 3rd century, the Empire underwent a crisis that threatened its existence, as the Gallic and Palmyrene Empires broke away from the Roman state, and a series of short-lived emperors led the Empire. It was reunified under Aurelian (r. 270–275). Diocletian set up two different imperial courts in the Greek East and Latin West in 286; Christians rose to power in the 4th century after the Edict of Milan. The imperial seat moved from Rome to Byzantium in 330, renamed Constantinople after Constantine the Great. The Migration Period, involving large invasions by Germanic peoples and by the Huns of Attila, led to the decline of the Western Roman Empire. With the fall of Ravenna to the Germanic Herulians and the deposition of Romulus Augustus in 476 AD by Odoacer, the Western Roman Empire finally collapsed. The Eastern Roman Empire survived for another millennium with Constantinople as its sole capital, until the city's fall in 1453.[f]
Due to the Empire's extent and endurance, its institutions and culture had a lasting influence on the development of language, religion, art, architecture, literature, philosophy, law, and forms of government across its territories. Latin evolved into the Romance languages while Medieval Greek became the language of the East. The Empire's adoption of Christianity resulted in the formation of medieval Christendom. Roman and Greek art had a profound impact on the Italian Renaissance. Rome's architectural tradition served as the basis for Romanesque, Renaissance and Neoclassical architecture, influencing Islamic architecture. The rediscovery of classical science and technology (which formed the basis for Islamic science) in medieval Europe contributed to the Scientific Renaissance and Scientific Revolution. Many modern legal systems, such as the Napoleonic Code, descend from Roman law. On the other hand, Rome's republican institutions have influenced the Italian city-state republics of the medieval period, the early United States, and modern democratic republics.
{{passThrough["info"]}}
---
QUESTION:
{{passThrough["question"]}}
---
Now use the text found above in INFORMATION, and ONLY the above text, to answer the QUESTION. If you can't find an answer in the above text, politely decline to answer explaining that you can't find the information. You can, however, finish a thought you started above if asked to continue, but don't write anything that isn't supported by the above text. And keep all of your replies short!
And here are the template's parameters:
- Output Type:
LLM
. This choice means that we'll "run" the template through an LLM (i.e., this will ping an LLM and return a result). Alternatively, we could have chosen "Prompt," in which case the extension would return the text of the completed template. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
500
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
No
. This asks the model to output its answer in something called JSON. We don't need to worry about that here, hence the selection of "No." - Output To:
Screen Only
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, we're content just to have it go to the screen. - Post-run Behavior:
FULL STOP
. Like the choice of output, we can decide what to do after a template runs. To keep things simple, I went with "FULL STOP." - Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
History
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"History\nMain article: History of the Roman Empire\nFor a chronological guide, see Timeline of Roman history.\nSee also: Campaign history of the Roman military and Roman Kingdom\nDuration: 39 seconds.0:39\nAnimated overview of the Roman territorial history from the Roman Republic until the fall of its last remnant (the Byzantine Empire) in 1453\nTransition from Republic to Empire\nFurther information: Roman Republic\nAugustus of Prima Porta\n\nRome had begun expanding shortly after the founding of the Roman Republic in the 6th century BC, though not outside the Italian peninsula until the 3rd century BC. Thus, it was an \"empire\" (a great power) long before it had an emperor.[20] The Republic was not a nation-state in the modern sense, but a network of self-ruled towns (with varying degrees of independence from the Senate) and provinces administered by military commanders. It was governed by annually elected magistrates (Roman consuls above all) in conjunction with the Senate.[21] The 1st century BC was a time of political and military upheaval, which ultimately led to rule by emperors.[22][23][24] The consuls' military power rested in the Roman legal concept of imperium, meaning \"command\" (though typically in a military sense).[25] Occasionally, successful consuls were given the honorary title imperator (commander); this is the origin of the word emperor, since this title was always bestowed to the early emperors.[26]\n\nRome suffered a long series of internal conflicts, conspiracies, and civil wars from the late second century BC (see Crisis of the Roman Republic) while greatly extending its power beyond Italy. In 44 BC Julius Caesar was briefly dictator before being assassinated. The faction of his assassins was driven from Rome and defeated at the Battle of Philippi in 42 BC by Mark Antony and Caesar's adopted son Octavian. Antony and Octavian's division of the Roman world did not last and Octavian's forces defeated those of Mark Antony and Cleopatra at the Battle of Actium in 31 BC. In 27 BC the Senate made Octavian princeps (\"first citizen\") with proconsular imperium, thus beginning the Principate (the first epoch of Roman imperial history, usually dated from 27 BC to 284 AD), and gave him the title Augustus (\"the venerated\"). Although the republic stood in name, Augustus had all meaningful authority.[27] Since his rule began an unprecedented period of peace and prosperity, he was so loved that he came to hold the power of a monarch de facto if not de jure. During the years of his rule, a new constitutional order emerged (in part organically and in part by design), so that, upon his death, this new constitutional order operated as before when Tiberius was accepted as the new emperor.[citation needed]\nPax Romana\nMain article: Pax Romana\nThe so-called \"Five Good Emperors\" of 96–180 AD\nNerva (r. 96–98)\nTrajan (r. 98–117)\nHadrian (r. 117–138)\nAntoninus Pius (r. 138–161)\nMarcus Aurelius (r. 161–180)\n\nThe 200 years that began with Augustus's rule is traditionally regarded as the Pax Romana (\"Roman Peace\"). The cohesion of the empire was furthered by a degree of social stability and economic prosperity that Rome had never before experienced. Uprisings in the provinces were infrequent and put down \"mercilessly and swiftly\".[28] The success of Augustus in establishing principles of dynastic succession was limited by his outliving a number of talented potential heirs. The Julio-Claudian dynasty lasted for four more emperors—Tiberius, Caligula, Claudius, and Nero—before it yielded in 69 AD to the strife-torn Year of the Four Emperors, from which Vespasian emerged as victor. Vespasian became the founder of the brief Flavian dynasty, followed by the Nerva–Antonine dynasty which produced the \"Five Good Emperors\": Nerva, Trajan, Hadrian, Antoninus Pius, and Marcus Aurelius.[citation needed]\nTransition from Classical to Late Antiquity\nMain articles: Later Roman Empire and Fall of the Western Roman Empire\nSee also: Barbarian kingdoms and Byzantine Empire\nThe Barbarian Invasions consisted of the movement of (mainly) ancient Germanic peoples into Roman territory. Historically, this event marked the transition between classical antiquity and the Middle Ages.\n\nIn the view of contemporary Greek historian Cassius Dio, the accession of Commodus in 180 marked the descent \"from a kingdom of gold to one of rust and iron\",[29] a comment which has led some historians, notably Edward Gibbon, to take Commodus' reign as the beginning of the Empire's decline.[30][31]\n\nIn 212, during the reign of Caracalla, Roman citizenship was granted to all freeborn inhabitants of the empire. The Severan dynasty was tumultuous; an emperor's reign was ended routinely by his murder or execution and, following its collapse, the Empire was engulfed by the Crisis of the Third Century, a period of invasions, civil strife, economic disorder, and plague.[32] In defining historical epochs, this crisis sometimes marks the transition from Classical to Late Antiquity. Aurelian (r. 270–275) stabilised the empire militarily and Diocletian reorganised and restored much of it in 285.[33] Diocletian's reign brought the empire's most concerted effort against the perceived threat of Christianity, the \"Great Persecution\".[citation needed]\n\nDiocletian divided the empire into four regions, each ruled by a separate tetrarch.[34] Confident that he fixed the disorder plaguing Rome, he abdicated along with his co-emperor, but the Tetrarchy collapsed shortly after. Order was eventually restored by Constantine the Great, who became the first emperor to convert to Christianity, and who established Constantinople as the new capital of the Eastern Empire. During the decades of the Constantinian and Valentinian dynasties, the empire was divided along an east–west axis, with dual power centres in Constantinople and Rome. Julian, who under the influence of his adviser Mardonius attempted to restore Classical Roman and Hellenistic religion, only briefly interrupted the succession of Christian emperors. Theodosius I, the last emperor to rule over both East and West, died in 395 after making Christianity the state religion.[35]\nThe Roman Empire by 476, noting western and eastern divisions\nThe administrative divisions of the Roman Empire in 395 AD\nFall in the West and survival in the East\n\nThe Western Roman Empire began to disintegrate in the early 5th century. The Romans were successful in fighting off all invaders, most famously Attila,[36] but the empire had assimilated so many Germanic peoples of dubious loyalty to Rome that the empire started to dismember itself.[37] Most chronologies place the end of the Western Roman Empire in 476, when Romulus Augustulus was forced to abdicate to the Germanic warlord Odoacer.[38][39][40]\n\nOdoacer ended the Western Empire by declaring Zeno sole emperor and placing himself as Zeno's nominal subordinate. In reality, Italy was ruled by Odoacer alone.[38][39][41] The Eastern Roman Empire, called the Byzantine Empire by later historians, continued until the reign of Constantine XI Palaiologos. The last Roman emperor died in battle in 1453 against Mehmed II and his Ottoman forces during the siege of Constantinople. Mehmed II adopted the title of caesar in an attempt to claim a connection to the Empire.[42]"
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Geography and demography
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Geography and demography\nMain articles: Demography of the Roman Empire and Borders of the Roman Empire\nFurther information: Classical demography\n\nThe Roman Empire was one of the largest in history, with contiguous territories throughout Europe, North Africa, and the Middle East.[43] The Latin phrase imperium sine fine (\"empire without end\"[44]) expressed the ideology that neither time nor space limited the Empire. In Virgil's Aeneid, limitless empire is said to be granted to the Romans by Jupiter.[45] This claim of universal dominion was renewed when the Empire came under Christian rule in the 4th century.[g] In addition to annexing large regions, the Romans directly altered their geography, for example cutting down entire forests.[47]\n\nRoman expansion was mostly accomplished under the Republic, though parts of northern Europe were conquered in the 1st century, when Roman control in Europe, Africa, and Asia was strengthened. Under Augustus, a \"global map of the known world\" was displayed for the first time in public at Rome, coinciding with the creation of the most comprehensive political geography that survives from antiquity, the Geography of Strabo.[48] When Augustus died, the account of his achievements (Res Gestae) prominently featured the geographical cataloguing of the Empire.[49] Geography alongside meticulous written records were central concerns of Roman Imperial administration.[50]\nA segment of the ruins of Hadrian's Wall in northern England, overlooking Crag Lough\n\nThe Empire reached its largest expanse under Trajan (r. 98–117),[51] encompassing 5 million square kilometres.[15][16] The traditional population estimate of 55–60 million inhabitants[52] accounted for between one-sixth and one-fourth of the world's total population[53] and made it the most populous unified political entity in the West until the mid-19th century.[54] Recent demographic studies have argued for a population peak from 70 million to more than 100 million.[55] Each of the three largest cities in the Empire – Rome, Alexandria, and Antioch – was almost twice the size of any European city at the beginning of the 17th century.[56]\n\nAs the historian Christopher Kelly described it:\n\n Then the empire stretched from Hadrian's Wall in drizzle-soaked northern England to the sun-baked banks of the Euphrates in Syria; from the great Rhine–Danube river system, which snaked across the fertile, flat lands of Europe from the Low Countries to the Black Sea, to the rich plains of the North African coast and the luxuriant gash of the Nile Valley in Egypt. The empire completely circled the Mediterranean ... referred to by its conquerors as mare nostrum—'our sea'.[52]\n\nTrajan's successor Hadrian adopted a policy of maintaining rather than expanding the empire. Borders (fines) were marked, and the frontiers (limites) patrolled.[51] The most heavily fortified borders were the most unstable.[23] Hadrian's Wall, which separated the Roman world from what was perceived as an ever-present barbarian threat, is the primary surviving monument of this effort.[57] "
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Languages
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Languages\nMain article: Languages of the Roman Empire\nSee also: Jireček Line\n\nLatin and Greek were the main languages of the Empire,[h] but the Empire was deliberately multilingual.[62] Andrew Wallace-Hadrill says \"The main desire of the Roman government was to make itself understood\".[63] At the start of the Empire, knowledge of Greek was useful to pass as educated nobility and knowledge of Latin was useful for a career in the military, government, or law.[64] Bilingual inscriptions indicate the everyday interpenetration of the two languages.[65]\n\nLatin and Greek's mutual linguistic and cultural influence is a complex topic.[66] Latin words incorporated into Greek were very common by the early imperial era, especially for military, administration, and trade and commerce matters.[67] Greek grammar, literature, poetry and philosophy shaped Latin language and culture.[68][69]\nA 5th-century papyrus showing a parallel Latin-Greek text of a speech by Cicero[70]\n\nThere was never a legal requirement for Latin in the Empire, but it represented a certain status.[71] High standards of Latin, Latinitas, started with the advent of Latin literature.[72] Due to the flexible language policy of the Empire, a natural competition of language emerged that spurred Latinitas, to defend Latin against the stronger cultural influence of Greek.[73] Over time Latin usage was used to project power and a higher social class.[74][75] Most of the emperors were bilingual but had a preference for Latin in the public sphere for political reasons, a \"rule\" that first started during the Punic Wars.[76] Different emperors up until Justinian would attempt to require the use of Latin in various sections of the administration but there is no evidence that a linguistic imperialism existed during the early Empire.[77]\n\nAfter all freeborn inhabitants were universally enfranchised in 212, many Roman citizens would have lacked a knowledge of Latin.[78] The wide use of Koine Greek was what enabled the spread of Christianity and reflects its role as the lingua franca of the Mediterranean during the time of the Empire.[79] Following Diocletian's reforms in the 3rd century CE, there was a decline in the knowledge of Greek in the west.[80] Spoken Latin later fragmented into the incipient romance languages in the 7th century CE following the collapse of the Empire's west.[81]\n\nThe dominance of Latin and Greek among the literate elite obscure the continuity of other spoken languages within the Empire.[82] Latin, referred to in its spoken form as Vulgar Latin, gradually replaced Celtic and Italic languages.[83][84] References to interpreters indicate the continuing use of local languages, particularly in Egypt with Coptic, and in military settings along the Rhine and Danube. Roman jurists also show a concern for local languages such as Punic, Gaulish, and Aramaic in assuring the correct understanding of laws and oaths.[85] In Africa, Libyco-Berber and Punic were used in inscriptions into the 2nd century.[82] In Syria, Palmyrene soldiers used their dialect of Aramaic for inscriptions, an exception to the rule that Latin was the language of the military.[86] The last reference to Gaulish was between 560 and 575.[87][88] The emergent Gallo-Romance languages would then be shaped by Gaulish.[89] Proto-Basque or Aquitanian evolved with Latin loan words to modern Basque.[90] The Thracian language, as were several now-extinct languages in Anatolia, are attested in Imperial-era inscriptions.[79][82] "
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Society
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Society\nFurther information: Ancient Roman society\nA multigenerational banquet depicted on a wall painting from Pompeii (1st century AD)\n\nThe Empire was remarkably multicultural, with \"astonishing cohesive capacity\" to create shared identity while encompassing diverse peoples.[92] Public monuments and communal spaces open to all—such as forums, amphitheatres, racetracks and baths—helped foster a sense of \"Romanness\".[93]\n\nRoman society had multiple, overlapping social hierarchies.[94] The civil war preceding Augustus caused upheaval,[95] but did not effect an immediate redistribution of wealth and social power. From the perspective of the lower classes, a peak was merely added to the social pyramid.[96] Personal relationships—patronage, friendship (amicitia), family, marriage—continued to influence politics.[97] By the time of Nero, however, it was not unusual to find a former slave who was richer than a freeborn citizen, or an equestrian who exercised greater power than a senator.[98]\n\nThe blurring of the Republic's more rigid hierarchies led to increased social mobility,[99] both upward and downward, to a greater extent than all other well-documented ancient societies.[100] Women, freedmen, and slaves had opportunities to profit and exercise influence in ways previously less available to them.[101] Social life, particularly for those whose personal resources were limited, was further fostered by a proliferation of voluntary associations and confraternities (collegia and sodalitates): professional and trade guilds, veterans' groups, religious sodalities, drinking and dining clubs,[102] performing troupes,[103] and burial societies.[104]\nLegal status\nMain articles: Status in Roman legal system and Roman citizenship\n\nAccording to the jurist Gaius, the essential distinction in the Roman \"law of persons\" was that all humans were either free (liberi) or slaves (servi).[105] The legal status of free persons was further defined by their citizenship. Most citizens held limited rights (such as the ius Latinum, \"Latin right\"), but were entitled to legal protections and privileges not enjoyed by non-citizens. Free people not considered citizens, but living within the Roman world, were peregrini, non-Romans.[106] In 212, the Constitutio Antoniniana extended citizenship to all freeborn inhabitants of the empire. This legal egalitarianism required a far-reaching revision of existing laws that distinguished between citizens and non-citizens.[107]\nWomen in Roman law\nMain article: Women in ancient Rome\nLeft: Fresco of an auburn maiden reading a text, Pompeian Fourth Style (60–79 AD), Pompeii, Italy\nRight: Bronze statuette (1st century AD) of a young woman reading, based on a Hellenistic original\n\nFreeborn Roman women were considered citizens, but did not vote, hold political office, or serve in the military. A mother's citizen status determined that of her children, as indicated by the phrase ex duobus civibus Romanis natos (\"children born of two Roman citizens\").[i] A Roman woman kept her own family name (nomen) for life. Children most often took the father's name, with some exceptions.[110] Women could own property, enter contracts, and engage in business.[111] Inscriptions throughout the Empire honour women as benefactors in funding public works, an indication they could hold considerable fortunes.[112]\n\nThe archaic manus marriage in which the woman was subject to her husband's authority was largely abandoned by the Imperial era, and a married woman retained ownership of any property she brought into the marriage. Technically she remained under her father's legal authority, even though she moved into her husband's home, but when her father died she became legally emancipated.[113] This arrangement was a factor in the degree of independence Roman women enjoyed compared to many other cultures up to the modern period:[114] although she had to answer to her father in legal matters, she was free of his direct scrutiny in daily life,[115] and her husband had no legal power over her.[116] Although it was a point of pride to be a \"one-man woman\" (univira) who had married only once, there was little stigma attached to divorce, nor to speedy remarriage after being widowed or divorced.[117] Girls had equal inheritance rights with boys if their father died without leaving a will.[118] A mother's right to own and dispose of property, including setting the terms of her will, gave her enormous influence over her sons into adulthood.[119]\nDressing of a priestess or bride, Roman fresco from Herculaneum, Italy (30–40 AD)\n\nAs part of the Augustan programme to restore traditional morality and social order, moral legislation attempted to regulate conduct as a means of promoting \"family values\". Adultery was criminalized,[120] and defined broadly as an illicit sex act (stuprum) between a male citizen and a married woman, or between a married woman and any man other than her husband. That is, a double standard was in place: a married woman could have sex only with her husband, but a married man did not commit adultery if he had sex with a prostitute or person of marginalized status.[121] Childbearing was encouraged: a woman who had given birth to three children was granted symbolic honours and greater legal freedom (the ius trium liberorum).[122]\nSlaves and the law\nMain article: Slavery in ancient Rome\n\nAt the time of Augustus, as many as 35% of the people in Roman Italy were slaves,[123] making Rome one of five historical \"slave societies\" in which slaves constituted at least a fifth of the population and played a major role in the economy.[j][123] Slavery was a complex institution that supported traditional Roman social structures as well as contributing economic utility.[124] In urban settings, slaves might be professionals such as teachers, physicians, chefs, and accountants; the majority of slaves provided trained or unskilled labour. Agriculture and industry, such as milling and mining, relied on the exploitation of slaves. Outside Italy, slaves were on average an estimated 10 to 20% of the population, sparse in Roman Egypt but more concentrated in some Greek areas. Expanding Roman ownership of arable land and industries affected preexisting practices of slavery in the provinces.[125] Although slavery has often been regarded as waning in the 3rd and 4th centuries, it remained an integral part of Roman society until gradually ceasing in the 6th and 7th centuries with the disintegration of the complex Imperial economy.[126]\nSlave holding writing tablets for his master (relief from a 4th-century sarcophagus)\n\nLaws pertaining to slavery were \"extremely intricate\".[127] Slaves were considered property and had no legal personhood. They could be subjected to forms of corporal punishment not normally exercised on citizens, sexual exploitation, torture, and summary execution. A slave could not as a matter of law be raped; a slave's rapist had to be prosecuted by the owner for property damage under the Aquilian Law.[128] Slaves had no right to the form of legal marriage called conubium, but their unions were sometimes recognized.[129] Technically, a slave could not own property,[130] but a slave who conducted business might be given access to an individual fund (peculium) that he could use, depending on the degree of trust and co-operation between owner and slave.[131] Within a household or workplace, a hierarchy of slaves might exist, with one slave acting as the master of others.[132] Talented slaves might accumulate a large enough peculium to justify their freedom, or be manumitted for services rendered. Manumission had become frequent enough that in 2 BC a law (Lex Fufia Caninia) limited the number of slaves an owner was allowed to free in his will.[133]\n\nFollowing the Servile Wars of the Republic, legislation under Augustus and his successors shows a driving concern for controlling the threat of rebellions through limiting the size of work groups, and for hunting down fugitive slaves.[134] Over time slaves gained increased legal protection, including the right to file complaints against their masters. A bill of sale might contain a clause stipulating that the slave could not be employed for prostitution, as prostitutes in ancient Rome were often slaves.[135] The burgeoning trade in eunuchs in the late 1st century prompted legislation that prohibited the castration of a slave against his will \"for lust or gain\".[136]\n\nRoman slavery was not based on race.[137] Generally, slaves in Italy were indigenous Italians,[138] with a minority of foreigners (including both slaves and freedmen) estimated at 5% of the total in the capital at its peak, where their number was largest. Foreign slaves had higher mortality and lower birth rates than natives, and were sometimes even subjected to mass expulsions.[139] The average recorded age at death for the slaves of the city of Rome was seventeen and a half years (17.2 for males; 17.9 for females).[140]\n\nDuring the period of republican expansionism when slavery had become pervasive, war captives were a main source of slaves. The range of ethnicities among slaves to some extent reflected that of the armies Rome defeated in war, and the conquest of Greece brought a number of highly skilled and educated slaves. Slaves were also traded in markets and sometimes sold by pirates. Infant abandonment and self-enslavement among the poor were other sources.[141] Vernae, by contrast, were \"homegrown\" slaves born to female slaves within the household, estate or farm. Although they had no special legal status, an owner who mistreated or failed to care for his vernae faced social disapproval, as they were considered part of the family household and in some cases might actually be the children of free males in the family.[142]\nFreedmen\nCinerary urn for the freedman Tiberius Claudius Chryseros and two women, probably his wife and daughter\n\nRome differed from Greek city-states in allowing freed slaves to become citizens; any future children of a freedman were born free, with full rights of citizenship. After manumission, a slave who had belonged to a Roman citizen enjoyed active political freedom (libertas), including the right to vote.[143] His former master became his patron (patronus): the two continued to have customary and legal obligations to each other.[144][145] A freedman was not entitled to hold public office or the highest state priesthoods, but could play a priestly role. He could not marry a woman from a senatorial family, nor achieve legitimate senatorial rank himself, but during the early Empire, freedmen held key positions in the government bureaucracy, so much so that Hadrian limited their participation by law.[145] The rise of successful freedmen—through political influence or wealth—is a characteristic of early Imperial society. The prosperity of a high-achieving group of freedmen is attested by inscriptions throughout the Empire, and by their ownership of some of the most lavish houses at Pompeii.[citation needed]\nCensus rank\nSee also: Senate of the Roman Empire, Equestrian order, and Decurion (administrative)\n\nThe Latin word ordo (plural ordines) is translated variously and inexactly into English as \"class, order, rank\". One purpose of the Roman census was to determine the ordo to which an individual belonged. The two highest ordines in Rome were the senatorial and equestrian.[citation needed] Outside Rome, the decurions, also known as curiales, were the top governing ordo of an individual city.[citation needed]\nFragment of a sarcophagus depicting Gordian III and senators (3rd century)\n\n\"Senator\" was not itself an elected office in ancient Rome; an individual gained admission to the Senate after he had been elected to and served at least one term as an executive magistrate. A senator also had to meet a minimum property requirement of 1 million sestertii.[146] Not all men who qualified for the ordo senatorius chose to take a Senate seat, which required legal domicile at Rome. Emperors often filled vacancies in the 600-member body by appointment.[147] A senator's son belonged to the ordo senatorius, but he had to qualify on his own merits for admission to the Senate. A senator could be removed for violating moral standards.[148]\n\nIn the time of Nero, senators were still primarily from Italy, with some from the Iberian peninsula and southern France; men from the Greek-speaking provinces of the East began to be added under Vespasian.[149] The first senator from the easternmost province, Cappadocia, was admitted under Marcus Aurelius.[k] By the Severan dynasty (193–235), Italians made up less than half the Senate.[151] During the 3rd century, domicile at Rome became impractical, and inscriptions attest to senators who were active in politics and munificence in their homeland (patria).[148]\n\nSenators were the traditional governing class who rose through the cursus honorum, the political career track, but equestrians often possessed greater wealth and political power. Membership in the equestrian order was based on property; in Rome's early days, equites or knights had been distinguished by their ability to serve as mounted warriors, but cavalry service was a separate function in the Empire.[l] A census valuation of 400,000 sesterces and three generations of free birth qualified a man as an equestrian.[153] The census of 28 BC uncovered large numbers of men who qualified, and in 14 AD, a thousand equestrians were registered at Cádiz and Padua alone.[m][155] Equestrians rose through a military career track (tres militiae) to become highly placed prefects and procurators within the Imperial administration.[156]\n\nThe rise of provincial men to the senatorial and equestrian orders is an aspect of social mobility in the early Empire. Roman aristocracy was based on competition, and unlike later European nobility, a Roman family could not maintain its position merely through hereditary succession or having title to lands.[157] Admission to the higher ordines brought distinction and privileges, but also responsibilities. In antiquity, a city depended on its leading citizens to fund public works, events, and services (munera). Maintaining one's rank required massive personal expenditures.[158] Decurions were so vital for the functioning of cities that in the later Empire, as the ranks of the town councils became depleted, those who had risen to the Senate were encouraged to return to their hometowns, in an effort to sustain civic life.[159]\n\nIn the later Empire, the dignitas (\"worth, esteem\") that attended on senatorial or equestrian rank was refined further with titles such as vir illustris (\"illustrious man\").[160] The appellation clarissimus (Greek lamprotatos) was used to designate the dignitas of certain senators and their immediate family, including women.[161] \"Grades\" of equestrian status proliferated.[162]\nUnequal justice\nCondemned man attacked by a leopard in the arena (3rd-century mosaic from Tunisia)\n\nAs the republican principle of citizens' equality under the law faded, the symbolic and social privileges of the upper classes led to an informal division of Roman society into those who had acquired greater honours (honestiores) and humbler folk (humiliores). In general, honestiores were the members of the three higher \"orders\", along with certain military officers.[163] The granting of universal citizenship in 212 seems to have increased the competitive urge among the upper classes to have their superiority affirmed, particularly within the justice system.[164] Sentencing depended on the judgment of the presiding official as to the relative \"worth\" (dignitas) of the defendant: an honestior could pay a fine for a crime for which an humilior might receive a scourging.[165]\n\nExecution, which was an infrequent legal penalty for free men under the Republic,[166] could be quick and relatively painless for honestiores, while humiliores might suffer the kinds of torturous death previously reserved for slaves, such as crucifixion and condemnation to the beasts.[167] In the early Empire, those who converted to Christianity could lose their standing as honestiores, especially if they declined to fulfil religious responsibilities, and thus became subject to punishments that created the conditions of martyrdom.[168]"
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Government and military
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Government and military\nMain article: Constitution of the Roman Empire\nForum of Gerasa (Jerash in present-day Jordan), with columns marking a covered walkway (stoa) for vendor stalls, and a semicircular space for public speaking\n\nThe three major elements of the Imperial state were the central government, the military, and the provincial government.[169] The military established control of a territory through war, but after a city or people was brought under treaty, the mission turned to policing: protecting Roman citizens, agricultural fields, and religious sites.[170] The Romans lacked sufficient manpower or resources to rule through force alone. Cooperation with local elites was necessary to maintain order, collect information, and extract revenue. The Romans often exploited internal political divisions.[171]\n\nCommunities with demonstrated loyalty to Rome retained their own laws, could collect their own taxes locally, and in exceptional cases were exempt from Roman taxation. Legal privileges and relative independence incentivized compliance.[172] Roman government was thus limited, but efficient in its use of available resources.[173]\nCentral government\nSee also: Roman emperor and Senate of the Roman Empire\nAntoninus Pius (r. 138–161) wearing a toga (Hermitage Museum)\n\nThe Imperial cult of ancient Rome identified emperors and some members of their families with divinely sanctioned authority (auctoritas). The rite of apotheosis (also called consecratio) signified the deceased emperor's deification.[174] The dominance of the emperor was based on the consolidation of powers from several republican offices.[175] The emperor made himself the central religious authority as pontifex maximus, and centralized the right to declare war, ratify treaties, and negotiate with foreign leaders.[176] While these functions were clearly defined during the Principate, the emperor's powers over time became less constitutional and more monarchical, culminating in the Dominate.[177]\n\nThe emperor was the ultimate authority in policy- and decision-making, but in the early Principate, he was expected to be accessible and deal personally with official business and petitions. A bureaucracy formed around him only gradually.[178] The Julio-Claudian emperors relied on an informal body of advisors that included not only senators and equestrians, but trusted slaves and freedmen.[179] After Nero, the influence of the latter was regarded with suspicion, and the emperor's council (consilium) became subject to official appointment for greater transparency.[180] Though the Senate took a lead in policy discussions until the end of the Antonine dynasty, equestrians played an increasingly important role in the consilium.[181] The women of the emperor's family often intervened directly in his decisions.[182]\n\nAccess to the emperor might be gained at the daily reception (salutatio), a development of the traditional homage a client paid to his patron; public banquets hosted at the palace; and religious ceremonies. The common people who lacked this access could manifest their approval or displeasure as a group at games.[183] By the 4th century, the Christian emperors became remote figureheads who issued general rulings, no longer responding to individual petitions.[184] Although the Senate could do little short of assassination and open rebellion to contravene the will of the emperor, it retained its symbolic political centrality.[185] The Senate legitimated the emperor's rule, and the emperor employed senators as legates (legati): generals, diplomats, and administrators.[186]\n\nThe practical source of an emperor's power and authority was the military. The legionaries were paid by the Imperial treasury, and swore an annual oath of loyalty to the emperor.[187] Most emperors chose a successor, usually a close family member or adopted heir. The new emperor had to seek a swift acknowledgement of his status and authority to stabilize the political landscape. No emperor could hope to survive without the allegiance of the Praetorian Guard and the legions. To secure their loyalty, several emperors paid the donativum, a monetary reward. In theory, the Senate was entitled to choose the new emperor, but did so mindful of acclamation by the army or Praetorians.[188]\nMilitary\nWinged Victory, ancient Roman fresco of the Neronian era from Pompeii\nThe Roman empire under Hadrian (ruled 117–138) showing the location of the Roman legions deployed in 125 AD\nMain articles: Imperial Roman army and Structural history of the Roman military\n\nAfter the Punic Wars, the Roman army comprised professional soldiers who volunteered for 20 years of active duty and five as reserves. The transition to a professional military began during the late Republic and was one of the many profound shifts away from republicanism, under which an army of conscript citizens defended the homeland against a specific threat. The Romans expanded their war machine by \"organizing the communities that they conquered in Italy into a system that generated huge reservoirs of manpower for their army\".[189] By Imperial times, military service was a full-time career.[190] The pervasiveness of military garrisons throughout the Empire was a major influence in the process of Romanization.[191]\n\nThe primary mission of the military of the early empire was to preserve the Pax Romana.[192] The three major divisions of the military were:\n\n the garrison at Rome, comprising the Praetorian Guard, the cohortes urbanae and the vigiles, who functioned as police and firefighters;\n the provincial army, comprising the Roman legions and the auxiliaries provided by the provinces (auxilia);\n the navy.\n\nRelief panel from Trajan's Column in Rome, showing the building of a fort and the reception of a Dacian embassy\n\nThrough his military reforms, which included consolidating or disbanding units of questionable loyalty, Augustus regularized the legion. A legion was organized into ten cohorts, each of which comprised six centuries, with a century further made up of ten squads (contubernia); the exact size of the Imperial legion, which was likely determined by logistics, has been estimated to range from 4,800 to 5,280.[193] After Germanic tribes wiped out three legions in the Battle of the Teutoburg Forest in 9 AD, the number of legions was increased from 25 to around 30.[194] The army had about 300,000 soldiers in the 1st century, and under 400,000 in the 2nd, \"significantly smaller\" than the collective armed forces of the conquered territories. No more than 2% of adult males living in the Empire served in the Imperial army.[195] Augustus also created the Praetorian Guard: nine cohorts, ostensibly to maintain the public peace, which were garrisoned in Italy. Better paid than the legionaries, the Praetorians served only sixteen years.[196]\n\nThe auxilia were recruited from among the non-citizens. Organized in smaller units of roughly cohort strength, they were paid less than the legionaries, and after 25 years of service were rewarded with Roman citizenship, also extended to their sons. According to Tacitus[197] there were roughly as many auxiliaries as there were legionaries—thus, around 125,000 men, implying approximately 250 auxiliary regiments.[198] The Roman cavalry of the earliest Empire were primarily from Celtic, Hispanic or Germanic areas. Several aspects of training and equipment derived from the Celts.[199]\n\nThe Roman navy not only aided in the supply and transport of the legions but also in the protection of the frontiers along the rivers Rhine and Danube. Another duty was protecting maritime trade against pirates. It patrolled the Mediterranean, parts of the North Atlantic coasts, and the Black Sea. Nevertheless, the army was considered the senior and more prestigious branch.[200]\nProvincial government\n\nAn annexed territory became a Roman province in three steps: making a register of cities, taking a census, and surveying the land.[201] Further government recordkeeping included births and deaths, real estate transactions, taxes, and juridical proceedings.[202] In the 1st and 2nd centuries, the central government sent out around 160 officials annually to govern outside Italy.[21] Among these officials were the Roman governors: magistrates elected at Rome who in the name of the Roman people governed senatorial provinces; or governors, usually of equestrian rank, who held their imperium on behalf of the emperor in imperial provinces, most notably Roman Egypt.[203] A governor had to make himself accessible to the people he governed, but he could delegate various duties.[204] His staff, however, was minimal: his official attendants (apparitores), including lictors, heralds, messengers, scribes, and bodyguards; legates, both civil and military, usually of equestrian rank; and friends who accompanied him unofficially.[204]\n\nOther officials were appointed as supervisors of government finances.[21] Separating fiscal responsibility from justice and administration was a reform of the Imperial era, to avoid provincial governors and tax farmers exploiting local populations for personal gain.[205] Equestrian procurators, whose authority was originally \"extra-judicial and extra-constitutional\", managed both state-owned property and the personal property of the emperor (res privata).[204] Because Roman government officials were few, a provincial who needed help with a legal dispute or criminal case might seek out any Roman perceived to have some official capacity.[206]\nLaw\nMain article: Roman law\nRoman portraiture frescos from Pompeii, 1st century AD, depicting two different men wearing laurel wreaths, one holding the rotulus (blondish figure, left), the other a volumen (brunet figure, right), both made of papyrus\n\nRoman courts held original jurisdiction over cases involving Roman citizens throughout the empire, but there were too few judicial functionaries to impose Roman law uniformly in the provinces. Most parts of the Eastern Empire already had well-established law codes and juridical procedures.[95] Generally, it was Roman policy to respect the mos regionis (\"regional tradition\" or \"law of the land\") and to regard local laws as a source of legal precedent and social stability.[95][207] The compatibility of Roman and local law was thought to reflect an underlying ius gentium, the \"law of nations\" or international law regarded as common and customary.[208] If provincial law conflicted with Roman law or custom, Roman courts heard appeals, and the emperor held final decision-making authority.[95][207][n]\n\nIn the West, law had been administered on a highly localized or tribal basis, and private property rights may have been a novelty of the Roman era, particularly among Celts. Roman law facilitated the acquisition of wealth by a pro-Roman elite.[95] The extension of universal citizenship to all free inhabitants of the Empire in 212 required the uniform application of Roman law, replacing local law codes that had applied to non-citizens. Diocletian's efforts to stabilize the Empire after the Crisis of the Third Century included two major compilations of law in four years, the Codex Gregorianus and the Codex Hermogenianus, to guide provincial administrators in setting consistent legal standards.[209]\n\nThe pervasiveness of Roman law throughout Western Europe enormously influenced the Western legal tradition, reflected by continued use of Latin legal terminology in modern law.[citation needed]\nTaxation\nFurther information: Taxation in ancient Rome\nThe Temple of Saturn, a religious monument that housed the treasury in ancient Rome\n\nTaxation under the Empire amounted to about 5% of its gross product.[210] The typical tax rate for individuals ranged from 2 to 5%.[211] The tax code was \"bewildering\" in its complicated system of direct and indirect taxes, some paid in cash and some in kind. Taxes might be specific to a province, or kinds of properties such as fisheries; they might be temporary.[212] Tax collection was justified by the need to maintain the military,[213] and taxpayers sometimes got a refund if the army captured a surplus of booty.[214] In-kind taxes were accepted from less-monetized areas, particularly those who could supply grain or goods to army camps.[215]\n\nThe primary source of direct tax revenue was individuals, who paid a poll tax and a tax on their land, construed as a tax on its produce or productive capacity.[211] Tax obligations were determined by the census: each head of household provided a headcount of his household, as well as an accounting of his property.[216] A major source of indirect-tax revenue was the portoria, customs and tolls on trade, including among provinces.[211] Towards the end of his reign, Augustus instituted a 4% tax on the sale of slaves,[217] which Nero shifted from the purchaser to the dealers, who responded by raising their prices.[218] An owner who manumitted a slave paid a \"freedom tax\", calculated at 5% of value.[o] An inheritance tax of 5% was assessed when Roman citizens above a certain net worth left property to anyone outside their immediate family. Revenues from the estate tax and from an auction tax went towards the veterans' pension fund (aerarium militare).[211]\n\nLow taxes helped the Roman aristocracy increase their wealth, which equalled or exceeded the revenues of the central government. An emperor sometimes replenished his treasury by confiscating the estates of the \"super-rich\", but in the later period, the resistance of the wealthy to paying taxes was one of the factors contributing to the collapse of the Empire.[53]"
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Economy
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Economy\nMain article: Roman economy\nA green Roman glass cup unearthed from an Eastern Han dynasty (25–220 AD) tomb in Guangxi, China\n\nThe Empire is best thought of as a network of regional economies, based on a form of \"political capitalism\" in which the state regulated commerce to assure its own revenues.[219] Economic growth, though not comparable to modern economies, was greater than that of most other societies prior to industrialization.[220] Territorial conquests permitted a large-scale reorganization of land use that resulted in agricultural surplus and specialization, particularly in north Africa.[221] Some cities were known for particular industries. The scale of urban building indicates a significant construction industry.[221] Papyri preserve complex accounting methods that suggest elements of economic rationalism,[221] and the Empire was highly monetized.[222] Although the means of communication and transport were limited in antiquity, transportation in the 1st and 2nd centuries expanded greatly, and trade routes connected regional economies.[223] The supply contracts for the army drew on local suppliers near the base (castrum), throughout the province, and across provincial borders.[224] Economic historians vary in their calculations of the gross domestic product during the Principate.[225] In the sample years of 14, 100, and 150 AD, estimates of per capita GDP range from 166 to 380 HS. The GDP per capita of Italy is estimated as 40[226] to 66%[227] higher than in the rest of the Empire, due to tax transfers from the provinces and the concentration of elite income.\n\nEconomic dynamism resulted in social mobility. Although aristocratic values permeated traditional elite society, wealth requirements for rank indicate a strong tendency towards plutocracy. Prestige could be obtained through investing one's wealth in grand estates or townhouses, luxury items, public entertainments, funerary monuments, and religious dedications. Guilds (collegia) and corporations (corpora) provided support for individuals to succeed through networking.[163] \"There can be little doubt that the lower classes of ... provincial towns of the Roman Empire enjoyed a high standard of living not equaled again in Western Europe until the 19th century\".[228] Households in the top 1.5% of income distribution captured about 20% of income. The \"vast majority\" produced more than half of the total income, but lived near subsistence.[229]\nCurrency and banking\nSee also: Roman currency and Roman finance\nSestertius issued under Hadrian circa AD 134–138\nSolidus issued under Constantine II, and on the reverse Victoria, one of the last deities to appear on Roman coins, gradually transforming into an angel under Christian rule[230]\n\nThe early Empire was monetized to a near-universal extent, using money as a way to express prices and debts.[231] The sestertius (English \"sesterces\", symbolized as HS) was the basic unit of reckoning value into the 4th century,[232] though the silver denarius, worth four sesterces, was also used beginning in the Severan dynasty.[233] The smallest coin commonly circulated was the bronze as, one-tenth denarius.[234] Bullion and ingots seem not to have counted as pecunia (\"money\") and were used only on the frontiers. Romans in the first and second centuries counted coins, rather than weighing them—an indication that the coin was valued on its face. This tendency towards fiat money led to the debasement of Roman coinage in the later Empire.[235] The standardization of money throughout the Empire promoted trade and market integration.[231] The high amount of metal coinage in circulation increased the money supply for trading or saving.[236] Rome had no central bank, and regulation of the banking system was minimal. Banks of classical antiquity typically kept less in reserves than the full total of customers' deposits. A typical bank had fairly limited capital, and often only one principal. Seneca assumes that anyone involved in Roman commerce needs access to credit.[235] A professional deposit banker received and held deposits for a fixed or indefinite term, and lent money to third parties. The senatorial elite were involved heavily in private lending, both as creditors and borrowers.[237] The holder of a debt could use it as a means of payment by transferring it to another party, without cash changing hands. Although it has sometimes been thought that ancient Rome lacked documentary transactions, the system of banks throughout the Empire permitted the exchange of large sums without physically transferring coins, in part because of the risks of moving large amounts of cash. Only one serious credit shortage is known to have occurred in the early Empire, in 33 AD;[238] generally, available capital exceeded the amount needed by borrowers.[235] The central government itself did not borrow money, and without public debt had to fund deficits from cash reserves.[239]\n\nEmperors of the Antonine and Severan dynasties debased the currency, particularly the denarius, under the pressures of meeting military payrolls.[232] Sudden inflation under Commodus damaged the credit market.[235] In the mid-200s, the supply of specie contracted sharply.[232] Conditions during the Crisis of the Third Century—such as reductions in long-distance trade, disruption of mining operations, and the physical transfer of gold coinage outside the empire by invading enemies—greatly diminished the money supply and the banking sector.[232][235] Although Roman coinage had long been fiat money or fiduciary currency, general economic anxieties came to a head under Aurelian, and bankers lost confidence in coins. Despite Diocletian's introduction of the gold solidus and monetary reforms, the credit market of the Empire never recovered its former robustness.[235]\nMining and metallurgy\nMain articles: Mining in ancient Rome and Roman metallurgy\nLandscape resulting from the ruina montium mining technique at Las Médulas, Spain, one of the most important gold mines in the Roman Empire\n\nThe main mining regions of the Empire were the Iberian Peninsula (gold, silver, copper, tin, lead); Gaul (gold, silver, iron); Britain (mainly iron, lead, tin), the Danubian provinces (gold, iron); Macedonia and Thrace (gold, silver); and Asia Minor (gold, silver, iron, tin).[citation needed] Intensive large-scale mining—of alluvial deposits, and by means of open-cast mining and underground mining—took place from the reign of Augustus up to the early 3rd century, when the instability of the Empire disrupted production.[citation needed]\n\nHydraulic mining allowed base and precious metals to be extracted on a proto-industrial scale.[240] The total annual iron output is estimated at 82,500 tonnes.[241] Copper and lead production levels were unmatched until the Industrial Revolution.[242][243][244][245] At its peak around the mid-2nd century, the Roman silver stock is estimated at 10,000 t, five to ten times larger than the combined silver mass of medieval Europe and the Caliphate around 800 AD.[244][246] As an indication of the scale of Roman metal production, lead pollution in the Greenland ice sheet quadrupled over prehistoric levels during the Imperial era and dropped thereafter.[247]\nTransportation and communication\nFurther information: Cursus publicus\nThe Tabula Peutingeriana (Latin for \"The Peutinger Map\") an Itinerarium, often assumed to be based on the Roman cursus publicus\n\nThe Empire completely encircled the Mediterranean, which they called \"our sea\" (Mare Nostrum).[248] Roman sailing vessels navigated the Mediterranean as well as major rivers.[56] Transport by water was preferred where possible, as moving commodities by land was more difficult.[249] Vehicles, wheels, and ships indicate the existence of a great number of skilled woodworkers.[250]\n\nLand transport utilized the advanced system of Roman roads, called \"viae\". These roads were primarily built for military purposes,[251] but also served commercial ends. The in-kind taxes paid by communities included the provision of personnel, animals, or vehicles for the cursus publicus, the state mail and transport service established by Augustus.[215] Relay stations were located along the roads every seven to twelve Roman miles, and tended to grow into villages or trading posts.[252] A mansio (plural mansiones) was a privately run service station franchised by the imperial bureaucracy for the cursus publicus. The distance between mansiones was determined by how far a wagon could travel in a day.[252] Carts were usually pulled by mules, travelling about 4 mph.[253]\nTrade and commodities\nSee also: Roman commerce, Indo-Roman trade relations, and Sino-Roman relations\n\nRoman provinces traded among themselves, but trade extended outside the frontiers to regions as far away as China and India.[254] Chinese trade was mostly conducted overland through middle men along the Silk Road; Indian trade also occurred by sea from Egyptian ports. The main commodity was grain.[255] Also traded were olive oil, foodstuffs, garum (fish sauce), slaves, ore and manufactured metal objects, fibres and textiles, timber, pottery, glassware, marble, papyrus, spices and materia medica, ivory, pearls, and gemstones.[256] Though most provinces could produce wine, regional varietals were desirable and wine was a central trade good.[257]\nLabour and occupations\nWorkers at a cloth-processing shop, in a painting from the fullonica of Veranius Hypsaeus in Pompeii\n\nInscriptions record 268 different occupations in Rome and 85 in Pompeii.[195] Professional associations or trade guilds (collegia) are attested for a wide range of occupations, some quite specialized.[163]\n\nWork performed by slaves falls into five general categories: domestic, with epitaphs recording at least 55 different household jobs; imperial or public service; urban crafts and services; agriculture; and mining. Convicts provided much of the labour in the mines or quarries, where conditions were notoriously brutal.[258] In practice, there was little division of labour between slave and free,[95] and most workers were illiterate and without special skills.[259] The greatest number of common labourers were employed in agriculture: in Italian industrial farming (latifundia), these may have been mostly slaves, but elsewhere slave farm labour was probably less important.[95]\n\nTextile and clothing production was a major source of employment. Both textiles and finished garments were traded and products were often named for peoples or towns, like a fashion \"label\".[260] Better ready-to-wear was exported by local businessmen (negotiatores or mercatores).[261] Finished garments might be retailed by their sales agents, by vestiarii (clothing dealers), or peddled by itinerant merchants.[261] The fullers (fullones) and dye workers (coloratores) had their own guilds.[262] Centonarii were guild workers who specialized in textile production and the recycling of old clothes into pieced goods.[p]\nRecreation of a deer hunt inspired by hunting scenes represented in Roman art."
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Architecture and engineering
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Architecture and engineering\nMain articles: Ancient Roman architecture, Roman engineering, and Roman technology\nThe Flavian Amphitheatre, more commonly known as the Colosseum\n\nThe chief Roman contributions to architecture were the arch, vault and dome. Some Roman structures still stand today, due in part to sophisticated methods of making cements and concrete.[265] Roman temples developed Etruscan and Greek forms, with some distinctive elements. Roman roads are considered the most advanced built until the early 19th century. The system of roadways facilitated military policing, communications, and trade, and were resistant to floods and other environmental hazards. Some remained usable for over a thousand years.[citation needed]\n\nRoman bridges were among the first large and lasting bridges, built from stone (and in most cases concrete) with the arch as the basic structure. The largest Roman bridge was Trajan's bridge over the lower Danube, constructed by Apollodorus of Damascus, which remained for over a millennium the longest bridge to have been built.[266] The Romans built many dams and reservoirs for water collection, such as the Subiaco Dams, two of which fed the Anio Novus, one of the largest aqueducts of Rome.[267]\nThe Pont du Gard aqueduct, which crosses the river Gardon in southern France, is on UNESCO's list of World Heritage Sites.\n\nThe Romans constructed numerous aqueducts. De aquaeductu, a treatise by Frontinus, who served as water commissioner, reflects the administrative importance placed on the water supply. Masonry channels carried water along a precise gradient, using gravity alone. It was then collected in tanks and fed through pipes to public fountains, baths, toilets, or industrial sites.[268] The main aqueducts in Rome were the Aqua Claudia and the Aqua Marcia.[269] The complex system built to supply Constantinople had its most distant supply drawn from over 120 km away along a route of more than 336 km.[270] Roman aqueducts were built to remarkably fine tolerance, and to a technological standard not equalled until modern times.[271] The Romans also used aqueducts in their extensive mining operations across the empire.[272]\n\nInsulated glazing (or \"double glazing\") was used in the construction of public baths. Elite housing in cooler climates might have hypocausts, a form of central heating. The Romans were the first culture to assemble all essential components of the much later steam engine: the crank and connecting rod system, Hero's aeolipile (generating steam power), the cylinder and piston (in metal force pumps), non-return valves (in water pumps), and gearing (in water mills and clocks).[273]"
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Daily life
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Daily life\nMain article: Culture of ancient Rome\nCityscape from the Villa Boscoreale (60s AD)\nCity and country\n\nThe city was viewed as fostering civilization by being \"properly designed, ordered, and adorned\".[274] Augustus undertook a vast building programme in Rome, supported public displays of art that expressed imperial ideology, and reorganized the city into neighbourhoods (vici) administered at the local level with police and firefighting services.[275] A focus of Augustan monumental architecture was the Campus Martius, an open area outside the city centre: the Altar of Augustan Peace (Ara Pacis Augustae) was located there, as was an obelisk imported from Egypt that formed the pointer (gnomon) of a horologium. With its public gardens, the Campus was among the most attractive places in Rome to visit.[275]\n\nCity planning and urban lifestyles was influenced by the Greeks early on,[276] and in the Eastern Empire, Roman rule shaped the development of cities that already had a strong Hellenistic character. Cities such as Athens, Aphrodisias, Ephesus and Gerasa tailored city planning and architecture to imperial ideals, while expressing their individual identity and regional preeminence.[277] In areas inhabited by Celtic-speaking peoples, Rome encouraged the development of urban centres with stone temples, forums, monumental fountains, and amphitheatres, often on or near the sites of preexisting walled settlements known as oppida.[278][279][q] Urbanization in Roman Africa expanded on Greek and Punic coastal cities.[252]\nAquae Sulis in Bath, England: architectural features above the level of the pillar bases are a later reconstruction.\n\nThe network of cities (coloniae, municipia, civitates or in Greek terms poleis) was a primary cohesive force during the Pax Romana.[184] Romans of the 1st and 2nd centuries were encouraged to \"inculcate the habits of peacetime\".[281] As the classicist Clifford Ando noted:\n\n Most of the cultural appurtenances popularly associated with imperial culture—public cult and its games and civic banquets, competitions for artists, speakers, and athletes, as well as the funding of the great majority of public buildings and public display of art—were financed by private individuals, whose expenditures in this regard helped to justify their economic power and legal and provincial privileges.[282]\n\nPublic toilets (latrinae) from Ostia Antica\n\nIn the city of Rome, most people lived in multistory apartment buildings (insulae) that were often squalid firetraps. Public facilities—such as baths (thermae), toilets with running water (latrinae), basins or elaborate fountains (nymphea) delivering fresh water,[279] and large-scale entertainments such as chariot races and gladiator combat—were aimed primarily at the common people.[283] Similar facilities were constructed in cities throughout the Empire, and some of the best-preserved Roman structures are in Spain, southern France, and northern Africa.[citation needed]\n\nThe public baths served hygienic, social and cultural functions.[284] Bathing was the focus of daily socializing.[285] Roman baths were distinguished by a series of rooms that offered communal bathing in three temperatures, with amenities that might include an exercise room, sauna, exfoliation spa, ball court, or outdoor swimming pool. Baths had hypocaust heating: the floors were suspended over hot-air channels.[286] Public baths were part of urban culture throughout the provinces, but in the late 4th century, individual tubs began to replace communal bathing. Christians were advised to go to the baths only for hygiene.[287]\nReconstructed peristyle garden based on the House of the Vettii\n\nRich families from Rome usually had two or more houses: a townhouse (domus) and at least one luxury home (villa) outside the city. The domus was a privately owned single-family house, and might be furnished with a private bath (balneum),[286] but it was not a place to retreat from public life.[288] Although some neighbourhoods show a higher concentration of such houses, they were not segregated enclaves. The domus was meant to be visible and accessible. The atrium served as a reception hall in which the paterfamilias (head of household) met with clients every morning.[275] It was a centre of family religious rites, containing a shrine and images of family ancestors.[289] The houses were located on busy public roads, and ground-level spaces were often rented out as shops (tabernae).[290] In addition to a kitchen garden—windowboxes might substitute in the insulae—townhouses typically enclosed a peristyle garden.[291]\n\nThe villa by contrast was an escape from the city, and in literature represents a lifestyle that balances intellectual and artistic interests (otium) with an appreciation of nature and agriculture.[292] Ideally a villa commanded a view or vista, carefully framed by the architectural design.[293] It might be located on a working estate, or in a \"resort town\" on the seacoast.[citation needed]\n\nAugustus' programme of urban renewal, and the growth of Rome's population to as many as one million, was accompanied by nostalgia for rural life. Poetry idealized the lives of farmers and shepherds. Interior decorating often featured painted gardens, fountains, landscapes, vegetative ornament,[293] and animals, rendered accurately enough to be identified by species.[294] On a more practical level, the central government took an active interest in supporting agriculture.[295] Producing food was the priority of land use.[296] Larger farms (latifundia) achieved an economy of scale that sustained urban life.[295] Small farmers benefited from the development of local markets in towns and trade centres. Agricultural techniques such as crop rotation and selective breeding were disseminated throughout the Empire, and new crops were introduced from one province to another.[297]\nBread stall, from a Pompeiian wall painting\n\nMaintaining an affordable food supply to the city of Rome had become a major political issue in the late Republic, when the state began to provide a grain dole (Cura Annonae) to citizens who registered for it[295] (about 200,000–250,000 adult males in Rome).[298] The dole cost at least 15% of state revenues,[295] but improved living conditions among the lower classes,[299] and subsidized the rich by allowing workers to spend more of their earnings on the wine and olive oil produced on estates.[295] The grain dole also had symbolic value: it affirmed the emperor's position as universal benefactor, and the right of citizens to share in \"the fruits of conquest\".[295] The annona, public facilities, and spectacular entertainments mitigated the otherwise dreary living conditions of lower-class Romans, and kept social unrest in check. The satirist Juvenal, however, saw \"bread and circuses\" (panem et circenses) as emblematic of the loss of republican political liberty:[300]\n\n The public has long since cast off its cares: the people that once bestowed commands, consulships, legions and all else, now meddles no more and longs eagerly for just two things: bread and circuses.[301]\n\nHealth and disease\nFurther information: Disease in Imperial Rome, Antonine plague, and Plague of Cyprian\n\nEpidemics were common in the ancient world, and occasional pandemics in the Empire killed millions. The Roman population was unhealthy. About 20 percent—a large percentage by ancient standards—lived in cities, Rome being the largest. The cities were a \"demographic sink\": the death rate exceeded the birth rate and constant immigration was necessary to maintain the population. Average lifespan is estimated at the mid-twenties, and perhaps more than half of children died before reaching adulthood. Dense urban populations and poor sanitation contributed to disease. Land and sea connections facilitated and sped the transfer of infectious diseases across the empire's territories. The rich were not immune; only two of emperor Marcus Aurelius's fourteen children are known to have reached adulthood.[302]\n\nThe importance of a good diet to health was recognized by medical writers such as Galen (2nd century). Views on nutrition were influenced by beliefs like humoral theory.[303] A good indicator of nutrition and disease burden is average height: the average Roman was shorter in stature than the population of pre-Roman Italian societies and medieval Europe.[304]\nFood and dining\nMain article: Food and dining in the Roman Empire\nSee also: Ancient Roman cuisine and Ancient Rome and wine\nStill life on a 2nd-century Roman mosaic\n\nMost apartments in Rome lacked kitchens, though a charcoal brazier could be used for rudimentary cookery.[305] Prepared food was sold at pubs and bars, inns, and food stalls (tabernae, cauponae, popinae, thermopolia).[306] Carryout and restaurants were for the lower classes; fine dining appeared only at dinner parties in wealthy homes with a chef (archimagirus) and kitchen staff,[307] or banquets hosted by social clubs (collegia).[308]\n\nMost Romans consumed at least 70% of their daily calories in the form of cereals and legumes.[309] Puls (pottage) was considered the food of the Romans,[310] and could be elaborated to produce dishes similar to polenta or risotto.[311] Urban populations and the military preferred bread.[309] By the reign of Aurelian, the state had begun to distribute the annona as a daily ration of bread baked in state factories, and added olive oil, wine, and pork to the dole.[312]\n\nRoman literature focuses on the dining habits of the upper classes,[313] for whom the evening meal (cena) had important social functions.[314] Guests were entertained in a finely decorated dining room (triclinium) furnished with couches. By the late Republic, women dined, reclined, and drank wine along with men.[315] The poet Martial describes a dinner, beginning with the gustatio (\"tasting\" or \"appetizer\") salad. The main course was kid, beans, greens, a chicken, and leftover ham, followed by a dessert of fruit and wine.[316] Roman \"foodies\" indulged in wild game, fowl such as peacock and flamingo, large fish (mullet was especially prized), and shellfish. Luxury ingredients were imported from the far reaches of empire.[317] A book-length collection of Roman recipes is attributed to Apicius, a name for several figures in antiquity that became synonymous with \"gourmet\".[318]\n\nRefined cuisine could be moralized as a sign of either civilized progress or decadent decline.[319] Most often, because of the importance of landowning in Roman culture, produce—cereals, legumes, vegetables, and fruit—were considered more civilized foods than meat. The Mediterranean staples of bread, wine, and oil were sacralized by Roman Christianity, while Germanic meat consumption became a mark of paganism.[320] Some philosophers and Christians resisted the demands of the body and the pleasures of food, and adopted fasting as an ideal.[321] Food became simpler in general as urban life in the West diminished and trade routes were disrupted;[322] the Church formally discouraged gluttony,[323] and hunting and pastoralism were seen as simple and virtuous.[322]\n\nSpectacles\nSee also: Ludi, Chariot racing, and Recitationes\nA victor in his four-horse chariot\n\nWhen Juvenal complained that the Roman people had exchanged their political liberty for \"bread and circuses\", he was referring to the state-provided grain dole and the circenses, events held in the entertainment venue called a circus. The largest such venue in Rome was the Circus Maximus, the setting of horse races, chariot races, the equestrian Troy Game, staged beast hunts (venationes), athletic contests, gladiator combat, and historical re-enactments. From earliest times, several religious festivals had featured games (ludi), primarily horse and chariot races (ludi circenses).[324] The races retained religious significance in connection with agriculture, initiation, and the cycle of birth and death.[r]\n\nUnder Augustus, public entertainments were presented on 77 days of the year; by the reign of Marcus Aurelius, this had expanded to 135.[326] Circus games were preceded by an elaborate parade (pompa circensis) that ended at the venue.[327] Competitive events were held also in smaller venues such as the amphitheatre, which became the characteristic Roman spectacle venue, and stadium. Greek-style athletics included footraces, boxing, wrestling, and the pancratium.[328] Aquatic displays, such as the mock sea battle (naumachia) and a form of \"water ballet\", were presented in engineered pools.[329] State-supported theatrical events (ludi scaenici) took place on temple steps or in grand stone theatres, or in the smaller enclosed theatre called an odeon.[330]\n\nCircuses were the largest structure regularly built in the Roman world.[331] The Flavian Amphitheatre, better known as the Colosseum, became the regular arena for blood sports in Rome.[332] Many Roman amphitheatres, circuses and theatres built in cities outside Italy are visible as ruins today.[332] The local ruling elite were responsible for sponsoring spectacles and arena events, which both enhanced their status and drained their resources.[167] The physical arrangement of the amphitheatre represented the order of Roman society: the emperor in his opulent box; senators and equestrians in reserved advantageous seats; women seated at a remove from the action; slaves given the worst places, and everybody else in-between.[333] The crowd could call for an outcome by booing or cheering, but the emperor had the final say. Spectacles could quickly become sites of social and political protest, and emperors sometimes had to deploy force to put down crowd unrest, most notoriously at the Nika riots in 532.[334]\nThe Zliten mosaic, from a dining room in present-day Libya, depicts a series of arena scenes: from top, musicians; gladiators; beast fighters; and convicts condemned to the beasts[335]\n\nThe chariot teams were known by the colours they wore. Fan loyalty was fierce and at times erupted into sports riots.[336] Racing was perilous, but charioteers were among the most celebrated and well-compensated athletes.[337] Circuses were designed to ensure that no team had an unfair advantage and to minimize collisions (naufragia),[338] which were nonetheless frequent and satisfying to the crowd.[339] The races retained a magical aura through their early association with chthonic rituals: circus images were considered protective or lucky, curse tablets have been found buried at the site of racetracks, and charioteers were often suspected of sorcery.[340] Chariot racing continued into the Byzantine period under imperial sponsorship, but the decline of cities in the 6th and 7th centuries led to its eventual demise.[331]\n\nThe Romans thought gladiator contests had originated with funeral games and sacrifices. Some of the earliest styles of gladiator fighting had ethnic designations such as \"Thracian\" or \"Gallic\".[341] The staged combats were considered munera, \"services, offerings, benefactions\", initially distinct from the festival games (ludi).[342] To mark the opening of the Colosseum, Titus presented 100 days of arena events, with 3,000 gladiators competing on a single day.[343] Roman fascination with gladiators is indicated by how widely they are depicted on mosaics, wall paintings, lamps, and in graffiti.[344] Gladiators were trained combatants who might be slaves, convicts, or free volunteers.[345] Death was not a necessary or even desirable outcome in matches between these highly skilled fighters, whose training was costly and time-consuming.[346] By contrast, noxii were convicts sentenced to the arena with little or no training, often unarmed, and with no expectation of survival; physical suffering and humiliation were considered appropriate retributive justice.[167] These executions were sometimes staged or ritualized as re-enactments of myths, and amphitheatres were equipped with elaborate stage machinery to create special effects.[167][347]\n\nModern scholars have found the pleasure Romans took in the \"theatre of life and death\"[348] difficult to understand.[349] Pliny the Younger rationalized gladiator spectacles as good for the people, \"to inspire them to face honourable wounds and despise death, by exhibiting love of glory and desire for victory\".[350] Some Romans such as Seneca were critical of the brutal spectacles, but found virtue in the courage and dignity of the defeated fighter[351]—an attitude that finds its fullest expression with the Christians martyred in the arena. Tertullian considered deaths in the arena to be nothing more than a dressed-up form of human sacrifice.[352] Even martyr literature, however, offers \"detailed, indeed luxuriant, descriptions of bodily suffering\",[353] and became a popular genre at times indistinguishable from fiction.[354]\nRecreation\nSo-called \"Bikini Girls\" mosaic from the Villa del Casale, Roman Sicily, 4th century\n\nThe singular ludus, \"play, game, sport, training\", had a wide range of meanings such as \"word play\", \"theatrical performance\", \"board game\", \"primary school\", and even \"gladiator training school\" (as in Ludus Magnus).[355] Activities for children and young people in the Empire included hoop rolling and knucklebones (astragali or \"jacks\"). Girls had dolls made of wood, terracotta, and especially bone and ivory.[356] Ball games include trigon and harpastum.[357] People of all ages played board games, including latrunculi (\"Raiders\") and XII scripta (\"Twelve Marks\").[358] A game referred to as alea (dice) or tabula (the board) may have been similar to backgammon.[359] Dicing as a form of gambling was disapproved of, but was a popular pastime during the festival of the Saturnalia.[citation needed]\n\nAfter adolescence, most physical training for males was of a military nature. The Campus Martius originally was an exercise field where young men learned horsemanship and warfare. Hunting was also considered an appropriate pastime. According to Plutarch, conservative Romans disapproved of Greek-style athletics that promoted a fine body for its own sake, and condemned Nero's efforts to encourage Greek-style athletic games.[360] Some women trained as gymnasts and dancers, and a rare few as female gladiators. The \"Bikini Girls\" mosaic shows young women engaging in routines comparable to rhythmic gymnastics.[s][362] Women were encouraged to maintain health through activities such as playing ball, swimming, walking, or reading aloud (as a breathing exercise).[363]\nClothing\nMain article: Clothing in ancient Rome\nFurther information: Roman hairstyles, Roman jewelry, and Cosmetics in ancient Rome\nTogate statue in the Museo Archeologico Nazionale d'Abruzzo\n\nIn a status-conscious society like that of the Romans, clothing and personal adornment indicated the etiquette of interacting with the wearer.[364] Wearing the correct clothing reflected a society in good order.[365] There is little direct evidence of how Romans dressed in daily life, since portraiture may show the subject in clothing with symbolic value, and surviving textiles are rare.[366][367]\n\nThe toga was the distinctive national garment of the male citizen, but it was heavy and impractical, worn mainly for conducting political or court business and religious rites.[368][366] It was a \"vast expanse\" of semi-circular white wool that could not be put on and draped correctly without assistance.[368] The drapery became more intricate and structured over time.[369] The toga praetexta, with a purple or purplish-red stripe representing inviolability, was worn by children who had not come of age, curule magistrates, and state priests. Only the emperor could wear an all-purple toga (toga picta).[370]\n\nOrdinary clothing was dark or colourful. The basic garment for all Romans, regardless of gender or wealth, was the simple sleeved tunic, with length differing by wearer.[371] The tunics of poor people and labouring slaves were made from coarse wool in natural, dull shades; finer tunics were made of lightweight wool or linen. A man of the senatorial or equestrian order wore a tunic with two purple stripes (clavi) woven vertically: the wider the stripe, the higher the wearer's status.[371] Other garments could be layered over the tunic. Common male attire also included cloaks and in some regions trousers.[372] In the 2nd century, emperors and elite men are often portrayed wearing the pallium, an originally Greek mantle; women are also portrayed in the pallium. Tertullian considered the pallium an appropriate garment both for Christians, in contrast to the toga, and for educated people.[365][366][373]\n\nRoman clothing styles changed over time.[374] In the Dominate, clothing worn by both soldiers and bureaucrats became highly decorated with geometrical patterns, stylized plant motifs, and in more elaborate examples, human or animal figures.[375] Courtiers of the later Empire wore elaborate silk robes. The militarization of Roman society, and the waning of urban life, affected fashion: heavy military-style belts were worn by bureaucrats as well as soldiers, and the toga was abandoned,[376] replaced by the pallium as a garment embodying social unity.[377] "
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Arts
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Arts\nMain articles: Roman art and Art collection in ancient Rome\n\nGreek art had a profound influence on Roman art.[378] Public art—including sculpture, monuments such as victory columns or triumphal arches, and the iconography on coins—is often analysed for historical or ideological significance.[379] In the private sphere, artistic objects were made for religious dedications, funerary commemoration, domestic use, and commerce.[380] The wealthy advertised their appreciation of culture through artwork and decorative arts in their homes.[381] Despite the value placed on art, even famous artists were of low social status, partly as they worked with their hands.[382]\nPortraiture\nMain article: Roman portraiture\nTwo portraits c. 130 AD: the empress Vibia Sabina (left); and the Antinous Mondragone\n\nPortraiture, which survives mainly in sculpture, was the most copious form of imperial art. Portraits during the Augustan period utilize classical proportions, evolving later into a mixture of realism and idealism.[383] Republican portraits were characterized by verism, but as early as the 2nd century BC, Greek heroic nudity was adopted for conquering generals.[384] Imperial portrait sculptures may model a mature head atop a youthful nude or semi-nude body with perfect musculature.[385] Clothed in the toga or military regalia, the body communicates rank or role, not individual characteristics.[386] Women of the emperor's family were often depicted as goddesses or divine personifications.[citation needed]\n\nPortraiture in painting is represented primarily by the Fayum mummy portraits, which evoke Egyptian and Roman traditions of commemorating the dead with realistic painting. Marble portrait sculpture were painted, but traces have rarely survived.[387]\nSculpture and sarcophagi\nMain articles: Roman sculpture and Ancient Roman sarcophagi\nOn the Ludovisi sarcophagus\n\nExamples of Roman sculpture survive abundantly, though often in damaged or fragmentary condition, including freestanding statuary in marble, bronze and terracotta, and reliefs from public buildings and monuments. Niches in amphitheatres were originally filled with statues,[388][389] as were formal gardens.[390] Temples housed cult images of deities, often by famed sculptors.[391]\n\nElaborately carved marble and limestone sarcophagi are characteristic of the 2nd to 4th centuries.[392] Sarcophagus relief has been called the \"richest single source of Roman iconography\",[393] depicting mythological scenes[394] or Jewish/Christian imagery[395] as well as the deceased's life.\nPainting\nMain article: Painting in ancient Rome\nThe Wedding of Zephyrus and Chloris (54–68 AD, Pompeian Fourth Style) within painted architectural panels from the Casa del Naviglio\n\nInitial Roman painting drew from Etruscan and Greek models and techniques. Examples of Roman paintings can be found in palaces, catacombs and villas. Much of what is known of Roman painting is from the interior decoration of private homes, particularly as preserved by the eruption of Vesuvius. In addition to decorative borders and panels with geometric or vegetative motifs, wall painting depicts scenes from mythology and theatre, landscapes and gardens, spectacles, everyday life, and erotic art.[citation needed]\nMosaic\nMain article: Roman mosaic\nThe Triumph of Neptune floor mosaic from Africa Proconsularis (present-day Tunisia)[396]\n\nMosaics are among the most enduring of Roman decorative arts, and are found on floors and other architectural features. The most common is the tessellated mosaic, formed from uniform pieces (tesserae) of materials such as stone and glass.[397] Opus sectile is a related technique in which flat stone, usually coloured marble, is cut precisely into shapes from which geometric or figurative patterns are formed. This more difficult technique became especially popular for luxury surfaces in the 4th century (e.g. the Basilica of Junius Bassus).[398]\n\nFigurative mosaics share many themes with painting, and in some cases use almost identical compositions. Geometric patterns and mythological scenes occur throughout the Empire. In North Africa, a particularly rich source of mosaics, homeowners often chose scenes of life on their estates, hunting, agriculture, and local wildlife.[396] Plentiful and major examples of Roman mosaics come also from present-day Turkey (particularly the (Antioch mosaics[399]), Italy, southern France, Spain, and Portugal.\nDecorative arts\nFurther information: Ancient Roman pottery and Roman glass\n\nDecorative arts for luxury consumers included fine pottery, silver and bronze vessels and implements, and glassware. Pottery manufacturing was economically important, as were the glass and metalworking industries. Imports stimulated new regional centres of production. Southern Gaul became a leading producer of the finer red-gloss pottery (terra sigillata) that was a major trade good in 1st-century Europe.[400] Glassblowing was regarded by the Romans as originating in Syria in the 1st century BC, and by the 3rd century, Egypt and the Rhineland had become noted for fine glass.[401]\n\n Silver cup, from the Boscoreale Treasure (early 1st century AD)\n Silver cup, from the Boscoreale Treasure (early 1st century AD)\n Finely decorated Gallo-Roman terra sigillata bowl\n Finely decorated Gallo-Roman terra sigillata bowl\n Gold earrings with gemstones, 3rd century\n Gold earrings with gemstones, 3rd century\n Glass cage cup from the Rhineland, 4th century\n Glass cage cup from the Rhineland, 4th century\n\nPerforming arts\nMain articles: Theatre of ancient Rome and Music of ancient Rome\nAll-male theatrical troupe preparing for a masked performance, on a mosaic from the House of the Tragic Poet\n\nIn Roman tradition, borrowed from the Greeks, literary theatre was performed by all-male troupes that used face masks with exaggerated facial expressions to portray emotion. Female roles were played by men in drag (travesti). Roman literary theatre tradition is particularly well represented in Latin literature by the tragedies of Seneca.[citation needed]\n\nMore popular than literary theatre was the genre-defying mimus theatre, which featured scripted scenarios with free improvisation, risqué language and sex scenes, action sequences, and political satire, along with dance, juggling, acrobatics, tightrope walking, striptease, and dancing bears.[402] Unlike literary theatre, mimus was played without masks, and encouraged stylistic realism. Female roles were performed by women.[403] Mimus was related to pantomimus, an early form of story ballet that contained no spoken dialogue but rather a sung libretto, often mythological, either tragic or comic.[404]\nTrio of musicians playing an aulos, cymbala, and tympanum (mosaic from Pompeii)\n\nAlthough sometimes regarded as foreign, music and dance existed in Rome from earliest times.[405] Music was customary at funerals, and the tibia, a woodwind instrument, was played at sacrifices.[406] Song (carmen) was integral to almost every social occasion. Music was thought to reflect the orderliness of the cosmos.[407] Various woodwinds and \"brass\" instruments were played, as were stringed instruments such as the cithara, and percussion.[406] The cornu, a long tubular metal wind instrument, was used for military signals and on parade.[406] These instruments spread throughout the provinces and are widely depicted in Roman art.[408] The hydraulic pipe organ (hydraulis) was \"one of the most significant technical and musical achievements of antiquity\", and accompanied gladiator games and events in the amphitheatre.[406] Although certain dances were seen at times as non-Roman or unmanly, dancing was embedded in religious rituals of archaic Rome.[409] Ecstatic dancing was a feature of the mystery religions, particularly the cults of Cybele[410] and Isis. In the secular realm, dancing girls from Syria and Cadiz were extremely popular.[411]\n\nLike gladiators, entertainers were legally infames, technically free but little better than slaves. \"Stars\", however, could enjoy considerable wealth and celebrity, and mingled socially and often sexually with the elite.[412] Performers supported each other by forming guilds, and several memorials for theatre members survive.[413] Theatre and dance were often condemned by Christian polemicists in the later Empire.[405][414] "
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Literacy, books, and education
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Literacy, books, and education\nPride in literacy was displayed through emblems of reading and writing, as in this portrait of Terentius Neo and his wife (c. 20 AD)\n\nEstimates of the average literacy rate range from 5 to over 30%.[415][416][417] The Roman obsession with documents and inscriptions indicates the value placed on the written word.[418][419][t] Laws and edicts were posted as well as read out. Illiterate Roman subjects could have a government scribe (scriba) read or write their official documents for them.[416][421] The military produced extensive written records.[422] The Babylonian Talmud declared \"if all seas were ink, all reeds were pen, all skies parchment, and all men scribes, they would be unable to set down the full scope of the Roman government's concerns\".[423]\n\nNumeracy was necessary for commerce.[419][424] Slaves were numerate and literate in significant numbers; some were highly educated.[425] Graffiti and low-quality inscriptions with misspellings and solecisms indicate casual literacy among non-elites.[426][u][84]\n\nThe Romans had an extensive priestly archive, and inscriptions appear throughout the Empire in connection with votives dedicated by ordinary people, as well as \"magic spells\" (e.g. the Greek Magical Papyri).[427]\n\nBooks were expensive, since each copy had to be written out on a papyrus roll (volumen) by scribes.[428] The codex—pages bound to a spine—was still a novelty in the 1st century,[429] but by the end of the 3rd century was replacing the volumen.[430] Commercial book production was established by the late Republic,[431] and by the 1st century certain neighbourhoods of Rome and Western provincial cities were known for their bookshops.[432] The quality of editing varied wildly,[433] and plagiarism or forgery were common, since there was no copyright law.[431]\nReconstruction of a wax writing tablet\n\nCollectors amassed personal libraries,[434] and a fine library was part of the cultivated leisure (otium) associated with the villa lifestyle.[435] Significant collections might attract \"in-house\" scholars,[436] and an individual benefactor might endow a community with a library (as Pliny the Younger did in Comum).[437] Imperial libraries were open to users on a limited basis, and represented a literary canon.[438] Books considered subversive might be publicly burned,[439] and Domitian crucified copyists for reproducing works deemed treasonous.[440]\n\nLiterary texts were often shared aloud at meals or with reading groups.[441] Public readings (recitationes) expanded from the 1st through the 3rd century, giving rise to \"consumer literature\" for entertainment.[442] Illustrated books, including erotica, were popular, but are poorly represented by extant fragments.[443]\n\nLiteracy began to decline during the Crisis of the Third Century.[444] The emperor Julian banned Christians from teaching the classical curriculum,[445] but the Church Fathers and other Christians adopted Latin and Greek literature, philosophy and science in biblical interpretation.[446] As the Western Roman Empire declined, reading became rarer even for those within the Church hierarchy,[447] although it continued in the Byzantine Empire.[448]\nEducation\nMain article: Education in ancient Rome\nA teacher with two students, as a third arrives with his loculus, a writing case[449]\n\nTraditional Roman education was moral and practical. Stories were meant to instil Roman values (mores maiorum). Parents were expected to act as role models, and working parents passed their skills to their children, who might also enter apprenticeships.[450] Young children were attended by a pedagogue, usually a Greek slave or former slave,[451] who kept the child safe, taught self-discipline and public behaviour, attended class and helped with tutoring.[452]\n\nFormal education was available only to families who could pay for it; lack of state support contributed to low literacy.[453] Primary education in reading, writing, and arithmetic might take place at home if parents hired or bought a teacher.[454] Other children attended \"public\" schools organized by a schoolmaster (ludimagister) paid by parents.[455] Vernae (homeborn slave children) might share in-home or public schooling.[456] Boys and girls received primary education generally from ages 7 to 12, but classes were not segregated by grade or age.[457] Most schools employed corporal punishment.[458] For the socially ambitious, education in Greek as well as Latin was necessary.[459] Schools became more numerous during the Empire, increasing educational opportunities.[459]\nMosaic from Pompeii depicting the Academy of Plato\n\nAt the age of 14, upperclass males made their rite of passage into adulthood, and began to learn leadership roles through mentoring from a senior family member or family friend.[460] Higher education was provided by grammatici or rhetores.[461] The grammaticus or \"grammarian\" taught mainly Greek and Latin literature, with history, geography, philosophy or mathematics treated as explications of the text.[462] With the rise of Augustus, contemporary Latin authors such as Virgil and Livy also became part of the curriculum.[463] The rhetor was a teacher of oratory or public speaking. The art of speaking (ars dicendi) was highly prized, and eloquentia (\"speaking ability, eloquence\") was considered the \"glue\" of civilized society.[464] Rhetoric was not so much a body of knowledge (though it required a command of the literary canon[465]) as it was a mode of expression that distinguished those who held social power.[466] The ancient model of rhetorical training—\"restraint, coolness under pressure, modesty, and good humour\"[467]—endured into the 18th century as a Western educational ideal.[468]\n\nIn Latin, illiteratus could mean both \"unable to read and write\" and \"lacking in cultural awareness or sophistication\".[469] Higher education promoted career advancement.[470] Urban elites throughout the Empire shared a literary culture imbued with Greek educational ideals (paideia).[471] Hellenistic cities sponsored schools of higher learning to express cultural achievement.[472] Young Roman men often went abroad to study rhetoric and philosophy, mostly to Athens. The curriculum in the East was more likely to include music and physical training.[473] On the Hellenistic model, Vespasian endowed chairs of grammar, Latin and Greek rhetoric, and philosophy at Rome, and gave secondary teachers special exemptions from taxes and legal penalties.[474] In the Eastern Empire, Berytus (present-day Beirut) was unusual in offering a Latin education, and became famous for its school of Roman law.[475] The cultural movement known as the Second Sophistic (1st–3rd century AD) promoted the assimilation of Greek and Roman social, educational, and esthetic values.[476]\n\nLiterate women ranged from cultured aristocrats to girls trained to be calligraphers and scribes.[477][478] The ideal woman in Augustan love poetry was educated and well-versed in the arts.[479] Education seems to have been standard for daughters of the senatorial and equestrian orders.[456] An educated wife was an asset for the socially ambitious household.[477]\nLiterature\nMain article: Latin literature\nSee also: Latin poetry\nStatue in Constanța, Romania (the ancient colony Tomis), commemorating Ovid's exile\n\nLiterature under Augustus, along with that of the Republic, has been viewed as the \"Golden Age\" of Latin literature, embodying classical ideals.[480] The three most influential Classical Latin poets—Virgil, Horace, and Ovid—belong to this period. Virgil's Aeneid was a national epic in the manner of the Homeric epics of Greece. Horace perfected the use of Greek lyric metres in Latin verse. Ovid's erotic poetry was enormously popular, but ran afoul of Augustan morality, contributing to his exile. Ovid's Metamorphoses wove together Greco-Roman mythology; his versions of Greek myths became a primary source of later classical mythology, and his work was hugely influential on medieval literature.[481] Latin writers were immersed in Greek literary traditions, and adapted its forms and content, but Romans regarded satire as a genre in which they surpassed the Greeks. The early Principate produced the satirists Persius and Juvenal.[citation needed]\n\nThe mid-1st through mid-2nd century has conventionally been called the \"Silver Age\" of Latin literature. The three leading writers—Seneca, Lucan, and Petronius—committed suicide after incurring Nero's displeasure. Epigrammatist and social observer Martial and the epic poet Statius, whose poetry collection Silvae influenced Renaissance literature,[482] wrote during the reign of Domitian. Other authors of the Silver Age included Pliny the Elder, author of the encyclopedic Natural History; his nephew, Pliny the Younger; and the historian Tacitus.\n\nThe principal Latin prose author of the Augustan age is the historian Livy, whose account of Rome's founding became the most familiar version in modern-era literature. The Twelve Caesars by Suetonius is a primary source for imperial biography. Among Imperial historians who wrote in Greek are Dionysius of Halicarnassus, Josephus, and Cassius Dio. Other major Greek authors of the Empire include the biographer Plutarch, the geographer Strabo, and the rhetorician and satirist Lucian.[citation needed]\n\nFrom the 2nd to the 4th centuries, Christian authors were in active dialogue with the classical tradition. Tertullian was one of the earliest prose authors with a distinctly Christian voice. After the conversion of Constantine, Latin literature is dominated by the Christian perspective.[483] In the late 4th century, Jerome produced the Latin translation of the Bible that became authoritative as the Vulgate. Augustine in The City of God against the Pagans builds a vision of an eternal, spiritual Rome, a new imperium sine fine that will outlast the collapsing Empire.[citation needed]\n\nIn contrast to the unity of Classical Latin, the literary esthetic of late antiquity has a tessellated quality.[484] A continuing interest in the religious traditions of Rome prior to Christian dominion is found into the 5th century, with the Saturnalia of Macrobius and The Marriage of Philology and Mercury of Martianus Capella. Prominent Latin poets of late antiquity include Ausonius, Prudentius, Claudian, and Sidonius Apollinaris.[citation needed] "
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Religion
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Religion\nMain articles: Religion in ancient Rome and Roman imperial cult\nSee also: History of the Jews in the Roman Empire, Early Christianity, Religious persecution in the Roman Empire, and Christianization of the Roman Empire as diffusion of innovation\nA Roman priest, his head ritually covered with a fold of his toga, extends a patera in a gesture of libation (2nd–3rd century)\nThe emperor Marcus Aurelius sacrificing at the Temple of Jupiter\n\nThe Romans thought of themselves as highly religious, and attributed their success to their collective piety (pietas) and good relations with the gods (pax deorum). The archaic religion believed to have come from the earliest kings of Rome was the foundation of the mos maiorum, \"the way of the ancestors\", central to Roman identity.[485] The priesthoods of the state religion were filled from the same pool of men who held public office, and the Pontifex Maximus was the emperor.[citation needed]\n\nRoman religion was practical and contractual, based on the principle of do ut des, \"I give that you might give\". Religion depended on knowledge and the correct practice of prayer, ritual, and sacrifice, not on faith or dogma, although Latin literature preserves learned speculation on the nature of the divine. For ordinary Romans, religion was a part of daily life.[486] Each home had a household shrine to offer prayers and libations to the family's domestic deities. Neighbourhood shrines and sacred places such as springs and groves dotted the city. The Roman calendar was structured around religious observances; as many as 135 days were devoted to religious festivals and games (ludi).[487]\n\nIn the wake of the Republic's collapse, state religion adapted to support the new regime. Augustus justified one-man rule with a vast programme of religious revivalism and reform. Public vows now were directed at the wellbeing of the emperor. So-called \"emperor worship\" expanded on a grand scale the traditional veneration of the ancestral dead and of the Genius, the divine tutelary of every individual. Upon death, an emperor could be made a state divinity (divus) by vote of the Senate. The Roman imperial cult, influenced by Hellenistic ruler cult, became one of the major ways Rome advertised its presence in the provinces and cultivated shared cultural identity. Cultural precedent in the Eastern provinces facilitated a rapid dissemination of Imperial cult, extending as far as Najran, in present-day Saudi Arabia.[v] Rejection of the state religion became tantamount to treason. This was the context for Rome's conflict with Christianity, which Romans variously regarded as a form of atheism and superstitio.[citation needed]\n\nThe Romans are known for the great number of deities they honoured. As the Romans extended their territories, their general policy was to promote stability among diverse peoples by absorbing local deities and cults rather than eradicating them,[w] building temples that framed local theology within Roman religion. Inscriptions throughout the Empire record the side-by-side worship of local and Roman deities, including dedications made by Romans to local gods.[489] By the height of the Empire, numerous syncretic or reinterpreted gods were cultivated, among them cults of Cybele, Isis, Epona, and of solar gods such as Mithras and Sol Invictus, found as far north as Roman Britain. Because Romans had never been obligated to cultivate one god or cult only, religious tolerance was not an issue.[490]\n\nMystery religions, which offered initiates salvation in the afterlife, were a matter of personal choice, practiced in addition to one's family rites and public religion. The mysteries, however, involved exclusive oaths and secrecy, which conservative Romans viewed with suspicion as characteristic of \"magic\", conspiracy (coniuratio), and subversive activity. Thus, sporadic and sometimes brutal attempts were made to suppress religionists. In Gaul, the power of the druids was checked, first by forbidding Roman citizens to belong to the order, and then by banning druidism altogether. However, Celtic traditions were reinterpreted within the context of Imperial theology, and a new Gallo-Roman religion coalesced; its capital at the Sanctuary of the Three Gauls established precedent for Western cult as a form of Roman-provincial identity.[491] The monotheistic rigour of Judaism posed difficulties for Roman policy that led at times to compromise and granting of special exemptions. Tertullian noted that Judaism, unlike Christianity, was considered a religio licita, \"legitimate religion\". The Jewish–Roman wars resulted from political as well as religious conflicts; the siege of Jerusalem in 70 AD led to the sacking of the temple and the dispersal of Jewish political power (see Jewish diaspora).\nA 3rd-century funerary stele is among the earliest Christian inscriptions, written in both Greek and Latin.\n\nChristianity emerged in Roman Judaea as a Jewish religious sect in the 1st century and gradually spread out of Jerusalem throughout the Empire and beyond. Imperially authorized persecutions were limited and sporadic, with martyrdoms occurring most often under the authority of local officials.[492] Tacitus reports that after the Great Fire of Rome in AD 64, the emperor attempted to deflect blame from himself onto the Christians.[493] A major persecution occurred under the emperor Domitian[494] and a persecution in 177 took place at Lugdunum, the Gallo-Roman religious capital. A letter from Pliny the Younger, governor of Bithynia, describes his persecution and executions of Christians.[495] The Decian persecution of 246–251 seriously threatened the Christian Church, but ultimately strengthened Christian defiance.[496] Diocletian undertook the most severe persecution of Christians, from 303 to 311.[citation needed]\n\nFrom the 2nd century onward, the Church Fathers condemned the diverse religions practiced throughout the Empire as \"pagan\".[497] In the early 4th century, Constantine I became the first emperor to convert to Christianity. He supported the Church financially and made laws that favored it, but the new religion was already successful, having moved from less than 50,000 to over a million adherents between 150 and 250.[498] Constantine and his successors banned public sacrifice while tolerating other traditional practices. Constantine never engaged in a purge,[499] there were no \"pagan martyrs\" during his reign,[500] and people who had not converted to Christianity remained in important positions at court.[499]: 302 Julian attempted to revive traditional public sacrifice and Hellenistic religion, but met Christian resistance and lack of popular support.[501]\nThe Pantheon in Rome, a Roman temple originally built under Augustus, later converted into a Catholic church in the 7th century[502]\n\nChristians of the 4th century believed the conversion of Constantine showed that Christianity had triumphed over paganism (in Heaven) and little further action besides such rhetoric was necessary.[503] Thus, their focus was heresy.[504][505] According to Peter Brown, \"In most areas, polytheists were not molested, and apart from a few ugly incidents of local violence, Jewish communities also enjoyed a century of stable, even privileged, existence\".[505]: 641–643 [506] There were anti-pagan laws, but they were not generally enforced; through the 6th century, centers of paganism existed in Athens, Gaza, Alexandria, and elsewhere.[507]\n\nAccording to recent Jewish scholarship, toleration of the Jews was maintained under Christian emperors.[508] This did not extend to heretics:[508] Theodosius I made multiple laws and acted against alternate forms of Christianity,[509] and heretics were persecuted and killed by both the government and the church throughout Late Antiquity. Non-Christians were not persecuted until the 6th century. Rome's original religious hierarchy and ritual influenced Christian forms,[510][511] and many pre-Christian practices survived in Christian festivals and local traditions. "
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Here's the template's title.
Legacy
Here's the template's text.
{
"question":"{{passThrough["question"]}}",
"info":"Legacy\nMain article: Legacy of the Roman Empire\nThe Virginia State Capitol (left), built in the late 1700s, was modelled after the Maison Carrée (right), in Nîmes, France, a Gallo-Roman temple built around 16 BC under Augustus.\n\nSeveral states claimed to be the Roman Empire's successor. The Holy Roman Empire was established in 800 when Pope Leo III crowned Charlemagne as Roman emperor. The Russian Tsardom, as inheritor of the Byzantine Empire's Orthodox Christian tradition, counted itself the Third Rome (Constantinople having been the second), in accordance with the concept of translatio imperii.[512] The last Eastern Roman titular, Andreas Palaiologos, sold the title of Emperor of Constantinople to Charles VIII of France; upon Charles' death, Palaiologos reclaimed the title and on his death granted it to Ferdinand and Isabella and their successors, who never used it. When the Ottomans, who based their state on the Byzantine model, took Constantinople in 1453, Mehmed II established his capital there and claimed to sit on the throne of the Roman Empire.[513] He even launched an invasion of Otranto with the purpose of re-uniting the Empire, which was aborted by his death. In the medieval West, \"Roman\" came to mean the church and the Catholic Pope. The Greek form Romaioi remained attached to the Greek-speaking Christian population of the Byzantine Empire and is still used by Greeks.[514]\n\nThe Roman Empire's control of the Italian peninsula influenced Italian nationalism and the unification of Italy (Risorgimento) in 1861.[515] Roman imperialism was claimed by fascist ideology, particularly by the Italian Empire and Nazi Germany.[citation needed]\n\nIn the United States, the founders were educated in the classical tradition,[516] and used classical models for landmarks in Washington, D.C..[517][518][519][520] The founders saw Athenian democracy and Roman republicanism as models for the mixed constitution, but regarded the emperor as a figure of tyranny.[521] "
}
And here are the template's parameters:
- Output Type:
Prompt
. By choosing "Prompt" the template runs without being submitted to an LLM. It's output is just the template after slotting in variable values. - Model:
gpt-4o-mini
. This input specifies what model we should use when running the prompt. Available models differ based on your API provider. See e.g., OpenAI's list of models. - Temperature:
0.7
. Temperature runs from 0 to 1 and specifies how "random" the answer should be. Here I'm using 0.7 because I'm happy to have the text be a little "creative." - Max Tokens:
250
. This number specifies how long the reply can be. Tokens are chunks of text the model uses to do its thing. They don't quite match up with words but are close. 1 token is something like 3/4 of a word. Smaller token limits run faster. - JSON:
Yes
. This asks the model to output its answer in something called JSON, which is a nice machine-readable way to structure data. See https://en.wikipedia.org/wiki/JSON - Output To:
Hidden
. We can output the first reply from the LLM to a number of places, the screen, the clipboard... Here, I've chosen the hide the output entirely. This is uesful when passing output to another template. - Post-run Behavior:
CHAT
. Like the choice of output, we can decide what to do after a template runs. Here we will trigger thetemplate.
- Hide Button:
checked
. This determines if a button is displayed for this template in the extension's popup window. We've checked the option because this template shouldn't be triggered by the user directly. Rather, it needs to be triggered by another template so that there's something in the{{passThrough}}
variable.
Working with the above templates
To work with the above templates, you could copy them and their parameters into LIT Prompts one by one, or you could download a single prompts file and upload it from the extension's Templates & Settings screen. This will replace your existing prompts.
You can download a prompts file (the above template and its parameters) suitable for upload by clicking this button:
Kick the Tires
It's one thing to read about something and another to put what you've learned into practice. Let's see how this template performs.
- Make it your own. Swap out the Roman Empire for something else; just be sure it's valid JSON. ;)
Export and Share
After you've made the templates your own and them behaving the way you like, you can export and share them with others. This will produce an HTML file you can share. This file should work on any internet connected device. To create your file, click the Export Interactions Page button. The contents of the textarea above the button will be appended to the top of your exported file. Importantly, if you don't want to share your API key, you should temporarily remove it from your settings before exporting.
If you want to see what an exported file looks like without having to make one yourself. You can use the buttons below. View export in browser will open the file in your browser, and Download export will download a file. In either case the following custom header will be inserted into your file. It will NOT include an API key. So, you'll have to enter one when asked if you want to see things work. This information is saved in your browser. If you've provided it before, you won't be asked again. It is not shared with me. To remove this information for this site (and only this site, not individual files), you can follow the instructions found on my privacy page. Remember, when you export your own file, whether or not it contains and API key depends on if you have one defined at the time of output.
Custom header:
<h2>Talk to the Roman Empire's Wikipedia Page</h2>
<p>Ask a single simple question of <a href="https://en.wikipedia.org/wiki/Roman_Empire" target="_blank">this Wikipedia</a> page ("top" through the <i>Legacy</i> section). No compound question! To understand what's going on here, check out this <a href="https://sadlynothavocdinosaur.com/posts/rag">post.
<hr style="border: solid 0px; border-bottom: solid 1px #555;margin: 5px 0 15px 0"/>
Not sure what's up with all those greater than and less than signs? Looking for tips on how to style your HTML? Check out this general HTML tutorial.
TL;DR References
ICYMI, here are blubs for a selection of works I linked to in this post. If you didn't click through above, you might want to give them a look now.
- On the Dangers of Stochastic Parrots: Can Language Models Be Too Big? 🦜 by Emily M. Bender, Timnit Gebru, Angelina McMillan-Major, and Shmargaret Shmitchell. There's a lot of history behind this paper. It was part of a chain of events that forced Timnit Gebru to leave Google where she was the co-lead of their ethical AI team, but more than that, it's one of the foundational papers in AI ethics, not to be confused with the field of "AI safety," which we will discuss later. It discusses several risks associated with large language models, including environmental/financial costs, biased language, lack of cultural nuance, misdirection of research, and potential for misinformation. If you want to engage critically with LLMs, this paper is a must read.
-
Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks by Patrick Lewis, Ethan Perez, Aleksandra Piktus, Fabio Petroni, Vladimir Karpukhin, Naman Goyal, Heinrich Küttler, Mike Lewis, Wen-tau Yih, Tim Rocktäschel, Sebastian Riedel, and Douwe Kiela. This is where we get the name "Retrieval-Augmented Generation." From the abstract:
Large pre-trained language models have been shown to store factual knowledge in their parameters, and achieve state-of-the-art results when fine-tuned on downstream NLP tasks. However, their ability to access and precisely manipulate knowledge is still limited, and hence on knowledge-intensive tasks, their performance lags behind task-specific architectures. Additionally, providing provenance for their decisions and updating their world knowledge remain open research problems. Pre-trained models with a differentiable access mechanism to explicit non-parametric memory can overcome this issue, but have so far been only investigated for extractive downstream tasks. We explore a general-purpose fine-tuning recipe for retrieval-augmented generation (RAG) -- models which combine pre-trained parametric and non-parametric memory for language generation. We introduce RAG models where the parametric memory is a pre-trained seq2seq model and the non-parametric memory is a dense vector index of Wikipedia, accessed with a pre-trained neural retriever. We compare two RAG formulations, one which conditions on the same retrieved passages across the whole generated sequence, the other can use different passages per token. We fine-tune and evaluate our models on a wide range of knowledge-intensive NLP tasks and set the state-of-the-art on three open domain QA tasks, outperforming parametric seq2seq models and task-specific retrieve-and-extract architectures. For language generation tasks, we find that RAG models generate more specific, diverse and factual language than a state-of-the-art parametric-only seq2seq baseline.