Method TryBeginSample
- Namespace
- IntentSharp.Trials
- Assembly
- IntentSharp.dll
TryBeginSample(DocumentId, out IntentTrial?)
For a runner: counts one call of an intent defined in document, and returns true, with the trial,
when that call is one the trial samples (every SampleEveryth since the trial started).
Run the candidate on such a call, then pass the trial and the outcome to Record(IntentTrial, TrialSample). Returns false, and
counts nothing, when no trial of the document is running.
public bool TryBeginSample(DocumentId document, out IntentTrial? trial)
Parameters
documentDocumentIdThe intent document the call's definition was loaded from.
trialIntentTrialThe running trial when the call is sampled; otherwise null.
Returns
- bool