본문으로 건너뛰기

Report Schema

Report는 deterministic diagnostic입니다. 제품 metadata에 저장하거나, collection UI에 표시하거나, regression gate로 사용할 수 있습니다. 같은 spec과 option이면 같은 report가 나와야 합니다.

OpenAPI collection report

analyze_openapi_collection()ToolGraph.analyze_openapi()는 다음 shape의 OpenAPICollectionReport를 반환합니다.

{
"summary": {},
"coverage": {},
"graph_readiness": {},
"issues": [],
"recommendations": []
}

Summary

Field의미
tool_countingested tool 수
operation_count반영된 OpenAPI operation 수
unique_tool_countduplicate 처리 후 tool 수
deprecated_tool_countdeprecated operation 수
readiness_score0-100 deterministic score
statusready, warning, blocked

점수 정책은 100점에서 시작해 blocker당 15점, warning당 5점을 감점하고 0-100으로 clamp합니다. blocker가 있으면 blocked, warning이 있거나 90점 미만이면 warning입니다.

Coverage

Field의미
request_schema_tool_countrequest schema가 있는 tool
response_schema_tool_countresponse schema가 있는 tool
consumes_field_countrequest/path/query/header/body leaf
produces_field_countresponse leaf
auth_field_countauth로 분류된 field
context_field_countruntime context로 분류된 field
enum_field_countenum field
response_envelope_tool_countresponse envelope candidate
semantic_action_known_rateaction이 unknown이 아닌 비율
semantic_resource_assigned_rateresource가 할당된 비율
semantic_module_assigned_ratepath/module이 할당된 비율

Issue

{
"severity": "warning",
"code": "missing_response_schema",
"tool": "getOrderDetail",
"message": "Operation has no response schema.",
"evidence": {"method": "GET", "path": "/orders/{orderId}"},
"recommendation": "Add a 2xx response schema or repair the contract."
}

주요 issue code:

Code의미
missing_request_schemarequest schema 누락
generic_request_bodyrequest body가 너무 generic
missing_response_schemaresponse schema 누락
duplicate_operation_idoperationId 중복
missing_operation_idoperationId 없음
auth_requiredOpenAPI상 auth 필요
unsupported_content_typecontent type 표현 어려움
response_envelope_detectedwrapper/body view candidate 감지
low_graph_connectivityproducer/consumer 연결성 약함
no_contract_fieldsconsumes/produces field 추출 실패
semantic_action_unknown_rate_highunknown action 비율 높음
semantic_resource_unassigned_rate_highresource 미할당 비율 높음
weak_edge_evidenceweak/structural edge 비율 높음
module_cluster_too_largemodule cluster가 너무 큼

저장 안전성

Report에는 raw request body, response body, auth header value, cookie, 사용자 식별값을 넣지 않습니다. runtime diagnostic을 추가하더라도 reason code, header name, scrub된 evidence만 저장하세요.

관련 문서