@agent-webui/ai-desk-harness-gimp 1.0.29-beta2 → 1.0.29-beta3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agent-webui/ai-desk-harness-gimp",
3
- "version": "1.0.29-beta2",
3
+ "version": "1.0.29-beta3",
4
4
  "description": "Vendored CLI-Anything GIMP harness for AI Desk",
5
5
  "files": [
6
6
  "manifest.json",
@@ -1,236 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: cli-anything-gimp
3
- Version: 1.0.0
4
- Summary: CLI harness for GIMP - Raster image processing via gimp -i -b (batch mode). Requires: gimp (apt install gimp)
5
- Home-page: https://github.com/HKUDS/CLI-Anything
6
- Author: cli-anything contributors
7
- Author-email:
8
- Classifier: Development Status :: 4 - Beta
9
- Classifier: Intended Audience :: Developers
10
- Classifier: Topic :: Software Development :: Libraries :: Python Modules
11
- Classifier: Topic :: Multimedia :: Graphics :: Editors
12
- Classifier: License :: OSI Approved :: MIT License
13
- Classifier: Programming Language :: Python :: 3
14
- Classifier: Programming Language :: Python :: 3.10
15
- Classifier: Programming Language :: Python :: 3.11
16
- Classifier: Programming Language :: Python :: 3.12
17
- Requires-Python: >=3.10
18
- Description-Content-Type: text/markdown
19
- Requires-Dist: click>=8.0.0
20
- Requires-Dist: Pillow>=10.0.0
21
- Requires-Dist: prompt-toolkit>=3.0.0
22
- Provides-Extra: dev
23
- Requires-Dist: pytest>=7.0.0; extra == "dev"
24
- Requires-Dist: pytest-cov>=4.0.0; extra == "dev"
25
- Dynamic: author
26
- Dynamic: classifier
27
- Dynamic: description
28
- Dynamic: description-content-type
29
- Dynamic: home-page
30
- Dynamic: provides-extra
31
- Dynamic: requires-dist
32
- Dynamic: requires-python
33
- Dynamic: summary
34
-
35
- # GIMP CLI
36
-
37
- A stateful command-line interface for image editing, built on Pillow.
38
- Designed for AI agents and power users who need to create and manipulate
39
- images without a GUI.
40
-
41
- ## Prerequisites
42
-
43
- - Python 3.10+
44
- - `Pillow` (image processing)
45
- - `click` (CLI framework)
46
- - `numpy` (blend modes, pixel analysis)
47
-
48
- Optional (for interactive REPL):
49
- - `prompt_toolkit`
50
-
51
- ## Install Dependencies
52
-
53
- ```bash
54
- pip install Pillow click numpy prompt_toolkit
55
- ```
56
-
57
- ## How to Run
58
-
59
- All commands are run from the `agent-harness/` directory.
60
-
61
- ### One-shot commands
62
-
63
- ```bash
64
- # Show help
65
- python3 -m cli.gimp_cli --help
66
-
67
- # Create a new project
68
- python3 -m cli.gimp_cli project new --width 1920 --height 1080 -o my_project.json
69
-
70
- # Create with a profile
71
- python3 -m cli.gimp_cli project new --profile hd720p -o project.json
72
-
73
- # Open a project and show info
74
- python3 -m cli.gimp_cli --project project.json project info
75
-
76
- # JSON output (for agent consumption)
77
- python3 -m cli.gimp_cli --json --project project.json project info
78
- ```
79
-
80
- ### Interactive REPL
81
-
82
- ```bash
83
- python3 -m cli.gimp_cli repl
84
- python3 -m cli.gimp_cli repl --project my_project.json
85
- ```
86
-
87
- Inside the REPL, type `help` for all available commands.
88
-
89
- ## Command Reference
90
-
91
- ### Project
92
-
93
- ```bash
94
- project new [--width W] [--height H] [--mode RGB|RGBA|L|LA] [--profile P] [-o path]
95
- project open <path>
96
- project save [path]
97
- project info
98
- project profiles
99
- project json
100
- ```
101
-
102
- Available profiles: `hd1080p`, `hd720p`, `4k`, `square1080`, `a4_300dpi`, `a4_150dpi`,
103
- `letter_300dpi`, `web_banner`, `instagram_post`, `instagram_story`, `twitter_header`,
104
- `youtube_thumb`, `icon_256`, `icon_512`
105
-
106
- ### Layer
107
-
108
- ```bash
109
- layer new [--name N] [--type image|text|solid] [--fill F] [--opacity O] [--mode M]
110
- layer add-from-file <path> [--name N] [--position P] [--opacity O] [--mode M]
111
- layer list
112
- layer remove <index>
113
- layer duplicate <index>
114
- layer move <index> --to <position>
115
- layer set <index> <property> <value>
116
- layer flatten
117
- layer merge-down <index>
118
- ```
119
-
120
- Layer properties: `name`, `opacity` (0.0-1.0), `visible` (true/false),
121
- `mode` (blend mode), `offset_x`, `offset_y`
122
-
123
- ### Canvas
124
-
125
- ```bash
126
- canvas info
127
- canvas resize --width W --height H [--anchor center|top-left|...]
128
- canvas scale --width W --height H [--resample lanczos|bicubic|bilinear|nearest]
129
- canvas crop --left L --top T --right R --bottom B
130
- canvas mode <RGB|RGBA|L|LA|CMYK|P>
131
- canvas dpi <value>
132
- ```
133
-
134
- ### Filters
135
-
136
- ```bash
137
- filter list-available [--category adjustment|blur|stylize|transform]
138
- filter info <name>
139
- filter add <name> [--layer L] [--param key=value ...]
140
- filter remove <index> [--layer L]
141
- filter set <index> <param> <value> [--layer L]
142
- filter list [--layer L]
143
- ```
144
-
145
- Available filters:
146
- - **Adjustments**: brightness, contrast, saturation, sharpness, autocontrast,
147
- equalize, invert, posterize, solarize, grayscale, sepia
148
- - **Blur**: gaussian_blur, box_blur, unsharp_mask, smooth
149
- - **Stylize**: find_edges, emboss, contour, detail
150
- - **Transform**: rotate, flip_h, flip_v, resize, crop
151
-
152
- ### Media
153
-
154
- ```bash
155
- media probe <file>
156
- media list
157
- media check
158
- media histogram <file>
159
- ```
160
-
161
- ### Export
162
-
163
- ```bash
164
- export presets
165
- export preset-info <name>
166
- export render <output> [--preset name] [--overwrite] [--quality Q] [--format F]
167
- ```
168
-
169
- Available presets: `png`, `png-max`, `jpeg-high`, `jpeg-medium`, `jpeg-low`,
170
- `webp`, `webp-lossless`, `tiff`, `tiff-none`, `bmp`, `gif`, `pdf`, `ico`
171
-
172
- ### Draw
173
-
174
- ```bash
175
- draw text --layer L --text "Hello" [--x X] [--y Y] [--font F] [--size S] [--color C]
176
- draw rect --layer L --x1 X --y1 Y --x2 X --y2 Y [--fill C] [--outline C]
177
- ```
178
-
179
- ### Session
180
-
181
- ```bash
182
- session status
183
- session undo
184
- session redo
185
- session history
186
- ```
187
-
188
- ## JSON Mode
189
-
190
- Add `--json` before the subcommand for machine-readable output:
191
-
192
- ```bash
193
- python3 -m cli.gimp_cli --json --project p.json layer list
194
- ```
195
-
196
- ## Running Tests
197
-
198
- ```bash
199
- cd agent-harness
200
- python3 -m pytest cli/tests/test_core.py -v # Unit tests (no images needed)
201
- python3 -m pytest cli/tests/test_full_e2e.py -v # E2E tests (creates test images)
202
- python3 -m pytest cli/tests/ -v # All tests
203
- ```
204
-
205
- ## Example Workflow
206
-
207
- ```bash
208
- # Create a project
209
- python3 -m cli.gimp_cli project new --width 1920 --height 1080 --profile hd1080p -o edit.json
210
-
211
- # Add an image layer
212
- python3 -m cli.gimp_cli --project edit.json layer add-from-file photo.jpg --name "Background"
213
-
214
- # Apply filters
215
- python3 -m cli.gimp_cli --project edit.json filter add brightness --layer 0 --param factor=1.2
216
- python3 -m cli.gimp_cli --project edit.json filter add contrast --layer 0 --param factor=1.1
217
- python3 -m cli.gimp_cli --project edit.json filter add saturation --layer 0 --param factor=1.3
218
-
219
- # Add a text overlay
220
- python3 -m cli.gimp_cli --project edit.json layer new --type text --name "Title"
221
- python3 -m cli.gimp_cli --project edit.json draw text --layer 0 --text "My Photo" --size 48 --color "#ffffff"
222
-
223
- # View the layer stack
224
- python3 -m cli.gimp_cli --project edit.json layer list
225
-
226
- # Save and render
227
- python3 -m cli.gimp_cli --project edit.json project save
228
- python3 -m cli.gimp_cli --project edit.json export render output.jpg --preset jpeg-high --overwrite
229
- ```
230
-
231
- ## Blend Modes
232
-
233
- Supported blend modes for layer compositing:
234
- `normal`, `multiply`, `screen`, `overlay`, `soft_light`, `hard_light`,
235
- `difference`, `darken`, `lighten`, `color_dodge`, `color_burn`,
236
- `addition`, `subtract`, `grain_merge`, `grain_extract`
@@ -1,25 +0,0 @@
1
- setup.py
2
- cli_anything/gimp/__init__.py
3
- cli_anything/gimp/__main__.py
4
- cli_anything/gimp/gimp_cli.py
5
- cli_anything/gimp/core/__init__.py
6
- cli_anything/gimp/core/canvas.py
7
- cli_anything/gimp/core/export.py
8
- cli_anything/gimp/core/filters.py
9
- cli_anything/gimp/core/layers.py
10
- cli_anything/gimp/core/media.py
11
- cli_anything/gimp/core/project.py
12
- cli_anything/gimp/core/session.py
13
- cli_anything/gimp/tests/__init__.py
14
- cli_anything/gimp/tests/test_core.py
15
- cli_anything/gimp/tests/test_full_e2e.py
16
- cli_anything/gimp/utils/__init__.py
17
- cli_anything/gimp/utils/gimp_backend.py
18
- cli_anything/gimp/utils/repl_skin.py
19
- cli_anything_gimp.egg-info/PKG-INFO
20
- cli_anything_gimp.egg-info/SOURCES.txt
21
- cli_anything_gimp.egg-info/dependency_links.txt
22
- cli_anything_gimp.egg-info/entry_points.txt
23
- cli_anything_gimp.egg-info/not-zip-safe
24
- cli_anything_gimp.egg-info/requires.txt
25
- cli_anything_gimp.egg-info/top_level.txt
@@ -1,2 +0,0 @@
1
- [console_scripts]
2
- cli-anything-gimp = cli_anything.gimp.gimp_cli:main
@@ -1,7 +0,0 @@
1
- click>=8.0.0
2
- Pillow>=10.0.0
3
- prompt-toolkit>=3.0.0
4
-
5
- [dev]
6
- pytest>=7.0.0
7
- pytest-cov>=4.0.0