import streamlit as st from transformers import pipeline from ldclient import LDClient, Config, Context import os import torch # Retrieve the LaunchDarkly SDK key from environment variables ld_sdk_key = os.getenv("LAUNCHDARKLY_SDK_KEY") # Initialize LaunchDarkly client with the correct configuration ld_client = LDClient(Config(ld_sdk_key)) # Set the user context for LaunchDarkly user = { "key": "test-user", "custom": { "groups": "beta_testers" } } context = Context(user)