Imported from thtsaman/TIG_YUKTI (
AGENTS.md). Install upstream withnpx skills add thtsaman/TIG_YUKTI. Copyright stays with the author.
Repository Guidelines
Project Structure & Module Organization
This is a Next.js application using the App Router. The codebase follows a highly modular "engine-based" architecture to handle complex examination logic.
.\src\app: Contains application routes and API endpoints..\src\lib: The core logic layer. It houses specialized "engines" for the examination platform:adaptive-engine.ts: Manages question difficulty adaptation.navigation-engine.ts: Handles question traversal logic.submission-engine.ts: Controls the canonical submission pipeline.exam-resume.ts&exam-persistence.ts: Manage offline state and session recovery.
.\src\components: Feature-based React components (e.g.,.\src\components\exam,.\src\components\auth)..\src\context: Global state management using React Context for authentication, caching, and exam runtime..\src\types: Centralized TypeScript definitions to ensure type safety across engines and components.
Build, Test, and Development Commands
Use npm for dependency management and running scripts.
npm run dev: Start the local development server athttp://localhost:3000.npm run build: Compile the project for production deployment.npm run start: Launch the production server.npm run lint: Execute ESLint checks to enforce code quality.
Note: There is currently no automated test suite implemented in this repository.
Coding Style & Naming Conventions
- TypeScript: Strict mode is enforced. Always provide explicit types for function parameters and return values. Prefer interfaces for object structures.
- Path Aliases: Use
@/*to reference the.\srcdirectory (e.g.,import { ... } from "@/lib/utils"). - Styling: Use Tailwind CSS 4 utility classes. Combine dynamic classes using
clsxandtailwind-mergeutilities. - Components: Leverage Radix UI primitives for accessible UI components and Lucide React for iconography.
- Validation: Use Zod for schema validation, especially for API payloads and form data.
Commit & Pull Request Guidelines
Commit messages must be concise and descriptive, following these prefix conventions:
feat:: Implementation of new functionality.fix:: Resolution of bugs or logic errors.refactor:: Code changes that neither fix a bug nor add a feature.Delete: Removal of obsolete files or code blocks.
Ensure that npm run lint passes before pushing changes or opening a pull request.