# `Gemini.Types.Live.AutomaticActivityDetection`
[🔗](https://github.com/nshkrdotcom/gemini_ex/blob/v0.13.0/lib/gemini/types/live/automatic_activity_detection.ex#L1)

Automatic activity detection configuration for Live API sessions.

Configures automatic detection of user activity (voice and text input).
When enabled (the default), the server automatically detects when the
user starts and stops speaking.

## Fields

- `disabled` - If true, automatic detection is disabled and client must send activity signals
- `start_of_speech_sensitivity` - How likely speech is to be detected at start
- `end_of_speech_sensitivity` - How likely detected speech is to end
- `prefix_padding_ms` - Duration of speech required before start-of-speech is committed
- `silence_duration_ms` - Duration of silence required before end-of-speech is committed

## Example

    %AutomaticActivityDetection{
      disabled: false,
      start_of_speech_sensitivity: :high,
      end_of_speech_sensitivity: :low,
      prefix_padding_ms: 100,
      silence_duration_ms: 500
    }

# `t`
[🔗](https://github.com/nshkrdotcom/gemini_ex/blob/v0.13.0/lib/gemini/types/live/automatic_activity_detection.ex#L30)

```elixir
@type t() :: %Gemini.Types.Live.AutomaticActivityDetection{
  disabled: boolean() | nil,
  end_of_speech_sensitivity: Gemini.Types.Live.Enums.EndSensitivity.t() | nil,
  prefix_padding_ms: integer() | nil,
  silence_duration_ms: integer() | nil,
  start_of_speech_sensitivity:
    Gemini.Types.Live.Enums.StartSensitivity.t() | nil
}
```

# `from_api`
[🔗](https://github.com/nshkrdotcom/gemini_ex/blob/v0.13.0/lib/gemini/types/live/automatic_activity_detection.ex#L114)

```elixir
@spec from_api(map() | nil) :: t() | nil
```

Parses from API response.

# `new`
[🔗](https://github.com/nshkrdotcom/gemini_ex/blob/v0.13.0/lib/gemini/types/live/automatic_activity_detection.ex#L50)

```elixir
@spec new(keyword()) :: t()
```

Creates a new AutomaticActivityDetection configuration.

# `to_api`
[🔗](https://github.com/nshkrdotcom/gemini_ex/blob/v0.13.0/lib/gemini/types/live/automatic_activity_detection.ex#L64)

```elixir
@spec to_api(t() | nil) :: map() | nil
```

Converts to API format (camelCase).

---

*Consult [api-reference.md](api-reference.md) for complete listing*
