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

# Types

> Core types and data structures

Reference for core types and data structures used in the mobile-use SDK.

## AgentProfile

Represents a profile for the mobile-use agent with LLM configuration.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.sdk.types import AgentProfile
```

### Constructor

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
AgentProfile(
    *,
    name: str,
    llm_config: LLMConfig | None = None,
    from_file: str | None = None,
)
```

**name** `str` *required*

Name of the profile

**llm\_config** `LLMConfig`

LLM configuration for the agent

**from\_file** `str`

Path to a file containing LLM configuration (JSONC format)

> [!WARNING]
>
> `llm_config` and `from_file` are mutually exclusive - use only one.

### Examples

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
# From file
profile = AgentProfile(
    name="default",
    from_file="llm-config.defaults.jsonc"
)

# Programmatic
from minitap.mobile_use.config import LLM, LLMConfig

profile = AgentProfile(
    name="custom",
    llm_config=LLMConfig(
        planner=LLM(provider="openai", model="gpt-5-nano"),
        cortex=LLM(provider="openai", model="gpt-5"),
        # ... other components
    )
)
```

***

## TaskRequest

Represents a mobile automation task request.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.sdk.types import TaskRequest
```

### Attributes

**goal** `str`

Natural language description of the task goal

**profile** `str | None`

Name of the agent profile to use

**task\_name** `str | None`

Name of the task for logging

**output\_description** `str | None`

Description of the expected output format

**output\_format** `type[TOutput] | None`

Pydantic model class for typed output

**max\_steps** `int`

Maximum number of steps the agent can take

**record\_trace** `bool`

Whether to record execution traces

**trace\_path** `Path`

Directory to save trace data

**llm\_output\_path** `Path | None`

Path to save LLM outputs

**thoughts\_output\_path** `Path | None`

Path to save agent thoughts

### Usage

TaskRequest objects are typically created via `TaskRequestBuilder`:

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
task_request = (
    agent.new_task("Your goal")
    .with_name("task_name")
    .build()
)
```

***

## AgentConfig

Configuration for the agent.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.sdk.types import AgentConfig
```

Created via `AgentConfigBuilder`:

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
config = (
    Builders.AgentConfig
    .with_default_profile(profile)
    .build()
)

agent = Agent(config=config)
```

***

## DevicePlatform

Enum for device platforms.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.sdk.types import DevicePlatform

# Available values
DevicePlatform.ANDROID
DevicePlatform.IOS
```

### Usage

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
config = (
    Builders.AgentConfig
    .for_device(platform=DevicePlatform.ANDROID, device_id="emulator-5554")
    .build()
)
```

***

## ServerConfig

Configuration for agent servers.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.sdk.types import ServerConfig
```

### Attributes

**adb\_server\_host** `str`

ADB server host

**adb\_server\_port** `int`

ADB server port

### Usage

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
servers = ServerConfig(
    adb_server_host="localhost",
    adb_server_port=5037
)

config = Builders.AgentConfig.with_servers(servers).build()
```

***

## LLMConfig

Configuration for LLM models used by different agent components.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.config import LLM, LLMConfig, LLMConfigUtils, LLMWithFallback
```

### Structure

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
llm_config = LLMConfig(
    planner=LLM(provider="openai", model="gpt-5-nano"),
    orchestrator=LLM(provider="openai", model="gpt-5-nano"),
    cortex=LLMWithFallback(
        provider="openai",
        model="gpt-5",
        fallback=LLM(provider="openai", model="gpt-5")
    ),
    executor=LLM(provider="openai", model="gpt-5-nano"),
    utils=LLMConfigUtils(
        hopper=LLM(provider="openai", model="gpt-5-nano"),
        outputter=LLM(provider="openai", model="gpt-5-nano")
    )
)
```

### Components

> [card] planner
>
> Creates high-level plans from goals

> [card] orchestrator
>
> Coordinates execution steps

> [card] cortex
>
> Visual understanding and decision-making

> [card] executor
>
> Performs specific actions

> [card] hopper
>
> Extracts relevant information from large data batches

> [card] outputter
>
> Extracts structured output

***

## LLM

Basic LLM configuration.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.config import LLM

llm = LLM(provider="openai", model="gpt-5")
```

**provider** `str` *required*

Provider name: `openai`, `google`, `xai`, `openrouter`

**model** `str` *required*

Model identifier (e.g., `gpt-5`, `gemini-2.5-flash`)

***

## LLMWithFallback

LLM configuration with a fallback model.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.config import LLM, LLMWithFallback

llm = LLMWithFallback(
    provider="openai",
    model="o4-mini",
    fallback=LLM(provider="openai", model="gpt-5")
)
```

If the primary model fails, the fallback is used automatically.

***

## TaskRequestCommon

Common configuration shared across tasks.

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
from minitap.mobile_use.sdk.types import TaskRequestCommon
```

Created via `TaskDefaults` builder:

```python theme={"theme":{"light":"github-light","dark":"vesper"}}
defaults = (
    Builders.TaskDefaults
    .with_max_steps(500)
    .build()
)
```

## Next Steps

> [card] [Agent SDK](https://www.minitap.ai/docs/mobile-use-sdk/sdk-reference/agent.md)
>
> Core Agent class reference

> [card] [Exceptions](https://www.minitap.ai/docs/mobile-use-sdk/sdk-reference/exceptions.md)
>
> Error handling reference


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.