Skip to content

Function: bandFor() ​

ts
function bandFor(bands, score): 
  | {
  max: number;
  min: number;
  outcome: "approve" | "reject" | "manual_review";
}
  | undefined;

The band a score falls into: [min, max), with the last band including its max.

Parameters ​

bands ​

object[]

score ​

number

Returns ​

| { max: number; min: number; outcome: "approve" | "reject" | "manual_review"; } | undefined

Released under the Apache-2.0 License.