Class: LlmCostTracker::PriceSync::RefreshPlan

Inherits:
Data
  • Object
show all
Defined in:
lib/llm_cost_tracker/price_sync.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#acceptedObject (readonly)

Returns the value of attribute accepted

Returns:

  • (Object)

    the current value of accepted



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def accepted
  @accepted
end

#changesObject (readonly)

Returns the value of attribute changes

Returns:

  • (Object)

    the current value of changes



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def changes
  @changes
end

#discrepanciesObject (readonly)

Returns the value of attribute discrepancies

Returns:

  • (Object)

    the current value of discrepancies



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def discrepancies
  @discrepancies
end

#failed_sourcesObject (readonly)

Returns the value of attribute failed_sources

Returns:

  • (Object)

    the current value of failed_sources



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def failed_sources
  @failed_sources
end

#flaggedObject (readonly)

Returns the value of attribute flagged

Returns:

  • (Object)

    the current value of flagged



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def flagged
  @flagged
end

#orphaned_modelsObject (readonly)

Returns the value of attribute orphaned_models

Returns:

  • (Object)

    the current value of orphaned_models



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def orphaned_models
  @orphaned_models
end

#pathObject (readonly)

Returns the value of attribute path

Returns:

  • (Object)

    the current value of path



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def path
  @path
end

#registryObject (readonly)

Returns the value of attribute registry

Returns:

  • (Object)

    the current value of registry



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def registry
  @registry
end

#rejectedObject (readonly)

Returns the value of attribute rejected

Returns:

  • (Object)

    the current value of rejected



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def rejected
  @rejected
end

#source_resultsObject (readonly)

Returns the value of attribute source_results

Returns:

  • (Object)

    the current value of source_results



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def source_results
  @source_results
end

#sources_usedObject (readonly)

Returns the value of attribute sources_used

Returns:

  • (Object)

    the current value of sources_used



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def sources_used
  @sources_used
end

#updated_registryObject (readonly)

Returns the value of attribute updated_registry

Returns:

  • (Object)

    the current value of updated_registry



46
47
48
# File 'lib/llm_cost_tracker/price_sync.rb', line 46

def updated_registry
  @updated_registry
end

Instance Method Details

#refresh_succeeded?Boolean

Returns:

  • (Boolean)


60
61
62
# File 'lib/llm_cost_tracker/price_sync.rb', line 60

def refresh_succeeded?
  source_results.any? { |_source, result| result.prices.any? }
end

#up_to_date?Boolean

Returns:

  • (Boolean)


64
65
66
# File 'lib/llm_cost_tracker/price_sync.rb', line 64

def up_to_date?
  changes.empty? && failed_sources.empty? && rejected.empty?
end