Skip to content

cuttie1979/sambanova_factory

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sambanova cloud rate-limited factory

Global Rate limiter implementation over a SambaNova Cloud OpenAI like Chat interface

Below you find a code example how you can use the ratelimited calls simply.

# Example code
import os
from sambanova_factory.LLMHelper import LLMHelper

sambanova_api_key = os.environ['SAMBANOVA_API_KEY']

LLMHelper(sambanova_api_key=sambanova_api_key)

call_result = LLMHelper.call_llama31_70b(
    system_prompt="""You are a helpful assistant!""",
    user_prompt="My name is {name}",
    variables={
        "name": "Mr. Smith"
    }
)

print(call_result)

About

Global Rate limiter implementation over a SambaNova Cloud OpenAI like Chat interface

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages