# Function buildLlamaGuard38BFilter

- buildLlamaGuard38BFilter<T extends ConfigType>(
  type: T,
  categories: [keyof LlamaGuard38B, ...(keyof LlamaGuard38B)[]],
  ): LlamaGuard38BFilterReturnType<T>

  Convenience function to build Llama Guard 3 8B filter.

  #### Type Parameters

  - T extends ConfigType

  #### Parameters

  - type: T

    Type of the filter, either `input` or `output`.

  - categories: [keyof LlamaGuard38B, ...(keyof LlamaGuard38B)[]]

    Categories to be enabled for filtering. Provide at least one category.

  #### Returns LlamaGuard38BFilterReturnType<T>

  Llama Guard 3 8B filter configuration.

  #### Example

      buildLlamaGuard38BFilter('input', ['elections', 'hate'])

  Copyright Ⓒ 2026 SAP SE or an SAP affiliate company. All rights reserved.

  - Defined in packages/orchestration/dist/util/filtering.d.ts:18