MCPcopy Create free account
hub / github.com/electric-sql/electric / enabledModelSet

Function enabledModelSet

packages/agents/src/model-catalog.ts:220–230  ·  view source on GitHub ↗
(
  values: ReadonlyArray<string> | null | undefined
)

Source from the content-addressed store, hash-verified

218}
219
220function enabledModelSet(
221 values: ReadonlyArray<string> | null | undefined
222): Set<string> | null {
223 if (!values) return null
224 const enabled = new Set<string>()
225 for (const value of values) {
226 const trimmed = value.trim()
227 if (trimmed) enabled.add(trimmed)
228 }
229 return enabled.size > 0 ? enabled : null
230}
231
232function filterChoicesByEnabledModels(
233 choices: Array<BuiltinModelChoice>,

Callers 1

Calls 1

addMethod · 0.45

Tested by

no test coverage detected