Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

poly-context

Skill by JetBrains

Implements PolyContext feature gating and environment detection for IntelliJ Platform plugins. It reports which context name, such as a web framework, applies at a file or PSI element. Aimed at plugin developers who need cached, cheap context checks.

  • Score 78
  • 21k stars
  • NOASSERTION
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install poly-context

Built from the published package, never by AI.

git clone --depth 1 https://github.com/JetBrains/intellij-community /tmp/intellij-community && mkdir -p ~/.claude/skills && cp -r /tmp/intellij-community/.claude/skills/poly-context ~/.claude/skills/poly-context

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install poly-context in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

PolyContext is an IntelliJ Platform mechanism that answers which coding environment applies at a location. For a given context kind, such as framework, it returns at most one active name, or null if none applies. It can be queried with a PsiElement, or with a VirtualFile and Project, which works before a PSI tree exists, such as during language substitution.

Detection can come from custom PolyContextProvider classes, from declarative context rules in Web Types files, or from PolyContextRulesProvider code. Users can also force values with a .ws-context file. The source notes that poly-symbols is the biggest consumer, but PolyContext has no dependency on PolySymbols or web frameworks. It is meant for developers building feature gating and environment detection in plugins.

Written from the project's SKILL.md and checked against it.

What it can do

  • PolyContext.getReturns the active context name for a kind at a PsiElement or VirtualFile location.
  • PolyContextProviderImplements isEnabled or isForbidden for direct, cached custom detection.
  • Context rules in Web TypesDeclares enable-when and disable-when rules in a contexts-config property.
  • PolyContextRulesProviderSupplies context rules from code for rules that cannot be expressed as static data.
  • ws-context overridesLets users force context values per path with a .ws-context JSON file.
  • PolyContextSourceProximityProviderCalculates proximity for package managers or languages with a global-library concept.

Try asking

  • Add a PolyContextProvider that detects my framework from the file imports
  • Write a Web Types contexts-config block that enables a context for .vue files
  • Show how to gate my PolySymbols registrations with PolyContext framework checks

Good to know

  • Results are called very often, so providers should cache them.
  • Rule output must stay stable, because a change triggers project rescanning and cache invalidation.
  • The pre-2024.2 Web Types layout is deprecated and should not be used for new files.
  • The source describes a general mechanism and lists only one official doc page for it.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: .claude/skills/poly-context/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Alternatives to poly-context

All alternatives →
openclaw-github-repo-commandersickn33
94

Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.

AAA Skill 50k
gradiogradio-app
94

Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.

AAA Skill 44k
hig-components-menussickn33
94

Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.

AAA Skill 50k
fastapi-templateswshobson
94

Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.

AAA Skill 43k
appfunctionsandroid
94

Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.

AAA Skill 11k
agent-qa-authoringsickn33
94

Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.

AAA Skill 50k

Compare with openclaw-github-repo-commander, gradio or hig-components-menus

poly-context: common questions

What does PolyContext return?

It returns the single active name for a context kind at a location, or null if none applies. For example, a framework kind might return vue, angular, astro, or null.

Can PolyContext run before a file is parsed?

Yes. The VirtualFile and Project overload works without PSI access, so it can be used during language substitution before a PSI tree is built.

Is PolyContext only for web frameworks?

No. The source gives non-web examples such as Ruby gems and Symfony bundles, and says it has no dependency on PolySymbols or web frameworks.

How do I install poly-context?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is poly-context free?

The code is published under the NOASSERTION licence. The service it connects to may have its own pricing.

Is poly-context safe to use?

It scores 78 of 100. Grades: maintenance A, licence F, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to poly-context?

Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.

poly-context Install

Add to stack

Loading.