OAG takes RAG to the next level
We are covering Ontology Augmented Generation (OAG), which is a more expansive, decision-centric version of Retrieval Augmented Generation (RAG). At a high level, RAG enables generative AI to retrieve data from outside sources. This allows LLMs to leverage context-specific external information — e.g., data on a business’ orders, customers, locations, etc. — to generate responses, reducing the risk of hallucinations. With RAG, LLMs can also cite the sources used to generate a particular response, building trust and providing a clear audit trail.
OAG takes RAG to the next level, allowing LLMs to leverage deterministic logic tools (e.g., forecasts and optimizers) and actions to close the loop with source systems via the Palantir Ontology. Each enterprise’s ontology encompasses the data, logic, and actions that drive operational decision-making in that specific context. Grounding LLMs in the Ontology effectively anchors them in the reality of a given business, not only driving more accurate, powerful applications, but also building even greater trust: LLMs can effectively “show their work” and surface specific sources from the enterprise’s own operational reality.
The Application
We start by showing the finished application we’ve built. In this scenario we have a fictional company — Titan Industries — that specializes in medical supplies confronting a fire at one of its distribution centers. The fire presents the risk of shortages for Titan’s customers, which we want to prevent. With AIP, we can build an application — previewed below — that enables us to quickly assess the impact of the fire, identify the affected orders, and surface actionable solutions (e.g., redistributing inventory to fulfill customer orders).
This application shows the Chain of Thought (CoT) reasoning steps that the LLM is taking, and which objects its accessing in the Ontology — providing transparency into how it arrived at its conclusion.
By utilizing metadata for pipeline creation and connecting to complex systems like SAP, HyperAuto streamlines data operations, allowing analysts to concentrate on strategic goals. HyperAuto allows you to go from source to Ontology in a matter of minutes.
The Ontology in turn integrates real-time data from all relevant sources into a semantic model of the business. This enables us to anchor AI in the operational truth of the enterprise, mitigating the risk of model hallucinations and creating the trust needed for decision-making.
Data as Code
Palantir’s “data as code” philosophy infuses data management with the principles of software development, providing users with control, flexibility, and reproducibility.
In essence, AIP treats data with the same care and dynamic interactions as code, allowing for iterative improvements and meticulous change management in a multi-user environment. Key to this system is the ability to branch — an idea that originates in version control systems — which allows multiple users to work on data simultaneously, fostering innovation without sacrificing data integrity.
In addition, users can easily surface the temporal evolution of datasets, facilitating debugging and problem-solving. This means users can move quickly and with confidence in the quality of their data.
AIP Logic: Giving LLMs data tools
Now that we have automatically created our data pipelines, defined our ontology, ensured that our data is clean, and set up our security controls, we’re ready to create our application.
We’ll do so using AIP Logic. AIP Logic revolutionizes the creation of AI-powered functions, offering a no-code environment that simplifies the integration of advanced LLMs with the Ontology. It is designed to streamline the development process, allowing builders to easily construct, test, and deploy AI-powered functions without delving into complex programming or tool configurations.
We show how AIP Logic allows us to equip the LLM with an Ontology-driven data tool — in this case, to help address the simulated supply chain issue at Titan Industries. The tools paradigm extends beyond data, to logic and action (as we’ll see in future videos), providing us the ability to safely “teach” the LLM new abilities — just like we would a new hire.
We start by inputting our prompts.
Because we have given the LLM access to certain objects in our ontology, we are able to include them in our prompts. This means that the LLM also has access to these objects’ links, actions, and other relationships — for example, a customer order object would include the customer name, the material ID, the distribution center, etc., and all the relationships between them. The LLM is therefore able to take these relationships into account when generating its response.
AIP Logic’s user-friendly interface allows us to easily craft prompts, debug prompts and tool usage, and monitor outcomes. The different logic blocks that we have built prompt the LLM to search affected orders, identify distribution centers with adequate supply of the necessary materials, and return to me a list of affected orders and suggested remediations.
Within a few minutes, we’re able to deploy an application that is ready to be activated in the event of a distribution center setback and identify actionable solutions to issues that arise (in this example, telling me how to resolve shortages caused by a fire at a distribution center). This application, based on the principles of Ontology Augmented Generation (OAG), demonstrates the power of AIP to ground AI in an enterprise’s data, logic, and actions to support real-time operational decision-making.
If you’re ready to unlock the power of full spectrum AI with ConstructOps Tools, sign up for an BuilderChain Discovery Bootcamp today. Your team will learn from construction industry experts, and more importantly, get hands-on experience with ConstructOps Tools and walk away having assembled real workflows in a project operations environment.