Class LlmConfigTestComponent

java.lang.Object
ai.mindconnect.adminui.ui.component.LlmConfigTestComponent
All Implemented Interfaces:
UiComponent

public final class LlmConfigTestComponent extends Object implements UiComponent
Body of the "Test LLM config" modal dialog.

Renders in one of three shapes:

  1. Empty / initial — a textarea + Send button + Close button.
  2. After a successful test — the response text, token counts, finish reason, duration. The form stays mounted so the admin can re-send a tweaked message.
  3. After a failed test — the error message highlighted in red. The form stays mounted; "Send" tries again.

The form posts back to POST /admin/api/llm-configs/{id}/test; the controller re-renders the same dialog with the supplied LlmConfigTestService.Result. The dialog overlay survives across the round-trip because the controller re-opens it via page.dialog(...) with the same close-href.

  • Constructor Details

  • Method Details

    • id

      public String id()
      Description copied from interface: UiComponent
      The DOM id this component renders with. Patch operations targeting this component (REPLACE / CLEAR / REMOVE) use this id, so it must match the id on the root UiNode returned by UiComponent.render().
      Specified by:
      id in interface UiComponent
    • title

      public String title()
    • render

      public ai.mindconnect.ui.model.UiNode render()
      Description copied from interface: UiComponent
      Full render — emit the component as a UiNode. Used both inside a page's full render and as the payload of a REPLACE patch.
      Specified by:
      render in interface UiComponent