Interface CodingPrompter

All Superinterfaces:
Manager
All Known Implementing Classes:
DisabledCodingPrompter, GeminiPrompter, OpenAIPrompter, OpenRouterPrompter

public interface CodingPrompter extends Manager

CodingPrompter

This interface represents a coding prompter, that will generate a code by players prompts.
  • Method Summary

    Modifier and Type
    Method
    Description
    generateCode(@NotNull String nickname, @NotNull UUID uuid, @NotNull String prompt, int actionsLimit)
    Generates a code by player's prompt.
    void
    setToken(@NotNull String token)
    Sets the token for coding prompter.

    Methods inherited from interface Manager

    getName, init, isEnabled
    Modifier and Type
    Method
    Description
    Returns name of manager, that will be displayed by request in the logs.
    void
    Initialization of manager.
    boolean
    Checks if manager is ready to work.
  • Method Details

    • generateCode

      @NotNull @NotNull CompletableFuture<String> generateCode(@NotNull @NotNull String nickname, @NotNull @NotNull UUID uuid, @NotNull @NotNull String prompt, int actionsLimit)
      Generates a code by player's prompt. Returns
      Parameters:
      nickname - name of player.
      uuid - uuid of player.
      prompt - prompt to generate code.
      actionsLimit - limit of actions per executor.
      Returns:
      code script YAML, or reason why code refused to generate.
    • setToken

      void setToken(@NotNull @NotNull String token)
      Sets the token for coding prompter.
      Parameters:
      token - new token.