From bacd883f0fee5f11f408214d4ede8ec3fea74ca7 Mon Sep 17 00:00:00 2001 From: Karma Riuk Date: Mon, 16 Jun 2025 17:38:19 +0200 Subject: [PATCH] updated schema for com gen upload --- public/index.html | 28 ++++++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/public/index.html b/public/index.html index 5e7d6f5..279a249 100644 --- a/public/index.html +++ b/public/index.html @@ -260,16 +260,32 @@ Comment Generation

- Submit a JSON object where each key is a string ID and each value is the generated comment. + Submit a JSON object where each key is a string ID and each value is an object representing + the proposed comment for that instance. Each comment must specify the file path, the + starting line, the ending line (or null), and the comment text itself. +

+

+ All fields are required and must follow the expected types exactly. The line_to + field can be null if the comment applies to a single line.


 {
-    "1234": "This method lacks null checks.",
-    "5678": "Consider renaming this variable for clarity."
-} 
-                    
- + "1234": { + "path": "src/Main.java", + "line_from": 10, + "line_to": 12, + "body": "Consider extracting this block into a separate method." + }, + "5678": { + "path": "src/Util.java", + "line_from": 42, + "line_to": null, + "body": "You might want to add a null check here." + } +} + +
Code Refinement