Install
$ agentstack add skill-alexpialetski-doccraft-doccraft-config ✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
About
doccraft — config
When to use
- After
doccraft init: run Analyse mode to tailor the freshly scaffolded
doccraft.json to the project's actual subsystems, surfaces, and themes.
- Any time you want to add or change a config field: run Edit mode with a
plain-English request ("add slice:billing", "set maxStoryFiles to 10").
- Before invoking
doccraft-storyordoccraft-queue-auditwhen skill
output references unfamiliar vocabulary — the config is probably stale.
Schema
The full JSON Schema for doccraft.json is embedded below. Use it for validation in Edit mode instead of calling any CLI.
{{DOCCRAFT_CONFIG_SCHEMA}}
Modes
Analyse mode (no specific field requested)
- Read the project tree: directory names,
package.jsonscripts/workspaces,
git remote, conventional-commit scope history if a .git/ dir is present.
- Propose values for each key group with one sentence of reasoning per group:
story.areas— one entry per logical subsystem (aligns with commit scopes).story.slices— one entry per user-facing product surface;[]for
purely technical tools.
story.themes— recurring cross-cutting concerns from the tree.story.id.tiers— e.g.[p0,p1,p2]for most projects; more tiers only
when severity levels are meaningfully distinct.
queueAudit.scale— lower thresholds for small repos, higher for large.sessionWrap.capture— disable categories for folder trees the project
does not maintain.
- Show the proposed
doccraft.jsondiff (or full file if none exists yet). - Wait for approval before writing any file.
- On approval: write
doccraft.jsonat the project root. MUST NOT rewrite
version or $schema — preserve those bytes exactly.
Edit mode (specific change requested)
- Read the current
doccraft.json(use defaults if missing). - Parse the requested change.
- Validate the proposed new value against the embedded schema above. If
invalid, report the violation and stop — do not write.
- Apply the change surgically: update only the targeted field(s), preserving
all other bytes (key order, whitespace, comments are not present in JSON but formatting should be preserved).
- Write
doccraft.jsonand confirm what changed.
Extensions
When doccraft.json declares an extensions: [...] array, each entry points at a project-local directory containing an extension.yaml manifest. At doccraft update, doccraft bakes fragments declared by those manifests into skill bodies at named injection points and scaffolds any declared folders. The extension framework is the supported way to add project-specific guidance (additional frontmatter fields, body sections, instructions) to the four core skills (doccraft-story, doccraft-adr, doccraft-queue-audit, doccraft-session-wrap) without forking doccraft.
When editing the extensions array:
- Order is significant. Fragments concatenate in declaration order at
each injection point — surface that to the user when adding a new entry.
- Each
pathmust be a directory relative to the project root, and
the directory must already exist (or be about to be created in the same change). doccraft does not scaffold extension directories; the user authors them.
- Validation runs at
doccraft update, not at config write time —
malformed manifests surface on the next update.
Constraints
- NEVER call
npx doccraft@latest— the embedded schema is authoritative
for the installed version. Reaching for @latest could propose fields not yet supported.
- NEVER rewrite
versionor$schema— those are managed by
doccraft update / bumpConfigVersion. Preserve them verbatim.
- Tolerate a missing
doccraft.json— proceed with defaults; offer to
create the file in Analyse mode.
- MUST gate on approval before writing any file in Analyse mode. Edit mode
may apply without a gate for single-field changes unless the change is destructive (e.g. clearing an entire array).
Pre-execution validation
Before writing or updating doccraft.json, MUST complete these checks:
- Read existing file — if
doccraft.jsonexists, read it in full
before proposing any changes. NEVER write from assumptions about current values.
- Schema validation — validate the proposed output against the
embedded schema above. If any field violates the schema, report the violation and stop — MUST NOT write an invalid file.
- Preserve managed fields — confirm that
versionand$schema
are byte-identical to the existing file. If the file is new, omit both (they are set by doccraft update).
- Extension paths exist — if editing the
extensionsarray, verify
each path directory exists on disk (or is being created in the same change). Flag missing directories rather than writing a broken config.
- No duplicate entries — arrays like
story.areas,story.slices,
story.themes MUST NOT contain duplicate values. Deduplicate silently and note what was removed.
Invalid examples (do not use)
- Calling
npx doccraft@latest llmor any CLI to fetch the schema —
NEVER; the embedded schema is authoritative.
- Overwriting
versionor$schema— NEVER; those are managed by
doccraft update.
- Writing
doccraft.jsonin Analyse mode without user approval —
NEVER; gate on approval first.
- Adding a value to
story.statusthat duplicates an existing entry
(e.g. adding todo when it already exists) — NEVER; deduplicate.
- Proposing fields not present in the embedded schema — NEVER; unknown
fields will confuse future doccraft update runs.
- Clearing an entire array in Edit mode without confirmation — NEVER;
destructive changes MUST be gated.
- Setting
extensions[].pathto a non-existent directory without
flagging it — NEVER; the user MUST create the directory first.
Done condition
The task is complete when:
- In Analyse mode: proposed values have been shown with reasoning,
user has approved, and doccraft.json has been written at the project root with version and $schema preserved.
- In Edit mode: the targeted field has been updated, the full file
validates against the embedded schema, and doccraft.json has been written with only the intended change applied.
- The output confirms what changed (field names and old → new values).
Workflow reminders
- After changing
story.areas,story.slices, orstory.themes,
existing stories with tags not in the new vocabulary are still valid — do not retroactively edit story files. The new vocabulary applies to future stories only.
- After changing
story.status,story.urgency, orstory.impact,
verify no existing story uses a value that was removed. If any do, flag them so the user can update those stories.
- After changing
queueAudit.scalethresholds, the next
doccraft-queue-audit run will use the new limits — no further action needed.
- After adding or removing an
extensionsentry, remind the user to
run doccraft update to bake fragments into skill bodies.
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: alexpialetski
- Source: alexpialetski/doccraft
- License: MIT
- Homepage: https://www.npmjs.com/package/doccraft
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet — be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.