TestLlm.Bypass (test_llm v0.1.0)

View Source

Stubing LLM responses with Bypass

Summary

Functions

base_url(bypass)

expect_response(key)

Stubs the expected response.

Options

Basic request options:

  • :key - stub reponse file name transformed to slug.
  • :original_base_url - The base url for the call to the LLM.
  • :bypass - The bypass connection.
  • :rerun - should the request be rerun and saved, defaults to :false.
  • :model - should the request be rerun and saved, defaults to the name of the model from the request if available.

expect_stream_response(key)

Stubs the expected stream response.

Options

Basic request options:

  • :key - stub reponse file name transformed to slug.
  • :original_base_url - The base url for the call to the LLM.
  • :bypass - The bypass connection.
  • :rerun - should the request be rerun and saved, defaults to :false.
  • :model - should the request be rerun and saved, defaults to the name of the model from the request if available.

get_stream_response_chunks(model, key)

open()

send_resp(conn, resp)