# CacheInfo

```python
class CacheInfo
```

Struct representing KV-cache information.

## Attributes

| Name | Description |
| --- | --- |
| [`cache_type`](<#cache-type>) |  |
| [`name`](<#name>) |  |
| [`layer_hash`](<#layer-hash>) |  |
| [`size`](<#size>) |  |
| [`num_batches`](<#num-batches>) |  |

### cache\_type

```python
property cache_type: CacheType
```

### name

```python
property name: str
```

### layer\_hash

```python
property layer_hash: str
```

### size

```python
property size: int
```

### num\_batches

```python
property num_batches: int
```

## Methods

| Name | Description |
| --- | --- |
| [`__init__`](<#init>) |  |
| [`from_cpp`](<#from-cpp>) |  |

### \_\_init\_\_

```python
def __init__(
    self,
    cache_type: CacheType = CacheType.Error,
    name: str = "",
    layer_hash: str = "",
    size: int = 0,
    num_batches: int = 0,
)
```

### from\_cpp

```python
def from_cpp(cls, _cache_info: _cQbRuntime.CacheInfo)
```
