Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

brain-doctor

Skill by jame581

Lints and repairs the Claude Brain Logseq graph, finding format mistakes that create phantom pages or broken macros. Built for people who keep a Claude Brain graph in Logseq and want to clean it up.

  • Score 52
  • 19 stars
  • MIT
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install brain-doctor

Built from the published package, never by AI.

git clone --depth 1 https://github.com/jame581/LogseqBrain /tmp/LogseqBrain && mkdir -p ~/.claude/skills && cp -r /tmp/LogseqBrain/plugin/skills/brain-doctor ~/.claude/skills/brain-doctor

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install brain-doctor in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

brain-doctor is an agent skill for the Claude Brain Logseq graph. It scans the whole graph for format mistakes that can silently corrupt it, such as phantom pages and broken macros. It reports what it finds, grouped by whether the issue can be fixed automatically or needs the user's decision. Its triggers include "lint brain", "check brain health", "fix brain" and "backfill digests".

Detection runs through a shared helper command, brain lint --all, and the skill follows a catalog of rules for meaning, tiers and remediation. Report mode changes nothing. Fix mode makes a backup and asks for confirmation before any write. Judgment cases such as broken links and duplicate entries are left for the user to decide. Loads, saves, status checks and first-time setup are handled by other skills. The skill is aimed at people who maintain a Logseq graph used with Claude.

Written from the project's SKILL.md and checked against it.

What it can do

  • Whole-graph lintScans every mechanical rule and the digest rules, reporting each finding by file, line and tier.
  • Report modeSummarizes issues in auto-fixable and needs-your-call groups without changing any file.
  • Fix modeRepairs findings after a backup and confirmation, with mechanical classes fixed in one pass.
  • Digest backfillBuilds missing digests after stating the read cost and getting one confirmation.
  • Digest rebuildRebuilds the digest for a named project when asked to rebuild digest for a project.
  • Backup before writesCopies the pages, journals and logseq folders to a timestamped folder before any change.
  • Post-repair verificationRe-lints changed files and checks backtick parity after repairs.
  • Activity loggingRecords each run with brain activity so changes are traceable.

What you need

  • Logseq with a Claude Brain graph
  • Bash shell, or Git for Windows (Git Bash) on PowerShell-only Windows

Try asking

  • lint brain
  • Why are there empty pages in my brain graph?
  • Backfill digests for my project pages

Good to know

  • Broken-link, duplicate-entry and structural-integrity changes are never written automatically.
  • Empty pages left by fixed text remain until Logseq is re-indexed.
  • Close Logseq or pause Sync during a bulk fix.
  • Not for loads, saves, status checks or first-time setup.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: plugin/skills/brain-doctor/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Alternatives to brain-doctor

All alternatives →

Compare with agentmemory-config, understand-knowledge or reports

brain-doctor: common questions

Does brain-doctor change my graph automatically?

Report mode changes nothing. Fixes run only after a backup and confirmation, and some classes, such as broken links and duplicate entries, are never written automatically.

Why are there empty pages left after a fix?

Logseq never deletes a page once it has parsed one, so empty pages survive until the graph is re-indexed in Logseq (All graphs, then Re-index).

What does a digest backfill do?

It builds missing Digest sections for pages. It reports the read cost and asks for one confirmation first, with project pages included by default.

How do I install brain-doctor?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is brain-doctor free?

The code is published under the MIT licence. The service it connects to may have its own pricing.

Is brain-doctor safe to use?

It scores 52 of 100. Grades: maintenance A, licence A, quality C. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to brain-doctor?

Similar skills: agentmemory-config, understand-knowledge, reports, forget.

brain-doctor Install

Add to stack

Loading.