Get your API Key

You can create your own API key by signing up on our console.

Logging your Open AI requests

We strongly suggest setting up logs to collect high quality data from your GPT4 requests.

Let us start with installing gigaml PyPi package.

python
  pip install gigaml

Here is how you can start using the finetuned models

python
  import openai, os
  from dotenv import load_dotenv
  # IMPORTING GIGA ML LIBRARY 
  from gigaml import OpenAI, GigaMlApi 

  load_dotenv('.env')

  client = OpenAI(
      api_key = os.environ.get('OPENAI_API_KEY'),

      #Initialise gigaml Client through API_KEY which can be generated via our console
      gigaml_client = GigaMlApi(token = os.environ.get("GIGAML_KEY")),
  )

  response = client.chat.completions.create(
      model = "gpt-3.5-turbo",
      messages = [{"role":"user", "content": "Who are you"}],
      tags = ["testing"],
      stream = True,
  )

  for chunk in response:
      print(chunk)

Once this process is done you can automatically log the requests and you see them on your dashboard

Creating/Uploading a Dataset

Start Finetuning Job

Note : The data set needs to be processed before you start the finetuning job.Once the data set is processed navigate to finetuning and start a job

Using finetuned models

You start using your finetuned models by changing the API end point

Make sure that you installed gigaml sdk

python
    pip install gigaml

Here is how you can start using the finetuned model

python
  import openai, os
  from dotenv import load_dotenv
  # IMPORTING GIGA ML LIBRARY 
  from gigaml import OpenAI, GigaMlApi 

  load_dotenv('.env')

  client = OpenAI(
      api_key = os.environ.get('OPENAI_API_KEY'),

      #Initialise gigaml Client through API_KEY which can be generated via our console
      gigaml_client = GigaMlApi(token = os.environ.get("GIGAML_KEY")),
  )

  response = client.chat.completions.create(
      model = MODEL_NAME_FROMCONSOLE,
      messages = [{"role":"user", "content": "Who are you"}],
      tags = ["prod"],
      stream = True,
  )

  for chunk in response:
      print(chunk)