Module: Legion::Extensions::Llamacpp::Runners::Slots
- Extended by:
- Helpers::Client
- Includes:
- Helpers::Lex
- Included in:
- Client
- Defined in:
- lib/legion/extensions/llamacpp/runners/slots.rb
Constant Summary
Helpers::Client::DEFAULT_HOST
Instance Method Summary
collapse
client, streaming_client
Instance Method Details
#erase_slot(id:) ⇒ Object
18
19
20
21
|
# File 'lib/legion/extensions/llamacpp/runners/slots.rb', line 18
def erase_slot(id:, **)
response = Helpers::Errors.with_retry { client(**).post("/slots/#{id}?action=erase") }
{ result: response.body, status: response.status }
end
|
#list_slots ⇒ Object
13
14
15
16
|
# File 'lib/legion/extensions/llamacpp/runners/slots.rb', line 13
def list_slots(**)
response = Helpers::Errors.with_retry { client(**).get('/slots') }
{ result: response.body, status: response.status }
end
|