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

# Empty Namespace Configuration

> A namespace must have at least one of scope or fields

## Error message

```
{context}: at least one of scope or fields must be provided
```

Example: `dataset: at least one of scope or fields must be provided`

## When this error occurs

The `dataset` and `rosetta_stone` namespace objects are optional at the top level. But if you include one, it must contain at least `scope`, `fields`, or both. An empty namespace object has no effect and indicates a configuration mistake.

## Example: request that triggers this error

```json theme={null}
{
  "defaults": {
    "enabled_stats": ["value_count"]
  },
  "refresh": { "trigger": "manual" },
  "dataset": {}
}
```

The `dataset` namespace is present but has neither `scope` nor `fields`.

## How to fix

Either add content to the namespace or remove it entirely:

**Option A: Add a scope**

```json theme={null}
{
  "defaults": {
    "enabled_stats": ["value_count"]
  },
  "refresh": { "trigger": "manual" },
  "dataset": {
    "scope": {
      "enabled_stats": ["value_count", "null_value_count"]
    }
  }
}
```

**Option B: Add fields**

```json theme={null}
{
  "defaults": {
    "enabled_stats": ["value_count"]
  },
  "refresh": { "trigger": "manual" },
  "dataset": {
    "fields": [
      {
        "field_name": "user_id",
        "enabled_stats": ["value_count", "count_distinct"]
      }
    ]
  }
}
```

**Option C: Remove the namespace**

```json theme={null}
{
  "defaults": {
    "enabled_stats": ["value_count"]
  },
  "refresh": { "trigger": "manual" }
}
```

If you want to disable stats for a namespace, use an empty `enabled_stats` array in the scope:

```json theme={null}
"dataset": {
  "scope": {
    "enabled_stats": []
  }
}
```
