B06_Decisions
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
php examples/B06_Decisions/ProviderEvaluation/evaluate.php classifier-dev
<?php
require 'examples/boot.php';
use Cognesy\Polyglot\Decision\Decision;
$response = Decision::using('classifier-dev')
->with(input: 'Refund the duplicate charge today.', questions: $questions)
->response();
// Evaluate typed probabilities and values against independently labeled cases.
$refundProbability = $response->answers()->noul('refund_requested')->probability();
$department = $response->answers()->choice('department')->value();
$urgency = $response->answers()->score('urgency')->value();
?>