> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/volcengine/OpenViking/llms.txt
> Use this file to discover all available pages before exploring further.

# abstract

> Read L0 abstract summary

Read the L0 abstract (\~100 token summary) of a directory or file. This is the most concise layer in OpenViking's hierarchical context system.

## Python SDK

```python theme={null}
from openviking import OpenViking

client = OpenViking()

# Get abstract of a directory
abstract = client.abstract("viking://resources/docs/")
print(f"Abstract: {abstract}")
# Output: "Documentation for the project API, covering authentication, endpoints..."
```

## HTTP API

<CodeGroup>
  ```bash cURL theme={null}
  curl -X GET "http://localhost:1933/api/v1/content/abstract?uri=viking://resources/docs/" \
    -H "X-API-Key: your-key"
  ```
</CodeGroup>

<RequestExample>
  ```http theme={null}
  GET /api/v1/content/abstract?uri=viking://resources/docs/
  ```
</RequestExample>

## Parameters

<ParamField path="uri" type="string" required>
  Viking URI (typically a directory, but can also be a file)
</ParamField>

## Response

<ResponseField name="status" type="string">
  Operation status (`ok` on success)
</ResponseField>

<ResponseField name="result" type="string">
  The L0 abstract summary (\~100 tokens)
</ResponseField>

<ResponseField name="time" type="number">
  Execution time in seconds
</ResponseField>

<ResponseExample>
  ```json theme={null}
  {
    "status": "ok",
    "result": "Documentation for the project API, covering authentication, endpoints, error handling, and best practices.",
    "time": 0.1
  }
  ```
</ResponseExample>

## CLI

```bash theme={null}
openviking abstract viking://resources/docs/
```

## Context Layers

OpenViking provides three hierarchical levels of content:

* **L0 (Abstract)**: \~100 token summary via `abstract()` (this method)
* **L1 (Overview)**: Structured overview via [`overview()`](/api/filesystem/overview)
* **L2 (Full)**: Complete content via [`read()`](/api/filesystem/read)

The abstract layer is ideal for:

* Quick directory summaries
* Agent context where token efficiency is critical
* Initial exploration of large codebases

## Implementation Details

The abstract is stored in a `.abstract.md` file within the directory. If not present, it's generated automatically from the directory contents.
