@ai-agent-tools/picgen 0.1.0-alpha.10 → 0.1.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -10,7 +10,6 @@ Alpha goals:
10
10
  - Gemini reference-image generation
11
11
  - `provider + preset + routing` configuration
12
12
  - `picgen setup`, `picgen doctor`, `picgen create --dry-run`
13
- - Local web interface with settings, generation, and history
14
13
  - Local Codex skill instructions
15
14
 
16
15
  ## Development
@@ -27,46 +26,32 @@ npm run build
27
26
  ## Install
28
27
 
29
28
  ```bash
30
- node -v
31
- npm -v
32
29
  npm install -g @ai-agent-tools/picgen
33
- npx -y skills add ai-agent-tools/picgen --skill picgen -g -y --copy
34
- picgen skill install codex
35
30
  picgen --help
36
31
  picgen quickstart
37
- picgen open
38
32
  ```
39
33
 
40
- Use `npx -y skills add ...` for cross-agent skill installation when supported. `picgen skill install codex` is a Codex-only fallback that copies the bundled skill into `~/.codex/skills/picgen`.
41
-
42
34
  Agent trial prompt:
43
35
 
44
36
  ```text
45
- 请帮我安装并配置 PicGen 生图工具。请先阅读并按这个指南执行:https://raw.githubusercontent.com/ai-agent-tools/picgen/refs/heads/main/docs/agent-install.md 。你负责判断是否在本机持久环境、安装 CLI skill、引导我配置 provider/API key,并先预览生成方案,等我确认后再生成测试图。不要让我理解命令细节,也不要让我把 API key 发到聊天里。
37
+ 请安装并体验 @ai-agent-tools/picgen:全局安装 npm install -g @ai-agent-tools/picgen,运行 picgen setup 配置,然后先 dry-run 预览,再确认生成一张测试图。如果我要用参考图,请使用 --reference <图片路径>。
46
38
  ```
47
39
 
48
- For agent-assisted installation, see [docs/agent-install.md](./docs/agent-install.md). For first-user rollout, see [docs/release-alpha.md](./docs/release-alpha.md).
40
+ For first-user rollout, see [docs/release-alpha.md](./docs/release-alpha.md).
49
41
 
50
42
  ## Commands
51
43
 
52
44
  ```bash
53
45
  picgen setup
54
46
  picgen quickstart
55
- picgen open
56
- npx -y skills add ai-agent-tools/picgen --skill picgen -g -y --copy
57
- picgen skill install codex
58
47
  picgen update check
59
48
  picgen doctor --json
60
- picgen create --dry-run --preset fast-draft "一张简洁的 PicGen 测试图"
61
- picgen create --yes --preset fast-draft "一张简洁的 PicGen 测试图"
49
+ picgen create --dry-run "一张产品发布会主视觉"
50
+ picgen create --yes "一张产品发布会主视觉"
62
51
  picgen create --dry-run --provider gemini_official --reference ./reference.png "基于参考图生成一张品牌海报"
63
52
  picgen create --yes --provider gemini_official --reference ./reference.png "基于参考图生成一张品牌海报"
64
53
  picgen provider list
65
54
  picgen provider add
66
- picgen provider quick-add gemini-proxy --host https://www.pandai.vip --prefer
67
- picgen key set PICGEN_GEMINI_PROXY_KEY --clipboard
68
- picgen key set PICGEN_GEMINI_PROXY_KEY --stdin
69
- picgen key list --json
70
55
  picgen provider test openai_official --json
71
56
  picgen provider prefer gemini_official
72
57
  picgen provider disable gemini_proxy
@@ -81,8 +66,6 @@ Quick-add setup asks only for the essentials: provider name, host URL, API key e
81
66
 
82
67
  Real `picgen create` calls ask for confirmation before contacting a provider. Use `--yes` only when you want to skip that CLI confirmation.
83
68
 
84
- `picgen open` starts a local web interface at `127.0.0.1`, defaulting to port `8188`. It is a foreground local server: keep the terminal open while using the page, and press Ctrl+C to close it. The page can configure multiple providers, save API keys to PicGen's managed env file, preview generation plans, generate images, and browse saved history under `outputs/picgen`.
85
-
86
69
  `--reference <path>` can be repeated to pass local reference images. Alpha supports reference images through the Gemini adapter. The OpenAI-compatible `/v1/images/generations` adapter does not support reference images yet; use a Gemini provider for reference-image generation.
87
70
 
88
71
  Gemini generation requests ask for image-only responses with `responseModalities: ["IMAGE"]`. Provider health checks still use a text-only request so they can verify host, key, model, and endpoint readiness without triggering image generation.
@@ -108,20 +91,6 @@ OPENAI_API_KEY=...
108
91
  GEMINI_API_KEY=...
109
92
  ```
110
93
 
111
- For non-technical users, `picgen setup` can save API keys for you in:
112
-
113
- ```text
114
- ~/.picgen/.env
115
- ```
116
-
117
- PicGen loads this managed env file automatically. Shell environment variables take priority, and a project `.env` can override the managed file for local testing.
118
-
119
- Each provider should have its own `api_key_env` value. When adding another provider of the same type, PicGen assigns a new key name by default, such as `PICGEN_GEMINI_PROXY_2_KEY`, so multiple channels do not overwrite each other's API keys.
120
-
121
- Older configs that reused the same `api_key_env` across multiple providers are migrated automatically when PicGen loads the config. PicGen keeps the first provider unchanged, assigns unique key names to the later providers, and copies the existing key value into the managed env file when the value is available.
122
-
123
- When agents inspect key configuration, they should use `picgen key list/show` so chat output only contains masked key status. To inspect or edit the full saved key directly, open `~/.picgen/.env`; a project `.env` in the current directory may override it, and shell environment variables take highest priority.
124
-
125
94
  You can start from the included example:
126
95
 
127
96
  ```bash