Aller directement au contenu principal

openhands.llm.metrics

ResponseLatency Objects

class ResponseLatency(BaseModel)

Metric tracking the round-trip time per completion call.

Metrics Objects

class Metrics()

Metrics class can record various metrics during running and evaluation. Currently, we define the following metrics: accumulated_cost: the total cost (USD $) of the current LLM. response_latency: the time taken for each LLM completion call.

get

def get() -> dict

Return the metrics in a dictionary.

log

def log()

Log the metrics.