惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

T
The Exploit Database - CXSecurity.com
V
Vulnerabilities – Threatpost
Google DeepMind News
Google DeepMind News
Attack and Defense Labs
Attack and Defense Labs
Webroot Blog
Webroot Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
TaoSecurity Blog
TaoSecurity Blog
I
Intezer
Application and Cybersecurity Blog
Application and Cybersecurity Blog
N
News | PayPal Newsroom
S
Security Affairs
T
Tor Project blog
P
Proofpoint News Feed
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
S
Security @ Cisco Blogs
H
Heimdal Security Blog
Hacker News: Ask HN
Hacker News: Ask HN
Help Net Security
Help Net Security
U
Unit 42
云风的 BLOG
云风的 BLOG
The Hacker News
The Hacker News
Cisco Talos Blog
Cisco Talos Blog
量子位
F
Full Disclosure
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
博客园 - 叶小钗
有赞技术团队
有赞技术团队
T
Troy Hunt's Blog
P
Privacy & Cybersecurity Law Blog
Forbes - Security
Forbes - Security
人人都是产品经理
人人都是产品经理
L
Lohrmann on Cybersecurity
Apple Machine Learning Research
Apple Machine Learning Research
Microsoft Security Blog
Microsoft Security Blog
博客园 - Franky
腾讯CDC
AI
AI
Last Week in AI
Last Week in AI
Latest news
Latest news
Google Online Security Blog
Google Online Security Blog
N
Netflix TechBlog - Medium
Engineering at Meta
Engineering at Meta
GbyAI
GbyAI
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
IT之家
IT之家
Martin Fowler
Martin Fowler
Blog — PlanetScale
Blog — PlanetScale
V2EX - 技术
V2EX - 技术
酷 壳 – CoolShell
酷 壳 – CoolShell

Hacker News: Show HN

PurrrrrFocus: Pomodoro Timer App - App Store Workflow Engine — Multi-Step Orchestration for Bun RapidPhoto: Pro Photo Editor App - App Store GitHub - DheerG/swarms: Achieve extraordinary results with claude code across a variety of tasks SPICE simulation → oscilloscope → verification with Claude Code — Lucas Gerads Show HN: VCoding – A 5 MB native Windows IDE with no dynamic dependencies Show HN: LLMs don't hallucinate because they're bad at math, it's the format GitHub - Agent-FM/agentfm-core: AgentFM is a peer-to-peer network that turns everyday computers into a decentralized AI supercomputer. AgentFM lets you run massive AI workloads directly across a global mesh of idle CPUs and GPUs. Show HN: Tracking Top US Science Olympiad Alumni over Last 25 Years GitHub - Potarix/agent-hub: One place to talk to all your agents Show HN: Runtime security for AI agents(injection,tool abuse, data exfiltration) GitHub - dubeyKartikay/lazyspotify: Terminal Spotify client for macOS and Linux GitHub - the-banana-tool/king-louie: Easy to use GUI Personal AI Assistant. Win/Linux/Mac. Show HN I made my vacation rental bookable by AI agents–no Airbnb, 0% commission GitHub - basteez/jsf-autoreload: maven plugin to enable hot reload on jsf projects uvm32/hosts/host-gdbstub at main · ringtailsoftware/uvm32 GitHub - labsai/EDDI: Config-driven engine that turns JSON into production-grade AI agents. Multi-agent orchestration, 12+ LLM providers, MCP/A2A protocols, RAG, persistent memory, and enterprise compliance (EU AI Act, GDPR, HIPAA). Built on Quarkus. GitHub - glitchnsec/fortyone-oss: AI Executive Assistant Platform Quickstart | Alien GitHub - muxshed/shed: One stream in, or many. Every destination, simultaneously. No cloud middleman, no per-channel fees, no limits. GitHub - ocrbase-hq/ocrbase: 📄 PDF/IMG ->.MD/JSON Document OCR API for PaddleOCR and GLMOCR. Self-hostable. GitHub - impactjo/home-memory: MCP server that lets your AI assistant remember everything about your home. GitHub - Sets88/dbcls: DbCls is a powerful terminal database client that supports various databases GitHub - neptun2000/heor-agent-mcp GitHub - SeanFDZ/macmind: Single-layer transformer in HyperTalk for the classic Macintosh RollQuation: Math Puzzles - Apps on Google Play GitHub - dropbox/witchcraft Show HN: Agent-cache – Multi-tier LLM/tool/session caching for Valkey and Redis GitHub - opentalon/opentalon: OpenTalon is an open-source platform built from the ground up in Go as a robust alternative to OpenClaw LinkedIn™ 职位抓取工具 - Chrome 应用商店 GitHub - EdoardoBambini/Agent-Armor-Iaga: AI agents are getting tool access — shell, file system, databases, APIs, secrets. But **nobody is governing what they actually do with it**. Frameworks like LangChain, CrewAI, AutoGen, and Claude Code give agents the power to execute. Agent Armor gives you the power to control, audit, and approve every single action before it happens. HN Vibes — Week 15, Apr 7–13 2026 GitHub - chojs23/ec: Easy terminal-native 3-way git mergetool vim-like workflow GitHub - SethPyle376/hiraeth: Local AWS emulator focused on fast integration testing, with SQS support, SQLite-backed state, and a debug-friendly web UI. GitHub - JakOb-dotcom/cloud-sandbox-security-analysis: Technical analysis and Proof of Concept (PoC) regarding environment variable exfiltration in containerized cloud sandboxes via side-channel data leaks. Springboards - Flint Alpha Show HN: A simpler coding agent harness GitHub - audiodude/sudomake-friends GitHub - 256thFission/mini-mythos: OSS clone of Anthropic’s Mythos harness to locate C/C++ memory vulnerabilities Show HN: OpenParallax: OS-level privilege separation for AI agent execution Hacker News Sorted - Chrome 应用商店 Show HN: How to Install Docker on Ubuntu 24.04 LTS: Complete 2026 Guide GitHub - himanshudongre/smriti GitHub - sverrirsig/claude-control: macOS desktop dashboard for monitoring and managing multiple Claude Code sessions GitHub - ory/dockertest: Write better integration tests! Dockertest helps you boot up ephermal docker images for your Go tests with minimal work. Chiral - Chrome 应用商店 Show HN: Two Claudes collaborating through shared memory on a $100 mini-PC GitHub - pmichaillat/latex-cv: Minimalist LaTeX template for academic CVs GitHub - oguzbilgic/posse: A web UI for Anthropic Managed Agents. GitHub - sshiraz/depsly: Dependency risk analysis tool for npm packages ABI Add safari/agent-harness — Safari browser automation via safari-mcp by achiya-automation · Pull Request #212 · HKUDS/CLI-Anything GitHub - Halfblood-Prince/trustcheck: Verify PyPI package attestations and improve Python supply-chain security GitHub - oguzbilgic/kern-ai: Agents that do the work and show it. GitHub - bruits/satteri: High-performance Markdown and MDX processing for the JavaScript ecosystem GitHub - tylergibbs1/feedstock: High-performance web crawler and scraper for TypeScript, powered by Bun and Playwright GitHub - Grimm67123/grimmbot: The self-improving sandboxed and open-source AI agent. With persistent memory and scheduling. GitHub - whitevanillaskies/whitebloom: Local whiteboard that blooms. GitHub - hwdsl2/docker-whisper: Docker image for a self-hosted Whisper speech-to-text server with speaker diarization and OpenAI-compatible transcription and translation APIs. Powered by faster-whisper. Supports all Whisper models, NVIDIA GPU (CUDA) acceleration, JSON/SRT/VTT output, SSE streaming, offline mode, and multi-arch (amd64, arm64). GitHub - yisding/reviewwiggum GitHub - MarwanAlsoltany/serrors: Structured errors for Go: sentinel hierarchies, typed data, custom formatting, and slog integration. GitHub - soatok/age-php GitHub - Luthiraa/markitme GitHub - stagas/rtdiff: realtime git diff gui and AI-assisted commits GitHub - tombedor/excalicharts GitHub - wh1le/excalidraw-edit: Open and edit .excalidraw files from the terminal. Offline, auto-saves to disk. MalExt Sentry - Malicious Extension Scanner - Chrome 应用商店 GitHub - syi0808/asciianimesvg: Generate animated ASCII art SVGs from text. CLI, Rust library, WASM, and web editor. GitHub - zaina-ml/ml_forge: A visual-based graph node editor for training computer vision models. GitHub - anakin87/llm-rl-environments-lil-course: 🌱 A little course on Reinforcement Learning Environments for evaluating and training Language Models GitHub - takaakit/superpowers-uml: Superpowers-UML modifies Superpowers to ensure a software development workflow in which AI agents design through UML modeling. AdriByte Studio - Sviluppo Web e Soluzioni Digitali GitHub - chouligi/angel-copilot: Your personalized Angel Investment Advisor Show HN: MoodSense AI (ML and FastAPI and Gradio, Deployed on Hugging Face) Moodsense Ai - a Hugging Face Space by aman179102 GitHub - agenteractai/lodmem: Level Of Detail Context Management for Agents GitHub - ostefani/subnetlens: A fast, concurrent network scanner with a TUI and plain-text CLI, built in Go. It discovers live hosts on your network, scans their open ports, resolves hostnames, and fingerprints operating systems—delivered. Cyber Pulse: Agentic Intel - Apps on Google Play Whisper API: Self-Hostable Speech to Text Transcription The Agent-Web Protocol Stack: A Research Thesis GitHub - msmarkgu/RelayFreeLLM: A restful API designed to route user prompts to various AI model providers. Show HN: Provepy – A Python decorator that proves your code using Lean and LLMs Show HN: Pardonned.com – A searchable database of US Pardons GitHub - patrickdappollonio/dux: Dux is a terminal UI that lets you run multiple AI coding agents side by side, each in its own git worktree, with full companion terminals, macros, commit generation, and a command palette that knows more tricks than you do. kMC Crystal Simulator Show HN: HyperFlow – A self-improving agent framework built on LangGraph GitHub - stef41/vibescore: 🎵 Grade your vibe-coded project. One command, instant letter grade across security, quality, dependencies, and testing. GitHub - stef41/lmscan: 🔍 Detect AI-generated text and fingerprint which LLM wrote it. Open-source GPTZero alternative. Zero dependencies, works offline. imgur.com GitHub - visionscaper/collabmem: Enabling long-term collaboration with Agentic AI - building up episodic and world model memory over time with in-context awareness 在 Steam 上购买 FriedrichAI: Offline AI 立省 10% GitHub - atripati/ark: AI Runtime Kernel — a context operating system for AI agents. Eliminates tool bloat, loads only what’s needed, and gives LLMs their reasoning space back. GitHub - nowork-studio/toprank: Open-source Claude Code skills for SEO, SEM, Google Ads GitHub - tacomanator/sash: Lightweight macOS menu bar app for reliably cycling through windows of the current application. Appents | Social Media Management for Product-First Teams GitHub - pnhoang/youtube-spam-blocker: Automatically detects and hides spam messages in YouTube Live chat. Set rate limits, keyword filters, and block repeat offenders. GitHub - decisionnode/DecisionNode: CLI + Local MCP - A shared structured memory store across Claude Code, Cursor, Windsurf, Antigravity, and every MCP client. Semantically queryable. GitHub - AvaCodeSolutions/django-email-learning: An open source Django app for creating email-based learning platforms with IMAP integration and React frontend components. The $100K Gap in Kubernetes Security Tooling Function Calling Harness: From 6.75% to 100%
GitHub - idodekerobo/draft-cli-plugin: The Draft PM Agent CLI Agent Plugin
idodekerobo · 2026-05-10 · via Hacker News: Show HN

Draft — Claude Code + Codex CLI + Cursor

Draft is a PM brain for Claude Code, Codex CLI, and Cursor. Install it once, run /setup, and every session starts with full product context — no re-explaining required.

Platform support: macOS and Linux only. The plugin's session hook is a bash script and requires a POSIX shell environment. Windows (including WSL) is untested and not currently supported.


Quick start

Claude Code

/plugin marketplace add idodekerobo/draft-cli-plugin
/plugin install draft
/draft:setup

Codex

curl -fsSL https://raw.githubusercontent.com/idodekerobo/draft-cli-plugin/main/scripts/codex-setup.sh | bash

Restart Codex, then run:

$draft-setup

Cursor

curl -fsSL https://raw.githubusercontent.com/idodekerobo/draft-cli-plugin/main/scripts/cursor-setup.sh | bash

Restart Cursor. Your product context loads automatically into every new Composer session — no action needed. If this is your first time using Draft, run /draft-setup in the Agent tab.


Why Draft

You open a new Claude session. It doesn't know what you shipped last week. It doesn't know you changed the ICP. It doesn't know you dropped that feature. You're back to square one — again.

That's the default. Every session starts blank.

Draft fixes two things that make this worse over time:

Context amnesia — the blank slate problem. Without Draft, you're re-explaining your product, your stack, your priorities at the start of every session. It's not just annoying — it means Claude is reasoning from whatever scraps you happened to paste in, not from a real picture of what you're building. Draft's session hook injects a live snapshot of your full product context (company, product, team, priorities, memory) before you type a single word.

Context rot — the slow decay problem. Even if you have a CLAUDE.md or context files, they go stale. You shipped something, changed direction, dropped a bet — and your docs still describe the old world. The longer you work, the more your context diverges from reality. Claude is confidently reasoning from a version of your product that no longer exists.

Draft solves this with an append-only log and a persistent index of recent changes. Every time something meaningful happens — a decision, a scope change, something shipped or dropped — draft-learner logs it and updates the index. That index loads in every session automatically. So even if your full context documents haven't been touched in weeks, the session always knows what just happened.

The feeling: your AI tool behaves like a collaborator who was in every previous session — not a new hire you brief from scratch each time.


Installation

Claude Code

Option 1 — Plugin marketplace (recommended):

/plugin marketplace add idodekerobo/draft-cli-plugin
/plugin install draft

Then run the setup interview:

/draft:setup

Option 2 — Local install (for testing/development):

claude --plugin-dir ./draft-cli-plugin
/draft:setup

The plugin's SessionStart hook handles everything else automatically on first launch.


Codex

This is a direct install, not a Codex plugin. The setup script writes directly into your ~/.codex/ directory — no plugin marketplace involved.

Option 1 — curl (no clone needed):

curl -fsSL https://raw.githubusercontent.com/idodekerobo/draft-cli-plugin/main/scripts/codex-setup.sh | bash

Option 2 — from a local clone:

bash ./scripts/codex-setup.sh

The script installs seven things:

  1. Creates ~/.draft/workspace/ with a blank context/memory structure
  2. Installs inject-context.sh to ~/.codex/hooks/draft/
  3. Registers the SessionStart hook in ~/.codex/hooks.json
  4. Enables the codex_hooks feature flag in ~/.codex/config.toml
  5. Installs sub-agent TOML files to ~/.codex/agents/
  6. Writes pm-agent instructions to ~/.codex/AGENTS.md
  7. Installs the $draft-setup skill to ~/.agents/skills/draft-setup/SKILL.md

After the script completes, restart Codex, then run:

$draft-setup

Note on $ prefix: $draft-setup is how Codex invokes skills. The $ prefix is Codex-specific — slash commands (like /draft:setup) are Codex built-ins only and cannot be extended by external installs.

To uninstall:

bash ./scripts/codex-uninstall.sh

Cursor

This is a direct install into ~/.cursor/. The setup script is smart about what it installs — if the Claude Code or Codex plugin is already installed, it skips anything that would create a duplicate PM brain in Cursor's context (see Multi-editor setup below).

Option 1 — curl (no clone needed):

curl -fsSL https://raw.githubusercontent.com/idodekerobo/draft-cli-plugin/main/scripts/cursor-setup.sh | bash

Option 2 — from a local clone:

bash ./scripts/cursor-setup.sh

The script installs:

  1. Creates ~/.draft/workspace/ if it doesn't already exist
  2. Installs cursor-session-start.sh to ~/.cursor/hooks/draft/
  3. Registers the sessionStart hook in ~/.cursor/hooks.json
  4. [If no Claude Code/Codex plugin] Installs draft-context.mdc to ~/.cursor/rules/
  5. [If no Claude Code plugin] Installs sub-agents to ~/.cursor/agents/
  6. Installs the /draft-setup skill to ~/.cursor/skills/ and ~/.agents/skills/

After the script completes, restart Cursor. Your product context will be automatically injected into every new Agent tab (Composer) session — you don't need to do anything. The injection happens silently in the background via the sessionStart hook.

If this is a fresh Draft install, open the Agent tab and run:

/draft-setup

To uninstall:

bash ./scripts/cursor-uninstall.sh

Keeping Draft up to date

Draft checks for updates automatically in the background on every session start. When a new version is available, your pm-agent will mention it at the start of your next session and offer to apply the update.

Check and apply an update

Claude Code:

/draft:update

Codex:

$draft-update

Cursor:

/draft-update

The update command shows what version you're on, what's available, and asks for confirmation before doing anything. It downloads the new files, updates your install, and tells you what changed. You'll need to restart your session for changes to take effect.

The update never touches your PM brain data at ~/.draft/workspace/ — only the plugin files themselves are updated.

How version tracking works

  • Your installed version is recorded at ~/.draft/version when you first install
  • The update check fetches the latest VERSION from the GitHub repo and compares (runs in background, cached for 60–720 minutes)
  • The update script re-downloads files at the exact tagged release version — no moving targets

Release workflow (for contributors)

# Bump VERSION and .claude-plugin/plugin.json, then:
git tag v1.x.x && git push origin v1.x.x
gh release create v1.x.x --title "v1.x.x" --notes "..."

How it works

Agent architecture

Draft uses an orchestrator + three sub-agents pattern. The pm-agent is the main thread — it handles all PM work and delegates to specialists.

Agent Role
pm-agent Orchestrator. Owns all PM behavior. Delegates to the three agents below.
draft-researcher Need to KNOW something — reads workspace files, fetches web content
draft-executor Need to DO something — writes PRDs, decision docs, updates files
draft-learner Need to REMEMBER something — updates context files, logs decisions

Most requests follow: draft-researcher gathers context → draft-executor acts → draft-learner saves. You can also invoke draft-learner directly — run /draft:learn anytime to capture a decision, scope change, or anything worth remembering outside of a full PM session.


Slash commands

Draft ships two slash commands (skills). Both are auto-discovered by Claude Code, and manually installed by the Codex and Cursor setup scripts.

/draft:setup ($draft-setup on Codex, /draft-setup on Cursor)

Runs the PM brain initialization interview. Ask it once at install, or again after a significant product shift. See Quick start.


/draft:learn ($draft-learn on Codex, /draft-learn on Cursor)

Manually tells Draft to remember something — a decision you made, a priority that shifted, a term your team uses, anything worth persisting to your workspace. You can call it three ways:

1. No arguments — conversational

/draft:learn

Draft asks one question: "What did you learn or decide?" You answer, it figures out where to write it, confirms what it saved.

Best when: you want to capture something but haven't formed it into a statement yet.


2. Free-form statement

/draft:learn we decided to drop the bridge daemon and go plugin-only

Draft reads the statement, classifies the type of learning (decision, priority shift, product direction, company update, team change, or preference), routes it to the right file(s), and confirms. It will only ask a clarifying question if the classification is genuinely ambiguous — most statements are clear enough to route automatically.

Best when: you know what you want to save and just want to say it.


3. Explicit tag

/draft:learn [decision] drop the bridge daemon
/draft:learn [priority] bridge daemon is now deferred
/draft:learn [product] ICP is now "the curator" — one high-agency PM who owns source of truth
/draft:learn [vocab] "builders" = PMs and founders using Claude Code

The tag tells Draft exactly where to write without any inference. Supported tags: [decision], [priority], [product], [company], [team], [memory], [pref], [vocab].

Best when: you know the type and want the fastest, most predictable path.


What gets written and where

Learning type Destination Log entry?
[decision] context/decisions/{slug}.md No (plus any affected index files)
[priority] context/priorities/index.md Yes
[product] context/product/index.md Yes
[company] context/company/index.md Structural changes only
[team] context/team/index.md Structural changes only
[memory] / [pref] / [vocab] memory/memory.md No

A single learning can map to multiple files. "We decided to cut the bridge daemon" writes a decision file, updates context/product/index.md, and updates context/priorities/index.md — because all three reflect the new reality.

Claude Code

settings.json activates draft:pm-agent as the main Claude Code thread. Every session opens with the pm-agent system prompt rather than the default Claude Code prompt.

Codex

~/.codex/AGENTS.md contains the pm-agent instructions and loads as persistent context for every Codex session. Sub-agents are installed as custom agent .toml files in ~/.codex/agents/.

Cursor

~/.cursor/rules/draft-context.mdc (installed with alwaysApply: true) contains the pm-agent instructions and is injected into every Agent tab session. Sub-agents are available in ~/.cursor/agents/ and invocable by name in the Agent tab. When Claude Code is also installed, Cursor reads ~/.claude/agents/ directly and draft-context.mdc is skipped to avoid duplication.


Context loading

There are two layers of context loaded at session start:

1. Agent system prompt — static

The pm-agent's instructions define:

  • PM role and orchestration behavior
  • Delegation rules and when to use each sub-agent
  • Document writing flow and template selection
  • Context staleness policy (7-day / 21-day)
  • Proactive memory rules and what's worth persisting
  • Onboarding detection (auto-starts setup interview if no context exists)

2. Workspace context — dynamic

Injected on every session start via hook. Outputs a live snapshot of:

Section What it contains
Workspace structure Two-level directory listing of context/
Context index Frontmatter from each context/*/index.md: name, description, last_updated, source
Current priorities Full context/priorities/index.md
Memory Full memory/memory.md — vocabulary, preferences, patterns, goals

The pm-agent uses this as its orientation layer. When a task needs more detail than the frontmatter provides, it reads the relevant file in full.

Editor Hook mechanism Output format
Claude Code SessionStartinject-context.sh Raw text into session context
Codex SessionStartinject-context.sh Raw text as developer context
Cursor sessionStartcursor-session-start.sh { "additional_context": "..." } JSON into initial system context

Session lifecycle

Claude Code — first session (after install)

  1. SessionStart hook fires → runs scripts/session-init.sh
  2. Workspace bootstrap (guarded — runs once): copies workspace-template/~/.draft/workspace/
  3. ~/.claude/settings.json updated (guarded — runs once): sets DRAFT_WORKSPACE env var, adds ~/.draft/workspace to additionalDirectories, grants Read/Write/Edit for ~/.draft/**
  4. Settings take effect on the next session start

Claude Code — every subsequent session

  1. session-init.sh guards pass, exits in <10ms
  2. inject-context.sh runs — outputs live workspace snapshot into session context
  3. draft:pm-agent activates as main thread
  4. pm-agent is oriented: context dimensions, freshness, priorities, memory

Codex — after running codex-setup.sh

  1. SessionStart hook fires → inject-context.sh runs, outputs workspace snapshot as developer context
  2. ~/.codex/AGENTS.md (pm-agent instructions) loads as persistent context
  3. pm-agent is oriented and ready

Cursor — after running cursor-setup.sh

  1. New Agent tab (Composer) session opens
  2. sessionStart hook fires → cursor-session-start.sh runs silently in the background
  3. Workspace snapshot injected as initial system context via additional_context
  4. draft-context.mdc rule loaded (if Claude Code plugin is not also installed)
  5. pm-agent is oriented and ready — context loads before you type your first message

Multi-editor setup

Draft's workspace at ~/.draft/workspace/ is shared across all editors. Running setup for multiple editors does not create multiple workspaces — it just connects each editor to the same PM brain.

If you use Claude Code + Cursor: Run claude plugin install first, then cursor-setup.sh. The Cursor setup script detects the Claude Code plugin and skips installing duplicate rules and sub-agents. Cursor reads ~/.claude/agents/ natively.

If you use Codex + Cursor: Run codex-setup.sh first, then cursor-setup.sh. The Cursor setup script detects ~/.codex/AGENTS.md and skips the rules install. Sub-agents are still installed to ~/.cursor/agents/ since Cursor does not read ~/.codex/agents/ natively.

If you use all three: Claude Code install first, then Codex, then Cursor. Cursor will use Claude Code's agents and skip its own rules install.


Plugin structure

draft-cli-plugin/
├── .claude-plugin/
│   ├── plugin.json               Claude Code plugin manifest
│   └── marketplace.json          Plugin marketplace catalog
├── .codex/
│   ├── AGENTS.md                 pm-agent instructions for Codex (→ ~/.codex/AGENTS.md)
│   └── agents/
│       ├── draft-researcher.toml Codex sub-agent definition
│       ├── draft-executor.toml   Codex sub-agent definition
│       └── draft-learner.toml    Codex sub-agent definition
├── .cursor/
│   ├── hooks.json                In-repo Cursor hooks config (dev use)
│   └── rules/
│       └── draft-context.mdc     pm-agent instructions for Cursor (→ ~/.cursor/rules/)
├── .cursor-plugin/
│   └── plugin.json               Cursor marketplace manifest (pending submission)
├── agents/
│   ├── pm-agent.md               Orchestrator agent (Claude Code + Cursor)
│   ├── draft-researcher.md       Researcher sub-agent
│   ├── draft-executor.md         Executor sub-agent
│   └── draft-learner.md          Learner sub-agent
├── skills/
│   ├── draft-setup/SKILL.md      Onboarding interview skill
│   └── draft-learn/SKILL.md      Manual learning capture skill
├── hooks/
│   └── hooks.json                Claude Code SessionStart hooks config
├── scripts/
│   ├── session-init.sh           Claude Code — guarded bootstrap + settings config
│   ├── inject-context.sh         Claude Code + Codex — context injection hook
│   ├── cursor-session-start.sh   Cursor — context injection hook (JSON output)
│   ├── codex-setup.sh            Codex — one-time setup
│   ├── codex-uninstall.sh        Codex — removes everything codex-setup.sh installed
│   ├── cursor-setup.sh           Cursor — one-time setup
│   └── cursor-uninstall.sh       Cursor — removes everything cursor-setup.sh installed
├── workspace-template/           Blank workspace, copied to ~/.draft/workspace on first run
│   ├── CLAUDE.md
│   ├── context/
│   │   ├── company/index.md
│   │   ├── product/index.md
│   │   ├── priorities/index.md
│   │   ├── team/index.md
│   │   ├── user/index.md
│   │   ├── decisions/            (empty — populated as decisions are made)
│   │   └── tensions.md
│   ├── docs/                     (empty — written artifacts live here)
│   └── memory/
│       └── memory.md
├── README.md
└── CHANGELOG.md

Workspace layout

All editors share the same workspace at ~/.draft/workspace/:

~/.draft/workspace/
├── context/
│   ├── company/index.md + log/
│   ├── product/index.md + log/
│   ├── user/index.md
│   ├── team/index.md + log/
│   ├── priorities/index.md + log/
│   ├── decisions/                 ← all decisions, one file per decision
│   └── tensions.md
├── memory/
│   └── memory.md
└── docs/                          ← written artifacts: analyses, PRDs, strategies
    YYYYMMDDHHMMSS_slug.md         (flat — no subdirectories)

The workspace lives outside ~/.claude/, ~/.codex/, and ~/.cursor/ intentionally — it's editor-agnostic and shared across all three.


Path conventions

Variable Resolves to Set by
$DRAFT_WORKSPACE ~/.draft/workspace session-init.sh (Claude Code) / codex-setup.sh (Codex) / cursor-setup.sh (Cursor)

Testing locally

Claude Code

# Load the plugin for a single session
claude --plugin-dir ./draft-cli-plugin

# Verify settings were written after first session
cat ~/.claude/settings.json | python3 -m json.tool

# Run setup
/draft:setup

# Verify workspace
ls ~/.draft/workspace/

Codex

# Run the setup script from the plugin repo
bash ./scripts/codex-setup.sh

# Verify hook was registered
cat ~/.codex/hooks.json | python3 -m json.tool

# Verify agents were installed
ls ~/.codex/agents/

# Verify AGENTS.md was written
head -5 ~/.codex/AGENTS.md

# Verify the skill was installed
ls ~/.agents/skills/

# Restart Codex, then run setup
$draft-setup

# To uninstall
bash ./scripts/codex-uninstall.sh

Cursor

# Run the setup script from the plugin repo
bash ./scripts/cursor-setup.sh

# Verify hook was registered
cat ~/.cursor/hooks.json | python3 -m json.tool

# Verify the session-start script outputs valid JSON
bash ~/.cursor/hooks/draft/cursor-session-start.sh

# Verify sub-agents were installed (if Claude Code plugin is not present)
ls ~/.cursor/agents/

# Verify rules file was installed (if Claude Code plugin is not present)
ls ~/.cursor/rules/

# Verify the skill was installed
ls ~/.cursor/skills/

# Restart Cursor — context loads automatically in every new Agent tab session
# If fresh install, run /draft-setup in the Agent tab

# To uninstall
bash ./scripts/cursor-uninstall.sh