--- alwaysApply: true --- When working with this project, follow these rules: ## Core Behavior - NEVER do anything i didn't ask you for! - Don't talk like a robot. Behave more like a human. - Be concise and direct in responses. - If you're unsure about something, ask for clarification instead of guessing. ## Code Quality & Principles - Follow DRY, SOLID, YAGNI and KISS principles. - Do NOT use old, outdated or deprecated APIs and functions. - Use double quotes ("") for strings consistently. - Prefer functional components over class components in React. - Use TypeScript strictly - avoid `any` types unless absolutely necessary. - DO NOT leave placeholders - ask me when it would be better or implement it fully. ## File Operations - If possible, try to update files in a single edit when making multiple changes. - Do NOT "cd" to the project directory. - NEVER edit/delete/regenerate .env files without explicit permission. - Don't use rg, it doesn't work anyway. ## Testing & Validation - Do NOT "test the implementation" when you are done. The only exception is when you need to typecheck or build the app, in that case: - To typecheck, run `npm run frontend:typecheck`. - To build, run `npm run frontend:build`. - Do NOT execute other commands like "cd". - If the typecheck passed, there's no need for checking the linter errors. ## Async Operations - When you need a delay, use `await delay(millis);` from `@/utils/utils` in an async function. If the current function is not async, make it async. ## Database - NEVER create database migrations, they are auto-generated. ## Project Structure Awareness - This is a React/TypeScript frontend with Python FastAPI backend - Uses MDUI components for UI - Has Electron support for desktop app - Uses Zustand for state management - Uses use-immer for immutable state updates - Uses React Router for navigation - Has WebSocket support for real-time features - Uses encryption (tweetnacl) for security ## Performance & Efficiency - Batch tool calls when possible to reduce latency - Use semantic search before grep when looking for concepts - Use TODOs for complex multi-step tasks to track progress ## Styling - Use SCSS modules - Use nested styles - Put SCSS into one folder per page ## Animations with Framer Motion - Don't use variants if they are used only once ## Debug Mode - When in debug mode and the issue is not yet fixed, ALWAYS end responses with `` containing the steps to reproduce the issue and trigger logging - When NOT in debug mode or when the issue IS fixed, escape the tag as `<reproduction_steps>` to avoid triggering it - Never use other `` tags, only ``