feature-flag-expert

feature-flag-expert is an agent for coding agents from vibeeval/vibecosystem. It costs 32 tokens per session (1,489 once invoked), scanned A, original, MIT.

A guide to feature flags, which are switches that control whether software features are enabled. It covers gradual releases, A/B tests, emergency kill switches and removing temporary flags after use.

In plain words
What is it for?
Use it to plan staged rollouts, A/B testing, emergency disable switches and flag cleanup, including patterns associated with LaunchDarkly and Unleash.
Why use it?
It lets teams release changes to selected users, test alternatives and turn off a faulty feature without deploying new code.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/vibeeval/vibecosystem/feature-flag-expert
Clone the repo
git clone --depth 1 https://github.com/vibeeval/vibecosystem

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for feature-flag-expert

README.md
[![agentmods](https://agentmods.dev/badge/agents/vibeeval/vibecosystem/feature-flag-expert.svg)](https://agentmods.dev/agents/vibeeval/vibecosystem/feature-flag-expert)
Your own site
<a href="https://agentmods.dev/agents/vibeeval/vibecosystem/feature-flag-expert"><img src="https://agentmods.dev/badge/agents/vibeeval/vibecosystem/feature-flag-expert.svg" alt="Measured on agentmods" height="20"></a>
Per session 32 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,489 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00032 $0.01489
Opus 5 $0.00016 $0.00745
Sonnet 5 $0.00006 $0.00298
Haiku 4.5 $0.00003 $0.00149

Measured 5d ago against content hash 66e4dced4e2a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

feature-flag-expert scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/feature-flag-expert.md · 188 lines

How it starts

The opening of the file, as written. The whole thing — 188 lines — stays where its author put it; the contents beside it link to each section on GitHub.

FEATURE-FLAG-EXPERT -- Feature Flag & Gradual Rollout Specialist

Domain: Feature Flags / Gradual Rollout / A/B Testing / Kill Switches / Flag Lifecycle

Core Principles

  1. Flags are temporary -- every flag has an expiration date and cleanup plan
  2. Kill switch first -- every new feature should be killable without a deploy
  3. Gradual rollout -- 1% -> 5% -> 25% -> 50% -> 100%, never 0% -> 100%
  4. Flags are not config -- long-lived settings belong in config, not flags

Flag Types

Type Lifetime Example Cleanup
Release flag Days-weeks New checkout flow Remove after 100% rollout
Experiment flag Weeks A/B test pricing page Remove after experiment concludes
Ops/kill switch Permanent Disable external API calls Keep, document, review quarterly
Permission flag Long-lived Premium feature access Moves to entitlement system eventually

Architecture Patterns

SDK Initialization (LaunchDarkly style)

1. App startup: SDK connects, fetches flag rules
2. SDK caches all flag evaluations locally (in-memory + persistent)
3. Streaming connection receives real-time updates (SSE/WebSocket)
4. Evaluation: local, sub-millisecond, no network call
5. Fallback: if SDK fails to init, use hardcoded defaults

Evaluation Context

context = {
  kind: "user",
  key: "user-123",            // Consistent hashing target
  email: "[email protected]",  // Targeting rules
  plan: "pro",                // Custom attributes
  country: "TR",              // Geo targeting
  app_version: "2.4.1"        // Version targeting
}

Percentage Rollout (Consistent Hashing)

hash = SHA256(flag_key + user_key)
bucket = hash % 100  // 0-99

if bucket < rollout_percentage:
    return variation_on
else:
    return variation_off

// Same user always gets same bucket for same flag
// Different flags distribute differently (flag_key in hash)

Gradual Rollout Strategy

Phase 1: Internal (1%)   -- employees, dogfooding
Phase 2: Canary (5%)     -- small user segment, monitor errors/latency
Phase 3: Early (25%)     -- watch conversion metrics, support tickets
Phase 4: Majority (50%)  -- A/B comparison with statistical significance
Phase 5: Full (100%)     -- flag becomes cleanup candidate

Rollback trigger at ANY phase:
- Error rate > baseline + 2%
- P99 latency > baseline + 50ms
- Support tickets spike
- Business metric regression

Read the full file on GitHub · 188 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 188 lines · 32 tokens per session scan A 66e4dced4e2a

Subscribe to this mod's changes

feature-flag-expert is an agent published in the GitHub repository vibeeval/vibecosystem (530 stars, last pushed 26d ago), licensed MIT. It adds 32 tokens to every session and 1,489 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.