Skip to content

Conversation

@RiwEZ
Copy link
Contributor

@RiwEZ RiwEZ commented Oct 21, 2025

No description provided.

@RiwEZ RiwEZ requested review from a team and Copilot October 21, 2025 03:43
@RiwEZ RiwEZ self-assigned this Oct 21, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a new GET endpoint /api/v1/analytics/contents-quality that allows administrators to query content quality scores for posts. The API supports two query modes: retrieving scores for specific content IDs, or filtering by quality levels (excellent, good, fair, weak, broken) with pagination support.

Key Changes:

  • New endpoint supporting quality score queries with scores ranging from 1-5
  • Support for both direct content ID lookups and quality level filtering
  • Pagination support when using quality level filters

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
v1/analytics/response.yaml Defines the 200 response schema including data structure, pagination, and two example scenarios
v1/analytics/parameter.yaml Adds query parameters: contentIds, contentsType, levels, and contentsQualityLimit
v1/analytics/index.yaml Defines the new contents-quality endpoint with operation details and security requirements
swagger.yaml Registers the new endpoint path in the main API specification
bundled.json Contains the bundled OpenAPI specification with all endpoint definitions

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

type: array
items:
type: object
required: [contentId, contentType, qualityScore, qualityReason, userId, contentCreatedAt, processedAt, model, networkId]
Copy link

Copilot AI Oct 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The schema marks qualityReason and model as required fields in the response, but these fields are not defined in the properties section and are missing from all example responses. Either remove them from the required array or add their definitions to the properties.

Copilot uses AI. Check for mistakes.
example: "post.text"
qualityScore:
type: number
description: Quality score from 1-5
Copy link

Copilot AI Oct 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The qualityScore allows decimal values (example: 4.5) but the quality level descriptions in the endpoint documentation suggest integer boundaries (score >= 5, 4 <= score < 5, etc.). Clarify whether scores are integers or decimals, and update the documentation or constraints accordingly.

Suggested change
description: Quality score from 1-5
description: Quality score from 1.0 to 5.0 (inclusive). Can be a decimal value such as 4.5.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants