anky2002 commited on
Commit
de2543d
·
verified ·
1 Parent(s): 4883725

Upload bayesian_engine.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. bayesian_engine.py +5 -1
bayesian_engine.py CHANGED
@@ -276,15 +276,19 @@ def bayesian_synthesis(agent_results: List[AgentEvidence]) -> ForensicVerdict:
276
  posterior_calibrated = temperature_scaling(posterior, temperature=1.3)
277
 
278
  # Step 6: Determine verdict and confidence
 
279
  if posterior_calibrated > 0.85:
280
  verdict = "FAKE"
281
  conf_label = "Very High"
282
  elif posterior_calibrated > 0.65:
283
  verdict = "LIKELY FAKE"
284
  conf_label = "High"
285
- elif posterior_calibrated > 0.45:
286
  verdict = "SUSPICIOUS"
287
  conf_label = "Moderate"
 
 
 
288
  elif posterior_calibrated > 0.25:
289
  verdict = "LIKELY AUTHENTIC"
290
  conf_label = "Moderate"
 
276
  posterior_calibrated = temperature_scaling(posterior, temperature=1.3)
277
 
278
  # Step 6: Determine verdict and confidence
279
+ # Fix: 48-52% is INCONCLUSIVE (posterior ≈ prior means evidence contributed nothing)
280
  if posterior_calibrated > 0.85:
281
  verdict = "FAKE"
282
  conf_label = "Very High"
283
  elif posterior_calibrated > 0.65:
284
  verdict = "LIKELY FAKE"
285
  conf_label = "High"
286
+ elif posterior_calibrated > 0.52:
287
  verdict = "SUSPICIOUS"
288
  conf_label = "Moderate"
289
+ elif posterior_calibrated >= 0.48:
290
+ verdict = "INCONCLUSIVE"
291
+ conf_label = "Low"
292
  elif posterior_calibrated > 0.25:
293
  verdict = "LIKELY AUTHENTIC"
294
  conf_label = "Moderate"