Imported from muhammd2refaat/Hamilul-Quran (
Admin-CMS/.agents/AGENTS.md). Install upstream withnpx skills add muhammd2refaat/Hamilul-Quran --skill .agents. Copyright stays with the author.
AI Agent Persona & Operational Guidelines
Project Context: Admin-CMS
When working in this specific repository, keep the following in mind:
- Framework: React 18, bootstrapped with Vite, using TypeScript.
- Styling: Tailwind CSS with plugins (
@tailwindcss/forms,@tailwindcss/typography). Icons vialucide-react. - State & Data Fetching:
zustandfor global client state,@tanstack/react-queryfor server state and API interactions, andaxiosfor HTTP requests. - Routing:
react-router-dom(v6). - Forms & Validation:
react-hook-formpaired with@hookform/resolversandzodfor schema validation. - UI Components: Utilizes
@tanstack/react-tablefor tables,@tanstack/react-virtualfor large lists,rechartsfor charts, and@tiptap/reactfor rich text editing. - Development Flow: Use
npm run devoryarn devto start the Vite development server.
Tool Usage Strategy
- Search: Use
ctx_globto find files. Usectx_searchto find exact content or symbols. Avoid using bashfindorrgdirectly when native tools are available. - Read: Use
ctx_readwith appropriate mode (signatures|map|full) for large files to save context window. Parallelize multiple file reads. - Write: Use
ctx_patchor nativeedittool to perform sequential replacements in a single turn. Ensureold_struniquely identifies the block. - Terminal: Use
ctx_shellfor testing, building, or ecosystem commands (npm run dev,npm run lint,npm run build).
Tone and Style
- Keep conversational text to an absolute minimum (under 100 words).
- Speak through actions and tool calls.
- State your intended plan briefly before executing complex tasks.
- Acknowledge system notifications briefly and continue working.
CRITICAL: ALWAYS use lean-ctx ctx_* tools instead of native equivalents. This is NOT optional.
MANDATORY MAPPING: • Read/cat -> ctx_read(path, mode) • Grep -> ctx_search(pattern, path) • Shell/bash -> ctx_shell(command) • Glob/find -> ctx_glob(pattern) • ls/find -> ctx_tree(path, depth)
NEVER use native Read/Grep/Shell/Glob when a ctx_* equivalent exists. SELF-CORRECT: the moment you reach for one, stop and call the ctx_* tool instead.
Tool selection by intent: • Orient / understand code (call FIRST) -> ctx_compose • Read a file -> ctx_read(path, mode=signatures|map|full); edit after reading -> ctx_patch • Exact symbol -> ctx_symbol; pattern -> ctx_search; by meaning -> ctx_semantic_search • Files by glob -> ctx_glob; structure -> ctx_tree; callers/impact -> ctx_callgraph • Verify after edits -> ctx_shell(test/build); memory -> ctx_session / ctx_knowledge Semantic questions -> search tools, not whole-file reads: reading more ≠ understanding more.
Anti-patterns — do NOT: • Chain ctx_search -> ctx_read -> ctx_symbol — one ctx_compose replaces all three • Use ctx_read(mode=full) for orientation — use mode=signatures • Use ctx_callgraph/ctx_graph for const/static/variable refs — they track call edges and file deps only; use ctx_search instead
PARALLEL: fire independent tool calls in the SAME turn — ctx_compose bundles multiple lookups into one call.
RECOVER: compression is reversible — read the shown path (no MCP) or ctx_read(raw=true), never re-read line-by-line.
OUTPUT STYLE: concise
- Bullet points over paragraphs
- Skip filler words and hedging ("I think", "probably", "it seems")
- 1-sentence explanations max, then code/action
- No repeating what the user said