AI & Agentslow risk

library-curator

Search the OD Library (the global asset registry) and apply matching assets into the current project mid-task. Use when the user asks to reuse an image they captured/uploaded earlier, "pull a logo/screenshot from my library", or to find and drop a stored asset into the page being built.

nexu-io/open-design·skills/library-curator/SKILL.md
61/ 100推薦值

匯入這個 Skill

選擇你的 coding agent,複製專案級或個人級安裝指令。

固定至平台收錄的 commit
匯入目前專案.agents/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a codex -y
匯入個人環境~/.agents/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a codex -g -y
手動放置目錄.agents/skills/library-curatorOfficial docs ↗
匯入目前專案.claude/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a claude-code -y
匯入個人環境~/.claude/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a claude-code -g -y
手動放置目錄.claude/skills/library-curatorOfficial docs ↗
匯入目前專案.agents/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a github-copilot -y
匯入個人環境~/.copilot/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a github-copilot -g -y
手動放置目錄.agents/skills/library-curatorOfficial docs ↗
匯入目前專案.agents/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a cursor -y
匯入個人環境~/.cursor/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a cursor -g -y
手動放置目錄.agents/skills/library-curatorOfficial docs ↗
匯入目前專案.agents/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a gemini-cli -y
匯入個人環境~/.gemini/skills/library-curator
npx skills add https://github.com/nexu-io/open-design/tree/7533db3f4342d09b27368fa5d907ebd3cdb93b75/skills/library-curator -a gemini-cli -g -y
Native Gemini CLIgemini skills install https://github.com/nexu-io/open-design.git --scope workspace --path skills/library-curator
手動放置目錄.agents/skills/library-curatorOfficial docs ↗
⚠ 安裝指令使用開源 skills CLI。執行前請檢查來源、腳本與權限。
# library-curator

Reuse assets that already live in the user's OD Library — images captured with
the OD Clipper, manual uploads, agent-generated media, and design-system
material — without asking the user to re-upload them.

## When to use

- The user references an asset they already have ("the screenshot I clipped",
  "my logo", "that hero image from earlier").
- You need an image for the page you're building and the user prefers their own
  library over freshly generated media.

## Tools (tool-token track)

Both endpoints authenticate with the run's tool token (`OD_TOOL_TOKEN`, injected
by the daemon) and operate on the project the run belongs to.

### Search

`POST /api/tools/library/search`

```json
{ "query": "blue hero background", "kind": "image", "limit": 20 }
```

Returns `{ "results": [{ "asset": { "id": "...", "kind": "image", "sourceTitle": "...", "width": 1600, "height": 900, "sources": [...] }, "score": 0 }], "semantic": false }`.

`semantic: false` means keyword/metadata matching (no embedding model
configured). Filter and rank the results yourself from the asset metadata.

### Apply

`POST /api/tools/library/apply`

```json
{ "assetId": "<id from search>", "dir": "assets" }
```

Copies the asset into the project (default subdir `library/`, or the `dir` you
pass) and returns `{ "relPath": "assets/<hash>.png" }`. Reference that
`relPath` from the HTML/CSS you write (e.g. `<img src="assets/ab12cd34ef.png">`).

## Recipe

1. Search with a tight query for the kind you need.
2. Pick the best result by dimensions / title / source.
3. Apply it to get a project-relative path.
4. Wire that path into the artifact you're editing.

If search returns nothing, fall back to media generation rather than guessing a
path — never invent a `relPath` that `apply` did not return.