MCPcopy Index your code
hub / github.com/docker/docker-agent / registerModelHook

Function registerModelHook

pkg/runtime/model_hook.go:89–91  ·  view source on GitHub ↗

registerModelHook installs the [hooks.HookTypeModel] factory on r using the runtime's default [hooks.ModelClient]. It is called once from [NewLocalRuntime] alongside the builtins.

(r *hooks.Registry, registry *provider.Registry)

Source from the content-addressed store, hash-verified

87// using the runtime's default [hooks.ModelClient]. It is called once
88// from [NewLocalRuntime] alongside the builtins.
89func registerModelHook(r *hooks.Registry, registry *provider.Registry) {
90 r.Register(hooks.HookTypeModel, hooks.NewModelFactory(providerModelClient{registry: registry}))
91}

Callers 1

NewLocalRuntimeFunction · 0.85

Calls 2

NewModelFactoryFunction · 0.92
RegisterMethod · 0.45

Tested by

no test coverage detected