AI RAG Injector 플러그인 OpenAPI 명세
AI RAG Injector 플러그인 OpenAPI 명세 (AI RAG Injector Plugin OpenAPI Specification)
이 문서는 AI RAG Injector 플러그인을 통해 Kong에서 청크 수집과 검색을 관리하는 API의 OpenAPI 명세예요. 프롬프트를 기반으로 관련 청크를 조회하는 lookup_chunks 엔드포인트의 경로, 파라미터, 요청·응답 형식이 상세히 정의되어 있어요. Kong Admin API 기본 URL 구성이나 personalAccessToken 보안 스킴처럼 API를 호출할 때 필요한 정보도 함께 확인할 수 있어요
출처: 문서
본문
---
openapi: 3.0.2
info:
title: AI RAG Injector API
version: 1.0.0
description: API for managing chunk ingestion and retrieval in Kong via the AI RAG
Injector plugin.
contact:
email: docs@konghq.com
name: Kong Inc
url: https://konghq.com
externalDocs:
description: AI RAG Injector Plugin API Specification
url: https://developer.konghq.com
servers:
- description: Default Admin API URL
url: "{protocol}://{hostname}:{port}{path}"
variables:
hostname:
default: localhost
description: Hostname for Kong's Admin API
path:
default: "/"
description: Base path for Kong's Admin API
port:
default: '8001'
description: Port for Kong's Admin API
protocol:
default: http
description: Protocol for requests to Kong's Admin API
enum:
- http
- https
security:
- personalAccessToken: []
paths:
"/ai-rag-injector/{plugin_id}/lookup_chunks":
post:
operationId: lookupChunks
summary: Retrieve Relevant Chunks for a Prompt
description: Looks up relevant chunks in the AI RAG Injector plugin based on
the provided prompt.
parameters:
- name: plugin_id
in: path
required: true
description: The ID of the AI RAG Injector plugin instance.
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
prompt:
type: string
description: The prompt used to retrieve relevant chunks.
exclude_contents:
type: boolean
description: Whether to exclude chunk contents in the response.
responses:
'200':
description: Relevant chunks found.
content:
application/json:
schema:
type: object
properties:
contents:
type: array
description: List of relevant chunks.
items:
type: string
metadata:
type: object
description: Metadata related to the retrieved chunks.
properties:
chunk_ids:
type: array
items:
type: string
description: Identifiers of retrieved chunks.
'400':
description: Invalid request, missing or incorrect parameters.
'404':
description: Plugin not found.
'500':
description: Internal server error.
tags:
- AI RAG Injector
"/ai-rag-injector/{plugin_id}/ingest_chunk":
post:
operationId: ingestChunk
summary: Ingest a Chunk into the AI RAG System
description: Ingests a chunk of content into the AI RAG Injector plugin for
retrieval in future queries.
parameters:
- name: plugin_id
in: path
required: true
description: The ID of the AI RAG Injector plugin instance.
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
content:
type: string
description: The content to be ingested into the AI RAG system.
responses:
'200':
description: Chunk successfully ingested.
content:
application/json:
schema:
type: object
properties:
metadata:
type: object
description: Metadata related to the ingested chunk.
properties:
chunk_id:
type: string
description: Unique identifier of the ingested chunk.
ingest_duration:
type: integer
description: Time taken to ingest the chunk in milliseconds.
embeddings_tokens_count:
type: integer
description: Number of tokens used in embeddings.
'400':
description: Invalid request, missing or incorrect parameters.
'404':
description: Plugin not found.
'500':
description: Internal server error.
tags:
- AI RAG Injector
tags:
- name: AI RAG Injector
description: API endpoints for managing chunk ingestion and retrieval in Kong via
the AI RAG Injector plugin.
components:
securitySchemes:
personalAccessToken:
type: http
scheme: bearer
bearerFormat: Token
관련 리소스
더 알아보기 (Learn more)
- AI RAG Injector 플러그인으로 챗봇이 컴플라이언스 정책을 따르도록 만드는 방법을 단계별로 안내해요 — Ensure chatbots adhere to compliance policies with the AI RAG Injector plugin
- AI RAG Injector 플러그인으로 지식 베이스 컬렉션에 대한 접근을 제어하는 방법을 다뤄요 — Control access to knowledge base collections with the AI RAG Injector plugin
- AI RAG Injector 플러그인으로 지식 베이스 쿼리를 필터링하는 방법을 소개해요 — Filter knowledge base queries with the AI RAG Injector plugin
- AI Gateway의 핵심 개념과 제공 기능을 전반적으로 살펴봐요 — About AI Gateway
- AI Gateway에서 사용할 수 있는 모든 플러그인 목록을 한눈에 확인해요 — All AI Gateway plugins