# 量化模型

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /api/create:
    post:
      summary: 量化模型
      deprecated: false
      description: Quantize a non-quantized model.
      tags:
        - 创建模型
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                model:
                  type: string
                  const: llama3.1:quantized
                  examples:
                    - llama3.1:quantized
                from:
                  type: string
                  const: llama3.1:8b-instruct-fp16
                  examples:
                    - llama3.1:8b-instruct-fp16
                quantize:
                  type: string
                  const: q4_K_M
                  examples:
                    - q4_K_M
              required:
                - model
                - from
                - quantize
            examples: {}
      responses:
        '200':
          description: 'A stream of JSON objects is returned:'
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                required:
                  - status
                x-apifox-orders:
                  - status
              example: "{\"status\":\"quantizing F16 model to Q4_K_M\"}\r\n{\"status\":\"creating new layer sha256:667b0c1932bc6ffc593ed1d03f895bf2dc8dc6df21db3042284a6f4416b06a29\"}\r\n{\"status\":\"using existing layer sha256:11ce4ee3e170f6adebac9a991c22e22ab3f8530e154ee669954c4bc73061c258\"}\r\n{\"status\":\"using existing layer sha256:0ba8f0e314b4264dfd19df045cde9d4c394a52474bf92ed6a3de22a4ca31a177\"}\r\n{\"status\":\"using existing layer sha256:56bb8bd477a519ffa694fc449c2413c6f0e1d3b1c88fa7e3c9d88d3ae49d4dcb\"}\r\n{\"status\":\"creating new layer sha256:455f34728c9b5dd3376378bfb809ee166c145b0b4c1f1a6feca069055066ef9a\"}\r\n{\"status\":\"writing manifest\"}\r\n{\"status\":\"success\"}"
          headers: {}
          x-apifox-name: Success
      security: []
      x-apifox-folder: 创建模型
      x-apifox-status: released
      x-run-in-apifox: https://app.apifox.com/web/project/6041320/apis/api-272428833-run
components:
  schemas: {}
  securitySchemes: {}
servers:
  - url: http://localhost:11434/api/
    description: 正式环境
security: []

```
