2. Create A Secret Key (Add to Package)

To fully utilize OpenSesame and start detecting AI hallucinations within your models, you’ll need to generate a secret key.

Step 1: Generate Your Secret Key

Once you have created your project, the next step is to generate a secret key. This key is essential for authenticating your requests and securing access to OpenSesame’s features.

  • Why Do You Need a Secret Key?
    • The secret key acts as an authentication mechanism that allows your application to interact with the OpenSesame API.
    • It ensures that your API requests are secure and helps OpenSesame identify which project the requests are associated with.

Step 2: Add the Secret Key to Your Codebase

After generating your secret key, you’ll need to add it to your codebase. This step is straightforward and involves a simple line of code.

  • How to Add the Secret Key:
    • Insert the secret key into the configuration settings of the package.
# Example of adding the secret key in a Python application
OPENSESAME_SECRET_KEY = 'your-secret-key-here'