set_organization_env Subroutine

private impure elemental subroutine set_organization_env(this, status)

Type Bound

openai

Arguments

Type IntentOptional Attributes Name
class(openai), intent(inout) :: this
integer, intent(out), optional :: status

Calls

proc~~set_organization_env~~CallsGraph proc~set_organization_env foropenai_base::openai%set_organization_env proc~set_organization foropenai_base::openai%set_organization proc~set_organization_env->proc~set_organization

Called by

proc~~set_organization_env~~CalledByGraph proc~set_organization_env foropenai_base::openai%set_organization_env proc~set_base_data foropenai_base::openai%set_base_data proc~set_base_data->proc~set_organization_env proc~conversation foropenai_ChatCompletion::ChatCompletion%conversation proc~conversation->proc~set_base_data program~test_base test_base program~test_base->proc~set_base_data program~test_chatcompletion test_ChatCompletion program~test_chatcompletion->proc~set_base_data program~test_imagegeneration test_ImageGeneration program~test_imagegeneration->proc~set_base_data program~test_transcription test_Transcription program~test_transcription->proc~set_base_data program~test_translation test_Translation program~test_translation->proc~set_base_data

Source Code

   elemental impure subroutine set_organization_env(this, status)
      class(openai), intent(inout)         :: this
      integer,       intent(out), optional :: status
      character(len=1024)                  :: tmp
      call get_environment_variable(this%organization_env, tmp, status = status)
      if (status==0) call this%set_organization(trim(tmp))
   end subroutine set_organization_env