Class: Rubyrag
- Inherits:
-
Object
- Object
- Rubyrag
- Defined in:
- lib/rubyrag.rb,
lib/rubyrag/cloudflare_auto_rag.rb
Defined Under Namespace
Instance Attribute Summary collapse
-
#rag ⇒ Object
readonly
Returns the value of attribute rag.
Instance Method Summary collapse
- #add(**options) ⇒ Object
-
#initialize(provider:, **options) ⇒ Rubyrag
constructor
A new instance of Rubyrag.
- #query(**options) ⇒ Object
Constructor Details
#initialize(provider:, **options) ⇒ Rubyrag
10 11 12 13 14 15 16 17 |
# File 'lib/rubyrag.rb', line 10 def initialize(provider:, **) @rag = case provider when :cloudflare_auto_rag Rubyrag::Rags::CloudflareAutoRag.new() else raise Error("Invalid provider: #{provider}") end end |
Instance Attribute Details
#rag ⇒ Object (readonly)
Returns the value of attribute rag.
6 7 8 |
# File 'lib/rubyrag.rb', line 6 def rag @rag end |
Instance Method Details
#add(**options) ⇒ Object
19 20 21 |
# File 'lib/rubyrag.rb', line 19 def add(**) rag.add(**) end |
#query(**options) ⇒ Object
23 24 25 |
# File 'lib/rubyrag.rb', line 23 def query(**) rag.query(**) end |