About NeMo-Guardrails
NeMo Guardrails is an open-source toolkit developed by NVIDIA, designed to facilitate the addition of programmable guardrails to LLM (Large Language Model)-based conversational systems. These guardrails, also referred to as “rails”, are mechanisms to control the output of a large language model. They can be used to prevent the model from discussing certain topics, to make it respond in a specific manner to particular user requests, to follow a predefined dialogue path, to adopt a specific language style, to extract structured data, and more. The toolkit is in its early alpha stages, and NVIDIA encourages the community to contribute to its development.
Features of NeMo Guardrails
- Building Trustworthy, Safe, and Secure LLM Conversational Systems: NeMo Guardrails allows developers to define the behavior of their LLM-powered applications on specific topics. This ensures that the application does not engage in discussions on unwanted topics, thereby building a more trustworthy and safe conversational system.
- Connectivity with Other Services: NeMo Guardrails provides the ability to seamlessly and securely connect an LLM to other services, also referred to as tools. This feature enhances the versatility of the LLM, allowing it to interact with a variety of external services.
- Guardrails Configuration with Colang: The toolkit introduces Colang, a modeling language specifically designed for creating flexible yet controllable dialogue flows. Colang, with its python-like syntax, is designed to be intuitive for developers. It allows for the configuration of guardrails by placing one or more .co files in a configuration folder.
- Community Contribution: NVIDIA has provided example rails in the repository as a starting point and invites the community to contribute to the development of NeMo Guardrails. This collaborative approach aims to make LLMs more trustworthy, safe, and secure for everyone.
Additional Features
- Alpha Release Disclaimer: The current release of NeMo Guardrails is an alpha version (0.4.0). It is undergoing active development and may be subject to changes and improvements. NVIDIA advises against deploying this alpha version in a production setting due to potential instability and unexpected behavior.
- Installation and Usage: NeMo Guardrails can be easily installed using pip. Once installed, developers can create an LLMRails instance, configure the desired rails, and then use it to interact with the LLM. The toolkit also provides support for asynchronous code bases and Jupyter notebooks.
- License: NeMo Guardrails is licensed under the Apache License, Version 2.0, ensuring its open-source nature and accessibility to developers worldwide.