pstack makes agents check their work. That's not the same as safe code
pstack wraps a coding agent in playbooks, principle files and a verification step. The verification step is worth having. Whether the code it ships is any safer has still not been measured.
pstack wraps an AI coding agent in written procedures: playbooks, principle files, and a step that makes the agent check its own work before it says it's done. I'd keep the checking step. I'm less sure about the shelf of principles, and nothing published yet shows the code that comes out is safer to ship. What would settle it is a defect or vulnerability rate for a pstack agent against the same agent without it. Nobody has measured that.
pstack is a free plugin by Lauren Tan, under the MIT licence. It installs in Cursor, and also in Claude Code. As of late November 2026 it is at version 0.15.48 with 59 skills and two specialist subagents1. Skills here are written instructions the agent loads when a task calls for them. At the centre is a router called /poteto-mode. It reads your request, picks one of twenty-two playbooks, and copies that playbook's steps into a to-do list1. Around it sit 24 principle files describing what good work looks like. The project moves fast. In October it had 56 skills and twenty-three playbooks.
The part I like is what happens at the end of a task. Setup offers to generate a verification skill for your project, a check the agent has to run, and it proves the check works once before handing it over2. The guide is honest about the cost. It says pstack "spends extra tokens on subagents and review panels" and calls that "the price of the rigor"2. Its argument is that an agent that can check its own work keeps going until the check passes, and one that can't hands every result back to you to check by hand2. I agree with that. A check that runs is deterministic. A paragraph about good engineering is not.
The best controlled evidence on written rules is a preprint called "Guardrails Beat Guidance". The authors scraped 679 rule files holding 25,532 rules and ran more than 5,000 agent runs on SWE-bench Verified, a set of real GitHub issues3. In the main test on 58 tasks, every rule condition beat the no-rule baseline of 50.0%, by 6.9 to 13.8 percentage points3. Randomly chosen rules and carefully curated ones both scored 63.8%.
SWE-bench Verified pass rate on 58 tasks, one model (Claude Opus 4.6), main experiment only ("Guardrails Beat Guidance", arXiv preprint, v2 May 2026).
Read that chart carefully. The authors say none of the conditions differed significantly from each other, and the gain for any single condition does not reach statistical significance on its own3. The headline rests on all seven conditions pointing the same way. Testing rules one at a time, they found the three that shaped behaviour were all prohibitions, such as "do not refactor unrelated code", and the four that distorted it were all positive instructions3. Removing that one prohibition cost 20 points, though the authors note it would not survive a strict correction for running 18 tests3. It is one model, it is not peer reviewed, and it measures whether the task passed, not whether the code was secure.
That matters for pstack, because most of its bulk is the shape that did no better than random: principle files telling the agent what good looks like. I'd also be careful about leaning on "prohibitions work". A November study of AGENTS.md files found compliance swung from 0% to 78% depending on the model, the harness and how the policy was worded. For Claude Sonnet 5 in Claude Code, "do not" wording was followed least, 17.3% of the time4. Another study found agents followed an out-of-date instruction file in 90.1% of their choices, even when the code said otherwise. Adding one sentence telling the agent to trust the code over the file fixed most of it5. Written instructions are followed, sometimes too well and sometimes barely. That is a weak base for safety.
The hands-on evidence for pstack itself is thin. The Neuron reported a test by Rob O'Shaughnessy (Rob Shocks on YouTube), who built the same project with and without it. The pstack run took about an hour against about thirty minutes, its checks caught three claims the agent had made up, and he preferred the result6. That is a useful anecdote about trust. It doesn't count defects. The Neuron also says Cursor engineers used Tan's skills 10,000 times in a single week before release6. That is usage, and it gives no source.
The security numbers are moving, slowly. In July 2026 Veracode said AI-generated code had stalled at a 56% security pass rate across more than 100 models and four testing snapshots7. On 29 October it reported the first real gain, an average of 62% across 18 models, driven mostly by one class of bug, cross-site scripting, with the weakest models still at 44 to 50%8. Both measure model output, not an agent configured with a plugin. At company scale, the Cloud Security Alliance cites Apiiro data showing monthly security findings at Fortune 50 firms rising from about 1,000 to more than 10,000 between December 2024 and June 20259. The same note covers hidden-Unicode injection into rule files9, which is worth remembering when your safety layer is a folder of text files the agent obeys.
So I'd keep the harness and treat the shelf as unproven. A verification skill turns "the build passed" into a test the agent must satisfy, and that's the kind of control I trust. What would change my view is a measured defect or vulnerability rate for pstack-style agents against a matched plain agent. Follow rates now exist. That number still doesn't.
Nothing here is financial, legal or investment advice. Every figure is published by its named source and carries the date it was published; figures may since have changed.
References
-
Cursor, pstack README (GitHub, version 0.15.48, accessed 27 November 2026) ↑
-
Lauren Tan, pstack guide: Set up pstack (GitHub, accessed 27 November 2026) ↑
-
Zhang et al., Guardrails Beat Guidance: A Large-Scale Study of Rules, Skills, and Persistent Configuration for Coding Agents (arXiv, v1 13 April 2026, v2 28 May 2026) ↑
-
Tsuchida et al., Do Coding Agents Follow AGENTS.md? The Effect of Policy Wording on Instruction Compliance (arXiv, 3 November 2026) ↑
-
Xu and Wu, Stale Instruction Files Override the Code in Coding Agents: A One-Sentence Fix (arXiv, 22 October 2026) ↑
-
The Neuron, pstack explained: Lauren Tan's system for trustworthy AI agents (10 September 2026) ↑
-
Veracode, LLMs Are Getting Smarter, But Not Safer: Veracode 2026 GenAI Code Security Report Finds AI-Generated Code Security Has Stalled at 56% Pass Rate (28 July 2026) ↑
-
Veracode, Veracode Finds First Meaningful Gain in AI Code Security Since 2025 as Average Pass Rate Hits 62% (29 October 2026) ↑
-
Cloud Security Alliance, Vibe Coding's Security Debt: The AI-Generated CVE Surge (4 April 2026) ↑