Skip to main content

Feedback

Records signal about whether a Decision (Aₜ) was correct. Stored feedback is consumed by POST /conditions/calibrate to derive the tighten or relax direction automatically.


Submit Decision Feedback

POST /feedback/decision

Records a feedback signal on a specific Decision (Aₜ).

ValueMeaningCalibration Effect
false_positiveCondition fired but should not have.Calibration will tighten.
false_negativeCondition did not fire but should have.Calibration will relax.
correctDecision was expected.No-op (stored for audit).
Feedback and the Equals Strategy

Feedback is stored for all strategies. But POST /conditions/calibrate always returns no_recommendation for equals conditions — feedback cannot drive numeric parameter adjustment for categorical conditions.

Request Body

ParameterTypeRequiredDescription
condition_idstringRequiredFully qualified condition identifier.
condition_versionstringRequiredExplicit condition version.
entitystringRequiredEntity the Decision (Aₜ) was made for.
timestampdatetimeRequiredISO 8601 UTC timestamp of the decision being rated.
feedbackenumRequiredfalse_positive | false_negative | correct.
notestringOptionalFree-text audit note.

Response

ParameterTypeRequiredDescription
statusenumAlwaysrecorded.
feedback_idstringAlwaysUnique feedback record identifier.

Response Codes

StatusDescription
200Feedback recorded.
400Invalid value or missing field.
401Unauthorised.
404Condition not found.

TypeScript Example

await client.feedback.decision({
conditionId: "org.high_churn",
conditionVersion: "1.0",
entity: "user_abc123",
timestamp: "2024-03-15T09:00:00Z",
feedback: "false_positive",
note: "One-off spike — user was active.",
});

// Now calibrate — direction derived automatically from stored feedback
const cal = await client.conditions.calibrate({
conditionId: "org.high_churn",
conditionVersion: "1.0",
});