Skip to content

Commit 79dd758

Browse files
committed
Fix path to different versions of the SQLi model
1 parent ca513f0 commit 79dd758

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugin/plugin.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ func (p *Plugin) OnTrafficFromClient(ctx context.Context, req *v1.Struct) (*v1.S
125125
var output map[string]interface{}
126126
err = requests.
127127
URL(p.ServingAPIAddress).
128-
Path(fmt.Sprintf("/v%s/models/%s:predict", p.ModelVersion, p.ModelName)).
128+
Path(fmt.Sprintf("/v1/models/%s/versions/%s:predict", p.ModelName, p.ModelVersion)).
129129
BodyJSON(map[string]interface{}{
130130
"inputs": []interface{}{cast.ToSlice(tokens["tokens"])},
131131
}).

0 commit comments

Comments
 (0)