MCPcopy Create free account
hub / github.com/AI45Lab/Code / builtin_confidence

Function builtin_confidence

core/src/agent/auto_delegation.rs:284–356  ·  view source on GitHub ↗
(name: &str, prompt: &str)

Source from the content-addressed store, hash-verified

282}
283
284fn builtin_confidence(name: &str, prompt: &str) -> f32 {
285 match name {
286 "explore"
287 if contains_any(
288 prompt,
289 &[
290 "find", "search", "locate", "inspect", "查找", "搜索", "定位", "探索", "检查",
291 ],
292 ) =>
293 {
294 0.84
295 }
296 "plan"
297 if contains_any(
298 prompt,
299 &["plan", "design", "architecture", "规划", "设计", "架构"],
300 ) =>
301 {
302 0.82
303 }
304 "verification"
305 if contains_any(
306 prompt,
307 &[
308 "test",
309 "verify",
310 "validate",
311 "regression",
312 "smoke",
313 "测试",
314 "验证",
315 "回归",
316 ],
317 ) =>
318 {
319 0.88
320 }
321 "review"
322 if contains_any(
323 prompt,
324 &[
325 "review",
326 "security",
327 "regression",
328 "risk",
329 "审查",
330 "评审",
331 "安全",
332 "风险",
333 ],
334 ) =>
335 {
336 0.86
337 }
338 "general"
339 if contains_any(
340 prompt,
341 &[

Callers 1

score_agent_for_promptFunction · 0.85

Calls 1

contains_anyFunction · 0.70

Tested by

no test coverage detected