Class: Langfuse::CLI::Types::MetricsQuery
- Inherits:
-
T::Struct
- Object
- T::Struct
- Langfuse::CLI::Types::MetricsQuery
- Defined in:
- lib/langfuse/cli/types.rb
Overview
Struct for metrics query parameters
Instance Method Summary collapse
Instance Method Details
#to_h ⇒ Object
84 85 86 87 88 89 90 91 92 93 94 |
# File 'lib/langfuse/cli/types.rb', line 84 def to_h { 'view' => view, 'metrics' => [{ 'measure' => measure, 'aggregation' => aggregation }], 'dimensions' => dimensions&.map { |d| { 'field' => d } }, 'fromTimestamp' => , 'toTimestamp' => , 'timeDimension' => granularity ? { 'granularity' => granularity } : nil, 'limit' => limit }.compact end |