Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Injects the canonical Obsidian vault frontmatter schema snippet into agent prompts before vault-write tasks to prevent malformed YAML.
18% 91%+73 ptsof test cases passed
Passed 20 of 22 test cases with the skill, and 4 of 22 without it.
After updating the schema, the guard script computes a new hash to indicate the snippet is stale. How many characters long is this computed hash?
Specifies the hash is 8 characters long
3 of 3 safety checks passed
Project-instruction file resolution:
CLAUDE.mdandAGENTS.md(Codex CLI) are transparent aliases — see skills/_shared/instruction-file-resolution.md. Wherever this skill mentionsCLAUDE.md, the alias rule applies.
vault-mirror and other vault-write agents frequently produce notes with missing or malformed YAML frontmatter — incorrect type enum values, missing id, wrong date formats. The resulting notes fail the vault-sync validator at session-end, causing hard-gate failures that interrupt the close flow.
This skill solves the problem at the source: it injects the canonical vault frontmatter schema as a Markdown snippet into agent prompts before any vault-write task is dispatched. Agents that receive the snippet produce conformant frontmatter on the first attempt, eliminating the validator feedback loop.
Trigger this skill whenever the task being dispatched has vault-write scope. Use the detectVaultTaskScope() heuristic from scripts/lib/frontmatter-guard.mjs to decide programmatically:
import { readVaultSchema, generateFrontmatterSnippet, detectVaultTaskScope } from './scripts/lib/frontmatter-guard.mjs';
const isVaultTask = detectVaultTaskScope(taskDescription, fileScope);
if (isVaultTask) {
const schema = readVaultSchema();
if (schema) {
const snippet = generateFrontmatterSnippet(schema);
// prepend snippet to agent system prompt
}
}
The heuristic fires when any of the following is true:
fileScope contains /Projects/vault/ in its path.fileScope is under a known vault subdirectory: 40-learnings/, 50-sessions/, 03-daily/, 01-projects/.taskDescription mentions vault or vault-mirror AND contains a write-intent keyword (write, create, generate, emit, mirror, update, add, insert).readVaultSchema() returns null when the schema source is missing — the caller must handle this gracefully (skip injection rather than throw).
The canonical call site is the wave-executor pre-dispatch hook. Before spawning an agent whose fileScope matches the heuristic, the coordinator calls:
Next to this one in the catalogue, plus more from the same author.