svg-picker
A Human-in-the-Loop Icon Selector for AI Agents
Inspired by HULA: Human-In-the-Loop Software Development Agents (ICSE SEIP 2025)
What Is This?
svg-picker is a lightweight tool that gives AI coding agents the ability to ask a human to visually select an icon, then returns the SVG source code directly to the agent via stdout.
Instead of guessing icon names or embedding random SVG strings, the AI can now say:
"I need a home icon — please select one from the options"
A native dark-themed window opens. The human picks. The AI gets clean SVG code.
The human provides visual judgment. The AI handles everything else.
Background: Why "Human-in-the-Loop"?
The paper HULA: Human-In-the-Loop Software Development Agents (Takerngsaksiri et al., ICSE SEIP 2025) demonstrates a critical insight:
Existing LLM-based coding agents rarely incorporate human feedback at intermediate stages. When humans can intervene during plan generation and code writing — not just review final output — development time and effort decrease significantly.
HULA was deployed at Atlassian JIRA and evaluated by real engineers. The results confirm what many suspected: fully autonomous AI agents produce better outcomes when humans stay in the loop.
svg-picker applies this principle to a specific, narrow task: icon selection. It is a minimal, production-ready implementation of human-in-the-loop tooling for AI agents — without the complexity of a full framework.
How It Works
User/CI: svg-picker <keyword>
│
▼
┌─────────────────┐
│ Search Iconify │ (Background thread)
│ Download SVGs │
└────────┬────────┘
│
▼
┌─────────────────────┐
│ GUI Window │ ← Human picks icon(s)
│ Dark theme │
│ Click to select │
└────────┬───────────┘
│
▼
SVG code to stdout → AI agent consumes it
The human acts as a visual judge — the AI remains in full control of the workflow.
Features
- Native GUI — PySide6 window, no browser required
- Themable —
cream/sky/darkbackgrounds via--theme - Pagination — 10 icons per page, flip with
‹/›buttons or←/→keys; selections persist across pages - Iconify API — Access to 150+ icon sets, 500,000+ icons
- stdout output — SVG code flows directly into the AI's context
- Cancellation signal — closing the window writes
[svg-picker] cancelled: ...to stderr so callers can distinguish user cancel from program crash - One-step install — pip install, single command
- Zero config — No API keys, no servers, no infrastructure
Install
pip install svg-picker
Or for development:
pip install -e .
Usage
svg-picker <keyword> [--theme cream|sky|dark]
Options
| Flag | Description |
|---|---|
-t, --theme <name> |
Background theme. Choices: cream (default), sky, dark |
Examples
svg-picker home # default cream theme
svg-picker home --theme sky # sky blue background
svg-picker arrow -t dark # dark theme, short flag
Default theme via .env
To set a project-wide default without typing --theme every time, edit .env in the directory you run svg-picker from. On first launch, svg-picker creates an empty .env for you if one doesn't exist — just add a line like:
# .env
SVG_PICKER_THEME=sky
Resolution order: CLI --theme → .env SVG_PICKER_THEME → cream. An invalid value in .env prints a warning to stderr and falls back to the built-in default.
Steps
- Window opens with the first page of 10 matching icons
- Click to select one or more; click again to deselect
- Flip pages with
‹/›buttons or←/→keys — selections persist across pages - Press Confirm — SVG source code is printed to stdout, window closes
- Close the window (X) to cancel — a
[svg-picker] cancelled: ...line is written to stderr
For AI Agents
As a Claude Code Skill
Place this file as ~/.claude/skills/svg-picker.md:
# svg-picker
Pick SVG icons via keyword search with human visual selection.
Usage: svg-picker <keyword> [--theme cream|sky|dark]
The human selects icons from the window. SVG source code is output to stdout.
If the window is closed without confirming, a "[svg-picker] cancelled: ..."
line is written to stderr — read stderr to distinguish cancel from crash.
Programmatic Usage
import subprocess
result = subprocess.run(
["svg-picker", "home"],
capture_output=True, text=True,
)
if result.returncode != 0:
# 程序异常退出 —— stderr 会有 Python traceback
raise RuntimeError(f"svg-picker crashed: {result.stderr}")
if "[svg-picker] cancelled" in result.stderr:
# 用户主动关闭窗口,没点 Confirm
if "selected but not confirmed" in result.stderr:
# 选了但没用上 —— 尊重取消意图,不要 fallback
print("User cancelled with selections discarded")
else:
print("User cancelled without selection")
else:
# 正常完成 —— result.stdout 是 SVG 源码
svg_code = result.stdout
# 每段格式:<!-- iconify_id -->\n<svg>...</svg>
Comparison
| svg-picker | HULA (Atlassian) | |
|---|---|---|
| Domain | Icon selection | Full software dev |
| Scope | Minimal, single-task | Full agent framework |
| Human role | Visual judge | Plan + code reviewer |
| Deployment | pip install | Jira plugin |
| Target | AI agents | Human engineers |
Both share the same core principle: human judgment improves AI output.
Related Work
- HULA: Human-In-the-Loop Software Development Agents — ICSE SEIP 2025
- acte — Framework for GUI-like Agent Tools
- OpenUI — Open Standard for Generative UI
License
MIT
Release files for svg-picker 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| svg_picker-0.1.0.tar.gz | 14.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| svg_picker-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 26.9 kB
Release files / svg_picker-0.1.0.tar.gz
| Download URL | svg_picker-0.1.0.tar.gz |
|---|---|
| Size | 14.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0fadd3548661811e0982673097fe7429aa7269630c2554d72a6e429fa6ed49dc
|
|
BLAKE2b-256 checksum How to use checksums |
6b8855a32b1e89852175b75fc694b2d076073072159491c5f42c25020809d9df
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / svg_picker-0.1.0-py3-none-any.whl
| Download URL | svg_picker-0.1.0-py3-none-any.whl |
|---|---|
| Size | 12.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4d9dc6d2c2d2d36868d936e6e4099f6a6af79644a9bcf6d0f2b45798e38fc4a3
|
|
BLAKE2b-256 checksum How to use checksums |
c4d8c9c4551c35b3fca3b02ebeac43f9c4cc32beabe4cbd02adad03c18b73a57
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|