> ## Documentation Index
> Fetch the complete documentation index at: https://docs.learnway.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# AI Assessment

> AI-driven project evaluation, code analysis, and personalized skill assessments.

# AI Assessment

LearnWay uses Google Gemini models to automatically evaluate user project submissions, code samples, and onboarding knowledge assessments.

***

## AI Project & Code Assessment

Evaluates submitted code repositories, contracts, or written assignments against project rubrics.

### Evaluation Workflow

1. User submits code or repository link via `/api/v2/projects/:id/submit`.
2. The AI Assessment worker analyses code clarity, security patterns, test coverage, and rubric compliance.
3. Structured scoring and targeted improvement recommendations are generated and saved.

### Example Assessment Result

```json theme={null}
{
  "success": true,
  "data": {
    "submissionId": "sub-12345",
    "status": "COMPLETED",
    "score": 92,
    "passed": true,
    "strengths": [
      "Proper use of OpenZeppelin ERC20 standard",
      "Comprehensive ReentrancyGuard implementation",
      "Clear NatSpec documentation comments"
    ],
    "weaknesses": [
      "Missing event emission in administrative function"
    ],
    "recommendations": [
      "Add `emit OwnershipTransferred(oldOwner, newOwner)` before returning in transferOwnership"
    ]
  }
}
```
