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

# Get Generation Stats

> Run stats for each attribute in the project with AI generation attached.
Attributes without generation are omitted. `GET /metadata/generation/stats`
is the deprecated form of this route.



## OpenAPI

````yaml /api-reference/openapi.json get /metadata/attributes/stats
openapi: 3.1.0
info:
  title: Aspect API
  description: Manage and search media in Aspect.
  version: 1.0.0
servers:
  - url: https://api.aspect.inc
security:
  - ApiKeyAuth: []
tags:
  - name: Users
  - name: API Keys
  - name: Workspaces
  - name: Projects
  - name: Directories
  - name: Assets
  - name: Attachments
  - name: Filesystem Items
  - name: Jobs
  - name: Collections
  - name: Comments
  - name: Search
  - name: Transcription
  - name: Metadata
  - name: Shares
  - name: Share Templates
  - name: Watermarks
paths:
  /metadata/attributes/stats:
    get:
      tags:
        - Metadata
      summary: Get Generation Stats
      description: >-
        Run stats for each attribute in the project with AI generation attached.

        Attributes without generation are omitted. `GET
        /metadata/generation/stats`

        is the deprecated form of this route.
      operationId: get_generation_stats
      parameters:
        - name: project_id
          in: query
          required: true
          schema:
            type: string
            format: uuid
            title: Project Id
            description: Project ID
          description: Project ID
        - name: attribute_ids
          in: query
          required: false
          schema:
            anyOf:
              - type: array
                items:
                  type: string
                  format: uuid
                minItems: 1
              - type: 'null'
            description: Only return stats for these attributes
            title: Attribute Ids
          description: Only return stats for these attributes
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MetadataGenerationStatsResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    MetadataGenerationStatsResponse:
      properties:
        columns:
          items:
            $ref: '#/components/schemas/CellColumnStats'
          type: array
          title: Columns
          description: One entry per AI-generated attribute
      type: object
      required:
        - columns
      title: MetadataGenerationStatsResponse
      description: API response schema for the per-column stats read.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    CellColumnStats:
      properties:
        column_id:
          type: string
          format: uuid
          title: Column Id
          description: 'Column ID: the attribute or object'
        pending:
          type: integer
          title: Pending
          description: Assets with a pass scheduled or in progress
        coverage:
          anyOf:
            - $ref: '#/components/schemas/CellCoverage'
            - type: 'null'
          description: Counts over the column's watch; null when the column watches nothing
      type: object
      required:
        - column_id
        - pending
      title: CellColumnStats
      description: |-
        One column's live counts: coverage is bounded by its current watch and
        absent when it watches nothing; pending counts every scheduled pass,
        including runs outside the watch.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    CellCoverage:
      properties:
        eligible:
          type: integer
          title: Eligible
          description: Cells the watch covers
        run:
          type: integer
          title: Run
          description: Watched cells with an answer, empty answers included
        failed:
          type: integer
          title: Failed
          description: Watched cells with no answer whose last pass failed
        not_run:
          type: integer
          title: Not Run
          description: Watched cells with no answer and no failed pass
      type: object
      required:
        - eligible
        - run
        - failed
        - not_run
      title: CellCoverage
      description: >-
        A watched column's live counts over its watch, partitioning the cells

        it covers: ``eligible == run + failed + not_run``. An answer outranks a

        failure, so a failed re-run over a kept value counts as run. An
        unwatched

        column has no territory to count, so it has no coverage.
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: Aspect API key (sk_...) in Authorization header. 'Bearer ' optional.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.