Class PickAndPlace2024LLMServiceProvider


public class PickAndPlace2024LLMServiceProvider extends TRLLMServiceProvider
  • Constructor Details

    • PickAndPlace2024LLMServiceProvider

      public PickAndPlace2024LLMServiceProvider()
  • Method Details

    • init

      protected void init()
      Description copied from class: DiarcComponent
      Perform any component initialization. This should not be used for setting local fields to default values as was the case in DIARC. This method is called after the constructor, and after parseArgs. Setting default values should be done in field declaration or in the constructor.
      Overrides:
      init in class TRLLMServiceProvider
    • additionalUsageInfo

      protected List<org.apache.commons.cli.Option> additionalUsageInfo()
      Description copied from class: DiarcComponent
      Override this method to define command line options available in sub-class. This should be paired with a parseArgs implementation.
      Overrides:
      additionalUsageInfo in class DiarcComponent
      Returns:
    • parseArgs

      protected void parseArgs(org.apache.commons.cli.CommandLine cmdLine)
      Description copied from class: DiarcComponent
      Override this method to parse command line args in the sub-class. Called directly after construction to pass runtime values that will override default values. This should parse all the options that additionalUsageInfo provides.
      Overrides:
      parseArgs in class DiarcComponent
    • getRefTypes

      protected List<String> getRefTypes()
      Specified by:
      getRefTypes in class TRLLMServiceProvider
    • getNluSystemPrompt

      protected Prompt getNluSystemPrompt()
      Specified by:
      getNluSystemPrompt in class TRLLMServiceProvider
    • getNluUserPrompt

      protected Prompt getNluUserPrompt()
      Specified by:
      getNluUserPrompt in class TRLLMServiceProvider
    • getNlgSystemPrompt

      protected Prompt getNlgSystemPrompt()
      Specified by:
      getNlgSystemPrompt in class TRLLMServiceProvider
    • getNlgUserPrompt

      protected Prompt getNlgUserPrompt()
      Specified by:
      getNlgUserPrompt in class TRLLMServiceProvider
    • getValidationSystemPrompt

      protected Prompt getValidationSystemPrompt()
      Specified by:
      getValidationSystemPrompt in class TRLLMServiceProvider
    • getValidationUserPrompt

      protected Prompt getValidationUserPrompt()
      Specified by:
      getValidationUserPrompt in class TRLLMServiceProvider
    • populatePromptVars

      protected Map<String,String> populatePromptVars(Utterance utterance, Map<String,String> promptVars, boolean system, boolean parsing, boolean validation)
      Description copied from class: TRLLMServiceProvider
      Return prompt variables relevant for the associated Prompt to be included in an upcoming request. Refer to the Prompt class and apply method if this notion is unfamiliar to you. These details may be generated on each request, or constantly updated in the background and provided to requests from this method. Please explicitly incorporate, overwrite, or discard information supplied in the passed in promptVars.
      Specified by:
      populatePromptVars in class TRLLMServiceProvider
      Parameters:
      utterance - - The input/output utterance associated with this request
      promptVars - - Default prompt variables containing common system information gathered in LLMServiceProvider
      system - - Whether these variables are being applied to the system message or user message
      parsing - - Whether this call is part of an NLU or NLG request
      validation - - (NLG Only) whether this call is associated with a system validation question
      Returns:
      The variables to apply to the associated prompt in an upcoming request
    • correctCommonNLUMistakes

      protected Utterance correctCommonNLUMistakes(Utterance utterance)
      Description copied from class: TRLLMServiceProvider
      Domain specific postprocessing on NLU completions. Simply return supplied utterance if you have no domain specific postprocessing.
      Specified by:
      correctCommonNLUMistakes in class TRLLMServiceProvider
    • getDescriptorType

      protected String getDescriptorType(String agentName, String descriptor)
      Description copied from class: TRLLMServiceProvider
      Used during NLU postprocessing - Check if the supplied descriptor matches any known references in the system. Return the associated reference's type (the descriptor will be typed replaced with a variable to later be dereferenced) Return an empty string if no match is found or you do not desire this functionality.
      Specified by:
      getDescriptorType in class TRLLMServiceProvider
    • getJapaneseVersionOfDescriptor

      public String getJapaneseVersionOfDescriptor(Symbol descriptor)
    • getJapaneseVersionOfDescriptor

      public String getJapaneseVersionOfDescriptor(String descriptorString)
    • handleDatabaseAddition

      public void handleDatabaseAddition(ActionDBEntry entry) throws ai.thinkingrobots.trade.TRADEException
      Overrides:
      handleDatabaseAddition in class TRLLMServiceProvider
      Throws:
      ai.thinkingrobots.trade.TRADEException