Safety and Risk Notice
I. Safety Challenges of Open-Ended Machine Learning Systems
We define API safety as a condition of freedom from physical, psychological, or social harm to people, including but not limited to death, injury, illness, suffering, misinformation, extreme behavior, property damage, or damage to the environment. Our notices and guidance regarding API safety are based on considerations specific to systems with machine learning (ML) components that can engage in high-bandwidth, open-ended interactions with humans, such as through natural language.
ML components have limited robustness. ML components can only be expected to provide reasonable outputs when the inputs they receive are sufficiently similar to the training data. Even if an ML system is considered safe when operating under conditions similar to its training data, unexpected user inputs may place the system in an unsafe state, and users are often unaware of which inputs will or will not cause unsafe behavior. Open-ended ML systems that interact with individuals, such as question-answering applications, are also susceptible to adversarial inputs from malicious users who deliberately attempt to place the system in an unintended state. Accordingly, as a mitigation measure, developers using this platform should manually evaluate model outputs for each use case under consideration, using outputs generated from a range of representative inputs and some adversarial inputs.
ML components are biased. ML components reflect the values and biases present in their training data, as well as those of their developers. Systems that use ML components, particularly those that interact in an open-ended manner, may perpetuate or amplify these values. Safety issues arise when values embedded in ML systems are harmful to individuals, groups, or important institutions. For ML components such as the API, which are trained on large quantities of value-laden training data collected from public sources, the scale of the training data and complex social factors make it impossible to eliminate harmful values entirely.
Open-ended systems present significant potential safety risks. Systems that engage in high-bandwidth interactions with end users, such as natural language conversations or question answering, can be used for almost any purpose. This makes it impossible to exhaustively identify and mitigate all potential safety risks in advance. Instead, we recommend an approach that focuses on broad categories and contexts of potential harm, continuously detects and responds to harmful incidents, and continually incorporates new mitigation measures as the need becomes apparent.
Safety requires ongoing consideration in the development of ML systems. The safety characteristics of ML systems change whenever their ML components are updated, for example, by retraining them with new data or training new components from scratch using new architectures. Because ML is an active field of research, and advances in research frequently yield new levels of performance, ML system designers should anticipate frequent updates to ML components and establish plans for ongoing safety analysis.
II. Harms to Consider in Risk Analysis
We provide examples of potential harms, or pathways to harm, that may arise in systems involving the API. The examples below are not exhaustive, and not every category applies to every application scenario; use cases vary in their degree of open-endedness and level of risk. When identifying potential harms, developers should consider the system to be developed in its context of use, including the people who use the system and those affected by it, and investigate sources of representative harms.
Providing false information. The system may provide users with false information concerning safety or health matters, such as incorrectly answering a user’s question about whether they are experiencing a medical emergency and should seek care. The intentional creation and dissemination of misleading information through the API is strictly prohibited.
Discrimination. The system may persuade users to believe things that are harmful to certain groups, for example, by using racist, sexist, or ableist language.
Harm to individuals. The system may produce outputs that could harm individuals, such as encouraging self-destructive behavior, including gambling, substance abuse, or self-harm, or damaging their self-esteem.
Incitement to violence. The system may persuade users to engage in violence against any other person or group.
Physical injury, property damage, or environmental damage. In certain use cases, for example, where a system using the API is connected to physical actuators capable of causing harm, the system is central to safety considerations, and unintended API behavior may cause malfunctions resulting in physical harm.
III. The Importance of Robustness
“Robustness” refers to a system’s ability to operate reliably as intended and expected in a particular environment. Developers using this platform should ensure that their applications have the robustness necessary for safe use and that such robustness is maintained over time.
Robustness is challenging. Language models such as those included in the API are useful for a range of purposes but may fail in unexpected ways due to factors such as limited knowledge of the world. These failures may be visible, such as generating irrelevant or obviously incorrect text, or may have no visible manifestation, such as failing to find relevant results when using API-powered search. The risks associated with using the API vary significantly across use cases, although general categories of robustness failures to consider include generating text that is irrelevant to the context, which can be made less likely by providing more context; generating inaccurate text due to gaps in the API’s current knowledge; and continuing objectionable context.
Context is critically important. Developers should bear in mind that the API’s output depends heavily on the context provided to the model. Providing the model with additional context, such as several high-quality examples of desired behavior before a new input, can make it easier to steer the model’s output in the desired direction.
Human oversight. Even with substantial efforts to improve robustness, some failures may still occur. API customers should therefore encourage end users to carefully review API outputs before taking any action, such as disseminating those outputs.
Continuous testing. Despite strong initial performance, the API may fail to perform as expected, including where the input distribution changes over time. In addition, the large-model open platform may provide improved versions of models over time, and developers should ensure that these versions continue to perform well in their particular environments.
IV. The Importance of Fairness
“Fairness” here refers to ensuring that the API neither performs less well because of users’ demographic characteristics nor produces text that is biased against certain groups. API users should take reasonable steps to identify and reduce foreseeable harms associated with demographic biases in the API.
Fairness in ML systems is extremely challenging. Because the API is trained on human data, our models exhibit various biases, including but not limited to biases relating to gender, race, and religion. For example, the API is trained primarily on Chinese-language text and is best suited to classifying, searching, summarizing, or generating such text. By default, the API performs less well on inputs that differ from the distribution of the data on which it was trained, including languages other than Chinese and specific Chinese dialects that are underrepresented in our training data. The large-model open platform provides information about some of the biases we have identified, although this analysis is not comprehensive; developers should consider fairness issues that may be particularly salient in their use cases, even if those issues are not addressed in our baseline analysis. Please note that context is critically important here: providing the API with insufficient context to guide its generation, or providing context relating to sensitive topics, is more likely to result in offensive outputs.
Identify the characteristics of fairness risks before deployment. Users should consider their customer base and the range of inputs they will submit to the API, and should evaluate the API’s performance across a variety of potential inputs to identify circumstances in which its performance may deteriorate.
**Filtering tools can provide some assistance, but they are not a universal solution. **This platform has enabled an automated filtering tool to flag potentially sensitive outputs and is working with customers to test and improve this tool. The filtering tool is intended to help developers mitigate the risk of offensive outputs, but it is not suitable for every application. Developers should consider whether their use cases require such techniques and, if so, how to modify those techniques to best suit their use cases. It is important to note that these tools are not a panacea for eliminating all potentially offensive outputs—offensive outputs using otherwise “safe” words may still be generated.
