File tree 3 files changed +4
-2
lines changed 3 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -68,7 +68,6 @@ func downloadFile(url string) (string, error) {
68
68
func ImageEndpoint (cl * config.BackendConfigLoader , ml * model.ModelLoader , appConfig * config.ApplicationConfig ) func (c * fiber.Ctx ) error {
69
69
return func (c * fiber.Ctx ) error {
70
70
input , ok := c .Locals (middleware .CONTEXT_LOCALS_KEY_LOCALAI_REQUEST ).(* schema.OpenAIRequest )
71
- log .Warn ().Str ("input" , fmt .Sprintf ("%+v" , * input )).Msg ("TEMP IMAGE TRACE" )
72
71
if ! ok || input .Model == "" {
73
72
log .Error ().Msg ("Image Endpoint - Invalid Input" )
74
73
return fiber .ErrBadRequest
Original file line number Diff line number Diff line change @@ -109,6 +109,7 @@ func RegisterOpenAIRoutes(app *fiber.App,
109
109
// images
110
110
app .Post ("/v1/images/generations" ,
111
111
re .BuildConstantDefaultModelNameMiddleware (model .StableDiffusionBackend ),
112
+ re .SetModelAndConfig (func () schema.LocalAIRequest { return new (schema.OpenAIRequest ) }),
112
113
re .SetOpenAIRequest ,
113
114
openai .ImageEndpoint (cl , ml , appConfig ))
114
115
Original file line number Diff line number Diff line change @@ -235,7 +235,9 @@ var _ = Describe("E2E test", func() {
235
235
modelName := "jina-reranker-v1-base-en"
236
236
237
237
req := schema.JINARerankRequest {
238
- Model : modelName ,
238
+ BasicModelRequest : schema.BasicModelRequest {
239
+ Model : modelName ,
240
+ },
239
241
Query : "Organic skincare products for sensitive skin" ,
240
242
Documents : []string {
241
243
"Eco-friendly kitchenware for modern homes" ,
You can’t perform that action at this time.
0 commit comments