Advanced Inference
advancedBayesian belief classification, Phi-B routing decisions, and Expected Free Energy evaluation.
Belief classify
POST
/v1/memory/belief/classifyClassify query via Bayesian inference: exact match, novel composition, or new pattern.
querystringrequiredText query to classify (auto-embedded).
200Response
{
"classification": "composition",
"probabilities": {
"exact_match": 0.12,
"composition": 0.73,
"novel": 0.15
},
"best_match_id": "pat_a1b2c3",
"confidence": 0.73
}Routing decide
POST
/v1/memory/routing/decideRouting decision via Phi-B geometric surprise: which pathway for a query.
querystringrequiredText query (auto-embedded).
contextstring | nullOptional context text to influence routing.
200Response
{
"pathway": "energy",
"scores": {
"exact": 0.23,
"energy": 0.89,
"attention": 0.45
},
"geometric_surprise": 0.34,
"confidence": 0.89
}EFE evaluate
POST
/v1/memory/efe/evaluateEvaluate Expected Free Energy for candidate pathways.
querystringrequiredText query (auto-embedded).
pathwaysarray[string]Default: ["exact", "energy", "attention"]Candidate pathways to evaluate.
200Response
{
"evaluations": {
"exact": {
"efe": 2.34,
"epistemic_value": 0.12,
"pragmatic_value": 0.89
},
"energy": {
"efe": 1.23,
"epistemic_value": 0.67,
"pragmatic_value": 0.92
},
"attention": {
"efe": 1.89,
"epistemic_value": 0.45,
"pragmatic_value": 0.78
}
},
"recommended": "energy"
}Tip
Lower EFE indicates a better pathway. The system uses these evaluations internally for Active Inference routing — this endpoint exposes the decision process for debugging and observability.
Next steps
- Explainability — XAI explanations of retrievals
- Regime — Operational regime
- Memory Vectors — Direct vector operations