agentleFS
nathanadaynathanaday/claude-atlas/skills/wiki-edit/SKILL.md

wiki-edit

Skill1 starsChanged 37 days agoMITView on GitHub

Change knowledge that exists: rewrite, rename, merge, split, remove with a redirect, retag, confirm a topic is current, or repair what lint found, as one reviewed change; and draft the topic of a subject that a wikified note marks as new, or that the user selects in a note with Make topic. Use for rewrite this topic, rename, merge these topics, split this topic, tag this under p3, rename a tag, this page is still right, fix the lint findings, fix the dead links, draft a topic titled X from this note. New knowledge from documents is wiki-sync; unlinking a repository is repo-unlink.

2 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

9 rules. About 0 are common, 3 are distinctive, and 6 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 6

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Every change to knowledge that exists goes through one change document.

    line 8
  2. Very specific:

    Read each document with Read, and the documents that link to it (search its title, or grep for [[Title).

    line 20
  3. Very specific:

    remove: a remove with redirect set to the document that links now name.

    line 29
  4. Very specific:

    Leave base out unless you read the document's hash.

    line 44
  5. Very specific:

    Use a tag that exists before you make a new one.

    line 46
  6. Very specific:

    when another document covers its subject, a remove with redirect set to it.

    line 60
  7. Distinctive:

    Create on a new mark of a wikified note (wiki-wikify): "Draft a topic titled <Title> from [[<note>]] and what the wiki holds.

    line 79
  8. Distinctive:

    Read the note with Read: the passage around the mark or the link, and every other place where the note speaks of the subject.

    line 93
  9. Distinctive:

    Read the topics and sources that say something about it.

    line 96

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

wiki-edit

Every change to knowledge that exists goes through one change document. Renames, removes, and retags keep every link and tag true, because code rewrites them in the same commit. A remove moves the document to tool/trash/; undo moves it back. You may undo only a change of a session: the user undoes the user's own acts (safe delete, Return).

Tools: vault, search, lint, change. References: changes.md, pages.md.

Procedure

  1. Resolve the documents to ids with search. For lint repairs, call lint (with tags to check only the documents under them) and take the findings the user chose.
  2. Read each document with Read, and the documents that link to it (search its title, or grep for [[Title).
  3. Build the Wiki Change Plan, one write per move:
    • rewrite: a modify with the whole new body;
    • rename: a rename with the new title; code rewrites the links;
    • merge: a modify of the topic that stays, with both contents and both citations, and a remove of the other with redirect set to the topic that stays;
    • split: a modify of the topic, and a create (type: topic, kind, title, fields, body) for each new topic, linked both ways;
    • remove: a remove with redirect set to the document that links now name; tell the user that the document goes to tool/trash/;
    • new tags on a document: a modify of fields.tags (the whole list);
    • a new place on the map: a modify of fields.up (the whole list; see Up in pages.md);
    • rename or merge a tag: a retag with from and to; code rewrites the tag in every document, the tags below it too; a to that exists merges the two;
    • a topic checked and still true: a confirm with id;
    • a dead link: create the target, or change the link in a modify;
    • an up finding: drop a self link; break a cycle at the link that points from the broader subject to the narrower one; drop the up of a source. crowded is wiki-map's;
    • a dead link that names an alias, an id, or plain text: link the title the finding names. Give every write a why: one line that says why the change makes it. Leave base out unless you read the document's hash; code records it at propose, and apply refuses a write whose document changed since. Use a tag that exists before you make a new one. In tagging: known mode, set new_tags: true only after the user agreed to each new tag.

Safe delete with backlinks

The palette's "Resolve with an agent" message names a knowledge document that the user wants to delete, and the documents that link it: "Remove [[<title>]] …: point each backlink elsewhere, or drop it, then propose a remove". The palette offers it only when documents link the target. When files of the user's link it too, the message names them: "[[<note>]] is the user's to fix, so leave it and propose no remove".

  1. Find the backlinks. The message names at most ten ("4 more"), so also search the title and grep the vault for [[<title>.
  2. Build one plan:
    • when another document covers its subject, a remove with redirect set to it; code points the links there, but not in scratchpad/, journals/, or checkout/;
    • otherwise, a modify of each linking knowledge document that points the link to another document or drops it, then a remove.
  3. A link outside the knowledge documents is the user's: in scratchpad/, journals/, checkout/, or any other note. Do not edit it. When the message names such a file, or you find one, propose the modify writes only, with no remove, and tell the user which files to fix before Safe delete runs again. A checked-out copy links its original in checkout_of.
  4. A file that is not a knowledge document (a note, an original) never comes to you from the palette, and no change removes it. A source's original in tool/source-core/originals/ leaves only with its source.

Draft a topic from a note

Two acts in Obsidian start a work document of kind draft and send you its first message. Report each step below with change action: progress and that id.

  • Create on a new mark of a wikified note (wiki-wikify): "Draft a topic titled <Title> from [[<note>]] and what the wiki holds; give it a why. Your work document is [[<doc>]] (<id>): report each step with change progress, and propose into it with change propose and id <id>." The note is the wikified copy in scratchpad/, and the mark {{new:<Title>|…}} names the subject.
  • Make topic on a selection in any note of the user's: "Draft a topic titled <Title> from the note <path>, where the user linked "<phrase>" to it, and what the wiki holds; …" with the same end. The note may be a topic, a journal note, or a scratchpad note. The selection is a link [[<Title>|<phrase>]] (or [[<Title>]]) already, so the topic resolves it.
  1. search the title. When a document holds it already, propose nothing: call change with action: reject, the id, and the reason ("<Title> exists", or "<Title> is an alias of <Other>"). The bubble in a wikified note then offers Link.
  2. Read the note with Read: the passage around the mark or the link, and every other place where the note speaks of the subject. Never edit the note.
  3. search the wiki for the subject: its title, the note's wording, and its aliases. Read the topics and sources that say something about it.
  4. Build one create write: type: topic, the kind that fits the subject (concept, entity, or policy), and title set to <Title> exactly, so that the bubble's Link finds the topic and the user's link resolves. Give it fields: a one-sentence description, tags that exist (the tags of the documents it draws on; the tag list is in the session-start context, or vault), aliases (the note's wording when it differs), status (draft when the topic is thin), and sources. Write the body with the sections of its kind (pages.md), and link the wiki's related topics under ## Related.
  5. Cite every claim. Cite a document of the wiki, with a locator, for each claim it supports, and list it in sources. A claim that only the note makes is the user's: cite the note, keep the user's wording, and never write more than the note says.
  6. Give the write a why: one line on what the note does with the subject, and that the wiki has no topic for it.
  7. Propose with change action: propose and id, with notes that name the note. One write: the topic. Change no other document.

Gate

Propose with change action: propose, with id when a work document runs. End the turn with one or two lines: the change document as a link, each new tag, the count of documents a retag rewrites, and for a remove, that the document goes to tool/trash/. Wait for the yes in the chat, then apply, or let the user decide in the document. The change tool refuses apply in the same turn as the proposal.

Hand off

wiki-review to check the result, after a large repair.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.