Connect a model

Root Signals subscription provides a set of models you can use in any of your skills. You are not limited by that selection, though. Integrating with cloud providers' models or connecting to locally hosted models is possible through the SDK or through the REST API.

Huggingface example

To use an HF inference endpoint, add the model endpoint via the SDK or through the REST API

curl --request POST \
     --url https://api.app.rootsignals.ai/v1/models/ \
     --header 'Authorization: Api-Key $ROOT_SIGNALS_API_KEY' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '
               {
                 "name": "huggingface/meta-llama/Meta-Llama-3-8B",
                 "url": "https://my-endpoint.huggingface.cloud",
                 "default_key": "$HF_KEY"
               }
            '

After adding the model, you can use it like any other model in your skills and evaluators.

skill = client.skills.create(
    name="My model test", prompt="Hello, my model!", model="huggingface/meta-llama/Meta-Llama-3-8B"
)

Last updated