Module: mellea.backends.aloras.openai.granite_aloras

OpenAI implementations for IBM’s “starter pack” of Activated LoRAs.

Functions

mellea.backends.aloras.openai.granite_aloras.add_granite_aloras(backend: OpenAIBackend)

Adds the IBM Granite “starter pack” ALoras to a backend.

Classes

class mellea.backends.aloras.openai.granite_aloras.OpenAIConstraintAlora(name: str, path: str, generation_prompt: str, backend: OpenAIBackend)

The Requirement Checking ALora for Granite 3.2 8B checks if the specified requirement was satisfied by the most recent model generation. Only one requirement is checked at a time.

Constructor

Initialize after checking that the backend is correct.

Methods

mellea.backends.aloras.openai.granite_aloras.OpenAIConstraintAlora.generate_using_strings(input: str, response: str, constraint: str, force_yn: bool = True)
Generates a constraint response from the ALora.