> ## Documentation Index
> Fetch the complete documentation index at: https://docs.neosantara.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Evaluate questions against shared state

> Fast, structured decision-making and evaluation model endpoint (compatible with Vercel AI Gateway evaluate & TypeSafe Jev).



## OpenAPI

````yaml /api-reference/openapi.json post /v1/evaluate
openapi: 3.1.0
info:
  title: Neosantara AI API
  description: OpenAI-compatible LLM Gateway
  version: 1.0.0
servers:
  - url: https://api.neosantara.xyz
    description: Neosantara Production Gateway
security:
  - bearerAuth: []
paths:
  /v1/evaluate:
    post:
      tags:
        - Evaluation
      summary: Evaluate questions against shared state
      description: >-
        Fast, structured decision-making and evaluation model endpoint
        (compatible with Vercel AI Gateway evaluate & TypeSafe Jev).
      operationId: postV1Evaluate
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                model:
                  type: string
                  minLength: 1
                  default: jev
                state:
                  anyOf:
                    - type: string
                    - type: object
                      additionalProperties: {}
                    - type: array
                      items: {}
                questions:
                  type: object
                  additionalProperties:
                    oneOf:
                      - type: object
                        properties:
                          type:
                            type: string
                            const: boolean
                          instructions:
                            anyOf:
                              - type: string
                                minLength: 1
                              - type: object
                                additionalProperties: {}
                              - type: array
                                items: {}
                              - type: 'null'
                          criteria:
                            type:
                              - object
                              - 'null'
                            properties:
                              'true':
                                anyOf:
                                  - type: string
                                  - type: object
                                    additionalProperties: {}
                                  - type: array
                                    items: {}
                                  - type: 'null'
                              'false':
                                anyOf:
                                  - type: string
                                  - type: object
                                    additionalProperties: {}
                                  - type: array
                                    items: {}
                                  - type: 'null'
                            additionalProperties: false
                        required:
                          - type
                        additionalProperties: true
                      - type: object
                        properties:
                          type:
                            type: string
                            const: noul
                          instructions:
                            anyOf:
                              - type: string
                                minLength: 1
                              - type: object
                                additionalProperties: {}
                              - type: array
                                items: {}
                              - type: 'null'
                          criteria:
                            type:
                              - object
                              - 'null'
                            properties:
                              'true':
                                anyOf:
                                  - type: string
                                  - type: object
                                    additionalProperties: {}
                                  - type: array
                                    items: {}
                                  - type: 'null'
                              'false':
                                anyOf:
                                  - type: string
                                  - type: object
                                    additionalProperties: {}
                                  - type: array
                                    items: {}
                                  - type: 'null'
                            additionalProperties: false
                        required:
                          - type
                        additionalProperties: true
                      - type: object
                        properties:
                          type:
                            type: string
                            const: choice
                          instructions:
                            anyOf:
                              - type: string
                                minLength: 1
                              - type: object
                                additionalProperties: {}
                              - type: array
                                items: {}
                              - type: 'null'
                          options:
                            type: array
                            items:
                              type: string
                          criteria:
                            anyOf:
                              - type: object
                                additionalProperties:
                                  anyOf:
                                    - type: string
                                    - type: object
                                      additionalProperties: {}
                                    - type: array
                                      items: {}
                                    - type: 'null'
                              - type: array
                                items: {}
                        required:
                          - type
                        additionalProperties: true
                      - type: object
                        properties:
                          type:
                            type: string
                            const: score
                          instructions:
                            anyOf:
                              - type: string
                                minLength: 1
                              - type: object
                                additionalProperties: {}
                              - type: array
                                items: {}
                              - type: 'null'
                          criteria:
                            anyOf:
                              - type: array
                                items:
                                  anyOf:
                                    - type: string
                                    - type: object
                                      additionalProperties: {}
                                    - type: array
                                      items: {}
                                minItems: 2
                              - type: object
                                additionalProperties: {}
                          scoring_rubric:
                            type: object
                            additionalProperties: {}
                        required:
                          - type
                        additionalProperties: true
              required:
                - state
                - questions
              additionalProperties: true
      responses:
        '200':
          description: Successful evaluation result
          content:
            application/json:
              schema:
                type: object
                properties:
                  model:
                    type: string
                  answers:
                    type: object
                    additionalProperties: {}
                  usage:
                    type: object
                    properties:
                      inputTokens:
                        type: number
                      outputTokens:
                        type: number
                required:
                  - model
                  - answers
        '400':
          description: Invalid request payload or question format
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      message:
                        type: string
                      type:
                        type: string
                      param:
                        type:
                          - string
                          - 'null'
                      code:
                        type:
                          - string
                          - 'null'
                    required:
                      - message
                required:
                  - error
        '404':
          description: Model not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      message:
                        type: string
                      type:
                        type: string
                      param:
                        type:
                          - string
                          - 'null'
                      code:
                        type:
                          - string
                          - 'null'
                    required:
                      - message
                required:
                  - error
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      message:
                        type: string
                      type:
                        type: string
                      param:
                        type:
                          - string
                          - 'null'
                      code:
                        type:
                          - string
                          - 'null'
                    required:
                      - message
                required:
                  - error
        '503':
          description: Upstream evaluation service unavailable
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      message:
                        type: string
                      type:
                        type: string
                      param:
                        type:
                          - string
                          - 'null'
                      code:
                        type:
                          - string
                          - 'null'
                    required:
                      - message
                required:
                  - error
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````

## Related topics

- [TypeSafe System One compatible evaluation](/api-reference/evaluation/typesafe-system-one-compatible-evaluation.md)
- [Percakapan & State](/id/gateway/responses-api/conversations.md)
- [Daytona Code Interpreter](/id/integrations/daytona-code-interpreter.md)
- [Tugas Latar Belakang & Webhook](/id/gateway/responses-api/background-jobs.md)
- [Server Tools & Integrasi MCP](/id/gateway/responses-api/tools.md)
