griptape-ai / ComfyUI-Griptape

A suite of Griptape nodes for ComfyUI
Apache License 2.0
97 stars 11 forks source link

Griptape Agent Config: Ollama #91

Closed freshlesh3 closed 3 days ago

freshlesh3 commented 1 month ago

Describe the bug When I use the node the prompt model list does not appear

To Reproduce Steps to reproduce the behavior:

  1. Insert Griptape Agent Config: Ollama
  2. Click on 'prompt model'
  3. List of Ollama models not available

Expected behavior List of Ollama LM models

Screenshots image

Desktop (please complete the following information):

Additional context I am running the latest update of Ollama. Tested with several models. When I run the Model, I see in terminal: [rgthree] First run patching recursive_output_delete_if_changed and recursive_will_execute. [rgthree] Note: If execution seems broken due to forward ComfyUI changes, you can disable the optimization from rgthree settings in ComfyUI.

When I use other Agents the text is not displayed but a response is visible in the terminal.

shhlife commented 1 month ago

Hi @freshlesh3 - if you refresh the page, I'm assuming the models don't show up?

is there any text in the developer console?

Another thing to try - can you open powershell and execute the following code:

# URL to fetch the local models
$url = "http://127.0.0.1:11434/api/tags"

# Make the GET request
$response = Invoke-RestMethod -Uri $url -Method Get -ErrorAction Stop

# Extract the model names
$models = $response.models | ForEach-Object { $_.name }

# Output the models
$models

What do you get?

freshlesh3 commented 1 month ago

Hi @shhlife thanks for your response. It returns a list of all the ollama models I use.

llama3-groq-tool-use:latest llama3.1:latest llava:7b taozhiyuai/llama-3-8b-lexi-uncensored:f16 llama2-uncensored:latest mannix/llama3-uncensored:latest llava:latest deepseek-coder-v2-english:latest ...

shhlife commented 1 month ago

@freshlesh3 okay - that's the code I'm using to get the models.. so it should be returning something. and doing a ctrl+r in the browser doesn't refresh the list and show them?

freshlesh3 commented 1 month ago

@shhlife No nothing. Refreshing, reloading, restarting still blank.

shhlife commented 1 month ago

Thanks @freshlesh3, and you've updated the griptape nodes with the latest? btw - I'm about to jump on a plane so I'll be out of contact for most of the day, but will keep working on this with you when I have access!

freshlesh3 commented 1 month ago

@shhlife, No problem, really appreciate the help. I'm on the latest version.

shhlife commented 1 month ago

Can you try the compatible driver?

image

freshlesh3 commented 1 month ago

I see the response appear and the promptask is run in the terminal but the text display does not appear in the display text node.

freshlesh3 commented 1 month ago

I also get an error when running the OpenAI agent as well. It tries to use a previously set OpenAI API key that is no longer active and been replaced in the .env file. Error code: 401 - {'error': {'message': 'Incorrect API key provided: sk-2bOuG***II7o.

shhlife commented 1 month ago

It sounds like you might be caught in an old install - can you try deleting the griptape custom nodes and re-installing? Maybe they didn’t update correctly..Cheers!-jasonSent from my iPhoneOn 26 Jul 2024, at 10:24 AM, StudioBFD @.*> wrote: I also get an error when running the OpenAI agent as well. It tries to use a previously set OpenAI API key that is no longer active and been replaced in the .env file. Error code: 401 - {'error': {'message': 'Incorrect API key provided: sk-2bOuG*****II7o.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: @.***>

freshlesh3 commented 1 month ago

There is a conflict with another custom node. I did an clean install on a vanilla ComfyUI build and don't have the issues. I don't have the time to investigate which one at the moment but will update the thread once I find it. Thanks @shhlife for the assist.

shhlife commented 1 month ago

So glad you were able to get it resolved - when you have time, let me know which node the conflict is with and I'll figure out how to get around it :) cheers!

-jason

PiDrawings commented 1 month ago

So, Having same issue, not having a list of Ollama models, but also display: text is not showing any while in terminal got responses, even tried to save to text the output, it works, but not showing in display: image image script for checking models downloaded output: codestral:latest mistral-large:latest phi3:14b phi3:latest llama3:latest

in the node I have only possibility to manually input.

Small Upate: Combine: Tool List also does not show properly, having only tool_1 on the left: image

shhlife commented 1 month ago

Okay - thanks for the detailed feedback and the images. The griptape framework just pushed a new release today that may resolve some of these issues. I’m at SIGGRAPH in Denver this week, but will try and get some time to see if this will fix it.

Note, the griptape comfyUI nodes won’t be using the new framework release yet because they are pinned to specific versions of the framework to limit the potential for breaking in case there are any changes that impact existing nodes. But I’ll try and test and update as soon as possible. Early next week at the latest!

PiDrawings commented 1 month ago

Okay - thanks for the detailed feedback and the images. The griptape framework just pushed a new release today that may resolve some of these issues. I’m at SIGGRAPH in Denver this week, but will try and get some time to see if this will fix it.

Note, the griptape comfyUI nodes won’t be using the new framework release yet because they are pinned to specific versions of the framework to limit the potential for breaking in case there are any changes that impact existing nodes. But I’ll try and test and update as soon as possible. Early next week at the latest!

Thanks for that, most Issues are gone when I've disabled all of my custom nodes. Still not seeing list of models in ollama, but consolidation of tools looks to work and I can see llm outputs in display text node. If will notice which custom node is impacting rest of issues spotted earlier, will give a hint in here.

shhlife commented 3 days ago

Hi, this should be resolved - please let me know if you're still seeing it.