Token导航 LogoToken导航TokenDH.com
研究检索敏感数据unknown未标认证来源可访问许可证需确认审计未展示

agent-bridge-for-photoshopPhotoshop Agent 桥

Agent Skill

用于辅助图像生成、图片编辑、视觉素材处理或图像模型工作流。它适合让 Agent 根据文本生成图片、处理背景、整理视觉提示词或调用相关图像工具。使用时需要确认输入图片、版权来源、输出格式和模型限制;涉及人物、品牌、商品或公开展示素材时,应额外核对授权、真实性和内容合规边界。

总安装

847

周安装

36

下载量

297
Local Agent

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:agent-bridge-for-photoshop(Photoshop Agent 桥)
来源仓库:https://agent-bridge-for-photoshop.jaredverdi.com
仓库路径:agent-bridge-for-photoshop
安装命令:
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。当前暂无明确安装命令,请以来源页面说明为准。

简介

用于辅助图像生成、图片编辑、视觉素材处理或图像模型工作流,适合文本转图片和视觉提示词整理场景。

  • 适用于 Photoshop 文档控制、图层管理和 UXP API 桥接的视觉处理任务。
  • 通过 psagent CLI 和 JSON 操作封包实现 Photoshop 自动化控制。
  • 涉及人物、品牌或公开展示素材时应核对授权、真实性和内容合规边界。
  • agent-bridge-for-photoshop 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

Agent Bridge for Photoshop Skill

Product summary

Agent Bridge for Photoshop is a local automation stack for Photoshop that provides a stable command surface, operation payload schema, and runtime bridge between CLI workflows and Photoshop UXP APIs. Agents use the psagent CLI to control Photoshop documents, layers, and operations through JSON operation envelopes. The bridge daemon runs on http://127.0.0.1:43120 and brokers calls between the CLI and a UXP plugin inside Photoshop. Key files: .psagent.json (project config), ~/.config/psagent/config.json (user config), operation envelope JSON payloads. Primary CLI: psagent with subcommands for sessions, documents, layers, operations, rendering, checkpoints, and diagnostics. MCP server available via psagent mcp-serve for agent tool integration.

When to use

Reach for this skill when:

  • Automating Photoshop document and layer operations (create, rename, delete, style, export)
  • Building reproducible creative workflows with deterministic operation sequences
  • Managing document state with checkpoints and rollback capabilities
  • Querying document structure (manifest, layers, properties)
  • Exporting renders (PNG/JPG) from Photoshop programmatically
  • Testing operation payloads before production use (dry-run mode)
  • Integrating Photoshop automation into agent-driven workflows via MCP tools
  • Debugging operation failures and validating bridge connectivity

Quick reference

Essential CLI commands

CommandPurpose
psagent session start [--profile <name>]Start a bridge session
psagent bridge statusCheck daemon and UXP connection
psagent doc open <path>Open a Photoshop document
psagent layer list [--match <regex>]List layers in active document
psagent op apply -f <ops.json> [--checkpoint] [--dry-run] [--op-delay-ms <ms>]Apply operation envelope
psagent op -hList available operations and quick catalog
psagent op <command> -hShow operation arguments, aliases, and example payload
`psagent render --format png\jpg --out <path>`Export active document
psagent checkpoint listList saved checkpoints
psagent checkpoint restore <id>Restore document to checkpoint
psagent doctorDiagnose health and connectivity
psagent mcp-serveStart MCP server for agent tools

Discover operation contracts from CLI help

Use these before writing an ops payload:

  • psagent op -h to see the full operation list/capability catalog.
  • psagent op <command> -h to see required args, supported args, notes, aliases, and a copy/paste JSON example for that operation.

Working patterns (quality-first)

  • Centered headline pattern: create or style text with position.x = 0, set maxWidth to the canvas/section width, and set alignment: "center" instead of hand-tuning x values.
  • Baseline positioning pattern: createTextLayer.position.y is the text baseline (not visual top). For large text, set a lower baseline and iterate with quick renders.
  • Readable text pattern: set explicit text color via textColor/color and add setLayerEffects drop shadow or stroke for contrast on busy photos.
  • Shape polish pattern: use createShapeLayer with cornerRadius and fillType: "gradient" for modern buttons/badges.
  • Photo frame pattern: place photo layer above a frame shape and apply createClippingMask to constrain photo bounds.
  • Single-transaction pattern: keep all dependent operations for one document in the same op apply call to avoid active-document drift between CLI invocations.
  • Iterative composition pattern: render after each logical group (background, photo, text, accents, CTA) and adjust before adding the next group.
  • Pacing pattern for stability: when Photoshop is unstable under heavy automation, set safety.opDelayMs (or CLI --op-delay-ms) to add a short delay between ops (for example 80-200ms).

BatchPlay recipes (high-friction cases)

  • Preserve text style while changing color: if using textStyleRange, include the full style payload (fontPostScriptName, fontName, fontStyleName, size with unitDouble/pointsUnit, and color) because Photoshop replaces style objects rather than merging.
  • Prefer first-class text ops when possible: use createTextLayer/setTextStyle for normal font/size/color/alignment workflows. Reserve batchPlay for gaps not covered by first-class ops.
  • Descriptor units are explicit: numeric descriptor values often require {"_obj": "unitDouble", "_unit": "pointsUnit", "_value": <number>} (or other unit enums) instead of raw numbers.

Global flags

FlagPurpose
--jsonOutput JSON format
--dry-run / -nPreview without mutation
--checkpointCreate checkpoint before operation
--timeout <ms>Override request timeout
--profile <name>Use named configuration profile
--config <path>Specify config file path
-v, --verboseVerbose logging
-q, --quietSuppress output

Configuration precedence

Flags override environment variables, which override session config, which override project config (.psagent.json), which override user config (~/.config/psagent/config.json), which override defaults.

Environment variables

VariablePurpose
PSAGENT_PROFILEDefault profile name
PSAGENT_TIMEOUT_MSRequest timeout in milliseconds
PSAGENT_PLUGIN_ENDPOINTUXP plugin endpoint (default: http://127.0.0.1:43120)
PSAGENT_DRY_RUNEnable dry-run mode by default

Operation envelope structure

{
  "transactionId": "tx-001",
  "doc": { "ref": "active" },
  "refs": {
    "hero": "layer_123"
  },
  "ops": [
    { "op": "createLayer", "name": "Draft", "ref": "draftLayer" },
    { "op": "renameLayer", "target": "$draftLayer", "name": "Draft v2" }
  ],
  "safety": {
    "dryRun": false,
    "checkpoint": false,
    "rollbackOnError": false,
    "onError": "abort"
  }
}

MCP tools (for agent use)

ToolPurpose
photoshop_capabilitiesReturn adapter mode and capability map
photoshop_open_documentOpen document by local path or URL
photoshop_get_manifestReturn document structure and metadata
photoshop_query_layersList layers with optional regex filter
photoshop_apply_opsApply operation envelope payload
photoshop_renderExport active document to PNG/JPG
photoshop_checkpoint_restoreRestore document to checkpoint by ID
photoshop_events_tailFetch recent adapter events

Decision guidance

When to use dry-run vs. checkpoint vs. rollback

ScenarioUseWhy
Testing operation syntax before production--dry-runValidates schema without mutating document
Want to undo if operation failsrollbackOnError: trueRestores document to pre-operation state on error
Need to save state before risky operations--checkpointCreates named snapshot for manual restore
Batch operations with per-op error handlingonError: "continue"Skips failed ops, continues with rest
Single operation must not failonError: "abort"Stops entire transaction on first error

When to use abort vs. continue error policy

ScenarioUseWhy
All operations depend on previous successonError: "abort"Prevents cascading failures
Some operations are optional/independentonError: "continue"Maximizes output even if some ops fail
Cleanup operations must run regardlessPer-op onError: "continue"Ensures deleteLayer runs even if earlier ops fail

When to use CLI vs. MCP server

ScenarioUseWhy
Direct command-line automationpsagent CLISimple, synchronous, full control
Agent-driven workflowspsagent mcp-serveExposes tools to agent clients via JSON-RPC
Integration testingpsagent CLI with --jsonStructured output for assertions
Real-time monitoringpsagent events tailStream recent operations and errors

Workflow

Typical task: Apply operations to a Photoshop document

  1. Start the bridge stack (one-time setup):

- Terminal A: psagent bridge daemon (runs on 127.0.0.1:43120) - Terminal B: Reload UXP plugin in Photoshop (or use npm run bridge:reload) - Terminal C (optional): psagent mcp-serve if using agent tools

  1. Verify connectivity:

- Run psagent bridge status — confirm "Connected" and queue is empty - Run psagent doctor — check health, exit code 0 = OK

  1. Open a document:

- psagent doc open./path/to/file.psd - Verify with psagent layer list to see current structure

  1. Create operation envelope:

- Write JSON file with ops array, safety settings, and refs for layer targeting - Use $refName syntax to reference layers created earlier in same transaction - Keep all dependent ops in one envelope for the same document

  1. Test with dry-run:

- psagent op apply -f ops.json --dry-run - Verify schema is valid and operation names are recognized - Check result for applied: 0 (no mutations)

  1. Apply with checkpoint:

- psagent op apply -f ops.json --checkpoint - Inspect result for applied, failed, aborted counts - If errors, check failures[] array for details

  1. Validate output iteratively:

- After each logical block, render and inspect: - psagent render --format png --out./preview-step-<n>.png - Confirm structure and refs: - psagent layer list - Inspect document properties as needed: - psagent doc manifest

  1. Rollback if needed:

- psagent checkpoint list to see available snapshots - psagent checkpoint restore <id> to revert to checkpoint

Typical task: Use MCP tools from an agent

  1. Start psagent mcp-serve in a terminal
  2. Agent client connects via JSON-RPC over stdio
  3. Call tools in order:

- photoshop_capabilities — confirm adapter is ready - photoshop_open_document — open target file - photoshop_get_manifest — inspect structure - photoshop_query_layers — find specific layers - photoshop_apply_ops — execute operation envelope - photoshop_render — export result - photoshop_checkpoint_restore — undo if needed

Common gotchas

  • Daemon not running: psagent op apply will timeout if psagent bridge daemon is not running on 127.0.0.1:43120. Always start daemon first.
  • UXP plugin disconnected: psagent bridge status shows "Disconnected" if Photoshop UXP panel is not loaded. Reload plugin with npm run bridge:reload or manually in Photoshop.
  • Text style confusion: createTextLayer already supports styling/fitting args like font, fontName, fontSize, textColor, alignment, maxWidth, and overlap controls. Use setTextStyle for post-create edits or re-styling existing text layers.
  • Text baseline mismatch: createTextLayer.position.y is baseline-aligned. If text appears clipped or too high, move the baseline down and re-render.
  • BatchPlay textStyleRange resets styles: textStyleRange[*].textStyle replaces style values; it does not patch them. Include full style fields (font + size + color) in the descriptor.
  • Active document drift across commands: Photoshop can switch active documents between separate CLI calls. Put dependent operations in one op apply payload and set doc.ref.
  • saveDocumentAs key confusion: saveDocumentAs uses output for destination path. path is not a valid key.
  • Layer references fail silently: Use $refName syntax to reference layers created in the same transaction. If reference is wrong, operation may target wrong layer or fail. Validate with --dry-run first.
  • Rollback doesn't work as expected: rollbackOnError: true uses best-effort history snapshot strategy. Some Photoshop actions may not be fully reversible. Test rollback behavior in dry-run before relying on it.
  • Checkpoint restore is slow: Restoring large documents from checkpoint can take seconds. Don't call checkpoint restore in tight loops.
  • Schema validation errors are silent in JSON output: Check result.failures[] array for validation errors. Exit code will be non-zero if schema validation fails.
  • Operation names are case-sensitive: Use exact canonical names like createLayer, not CreateLayer or create_layer. Alias forms (e.g., layer.rename) map to canonical names.
  • Timeout on slow operations: Large document operations may exceed default timeout. Use --timeout <ms> to increase limit for batch operations.
  • Dry-run still requires valid document: --dry-run validates schema but still needs an open document. Session must be active.

Verification checklist

Before submitting work with Agent Bridge for Photoshop:

  • Bridge daemon is running on 127.0.0.1:43120 (verify with psagent bridge status)
  • UXP plugin is connected (status shows "Connected", not "Disconnected")
  • Document is open (psagent doc open succeeded, psagent layer list returns layers)
  • Operation envelope JSON is valid (test with --dry-run first)
  • All layer references use correct $refName syntax
  • Text operations account for baseline positioning (position.y)
  • If using batchPlay textStyleRange, descriptors include full style fields to preserve font/size/color
  • Error policy is set correctly (onError: "abort" or "continue" as needed)
  • Checkpoint is created before risky operations (--checkpoint flag)
  • Result payload shows expected applied count (not failed or aborted)
  • Cleanup operations (e.g., deleteLayer) are included to remove temporary layers
  • Output is validated (render exported, manifest checked, layers verified)
  • Exit code is 0 for success, non-zero for errors

Resources

For additional documentation and navigation, see: https://agent-bridge-for-photoshop.jaredverdi.com/llms.txt

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Local Agent

83.52%
按下载量换算248

安全审计

暂无安全审计结果可展示。

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills