eca icon indicating copy to clipboard operation
eca copied to clipboard

Configuration option to select providers/models allowed by corporate policies.

Open DeLaGuardo opened this issue 1 year ago • 13 comments

To upvote this issue, give it a thumbs up. See this list for the most upvoted issues.

DeLaGuardo avatar Sep 30 '25 12:09 DeLaGuardo

We want to support a way to restrict which models should be enabled for a project, currently, we merge with all available in global config

ericdallo avatar Sep 30 '25 14:09 ericdallo

Wouldn't it be enough to have your own behavior with a specific model? I'm thinking about what the main motivation is. If someone wants to bypass it, they can always modify the config, right?

zikajk avatar Sep 30 '25 15:09 zikajk

Hum, Agree, @DeLaGuardo, take a look at custom behaviors, but as @zikajk stated, user can always change locally the config and no one will know it, so it doesn't fix your problem

ericdallo avatar Sep 30 '25 21:09 ericdallo

The main motivation is to help with onboarding for a new maintainer. My team's corporate policy explicitly allows only one provider which is different from the default provider of eca. Right now any new team member might accidentally start to use a restricted provider if they assume the project is configured the right way from the start.

How about an alternative solution — something like the "defaultProvider" configuration option could help as well as an explicit "allow list" if connected with the already existing "defaultModel".

DeLaGuardo avatar Oct 01 '25 07:10 DeLaGuardo

I looked at custom behaviors and I got the impression that it starts only after initial login to the selected provider.

DeLaGuardo avatar Oct 01 '25 07:10 DeLaGuardo

How about an alternative solution — something like the "defaultProvider" configuration option could help as well as an explicit "allow list" if connected with the already existing "defaultModel".

Hum, still doesn't look quite right to me, you can always define a behavior and a default behavior via config for a project and that would just work, but always the user will have the possibility to change the local config or /login to other providers...

Even adding a restriction config (unallowedProviders or something), user can always open the local file, remove it and restart ECA you know? It looks to me, it's better focus on how to provide a good default for your users than try to restrict anything, WDYT?

ericdallo avatar Oct 01 '25 11:10 ericdallo

How about an alternative solution — something like the "defaultProvider" configuration option could help as well as an explicit "allow list" if connected with the already existing "defaultModel".

Hum, still doesn't look quite right to me, you can always define a behavior and a default behavior via config for a project and that would just work, but always the user will have the possibility to change the local config or /login to other providers...

Even adding a restriction config (unallowedProviders or something), user can always open the local file, remove it and restart ECA you know? It looks to me, it's better focus on how to provide a good default for your users than try to restrict anything, WDYT?

Right, I'm not focused on restrictions but on providing better default experience. This is exactly why something like "defaultProvider" might be useful. Obviously, it is always a case when someone do something on their own that might cause some policy violation. Same as you, I don't think eca should "restrict" anything besides behaviour and tools like any other agent.

DeLaGuardo avatar Oct 01 '25 12:10 DeLaGuardo

At this point, it's possible to create a custom behavior with the default model, and this custom behavior can be configured as the default one.

Something like:

{"behavior": {
  "default": {
    "defaultModel": "deepseek/deepseek-chat-v3.1",
    "toolCall": {"approval": {"byDefault": "allow"}}}},
...
"defaultBehavior": "default"}

Or you can configure just the global defaultModel. But if you want to make sure the user can choose only between, for example, 5 models by one specific provider, that's not possible right now.

Maybe we can add something like availableProviders to configuration (on root and behavior levels)?

zikajk avatar Oct 01 '25 20:10 zikajk

Yeah, I thought something similar @zikajk, availableProviders seems like a good easy approach, we could just filter on initialized when returning models and that's it.

ericdallo avatar Oct 01 '25 23:10 ericdallo

Maybe we can add something like availableProviders to configuration (on root and behavior levels)?

Sounds amazing! Will definetely solve this problem for me.

DeLaGuardo avatar Oct 02 '25 08:10 DeLaGuardo

@DeLaGuardo LMK if you wanna work on that, otherwise I will move to priorization

ericdallo avatar Oct 02 '25 13:10 ericdallo

@ericdallo Yes, I'd like to add it myself, and I might have a few questions. Would it be okay to ping you on Slack?

DeLaGuardo avatar Oct 02 '25 14:10 DeLaGuardo

Sure!

ericdallo avatar Oct 02 '25 14:10 ericdallo