Skip to content

Conversation

farrelmahaztra
Copy link

@farrelmahaztra farrelmahaztra commented Oct 7, 2025

Note

Replace string-based agent identifiers with a new AgentType enum and update CLI, evaluation flow, examples, and tests to use it consistently.

  • Types:
    • Introduce AgentType enum (claude, openai, vllm, litellm, integration_test) in hud/types.py and export it.
  • CLI:
    • hud/cli/__init__.py: Use AgentType for agent selection/validation; update interactive choices to return enum values; normalize and cast to AgentType before invoking eval_command.
    • hud/cli/eval.py: Switch eval_command and helpers to accept AgentType; update API key checks and branching logic to compare against enum values; adjust Typer option types.
  • Evaluation helpers:
    • Update build_agent, run_single_task, and run_full_dataset to accept and branch on AgentType instead of string literals; propagate enum through config building.
  • Examples:
    • examples/run_evaluation.py: Replace Literal["claude","openai"] with Literal[AgentType.CLAUDE, AgentType.OPENAI] and update comparisons accordingly.
  • Tests:
    • Update tests in hud/cli/tests/test_eval.py to import and pass AgentType values instead of strings.

Written by Cursor Bugbot for commit 0dbb920. This will update automatically on new commits. Configure here.

Copy link
Contributor

promptless bot commented Oct 7, 2025

📝 Documentation updates detected!

New suggestion: Add AgentType enum API reference for PR #164
Updated existing suggestion: Add comprehensive LiteLLM agent documentation for PR #137 multi-provider support

Copy link
Contributor

@dylanbowman314 dylanbowman314 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jdchawla29 Do we need to expand AgentType to other parts of the sdk?

raise typer.Exit(1)

# Type narrowing: agent is now guaranteed to be an AgentType value after validation
agent = AgentType(agent)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, do we need this?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally no, but hud_console.select doesn't have a generic return type yet based on the values of the choices so by default agent here is str | Literal[AgentType.VLLM]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants