# Overview (/docs/docklee/overview)
Docklee sits between your application and your model. It holds two things your app would otherwise build itself: knowledge it can answer from, and memory about the people it serves.

Use Docklee when your assistant needs to cite your own content, remember a user from one session to the next, or both.

<FlowDiagram
  caption="Your app writes with Dock, Docklee stores and organizes the data, and your app reads it back with Lynk."
  stages={[
    { title: 'Your app', detail: 'Captures documents, events, and conversations.' },
    { title: 'Dock', detail: 'Sends them to a container or a memory space.' },
    { title: 'Docklee', detail: 'Processes, links, and keeps the data current.' },
    { title: 'Lynk', detail: 'Returns answers, context, or memories to your model.' },
  ]}
/>

## Two runtimes [#two-runtimes]

| Runtime | Holds | Read with |
| --- | --- | --- |
| **Knowledge Engines** | Documents, pages, and app data, stored in vector and OKF containers | `lynk.query` and `lynk.retrieve` |
| **Docklee Universal Memory** | Facts, preferences, events, and history, stored in memory spaces | `lynk.recall` |

The runtimes are separate. Knowledge never mixes into a memory space, and memory never appears in an engine's answers. One API key can reach either runtime or both.

## One package, two classes [#one-package-two-classes]

The `docklee` package has a class for each direction of data.

| Class | What it does | Methods |
| --- | --- | --- |
| `Dock` | Writes into a container or a memory space | `capture`, `flush`, `instrument`, `watch`, `listen`, `close` |
| `Lynk` | Reads from an engine or a memory space | `query`, `retrieve`, `recall`, `close` |

Both classes read `DOCKLEE_API_KEY` from the environment:

<CodeTabs items={['Python', 'TypeScript']}>
  <Tab value="Python">
    ```python
    from docklee import Dock, Lynk

    dock = Dock()
    lynk = Lynk()
    ```
  </Tab>
  <Tab value="TypeScript">
    ```ts
    import { Dock, Lynk } from 'docklee';

    const dock = new Dock();
    const lynk = new Lynk();
    ```
  </Tab>
</CodeTabs>

## Three ways to read [#three-ways-to-read]

| Method | Returns | Best for |
| --- | --- | --- |
| `lynk.query` | A finished answer with a confidence score and citations, in one response or as a stream | Assistants that answer from your content |
| `lynk.retrieve` | The ranked chunks behind an answer | Apps that run their own model |
| `lynk.recall` | Memory records, each with a type and a confidence score | Personalizing replies for a user |

## Where you set things up [#where-you-set-things-up]

The [Docklee dashboard](https://app.docklee.com) holds the resources the SDK uses.

| Section | What you do there |
| --- | --- |
| **Sources** | Connect documents, apps, and data once, for every engine |
| **Knowledge Engines** | Create engines and link sources to them |
| **DUM** | Create memory spaces, then inspect, review, and correct what they hold |
| **API Keys** | Create keys and limit what each one can reach |
| **Usage** | See how much each runtime is used |

## Next steps [#next-steps]

Now you know the parts. The Quickstart puts them together in a few minutes.

<Cards>
  <Card title="Quickstart" href="/docs/docklee/quickstart" description="Write a memory, recall it, and query an engine." />
  <Card title="Memory vs Knowledge" href="/docs/docklee/memory-vs-knowledge" description="Which runtime fits the data you have." />
  <Card title="How Docklee works" href="/docs/docklee/how-docklee-works" description="The full path from a write to a read." />
</Cards>
