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

# Submit Feedback Signal

> Submit a feedback signal to assess model performance for a specific inference. Feedback signals are used for reinforcement learning and model improvement.

**Authentication**: Requires the same API key authentication as inference requests. For JWT-enabled keys, the user ID from the JWT will be included in the feedback metadata.



## OpenAPI

````yaml POST /{project_uid}/feedback/{inference_log_id}
openapi: 3.0.1
info:
  title: Datawizz
  description: The Datawizz API
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://www.datawizz.app/api
    description: Datawizz Dashboard API
  - url: https://gw.datawizz.app
    description: Datawizz AI Gateway
security:
  - bearerAuth: []
paths:
  /{project_uid}/feedback/{inference_log_id}:
    post:
      tags:
        - Feedback
      summary: Submit feedback signal for an inference
      description: >-
        Submit a feedback signal to assess model performance for a specific
        inference. Feedback signals are used for reinforcement learning and
        model improvement.


        **Authentication**: Requires the same API key authentication as
        inference requests. For JWT-enabled keys, the user ID from the JWT will
        be included in the feedback metadata.
      operationId: submitFeedback
      parameters:
        - name: project_uid
          in: path
          required: true
          description: The unique identifier of the project
          schema:
            type: string
            format: uuid
        - name: inference_log_id
          in: path
          required: true
          description: The unique identifier of the inference log
          schema:
            type: string
            format: uuid
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/FeedbackSignalRequest'
            examples:
              positive_feedback:
                summary: Positive feedback with high score
                value:
                  score: 0.9
                  weight: 1
                  signal_source: user
                  signal_type: explicit
                  qualitative_feedback: Great response, very helpful!
              negative_feedback:
                summary: Negative feedback with improvement
                value:
                  score: -0.5
                  weight: 0.8
                  signal_source: user
                  signal_type: explicit
                  qualitative_feedback: Response was inaccurate
                  improvement:
                    role: assistant
                    content: Here is the corrected response...
      responses:
        '201':
          description: Feedback signal recorded successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    format: uuid
                    description: The unique identifier of the feedback signal
                  message:
                    type: string
                    example: Feedback signal recorded successfully
        '400':
          description: Bad request - Invalid feedback data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized - Invalid or missing API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Forbidden - Inference log does not belong to this project
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not found - Inference log not found or expired
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      servers:
        - url: https://gw.datawizz.app
components:
  schemas:
    FeedbackSignalRequest:
      type: object
      required:
        - score
        - weight
      properties:
        score:
          type: number
          format: float
          minimum: -1
          maximum: 1
          description: Quality score of the response (-1 is worst, 1 is best)
          example: 0.8
        weight:
          type: number
          format: float
          minimum: 0
          maximum: 1
          description: >-
            Importance of this signal (0 is least important, 1 is most
            important)
          example: 1
        improvement:
          type: object
          nullable: true
          description: >-
            An improved version of the response (used for supervised
            fine-tuning)
          example:
            role: assistant
            content: Improved response text...
        qualitative_feedback:
          type: string
          nullable: true
          description: Qualitative feedback about the response (used for RLHF)
          example: The response was accurate but could be more concise
        signal_name:
          type: string
          nullable: true
          description: Name of the signal/sensor for observability
          example: user_thumbs_up
        signal_source:
          type: string
          enum:
            - system
            - user
          default: user
          description: Source of the feedback signal
          example: user
        signal_type:
          type: string
          enum:
            - explicit
            - implicit
          default: explicit
          description: Type of feedback signal
          example: explicit
        metadata:
          type: object
          nullable: true
          description: Additional metadata for observability
          example:
            ui_version: 1.2.3
            session_id: abc123
    Error:
      required:
        - error
        - message
      type: object
      properties:
        error:
          type: integer
          format: int32
        message:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````