# Getting started

> Install Topic Map, make a collection from a folder of notes, index it and search it.

## Install

Topic Map is in Obsidian's community directory. Install Model Hub first: it holds the AI keys Topic Map uses.

1. In **Settings → Community plugins**, select **Browse**, then install and enable **Model Hub**. Add a provider in its settings and apply a preset on its Tiers tab.
2. Browse again for **Topic Map**, then install and enable it.
3. For collections of books, install **Library Hub** the same way. This is optional.

Open **Settings → Topic Map → Setup**. Under **Connections**, Model Hub should say *Connected*.

## Make a collection

A folder of notes is the quickest start.

1. Open **Settings → Topic Map → Collections** and select **New collection…**.
2. Give it a **Name**.
3. Set **Source** to **Notes in a folder** and enter the folder's path.
4. Choose a **Lens**: **nonfiction** for notes that argue, explain or advise; **fiction** for stories.
5. Select **Create**.

![The New collection dialog: a name, a source, a lens and an About line](img/2-new-collection.png)

The collection is saved as a note in the `Topic Map` folder. Nothing is indexed yet.

## Index it

1. Run the command **Topic Map: Collection: Index…** and pick the collection.
2. Read the dry run: how many passages it would read and an estimate of the tokens. Nothing has been sent yet.
3. Set a spend limit if you want one, then select **Index**.

![The Index dialog before a run: the counts, what the run would do and its cost, then the quality pick and the spend limit](img/index-dialog.png)

The job shows its progress and its cost so far. You can cancel it; a later run picks up where it stopped.

## Search it

1. Run **Topic Map: Use: Search**. A pane opens at the side.
2. Pick the collection and ask a question.
3. Select a card to open its passage, with the quoted words highlighted.

![The search pane: a question, the facet tabs, a filter, and two cards with their quotes](img/search.png)

Next: [find its topics](find-topics.md), or [draft a write-up](draft-a-write-up.md). If something did not work, see [Troubleshooting](troubleshooting.md).
