MCPcopy Create free account
hub / github.com/openai/plugins / inferGoalFromRequest

Function inferGoalFromRequest

plugins/plugin-eval/src/core/workflow-guide.js:56–163  ·  view source on GitHub ↗
(requestText)

Source from the content-addressed store, hash-verified

54}
55
56function inferGoalFromRequest(requestText) {
57 const normalized = String(requestText || "")
58 .trim()
59 .toLowerCase();
60
61 if (!normalized) {
62 return null;
63 }
64
65 const signals = [
66 [
67 "analysis",
68 requestSignal(
69 [
70 "full analysis",
71 "full eval",
72 "full evaluation",
73 "analyze this",
74 "analysis of",
75 "give me an analysis",
76 "deep analysis",
77 "deep dive",
78 ],
79 "it asks for a fuller analysis flow instead of only a single report or benchmark step",
80 ),
81 ],
82 [
83 "measure",
84 requestSignal(
85 [
86 "measure the real token usage",
87 "real token usage",
88 "observed usage",
89 "actual token usage",
90 "measure token usage",
91 ],
92 "it asks for measured or observed token usage",
93 ),
94 ],
95 [
96 "benchmark",
97 requestSignal(
98 [
99 "benchmark",
100 "dry-run",
101 "dry run",
102 "starter scenario",
103 "scenario",
104 ],
105 "it asks for a benchmark flow or scenario harness",
106 ),
107 ],
108 [
109 "budget",
110 requestSignal(
111 [
112 "explain the token budget",
113 "token budget",

Callers 1

buildWorkflowGuideFunction · 0.85

Calls 1

requestSignalFunction · 0.85

Tested by

no test coverage detected