본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

AI 프롬프트 템플릿 플러그인 구성 참조

원문 보기 위키 갱신

AI 프롬프트 템플릿 플러그인 구성 참조 (AI Prompt Template Plugin Configuration Reference)

이 문서는 Kong의 AI 프롬프트 템플릿 플러그인에서 설정할 수 있는 구성 옵션을 스키마 형태로 정리한 참조 자료예요. 템플릿 이름과 mustache 스타일 플레이스홀더 정의 방법, 템플릿과 매칭되지 않는 요청 허용 여부, 원본 요청 로깅, 요청 본문 최대 크기 같은 파라미터의 기본값과 설명을 한눈에 확인할 수 있어요. consumer나 consumer_group, protocols처럼 플러그인 적용 대상과 프로토콜 범위를 지정하는 공통 필드도 함께 다루고 있어요

출처: 문서

본문

{
  "properties": {
    "config": {
      "properties": {
        "allow_untemplated_requests": {
          "default": true,
          "description": "Set true to allow requests that don't call or match any template.",
          "type": "boolean"
        },
        "log_original_request": {
          "default": false,
          "description": "Set true to add the original request to the Kong log plugin(s) output.",
          "type": "boolean"
        },
        "max_request_body_size": {
          "default": 1048576,
          "description": "max allowed body size allowed to be introspected. 0 means unlimited, but the size of this body will still be limited by Nginx's client_max_body_size.",
          "type": "integer"
        },
        "templates": {
          "description": "Array of templates available to the request context.",
          "items": {
            "properties": {
              "name": {
                "description": "Unique name for the template, can be called with `{template://NAME}`",
                "type": "string"
              },
              "template": {
                "description": "Template string for this request, supports mustache-style `{{placeholders}}`",
                "type": "string"
              }
            },
            "required": [
              "name",
              "template"
            ],
            "type": "object"
          },
          "type": "array"
        }
      },
      "required": [
        "templates"
      ],
      "type": "object"
    },
    "consumer": {
      "additionalProperties": false,
      "description": "If set, the plugin will activate only for requests where the specified has been authenticated. (Note that some plugins can not be restricted to consumers this way.). Leave unset for the plugin to activate regardless of the authenticated Consumer.",
      "properties": {
        "id": {
          "type": "string"
        }
      },
      "type": "object"
    },
    "consumer_group": {
      "additionalProperties": false,
      "description": "If set, the plugin will activate only for requests where the specified consumer group has been authenticated. (Note that some plugins can not be restricted to consumers groups this way.). Leave unset for the plugin to activate regardless of the authenticated Consumer Groups",
      "properties": {
        "id": {
          "type": "string"
        }
      },
      "type": "object"
    },
    "expressions": {
      "additionalProperties": true,
      "type": "object"
    },
    "protocols": {
      "default": [
        "grpc",
        "grpcs",
        "http",
        "https"
      ],
      "description": "A set of strings representing HTTP protocols.",
      "items": {
        "enum": [
          "grpc",
          "grpcs",
          "http",
          "https"
        ],
        "type": "string"
      },
      "type": "array"
    },
    "route": {
      "additionalProperties": false,
      "description": "If set, the plugin will only activate when receiving requests via the specified route. Leave unset for the plugin to activate regardless of the route being used.",
      "properties": {
        "id": {
          "type": "string"
        }
      },
      "type": "object"
    },
    "service": {
      "additionalProperties": false,
      "description": "If set, the plugin will only activate when receiving requests via one of the routes belonging to the specified Service. Leave unset for the plugin to activate regardless of the Service being matched.",
      "properties": {
        "id": {
          "type": "string"
        }
      },
      "type": "object"
    }
  },
  "required": [
    "config"
  ]
}

더 알아보기 (Learn more)

이 문서에는 원문에서 추출한 별도의 관련 문서 링크가 없어요.