Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aihorde do not set model #526

Open
greatlord opened this issue Nov 22, 2024 · 2 comments
Open

aihorde do not set model #526

greatlord opened this issue Nov 22, 2024 · 2 comments

Comments

@greatlord
Copy link

Hi I discover aihorde does allown you set model even you have choice one, it use random one in current code
KoboldAI/modeling/inference_models/horde/class.py
def _raw_generate(

we can found this code
cluster_metadata = {
"prompt": decoded_prompt,
"params": reqdata,
"models": [x for x in utils.koboldai_vars.cluster_requested_models if x],
"trusted_workers": False,
}

the var utils.koboldai_vars.cluster_requested_models is never set.
so I did change the code to this
matched_models = [x for x in self.models if x.get('name') == self.model_name]
cluster_metadata = {
"prompt": decoded_prompt,
"params": reqdata,
"models": self.model,
"trusted_workers": False,
}

  now it takes the model I choice, but I think it should find all model that are simulre with different names and do a array of it so it use more server
@henk717
Copy link
Owner

henk717 commented Nov 22, 2024

For modern AI horde support I recommend koboldai.net which is made specifically for it

@greatlord
Copy link
Author

Hi henk717, thanks for you tips.
I am not instreed in that, I am doing small side project in python
proxy lightweight proxy so koboldai and other can connect to LM Studio or other that have openai compatible API

I notes a bug in my code it did not respect select all value now it does
selected_model = self.model
if ( self.model == ["all"]):
selected_model = []

    cluster_metadata = {
            "prompt": decoded_prompt,
        "params": reqdata,
        "models": selected_model,
        "trusted_workers": False,
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants