feature-flag
Skill9 starsChanged 3 months agoMITView on GitHub
3 other projects use a version of this.
Adopted by
Most recently taken up by
- speakeasy-api/gramtheir own version, first seen Oct 1, 2026
- elastic/docs-buildertheir own version, first seen Sep 15, 2026
- Pradnyeshp/Claude-Skillstheir own version, first seen Jul 6, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- speakeasy-api/gram★ 271same name
- elastic/docs-builder★ 25same name
- Pradnyeshp/Claude-Skills★ 2same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository109 other files it gives its agents.
- AGENTS.mdAGENTS.md
- docs/agents.mdAGENTS.md
- agent/CLAUDE.mdCLAUDE.md
- CLAUDE.mdCLAUDE.md
- router/CLAUDE.mdCLAUDE.md
- .agents/skills/llms.txtllms.txt
- agent-harnessSkill
- auto-fixSkill
- brain-dumpSkill
- industrial-brutalist-uiSkill
- changelog-enforcerSkill
- checkpoint-strategySkill
- context-primeSkill
- cooldown-resumeSkill
- council-reviewSkill
- data-quality-auditSkill
- debug-tracerSkill
- dependency-auditSkill
- deslopSkill
- docs-syncSkill
- duplicate-threadSkill
- email-triageSkill
- fabric-patternsSkill
- git-hygieneSkill
- graphifySkill
- implementation-plannerSkill
- insightsSkill
- issue-resolverSkill
- learn-ruleSkill
- local-ai-querySkill
- lr-schedule-advisorSkill
- minimalist-uiSkill
- modularity-reviewSkill
- full-output-enforcementSkill
- parallel-agentsSkill
- parallel-worktreesSkill
- prompt-librarySkill
- prompt-transparencySkill
- pro-workflowSkill
- redesign-existing-projectsSkill
- release-readinessSkill
- replay-learningsSkill
- repo-memory-updaterSkill
- repowise-intelligenceSkill
- researchSkill
- resource-panelSkill
- risky-module-reviewSkill
- sandboxed-execSkill
- scope-guardSkill
- self-improveSkill
- session-handoffSkill
- skill-composerSkill
- smart-commitSkill
- high-end-visual-designSkill
- stitch-design-tasteSkill
- system-prompt-auditSkill
- task-alive-updatesSkill
- task-scoperSkill
- design-taste-frontendSkill
- test-first-executorSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
8 rules. 0 are common, 7 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
7
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 56
Write tests for BOTH flag states:
- Distinctive: line 79
Delete the disabled path and the flag check entirely
- Very specific: line 82
Default to false (off) for new feature flags
- Distinctive: line 83
Every flag must have a planned removal date
- Distinctive: line 84
Never ship permanent flags — they are always temporary
- Distinctive: line 85
Test both code paths, always
- Distinctive: line 86
Keep flag logic at the boundary (entry point), not scattered through business logic
- Distinctive: line 87
Never nest feature flags more than 1 level deep
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Skill: feature-flag
Purpose
Implement new features behind feature flags to enable safe, gradual rollouts and easy rollbacks without code deployments.
Trigger
Use when:
- Implementing a risky or large feature
- A feature needs gradual rollout
- A/B testing is desired
- The feature might need to be disabled quickly in production
Process
Step 1: Assess Flag Need
Determine if a feature flag is appropriate:
- Always flag: breaking changes, major UI changes, experimental features
- Consider flagging: new integrations, significant logic changes
- Skip flagging: bug fixes, minor improvements, refactors
Step 2: Define the Flag
# Flag definition
FLAG_NAME = "feature_[descriptive_name]"
FLAG_DEFAULT = False # default to OFF for new features
FLAG_DESCRIPTION = "[what this flag controls]"
FLAG_OWNER = "[team or person responsible]"
FLAG_CREATED = "[date]"
FLAG_PLANNED_REMOVAL = "[date or milestone when flag should be cleaned up]"Step 3: Implement the Guard
# Python example
from agent.config import get_feature_flag
def some_feature():
if not get_feature_flag("feature_new_thing"):
return existing_behavior()
return new_behavior()// TypeScript example
import { isFeatureEnabled } from './config/flags';
function someFeature() {
if (!isFeatureEnabled('feature_new_thing')) {
return existingBehavior();
}
return newBehavior();
}Step 4: Test Both Paths
Write tests for BOTH flag states:
def test_feature_disabled(monkeypatch):
monkeypatch.setenv("FEATURE_NEW_THING", "false")
assert some_feature() == expected_old_behavior
def test_feature_enabled(monkeypatch):
monkeypatch.setenv("FEATURE_NEW_THING", "true")
assert some_feature() == expected_new_behaviorStep 5: Document the Flag
Add to docs/feature-flags.md:
| Flag | Default | Description | Owner | Remove By |
|------|---------|-------------|-------|-----------|
| feature_new_thing | false | [description] | [owner] | [milestone] |Step 6: Plan Removal
Feature flags are technical debt. Schedule cleanup:
- Set a calendar reminder or create an issue for flag removal
- Flag removal = merge the "enabled" path as the only path
- Delete the disabled path and the flag check entirely
Rules
- Default to
false(off) for new feature flags - Every flag must have a planned removal date
- Never ship permanent flags — they are always temporary
- Test both code paths, always
- Keep flag logic at the boundary (entry point), not scattered through business logic
- Never nest feature flags more than 1 level deep
Anti-Patterns
- Flags that have been on for >6 months without a removal plan
- Flags that control more than one conceptually distinct feature
- Business logic that reads flags directly (flags belong at the interface layer)
- Flags without tests for both states
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.

