Libraries

On this page, we will take a look at Halluminate's python and node libraries.

Python Library

You can install Halluminate's python library with the following code:

Python Installation

pip install halluminate

Once this is installed, you can use the library and your API key to run the following code:

Example Usage

from halluminate import Halluminate

hm = Halluminate(api_token="<your_token_here>")

response = hm.evaluate_basic(
    criteria_uuid="<your_criteria_uuid_here>",
    model_output="To remove rust from an old set of weights, scrub them with a mixture of vinegar and baking soda."
)

JavaScript Library

You can install Halluminate's javascript library with the following code:

JavaScript Installation

npm install halluminate

Once this is installed, you can use the library and your API key to run the following code:

Example Usage

const Halluminate = require('halluminate');

const halluminate = new Halluminate('<your_token_here>');

const criteriaUuid = '<your_criteria_uuid_here>';
const modelOutput = "To remove rust from an old set of weights, scrub them with a mixture of vinegar and baking soda.";

halluminate.evaluateBasic(criteriaUuid, modelOutput)
  .then(result => {
    console.log('Evaluation result:', result);
  })
  .catch(error => {
    console.error('Error:', error);
  });

Was this page helpful?