> ## Documentation Index
> Fetch the complete documentation index at: https://docs.galileo.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# createDecisionMetric

***

# Function: createDecisionMetric()

```ts theme={null}
function createDecisionMetric(
  params: CreateDecisionMetricParams,
): Promise<BaseScorerVersionResponse>;
```

Defined in: [src/utils/metrics.ts](https://github.com/rungalileo/galileo-js/blob/main/src/utils/metrics.ts)

Creates a decision metric. See Metrics.createDecisionMetric.

## Parameters

### params

[`CreateDecisionMetricParams`](/sdk-api/typescript/reference/types/interfaces/CreateDecisionMetricParams)

The parameters for creating the decision metric.

## Returns

`Promise`\<[`BaseScorerVersionResponse`](/sdk-api/typescript/reference/types/type-aliases/BaseScorerVersionResponse)>

A promise that resolves to the created scorer version.

## Example

```typescript theme={null}
import { createDecisionMetric, OutputType } from "galileo";

await createDecisionMetric({
  name: "refund_intent",
  question: "What does the customer want?",
  outputType: OutputType.CATEGORICAL,
  answerOptions: ["refund", "exchange", "other"],
});
```
