Hacker

Qin HEYI

@qinheyi

Joined Oct 2026Developer at IndependentChina
  • Flag Pilot — from pull request to a safe, gradual Flagsmith rollout, with a human on the button

    Flagsmith Experimentation HackathonNov 2026

    Shipping risky code safely with feature flags is a lot of manual work. You name a flag, build the cohorts, ramp 1% → 100%, watch error rates, roll back when something breaks, and months later remove the dead flag and its code. Most teams skip steps, and that's how incidents and flag debt happen. Flag Pilot is a terminal agent that does this work in Flagsmith. It never touches anything without a person approving it first. - plan: reads a PR diff and drafts a rollout plan: flag name, risk class (payments/auth → high), stages (internal → 1 → 5 → 25 → 50 → 100%), rollback limits, where to gate the code, and an A/B idea for UI changes. The draft comes from MiniMax, or from a zero-token heuristic when no key is set. Deterministic guardrails then clamp it: no stage grows more than 10×, the internal stage is never skipped, and limits can't be looser than policy. - apply / advance: shows a *change plan*, the exact `flagsmith` CLI commands it will run, and waits for `y`. In production you have to type the environment name, and `--yes` is refused. The plan is hashed, so only the commands you saw can run. It creates a flag that is OFF by default, an internal dog-food segment, a sticky per-environment `PERCENTAGE_SPLIT` segment and the segment overrides. Before it proposes each next stage, it runs health checks with simulated shoppers on the demo shop. Flagsmith Edge decides which shoppers get the new path. The agent waits for Edge propagation, then compares error rates between exposed and unexposed users using a Wilson lower bound, so a single unlucky error doesn't trigger anything. The result is ADVANCE, HOLD or ROLLBACK. - rollback: when the gate is confidently red, it flips the kill switch on its own. This is the only write it does without asking, because it only reduces exposure. Internal users keep the feature so engineers can debug it. - stale: finds flags that are 100% ON in every environment and haven't changed for a while. It greps the code and writes a patch that keeps the ON branch, deletes the OFF branch and is checked to compile, plus a draft PR body. Both stay local. Archiving the flag in Flagsmith needs approval. - explain: shows why a given identity sees a flag (`TARGETING_MATCH; segment=…`). - Everything goes into a redacted JSONL audit log: every CLI call, approval, rejection, gate decision and rollback. The real end-to-end run against Flagsmith Cloud is in `docs/evidence/`. It took 4m54s with 0 errors and covered: plan, approved bootstrap, 1% → 5% → 25%, injected bug, automatic rollback, a second flag taken to 100% in dev and prod, stale detection, cleanup patch and archive.

  • CompGraph

    Graph HacksOct 2026

    CompGraph is a personal competition-advisor agent that keeps contests, eligibility requirements, resources, and past decisions in FalkorDB, then answers what to enter next with traceable multi-hop graph paths. Problem: Hackathon hunters juggle deadlines, blockers (LinkedIn, ID verify, YouTube), and past join or abandon decisions. An LLM alone invents reasons. The project is a connected personal brain that can show why a contest is or is not a fit. Solution: CompGraph models competitions and the requirements they REQUIRES, personal Resource nodes the person HAS that SATISFIES those requirements, and Decision precedents (DECIDED / ABOUT) written back as session memory. Agent tools (list_gaps, recommend_next, explain_path, remember_decision) are thin wrappers over Cypher. MiniMax is optional polish; templates work offline. Graph model: Person —HAS→ Resource —SATISFIES→ Requirement ←REQUIRES— Competition. Person —DECIDED→ Decision —ABOUT→ Competition. How FalkorDB is central: Remove FalkorDB and eligibility gaps, ranked recommendations, path explanations, and persistent decisions disappear. The UI visualizes the same paths the tools return. Setup for judges: docker compose up -d && ./scripts/load.sh && npm install && npm start, then open http://127.0.0.1:8787 and use Explain path, Recommend next, and Remember. Or open the live demo (read-only) and watch the demo video for the live FalkorDB session. AI disclosure: AI coding assistants helped with scaffolding and docs. Qin HEYI owns the graph model, Cypher, architecture, and verification. Built with FalkorDB, Node.js, Express, optional MiniMax, Docker Compose, and Vercel. Tracks: Company Brain (primary) and Agents That Act on Connected Data.