Skip to content

Commit 50e340d

Browse files
committed
Ensure prefix cache plugin implements all preprae data plugin methods
1 parent 3f2a9d4 commit 50e340d

File tree

1 file changed

+8
-0
lines changed
  • pkg/epp/scheduling/framework/plugins/multi/prefix

1 file changed

+8
-0
lines changed

pkg/epp/scheduling/framework/plugins/multi/prefix/plugin.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,14 @@ func (p *Plugin) WithName(name string) *Plugin {
207207
return p
208208
}
209209

210+
func (p *Plugin) Produces() map[string]any {
211+
return map[string]any{dplugins.PrefixCacheMatchPrecentKey: dplugins.PrefixCacheMatchPercent{}}
212+
}
213+
214+
func (p *Plugin) Consumes() map[string]any {
215+
return map[string]any{}
216+
}
217+
210218
func (p *Plugin) PrepareRequestData(ctx context.Context, request *types.LLMRequest, pods []types.Pod) error {
211219
// pre score step, hashing prompt and find longest prefix match.
212220
hashes := hashPrompt(ctx, request, getBlockSize(pods, p.config), p.config.MaxPrefixBlocksToMatch)

0 commit comments

Comments
 (0)