intellij-obsolete-plugins / ai-playground
CLAUDE.md44 starsChanged 45 days agoApache-2.0View on GitHub
In this repository2 other files it gives its agents.
- aidebugger/CLAUDE.mdCLAUDE.md
- ai-playground/.cursor/rules/project-structure.mdcCursor rule
The file
Show its rules and text
We split this CLAUDE.md into the rules it gives an agent
38 rules. About 0 are common, 22 are distinctive, and 16 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈22
Distinctive · estimate
This author's own choices. Worth a look.
16
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Follow Kotlin style guidelines with 2-space indentation
- Distinctive: line 9
Prefer val over var, immutable data structures when possible
- Distinctive: line 10
Use descriptive names (camelCase for functions/variables, PascalCase for classes)
- Distinctive: line 11
Add KDoc comments for public APIs and complex methods
- Distinctive: line 13
Follow MVVM pattern for UI components
- Distinctive: line 14
Use coroutines for asynchronous operations.
- Distinctive: line 17
NEVER MIX REGULAR LOCKS AND COROUTINES - this can lead to deadlocks
- Distinctive: line 18
DO NOT use Java's synchronized blocks with coroutines
- Distinctive: line 19
DO NOT call suspending functions inside synchronized blocks
- Distinctive: line 20
Use kotlinx.coroutines.sync.Mutex for thread-safety when needed
- Distinctive: line 21
Use AtomicInteger/AtomicBoolean for simple shared counters
- Distinctive: line 22
Use withContext() to switch between dispatchers
- Distinctive: line 23
Use structured concurrency with launch{} within a defined scope
- Distinctive: line 27
Always handle exceptions in coroutines using try/catch or supervisorScope
- Distinctive: line 32
Follow IntelliJ plugin development guidelines
- Distinctive: line 33
Use proper disposal for resources with DisposableScope
- Distinctive: line 44
No initial welcome message for a cleaner start experience
- Very specific: line 60
Always use Jewel components from org.jetbrains.jewel.ui.component.* when available
- Very specific: line 61
Prefer Jewel's Text, TextField, Icon, IconButton components over Material equivalents
- Very specific: line 62
Use JewelTheme.globalColors for accessing theme colors
- Very specific: line 63
Use standard Box, Column, Row from Compose foundation for layout
- Distinctive: line 66
Do NOT use Material components (Material3 is not available in the project)
- Very specific: line 67
Do NOT use Button - create custom buttons using Box + clickable modifier
- Very specific: line 68
Do NOT use Surface - use Box with background and border instead
- Very specific: line 69
Do NOT use Material's Divider - create a simple divider with a Box with height and background
- Very specific: line 72
Use androidx.compose.ui.window.Dialog for dialogs
- Very specific: line 74
Use theme colors: JewelTheme.globalColors.panelBackground for dialog backgrounds
- Very specific: line 75
Use JewelTheme.globalColors.borders.normal for borders
- Very specific: line 79
Use JewelTheme.isDark to check if dark theme is active
- Very specific: line 80
Use JewelTheme.globalColors.panelBackground for default background
- Very specific: line 82
Use primaryColor and primaryColorLight for accent colors
- Very specific: line 83
Use surfaceColor() composable function to get the current surface color
- Very specific: line 86
Always use icons from AllIconsKeys.* namespace
- Very specific: line 96
Create reusable components when needed (e.g., DialogButton)
- Distinctive: line 97
Document components with KDoc comments
- Distinctive: line 98
Follow Jewel's design style (rounded corners, proper spacing)
- Distinctive: line 99
Use theme colors for consistency with IDE
- Distinctive: line 100
Test on both light and dark themes
≈ “Common” is an estimate: at least 1 in 5 of the 26,980 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AI Playground Plugin Development Reference
Project
- You cannot build or run the project by your own, ask human for that and always ask for the feedback
Code Style
- Follow Kotlin style guidelines with 2-space indentation
- Prefer val over var, immutable data structures when possible
- Use descriptive names (camelCase for functions/variables, PascalCase for classes)
- Add KDoc comments for public APIs and complex methods
- Handle nullability explicitly with nullable types and safe calls
- Follow MVVM pattern for UI components
- Use coroutines for asynchronous operations; consider thread safety in UI operations
Coroutines and Concurrency
- NEVER MIX REGULAR LOCKS AND COROUTINES - this can lead to deadlocks
- DO NOT use Java's synchronized blocks with coroutines
- DO NOT call suspending functions inside synchronized blocks
- Use kotlinx.coroutines.sync.Mutex for thread-safety when needed
- Use AtomicInteger/AtomicBoolean for simple shared counters
- Use withContext() to switch between dispatchers
- Use structured concurrency with launch{} within a defined scope
- In UI components, use viewModelScope or a lifecycle-aware coroutineScope
- Be careful with MutableStateFlow updates from multiple coroutines
- For complex state management, consider using a single-threaded context
- Always handle exceptions in coroutines using try/catch or supervisorScope
Project Structure
- src directory has package prefix: "com.intellij.aiplayground"
- UI components use JetBrains Compose with Jewel components
- Follow IntelliJ plugin development guidelines
- Use proper disposal for resources with DisposableScope
- Implement token management for LLM API calls
Model Selection UI Design
- Models are grouped by provider in a single scrollable list
- Model section starts empty by default for new users
- Selected models are visually distinct and persist between IDE restarts
- Model selection state is saved to persistent storage automatically
- Users can toggle models on/off, including removing the last one
- UI adapts responsively to available screen space
- Interface prioritizes clarity with minimal redundancy
- No initial welcome message for a cleaner start experience
- Message input supports Enter key for sending messages
Chat UI Design
- Multiple chats are supported with persistent storage
- Chat messages are saved automatically between sessions
- Each chat maintains its own history and active model selection
- Chat selector header shows current chat with dropdown for switching
- Users can create, rename, and delete chats
- Chat titles are auto-generated from the first user message
- New chats inherit active model settings from global preferences
- Messages are displayed with provider attribution and timestamps
Jewel UI Component Guidelines
Components to Use
- Always use Jewel components from
org.jetbrains.jewel.ui.component.*when available - Prefer Jewel's
Text,TextField,Icon,IconButtoncomponents over Material equivalents - Use
JewelTheme.globalColorsfor accessing theme colors - Use standard
Box,Column,Rowfrom Compose foundation for layout
Components to Avoid
- Do NOT use Material components (Material3 is not available in the project)
- Do NOT use
Button- create custom buttons usingBox+clickablemodifier - Do NOT use
Surface- useBoxwith background and border instead - Do NOT use Material's
Divider- create a simple divider with a Box with height and background
Dialogs and Modals
- Use
androidx.compose.ui.window.Dialogfor dialogs - Build dialog content with
Boxand other foundation components - Use theme colors:
JewelTheme.globalColors.panelBackgroundfor dialog backgrounds - Use
JewelTheme.globalColors.borders.normalfor borders - For dividers use:
Boxwithheight(1.dp)and background color
Theme and Colors
- Use
JewelTheme.isDarkto check if dark theme is active - Use
JewelTheme.globalColors.panelBackgroundfor default background - Use
JewelTheme.globalColors.borders.normalfor borders - Use
primaryColorandprimaryColorLightfor accent colors - Use
surfaceColor()composable function to get the current surface color
Icons
- Always use icons from
AllIconsKeys.*namespace - Common icons:
AllIconsKeys.General.Add(plus icon)AllIconsKeys.General.Remove(minus icon)AllIconsKeys.General.Menu(hamburger menu)AllIconsKeys.General.ChevronDown(dropdown indicator)AllIconsKeys.Actions.Edit(pencil icon)AllIconsKeys.General.Close(X icon)
Custom Components
- Create reusable components when needed (e.g.,
DialogButton) - Document components with KDoc comments
- Follow Jewel's design style (rounded corners, proper spacing)
- Use theme colors for consistency with IDE
- Test on both light and dark themes
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

