# DiskCache

* Type: Cache
* Description: Uses Disk files (and SQLite DBs) as Caches. Takes advantage of the disk space instead of RAM.

This Cache is built on top of [diskcache](http://www.grantjenks.com/docs/diskcache/index.html) on its `FanoutCache`.

An extra installation is required: `pip install pyot[diskcache]`

## *class* `DiskCache`

Backend: `pyot.stores.diskcache.DiskCache`

Definitions:

* `__init__`
  * `directory`: `str | Path`

    > Path of the directory used as cache.
  * `expirations`: `Dict[str, int | float | timedelta] = None`
  * `log_level`: `int = 0`
  * `**kwargs`

    > Any extra kwargs provided will be passed into `diskcache.FanoutCache`.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://pyot.iann838.com/stores/diskcache.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
