remriel22 downloadsApply local keyword and regex tag rules to notes, with batch previews and keyword suggestions.
A free, local Obsidian plugin for a controlled tag taxonomy. It uses keyword and regular expression rules, and suggests tags using simple word frequency. No LLM, account, network request, or API key is used.
Install the current published release from the Obsidian community directory, or install a local build manually.
For a source build, install Node.js and run npm ci, npm run typecheck, and npm run build in this folder. The build writes main.js. Run npm test for the mocked smoke checks.
Releases are published from version tags such as 1.0.2. Keep the versions in package.json, manifest.json, and versions.json aligned, then push the tag. The GitHub Actions release workflow builds the plugin, creates the release with main.js, manifest.json, and styles.css, and generates GitHub artifact attestations for main.js and styles.css.
Open Settings > Rule-Based Auto-Tagger. Add or remove rules, choose a keyword or phrase or a JavaScript regular expression, toggle case-insensitive matching, and enter tags separated by commas or spaces. Omit regex slash delimiters and flags; use the toggle for case handling. Keywords match complete words or phrases, not fragments inside a larger word. Matching examines the note body, not its frontmatter.
Tags may contain letters, numbers, underscores, hyphens, and nested slashes; a tag must include a letter, underscore, or hyphen. A leading hash is optional. Empty or invalid rules are skipped, with a notice when a command runs. Regular expressions run locally and should be kept simple enough to finish promptly.
Starter rules cover machine learning, artificial intelligence, AI, meeting, and project. For example, the phrase Machine Learning adds #ai and #ml. Edit or remove these defaults to match your taxonomy. Rule edits are saved with the plugin settings.
Open the command palette and choose:
In Where to put new tags, choose Frontmatter (the default) to add tags to the frontmatter tags property, or Inline, at end of note to append a single line such as #ai #ml. Inline placement preserves the frontmatter and existing body text. Both placements check frontmatter, inline, and cached tags for duplicates case-insensitively. Batch previews show the placement before you apply. During a batch, each note is checked again before writing, and only tags shown in its preview can be added. Notes with malformed or unsupported frontmatter are skipped. Reports show skipped or failed counts; details appear in the developer console.
If a note ends inside an unclosed code fence, appended inline tags are treated as code. Obsidian indexes them once the fence is closed above the tag line.
Suggestions are ranked by word count, exclude common English stop words and existing tags, and ignore fenced code blocks. They are suggestions, not a controlled taxonomy: inspect them before adding them.
All matching happens locally inside Obsidian. The plugin makes no network calls. Tag vault and Tag current folder enumerate Markdown paths in the chosen scope and read those notes to build a preview; no changes happen until you apply it. It does not automatically modify notes on save; commands run only when invoked.
The requested workflow is inspired by the Obsidian Forum discussion Automatic Tag Generation.
MIT. See LICENSE.