MCPcopy
hub / github.com/mudler/LocalAI / writeCandidate

Function writeCandidate

core/http/middleware/route_model_test.go:417–420  ·  view source on GitHub ↗
(modelDir, name string)

Source from the content-addressed store, hash-verified

415}
416
417func writeCandidate(modelDir, name string) {
418 body := "name: " + name + "\nbackend: mock-backend\n"
419 Expect(os.WriteFile(filepath.Join(modelDir, name+".yaml"), []byte(body), 0o644)).To(Succeed())
420}
421
422func toYAML(cfg *config.ModelConfig) string {
423 b, err := yaml.Marshal(cfg)

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected