Guardrails API Documentation
Guardrails APIs
- GETHealth Check
- GETStatus Check
- GETModels Loaded
- POSTGuardrails Detect
- POSTGuardrails Batch Detect
- POSTPII anonymization and de-anonymization
- POSTDetect Hallucination
- POSTGuardrails Adherence
- POSTGuardrails Relevancy
- POSTAdd Policy
- GETGet Policy
- PATCHModify Policy
- DELDelete Policy
- GETList Policies
- POSTDetect with Policy
Guardrails APIs
Guardrails Adherence
POST
/
guardrails
/
adherence
Copy
Ask AI
curl --request POST \
--url https://api.enkryptai.com/guardrails/adherence \
--header 'Content-Type: application/json' \
--header 'apikey: <api-key>' \
--data '{
"llm_answer": "C.V. Raman won the Nobel Prize for Physics in 1930 for his work on making some science stuff or cooking stuff",
"context": "Indian scientists have made significant contributions to various scientific fields. C.V. Raman won the Nobel Prize for Physics in 1930 for his work on light scattering. Other notable scientists include Srinivasa Ramanujan, a mathematical genius, and A.P.J. Abdul Kalam, a key figure in India'\''s aerospace and nuclear programs."
}'
Copy
Ask AI
{
"adherence_score": 0.5
}
Authorizations
Body
application/json
Response
200 - application/json
Successful Response
The response is of type object
.
Copy
Ask AI
curl --request POST \
--url https://api.enkryptai.com/guardrails/adherence \
--header 'Content-Type: application/json' \
--header 'apikey: <api-key>' \
--data '{
"llm_answer": "C.V. Raman won the Nobel Prize for Physics in 1930 for his work on making some science stuff or cooking stuff",
"context": "Indian scientists have made significant contributions to various scientific fields. C.V. Raman won the Nobel Prize for Physics in 1930 for his work on light scattering. Other notable scientists include Srinivasa Ramanujan, a mathematical genius, and A.P.J. Abdul Kalam, a key figure in India'\''s aerospace and nuclear programs."
}'
Copy
Ask AI
{
"adherence_score": 0.5
}
Assistant
Responses are generated using AI and may contain mistakes.