Back to Blog
AI & Technology

Building Better AI: Introducing Granite Libraries and Project Granite Switch for Modular Development

Building Better AI: Introducing Granite Libraries and Project Granite Switch for Modular Development The landscape of artificial intelligence is evolving rapidly, transitioning from systems that strug...

Building Better AI: Introducing Granite Libraries and Project Granite Switch for Modular Development
SG
Saksham Gupta
Founder & CEO
July 13, 2026
4 min read

Building Better AI: Introducing Granite Libraries and Project Granite Switch for Modular Development

The landscape of artificial intelligence is evolving rapidly, transitioning from systems that struggle to produce coherent outputs to sophisticated models capable of executing complex tasks and driving enterprise workflows. However, the fundamental approach to building and interacting with AI remains distinct from traditional software development. To bridge this gap, IBM has introduced Granite Libraries and Project Granite Switch, two innovative tools designed to enhance modularity and rigor in AI development.

The Need for Modularity in AI

Historically, AI models, particularly large language models (LLMs), have been monolithic entities. Modifying their behavior often required retraining the entire model or crafting intricate prompts, which can be time-consuming and inefficient. This lack of modularity hampers collaboration among teams that wish to enhance specific functionalities without disrupting the entire model.

In contrast, traditional software development relies on modular components that can be independently developed, tested, and deployed. This approach allows multiple teams to work concurrently, each focusing on their area of expertise. By applying similar principles to AI, developers can create more precise and efficient models, thereby meeting enterprise needs more effectively.

Introducing Granite Libraries

Granite Libraries are a pioneering step towards enabling customization in AI models akin to software dependencies. The libraries consist of adapter functions that empower models to perform specialized tasks without necessitating full retraining. Each adapter function acts like a small model, trained to handle specific outputs, which can include scoring documents for relevance, rewriting queries, or even assessing safety.

IBM has released three key libraries tailored for common enterprise applications:

  1. RAG Library: This library focuses on retrieval-augmented generation tasks, such as query rewriting and hallucination detection. It equips models with the ability to assess the relevance of generated responses.

  2. Core Library: This library supplies foundational capabilities, including requirement checks and certainty scoring, which are essential for ensuring the quality of AI outputs.

  3. Guardian Library: This library allows models to perform in-line safety and factuality checks, eliminating the need for separate safety models and enhancing the reliability of outputs.

These libraries are designed to be modular, meaning enterprises can incrementally adopt and integrate them into their existing systems. This flexibility mirrors modern software practices, allowing organizations to enhance their AI systems progressively as new needs arise.

The Role of Project Granite Switch

To complement Granite Libraries, IBM has also unveiled Project Granite Switch. This toolkit allows developers to manage and integrate the specialized components from the Granite Libraries into existing model architectures seamlessly. By leveraging this toolkit alongside the recently released Granite 4.1 models, developers can transform unpredictable text generation into deterministic programming functions.

The beauty of Project Granite Switch lies in its ability to manage the dynamic interactions between different adapter functions. By allowing these components to communicate effectively, it enhances the overall robustness of AI applications. This modularity ensures that when a specific function needs improvement or modification, it can be done without impacting the entire model framework.

Mellea: The Interface Between Functions

The introduction of Mellea serves as a critical interface that enables the adapter functions to behave like conventional software components. Mellea automates the tagging and formatting requirements for activating specific adapters, ensuring that developers can focus on higher-level functionalities without getting bogged down in the intricacies of AI text generation.

This capability is particularly valuable when integrating adapter functions into existing applications. By enforcing strict formatting rules in real time, Mellea shields developers from the unpredictable nature of raw AI outputs, making it easier to implement AI within enterprise settings.

Enhancing Performance with Granite Libraries

The impact of Granite Libraries on model performance is significant. For instance, when a Granite 4.1 model is equipped with a requirement-check adapter function, its accuracy can leap from 51% to 84% on benchmarks designed for instruction-following tasks. This substantial improvement underscores the effectiveness of modular components in enhancing the capabilities of AI models.

Each adapter function is meticulously trained to excel at a specific task, making it possible for developers to combine these functions in ways that optimize performance and reliability. This modular approach not only streamlines the development process but also empowers enterprises to leverage AI's full potential, providing tailored solutions that can adapt to evolving needs.

Conclusion

As artificial intelligence continues to advance, the need for a structured approach to AI development becomes increasingly evident. With Granite Libraries and Project Granite Switch, IBM is pioneering a new era of modularity and rigor in AI, drawing on principles from software engineering to enhance the capabilities of LLMs. These innovations not only facilitate collaboration among development teams but also enable enterprises to build more accurate and efficient AI systems tailored to their unique requirements. By embracing this modular approach, organizations can position themselves at the forefront of the AI revolution, unlocking new possibilities for innovation and growth.

Share this article
SG

Saksham Gupta

Founder & CEO

Saksham Gupta is the Co-Founder and Technology lead at Edubild. With extensive experience in enterprise AI, LLM systems, and B2B integration, he writes about the practical side of building AI products that work in production. Connect with him on LinkedIn for more insights on AI engineering and enterprise technology.