pwf-doc

pwf-doc is a command for Claude Code from J-Pster/Psters_AI_Workflow. It costs 161 tokens per session (2,802 once invoked), scanned A, original, MIT.

A command for creating or updating technical documentation for specific parts of a software project, such as serverless functions, backend modules, frontend features, system architecture, or design decisions.

In plain words
What is it for?
Use it to document one Lambda function, a group of Lambdas, a backend module, a frontend feature, the overall system design, or to check documents for outdated or contradictory information.
Why use it?
It gives documentation work a clear scope and helps keep existing documents up to date instead of creating conflicting copies.

Command for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Good fit Use it to document one Lambda function, a group of Lambdas, a backend module, a frontend feature, the overall system design, or to check documents for outdated or contradictory information.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/j-pster/psters_ai_workflow/pwf-doc
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/J-Pster/Psters_AI_Workflow

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pwf-doc

README.md
[![agentmods](https://agentmods.dev/badge/commands/j-pster/psters_ai_workflow/pwf-doc.svg)](https://agentmods.dev/commands/j-pster/psters_ai_workflow/pwf-doc)
Your own site
<a href="https://agentmods.dev/commands/j-pster/psters_ai_workflow/pwf-doc"><img src="https://agentmods.dev/badge/commands/j-pster/psters_ai_workflow/pwf-doc.svg" alt="Measured on agentmods" height="20"></a>
Per session 161 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,802 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00161 $0.02802
Opus 5 $0.00081 $0.01401
Sonnet 5 $0.00032 $0.00560
Haiku 4.5 $0.00016 $0.00280

Measured 9d ago against content hash a6a1092e803e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

pwf-doc scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/psters-ai-workflow/commands/pwf-doc.md · 268 lines

How it starts

The opening of the file, as written. The whole thing — 268 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Force Technical Documentation by Scope

Note: The current year is 2026.

Use this command when you want explicit technical documentation output for a specific scope (module, feature, architecture, ADR, or global update). This is the general command to generate or update any documentation by described scope.

Work commands already update docs. /pwf-work, /pwf-work-plan, /pwf-work-light, and /pwf-work-tdd update docs as part of their workflow. Use /pwf-doc for explicit, scope-targeted documentation beyond that flow.

Anti-drift guidance: Before creating new docs, check if a related doc already exists. Prefer updating or syncing the existing doc instead of creating duplicates. This avoids drift and keeps documentation authoritative.

The living documentation lives in:

  • docs/lambdas/ — Lambda and processor repos
  • docs/modules/ — NestJS backend modules (or equivalent)
  • docs/features/ — Angular frontend features (or equivalent)
  • docs/decisions/ — Architecture Decision Records (ADRs)
  • docs/architecture.md — System-wide architecture overview

Input

<doc_target> #$ARGUMENTS </pwf-doc_target>

If empty, show:

Usage:
  /pwf-doc lambda <repo-name>      Document a Lambda repo     (e.g. /pwf-doc lambda email-classifier-lambda)
  /pwf-doc lambdas                 Document ALL Lambda repos in parallel
  /pwf-doc module <module-name>    Document a backend module   (e.g. /pwf-doc module projects)
  /pwf-doc feature <feature-name>  Document a frontend feature (e.g. /pwf-doc feature dashboard)
  /pwf-doc architecture            Generate/update docs/architecture.md
  /pwf-doc update                  Scan all docs for staleness and contradictions
  /pwf-doc adr "<decision>"        Create an Architecture Decision Record
  /pwf-doc custom "<target-and-pattern>"  Generate/update any doc from user-described scope
  /pwf-doc infrastructure          Generate/update docs/infrastructure.md

Agent invocation

When spawning docs agents via Task tool, use collision-safe naming: psters-ai-workflow:docs:<agent-name>.

Read the full file on GitHub · 268 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 268 lines · 161 tokens per session scan A a6a1092e803e

Subscribe to this mod's changes

pwf-doc is a command published in the GitHub repository J-Pster/Psters_AI_Workflow (289 stars, last pushed 5mo ago), licensed MIT. It adds 161 tokens to every session and 2,802 once invoked, about $0.0008 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.