# Personal wiki

Sources you give your agent, kept as they are, and the linked notes it writes from them.

This is a recipe from flie: a person can read it first, and an agent follows
it. It makes one folder in the person's flie, with a README in it that holds
the rules, so every agent that opens the folder later works the same way.

## 1. Make sure flie is set up

If the `flie` command is not found or `flie whoami` says nobody is signed in,
and you have no flie tools over MCP, set flie up first, with the person's
authorization, by following https://flie.sh/setup.md
Then come back here.

The steps below are `flie` commands. Over MCP, call the tools of the same
names, with the same arguments written as named arguments, and pass a file's
text as `content` instead of `--from`.

## 2. Make the folder

`flie whoami` prints the person's Root folder. Make the folder there unless
the person names another place. If a folder called "Wiki" is already
there (`flie agent list <root ID>`), use it: read its README and follow it
instead of starting again.

    flie agent mkdir <root ID> "Wiki"
    flie agent mkdir <folder ID> "sources"
    flie agent mkdir <folder ID> "topics"

Each command prints the new item's name and its ID; every later command names
the item by that ID. Laid out, the folder is:

    Wiki/
      README.md   the rules
      index.md    every topic, one line each
      sources/    kept as given
      topics/     one note per idea

## 3. Write the README, then start

Write this README into the folder, adapted where the person says so, with the
text on stdin:

    flie agent create --from - <folder ID> "README.md"

~~~markdown
# Wiki

Notes an agent writes from the sources <the person> gives it. The person reads
and corrects them; agents answer from them.

- sources/: everything the person gives, kept exactly as given. Never edit these.
- topics/: one note per idea, named for the idea.
- index.md: every topic, one line each, with what it covers.

## A topic note

    # MCP
    In short: one or two sentences.
    Notes: what the sources say, in your words.
    See also: other topics, by name.
    Sources: the files in sources/ this comes from.

## Rules

- Every note links the sources it comes from.
- Prefer updating a topic to starting a new one. Keep notes short.
- When a source contradicts a note, say so in the note rather than hiding it.

## When to write

- When the person gives you a source: save it in sources/, then update or write
  the topics it supports, then index.md.
~~~

Then create index.md the same way.

Take the source the person gave you, or ask for a first one. Save it in sources/ as given, write the topic notes it supports, and update index.md.

## 4. Ask the person, then connect their other agents if they want

Any agent reaches this same folder once its host has flie's server registered,
once per host. Offer it; register only the hosts the person asks for:

- **Claude Code** — `claude mcp add --transport http flie https://flie.sh/mcp`
- **Codex** — `codex mcp add flie --url https://flie.sh/mcp`, then `codex mcp login flie` to sign in
- **Cursor** — add `{"mcpServers": {"flie": {"url": "https://flie.sh/mcp"}}}` to `~/.cursor/mcp.json`

In Cursor, flie shows Needs authentication under Tools & MCPs in its settings, and Connect there is what opens your browser. The person completes each sign-in, not you.

## Done

Tell the person what you made, give them the folder's link
(`flie agent link <folder ID>`), and ask whether to connect their other agents (step 4).
Editing its README changes the rules for every agent that reads it. How to
change a file without losing anyone's edits: https://flie.sh/skill.md.
End your reply with the question in step 4.
