ENFUGUE is an open-source web app for making studio-grade images and video using generative AI.
GPL-3.0 License
diffusers
extensions.A script is provided for Windows and Linux machines to install, update, and run ENFUGUE. Copy the relevant command below and answer the on-screen prompts to choose your installation type and install optional dependencies.
Access the command prompt from the start menu by searching for "command." Alternatively, hold the windows key on your keyboard and click x
, then press r
or click run
, then type cmd
and press enter or click ok
.
curl https://raw.githubusercontent.com/painebenjamin/app.enfugue.ai/main/enfugue.bat -o enfugue.bat
.\enfugue.bat
curl https://raw.githubusercontent.com/painebenjamin/app.enfugue.ai/main/enfugue.sh -o enfugue.sh
chmod u+x enfugue.sh
./enfugue.sh
Both of these commands accept the same flags.
USAGE: enfugue.(bat|sh) [OPTIONS]
Options:
--help Display this help message.
--conda / --portable Automatically set installation type (do not prompt.)
--update / --no-update Automatically apply or skip updates (do not prompt.)
--mmpose / --no-mmpose Automatically install or skip installing MMPose (do not prompt.)
If you want to install without using the installation scripts, see this Wiki page.
Many configuration options are available, but none are required. If you want to specify things such as the host and port that the server listens on, please review the documentation for this on this Wiki page.
By default, the UI deploys two servers, one with and without SSL. After starting the server, open a browser and navigate to https://app.enfugue.ai:45554
. If that doesn't work due to your networking configuration, you can instead access the server at http://127.0.0.1:45555
or http://localhost:45555
. Some features are only available in a secure environment and will be disabled when using the insecure server, review the troubleshooting and configuration guides to figure out why it may not be working.
Please read the newly-written New User Quick-Start Guide for basic usage and controls.
When enabled, authentication will be required when using Enfugue. This enables system administrators to create a two-tiered hierarchy of users and administrators, where users are not permitted to modify models or the installation itself; they are only allowed to use the pre-configured setup. The primary impetus behind this was to create the ability for parents to curate an environment for children to safely experiment with generative AI.
Once enabled in the settings menu, you will be taken to a login screen. The default user and password are both enfugue
, all lowercase. You can change any other user's password as an administrator.
If you ever forget your password, you can reset the root password by creating a file named password_reset.txt
in the enfugue cache directory with the desired new password, then restart the server. The cache directory is located at ~/.cache/enfugue/
, where ~
is your home directory or user directory, depending on platform.
Here are a few quick tips to getting great results:
Here are a few steps to take if you're having trouble getting Enfugue to work for you:
45554
and 45555
. This would be uncommon, but possible in strict environments. See here for details on how to create an Inbound Port rule.my.enfugue.ai
, go directly to https://app.enfugue.ai:45554/
http://127.0.0.1:45555/
.If all else fails, you can always try deleting the enfugue
folder and enfugue.db
file in your ~/.cache
directory to re-initialize the application.
These flags are the precision level and format of the model. In order to use all of Enfugue's features, Enfugue will change these formats and precisions as necessary, so in theory any of them will work the same as the other. In practice, if one is available, pick Pruned
and FP16/Half
for the fastest download and processes.
There is still much to be learned about generative AI in general, and Stable Diffusion in specific. A great starting point has been preconfigured in Enfugue, but there will be no one-size-fits-all set of parameters that works for every kind of image you want to generate. The best way to learn is simply to play with the values and see what the effect is on the final image.
Additional resources will be made available as they are needed, so don't hesitate to ask for what you think will work best for you.
Enfugue uses an extension of diffusers.StableDiffusionPipeline
that provides a number of additional arguments over the typical signature, weaving between txt2img
, img2img
, inpaint
and controlnet
as necessary. It also has TensorRT support for all models in the pipeline. Start here for documentation on how it is used.
The entirety of Enfugue's capabilities are available via JSON API. Find the documentation in the wiki.
For anyone interested in building from source themselves, simply check out this repository and issue a make
command to build the associated binary release. See below for all make targets.
Build Step | Description | Depends On |
---|---|---|
clean | This target removes build artifacts. | None |
typecheck | This step runs mypy against each source file. See mypy-lang.org for details on python static typing. Mypy is ran with the --strict flag, meaning all constraints are opted in. |
Python source files |
importcheck | This step runs importcheck against each source file. See github for details on importcheck; simply put, it will produce an error if an imported module is not used. |
Python source files |
unittest | This step runs doctest against each source file. See the Python Documentation for details on doctest. This will run all tests placed in docstrings, you will see these as python commands in the documentation, prepended by >>>
|
Python source files |
test | This step runs enfugue.test.run . This will run the main method in <n>*.py files places in the test directory. |
Python source files, python test files |
vendor | This step fetches vendor resources by running all scripts under the vendor/ directory. |
Script files |
js | This step compresses and mangles the .mjs files using terser . |
src/js/*.mjs files |
css | This step minifies all css files using cssminify . |
src/css/*.css files |
html, img | These step simply copy the relevant static directories (/html , /img ) to the build directory. |
src/html/*.html files, src/img/*.* files |
sdist | This step compiles the source distribution into an installable .tar.gz file, suitable for passing to pip install . Contains all the results of the previous steps |
Python source files, passing typecheck , importcheck , unittest , and test , running vendor , compiling js , css , html , and img
|
dist | This step compiles the relevant executable artifact (and zips/tars it). | sdist |
dockerfile | This step compiles the dockerfile and prepares it for building. | sdist |
docker | This step builds the docker image. | dockerfile |
To run directly from source (in development mode,) use the scripts/run-dev.sh
script. This works on Windows (in Cygwin) and on Linux, it has not been tested on MacOS.