docs: update README and CLAUDE.md with recent features
- Add regenerate command documentation - Add download target type - Fix reference_images field (list, not single string) - Document archive behavior for clean command - Update module structure to reflect actual files - Add OpenAI provider documentation - Update supported models list - Add OPENAI_API_KEY to environment variables
This commit is contained in:
parent
d76951fe47
commit
fda28b5afa
2 changed files with 80 additions and 23 deletions
33
README.md
33
README.md
|
|
@ -85,10 +85,11 @@ defaults:
|
|||
| `prompt` | string | Inline prompt text, or path to a prompt file |
|
||||
| `model` | string | Override the default model for this target |
|
||||
| `inputs` | list[string] | Files this target depends on (other targets or existing files) |
|
||||
| `reference_image` | string | Image file for image-to-image generation |
|
||||
| `reference_images` | list[string] | Image files for image-to-image generation |
|
||||
| `control_images` | list[string] | Control images (for canny/depth models) |
|
||||
| `width` | int | Image width in pixels |
|
||||
| `height` | int | Image height in pixels |
|
||||
| `download` | string | URL to download instead of generating (mutually exclusive with prompt) |
|
||||
|
||||
Target type is inferred from the file extension:
|
||||
- **Image**: `.png`, `.jpg`, `.jpeg`, `.webp`
|
||||
|
|
@ -133,6 +134,23 @@ targets:
|
|||
|
||||
hokusai resolves dependencies automatically. If you build a single target, its transitive dependencies are included.
|
||||
|
||||
### Download targets
|
||||
|
||||
Targets can download files from URLs instead of generating them:
|
||||
|
||||
```yaml
|
||||
targets:
|
||||
reference.jpg:
|
||||
download: https://example.com/image.jpg
|
||||
|
||||
variation.png:
|
||||
prompt: "A variation of this image in watercolor style"
|
||||
reference_images:
|
||||
- reference.jpg
|
||||
```
|
||||
|
||||
Download targets participate in dependency resolution like any other target. They are skipped if the URL hasn't changed.
|
||||
|
||||
### Archiving previous outputs
|
||||
|
||||
Set `archive_folder` at the top level to preserve previous versions of generated files. When a target is rebuilt, the existing output is moved to the archive folder with an incrementing numeric suffix:
|
||||
|
|
@ -157,10 +175,23 @@ Build all targets, or a specific target and its dependencies.
|
|||
- Runs independent targets in parallel
|
||||
- Continues building if a target fails (dependents of the failed target are skipped)
|
||||
|
||||
### `hokusai regenerate <targets...>`
|
||||
|
||||
Force regeneration of specific targets, ignoring their up-to-date status. Useful for getting a new variation of an AI-generated output without changing the prompt.
|
||||
|
||||
```bash
|
||||
hokusai regenerate hero.png # regenerate one target
|
||||
hokusai regenerate hero.png logo.png # regenerate multiple targets
|
||||
```
|
||||
|
||||
If `archive_folder` is set, the previous versions are archived before regeneration.
|
||||
|
||||
### `hokusai clean`
|
||||
|
||||
Remove all generated target files and the build state file (`.hokusai.state.yaml`). Input files are preserved.
|
||||
|
||||
If `archive_folder` is set, files are moved to the archive instead of being deleted.
|
||||
|
||||
### `hokusai graph`
|
||||
|
||||
Print the dependency graph showing build stages:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue