Toggle Menu
Prev Up Next

# `langchain_experimental.rl_chain.pick_best_chain`.PickBestRandomPolicy

class langchain_experimental.rl_chain.pick_best_chain.PickBestRandomPolicy(feature_embedder: Embedder, **kwargs: Any)

  Random policy for PickBest chain.

  Methods

  `__init__`(feature_embedder, **kwargs) |
  `learn`(event) |
  `log`(event) |
  `predict`(event) |
  `save`() |

  Parameters

    - feature_embedder (base.Embedder) –

    - kwargs (Any) –

  __init__(feature_embedder: Embedder, **kwargs: Any)
    Parameters

      - feature_embedder (Embedder) –

      - kwargs (Any) –

  learn(event: PickBestEvent) → None
    Parameters

      event (PickBestEvent) –

    Return type

      None

  log(event: PickBestEvent) → None
    Parameters

      event (PickBestEvent) –

    Return type

      None

  predict(event: PickBestEvent) → List[Tuple[int, float]]
    Parameters

      event (PickBestEvent) –

    Return type

      List[Tuple[int, float]]

  save() → None
    Return type

      None