open-pencil AGENTS.md

open-pencil AGENTS.md is an instructions file for Codex, OpenCode from open-pencil/open-pencil. It costs 5,082 tokens per session, scanned A, original, MIT.

Project instructions for OpenPencil, a Vue-based design editor that uses a monorepo, meaning one repository containing several related software packages. They describe its packages, exports, architecture, and settings.

In plain words
What is it for?
Use them when developing OpenPencil’s scene graph, file-format support, rendering, layout, editor tools, documentation, or public package exports.
Why use it?
They give coding agents the project-specific terminology and boundaries needed to change the right package without breaking shared interfaces.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions AGENTS.md.

About the project

OpenPencil is an open-source design editor that opens and edits Figma and Pencil files, supports AI-assisted design changes, and includes a programmable headless Vue toolkit for custom editors. It is for designers and developers creating, inspecting, converting, and exporting interface designs, while the catalogue instructions help coding agents work with its capabilities.

open-pencil/open-pencil · 8,172 stars · on GitHub · openpencil.dev

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.

agentmods
npx agentmods add instructions/open-pencil/open-pencil/agents-md
Clone the repo
git clone --depth 1 https://github.com/open-pencil/open-pencil

Made for: Codex, OpenCode.

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 open-pencil AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/open-pencil/open-pencil/agents-md.svg)](https://agentmods.dev/instructions/open-pencil/open-pencil/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/open-pencil/open-pencil/agents-md"><img src="https://agentmods.dev/badge/instructions/open-pencil/open-pencil/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 5,082 This file is loaded in full into every session.
When invoked 5,082 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
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.05082 $0.05082
Opus 5 $0.02541 $0.02541
Sonnet 5 $0.01016 $0.01016
Haiku 4.5 $0.00508 $0.00508

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

Security

Grade A, and why

open-pencil AGENTS.md 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 2d 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.

AGENTS.md · 235 lines

How it starts

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

OpenPencil

Vue 3 + CanvasKit (Skia WASM) + Yoga WASM design editor. Tauri v2 desktop, also runs in browser.

Roadmap: packages/docs/development/roadmap.md tracks product direction, Figma compatibility gaps, and raw metadata coverage. This file keeps agent-facing architecture, conventions, and commands; detailed public docs live under packages/docs/**.

Monorepo

Bun workspace packages:

  • scene-graph — framework-neutral graph, node types, geometry, copy/snap/undo, variables, instances, and hit testing.
  • pen — Pencil.dev .pen model, parser, and SceneGraph adapter.
  • kiwi — SceneGraph-independent Kiwi schema/runtime, codecs, containers, and parse helpers.
  • fig.fig archives, SceneGraph conversion, metadata policy, and component/instance interpretation.
  • core — renderer, layout, editor, Figma API, tools, clipboard, vector conversion, and document I/O; depends on scene-graph, pen, kiwi, and fig, and keeps browser DOM out.
  • dom-css — DOM/CSS/HTML/JSX/Tailwind projection and browser/headless adapters.
  • vue — headless Vue 3 SDK primitives and composables; the root app is one consumer.
  • cli — headless .fig inspection, export, and linting with citty and agentfmt.
  • mcp — stdio and Hono HTTP MCP server reusing Core tools.
  • harness — optional Node companion for HarnessAgent sessions and its bounded JSONL host protocol; Tauri launches the separately installed command.
  • docs — published VitePress site. Use bun run docs:dev, bun run docs:build for fast checks, and bun run docs:build:production for deployment output.

The root Tauri/Vite app lives in src/; app services and state belong under src/app/**, views under src/views/**, and app UI under src/components/**.

Public package exports

Across package/app boundaries, import the owning package's public exports—never workspace internals or forwarding-only shims. @open-pencil/scene-graph owns graph types and primitives; @open-pencil/kiwi owns low-level Kiwi/FIG helpers; @open-pencil/core provides the compatibility barrel plus targeted subpaths listed in packages/core/package.json.

Read the full file on GitHub · 235 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. 2d ago Changed · -128 lines · -4,846 tokens per session scan B → A bfa0d6f1a9f1
  2. 3d ago Changed · +2 lines · +302 tokens per session 006aab035286
  3. 6d ago First seen · 361 lines · 9,626 tokens per session scan B 2a67f52e8d67

Subscribe to this mod's changes

open-pencil AGENTS.md is an instructions file published in the GitHub repository open-pencil/open-pencil (8,172 stars, last pushed yesterday), licensed MIT. It adds 5,082 tokens to every session, about $0.0254 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.