Introduction

In modern user interface design, the optimization of the user experience is an ongoing pursuit. ComyUI, as an advanced user interface, helps users complete tasks more efficiently by integrating large language models. This article will detail how to use large language models on ComyUI to reverse-engineer prompts, thereby enhancing the fluidity and efficiency of user interactions.

Step One: Download and Install Ollama

Ollama is an open-source large language model service tool designed to allow users to run large language models (LLMs) on their local devices.

We download Ollama from the official website: https://ollama.com/

Choose the appropriate system for download and installation.

image.png

Download the Ollama model. Click on the 'models' at the top right of the website to see a variety of models. Here, we will use the 'llava-phi3' model as an example to teach you how to install it. The 'llava-phi3' is a visual model that can recognize our images and generate prompts, which is very useful.

image.png

On the 'llava-phi3' homepage, copy the command 'ollama run llava-phi3:latest'.

image.png

Ensure that your Ollama is installed and running.

image.png

Then, open the CMD command line window, paste the copied command, and Ollama will automatically download the model and invoke it.

image.png

You can send messages to start a conversation, which indicates a successful installation.

image.png

Step Two: Download the ComfyUI Ollama Plugin

We search for Ollama in the manager and install it.

You can also install via Git URL: https://github.com/stavsap/comfyui-ollama

image.png

Step Three: Use Ollama in ComfyUI

After installation, we can use the Ollama Vision node to generate prompts based on the images we provide.

image.png

Example: If you are using the SD3 or Kolors model with strong semantic understanding, this plugin is very useful. If you are using SD1.5 or SDXL, use the WD1.4 tag to reverse-engineer prompts.

image.png

Conclusion

Following the above steps, you can effectively use large language models on ComyUI to reverse-engineer prompts and enhance the user experience.

------------------------------------------------------------------------------------------

The AI tutorial of Chinaz Stationery is part of the AI drawing tutorial platform under Chinaz Stationery

A large number of AI free tutorials, continuously updated dry goods content

To learn more about AI drawing tutorials in depth, please visit

https://aisc.chinaz.com/jiaocheng/