# InMemoryDocstore

> **Class** in `langchain_community`

📖 [View in docs](https://reference.langchain.com/python/langchain-community/docstore/in_memory/InMemoryDocstore)

Simple in memory docstore in the form of a dict.

## Signature

```python
InMemoryDocstore(
    self,
    _dict: Optional[Dict[str, Document]] = None,
)
```

## Extends

- `Docstore`
- `AddableMixin`

## Constructors

```python
__init__(
    self,
    _dict: Optional[Dict[str, Document]] = None,
)
```

| Name | Type |
|------|------|
| `_dict` | `Optional[Dict[str, Document]]` |


## Methods

- [`add()`](https://reference.langchain.com/python/langchain-community/docstore/in_memory/InMemoryDocstore/add)
- [`delete()`](https://reference.langchain.com/python/langchain-community/docstore/in_memory/InMemoryDocstore/delete)
- [`search()`](https://reference.langchain.com/python/langchain-community/docstore/in_memory/InMemoryDocstore/search)

---

[View source on GitHub](https://github.com/langchain-ai/langchain-community/blob/a6a6079511ac8a5c1293337f88096b8641562e77/libs/community/langchain_community/docstore/in_memory.py#L10)