convez.ai
MCP Server
BrunoLagoa

memflow-command-system

BrunoLagoa/memflow-command-system

Ver no GitHub
InicialPluginScore · de 0 a 100

Open-source SDLC command system with AI: predictable workflows, strict quality gates, and persistent decision memory.

Instalação

$npx convez-ai BrunoLagoa/memflow-command-system

1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.

Métricas

Estrelas
4
Forks
1
Acompanhando
0
Saúde
42%
Último commit
há 3 semanas
Versão
v1.4.1
Issues abertas
0
Contribuidores
1

README

A tradução para o português deste README ainda está na fila.

English | Português (Brasil)


In one sentence

Memflow turns the "open a chat and hope for the best" habit into an engineering flow that decides with criteria, executes with discipline, validates with rigor, and remembers decisions across sessions.


Why Memflow?

Most AI workflows look like this: open chat, paste context, ask for code, hope for the best, repeat. Every session restarts from zero. Decisions evaporate. The same mistakes get re-litigated next week.

Memflow swaps improvisation for an auditable, repeatable process:

Without MemflowWith Memflow
Every session restarts from zeroMemory reused across sessions
Decisions get lost in chat historyDecisions become structured memory with category, impact, and score
Always the most expensive (or cheapest) modelThe right model for the task — cheap by default, escalate when needed
"Looks approved" by feelingExplicit final gate: OK or BLOCKED
AI decides and executes in one shotEach step waits for explicit confirmation before moving on

Under the hood, Memflow works like an engineering team in stages:

  • Workflow — classifies the task, routes exploration when needed (/brainstorm), and picks the right strategy and model.
  • Execution — implements with controlled fallbacks and explicit checkpoints.
  • Validation — strict final gate (OK or BLOCKED), no approval by feeling.
  • Memory — captures relevant decisions with category, impact, and a 0–100 score, and reuses them across sessions.

The result is something you can audit, repeat, and trust.


Quick start

One interactive command. It detects your environment, asks 3 questions, and installs.

macOS / Linux

curl -fsSL https://raw.githubusercontent.com/BrunoLagoa/memflow-command-system/main/scripts/install.sh | bash -s -- install

Windows (PowerShell)

powershell -ExecutionPolicy Bypass -Command "iwr https://raw.githubusercontent.com/BrunoLagoa/memflow-command-system/main/scripts/install.ps1 -OutFile $env:TEMP\install.ps1; & $env:TEMP\install.ps1 install"

The wizard guides you through 3 choices:

  1. Operating system
  2. Platform — OpenCode, VSCode, Cursor, or Claude Code
  3. Scope — global or local (when applicable)

Then jump straight to your first commands:

/context
/workflow

New to Memflow? Read the first 10 minutes guide for a step-by-step walkthrough with real examples.

Need scripted installs, update, check or uninstall? See the advanced installation guide.


How it works — the flow

   ┌──────────┐   ┌──────────────┐   ┌────────────────┐   ┌──────────┐
   │ /context │──▶│  /workflow   │──▶│    /execute    │──▶│ /review  │
   │   load   │   │   decide     │   │    (or /plan)  │   │ validate │
   │  memory  │   │   model      │   │   implement    │   │          │
   └──────────┘   └──────┬───────┘   └────────────────┘   └────┬─────┘
                         │                                      │
                  ┌──────▼───────┐                    ┌─────────▼──────┐
                  │ /brainstorm  │                    │  /memory-save  │
                  │  (optional)  │                    │   (optional)   │
                  └──────────────┘                    └────────────────┘
  • /context → /workflow → /execute → /review is the main path.
  • When /workflow detects insufficient clarity or unresolved trade-offs, it routes to /brainstorm first. Handoff after approval goes to /prd, /spec, or /plan.
  • For high-risk work, finish with /review-code (deep technical review) and /review-enforce-rules (strict final gate).

What's included

Orchestration commands

The control layer that decides, executes, and validates — the main path.

CommandWhat it does
/contextLoad project context, memory, operating mode, and available skills
/workflowClassify the task; decide exploration (/brainstorm), execution strategy, level, primary model, and fallbacks
/executeApply the decision with controlled fallback
/reviewValidate technical and architectural adherence
/review-codeDeep technical validation before production readiness
/review-enforce-rulesStrict final gate with binary output: OK or BLOCKED

Capability commands

Specialized resolution for everyday tasks, called by the workflow as needed.

CategoryCommands
Discovery & definition/brainstorm, /prd, /spec, /plan
Implementation & quality/debug, /refactor, /test-plan
Memory/memory-init, /memory-save

Key differentiators

  • Structured exploration — /brainstorm compares 2–5 approaches in a phased dialogue, with HARD-GATE, self-review, optional artifact save, and handoff to /prd, /spec, or /plan.
  • Decision reuse by score — high-scoring decisions are auto-reused across sessions.
  • Cost/quality model policy — primary model + same-level fallbacks; escalate only when justified.
  • Functional degraded mode — keeps working even when .agents is missing.
  • Smart memory persistence — decision versioning with (update) semantics.
  • Anti-compaction invariants — pt-BR + Memflow identity re-hydrated via /context and /workflow.
  • MCP integration — code, contextual memory, and external docs.
  • Live plans — when /plan is saved, tasks are sized by complexity with status markers ([ ], [-], [x], [!]) and execution modes ([P] parallel, [S] sequential).

Quick glossary

Terms that show up across the project, one line each:

TermWhat it means
.agentsProject context folder that /context loads (memory, modes, skills).
Score 0–100Relevance rating of a decision; the higher it is, the more it gets reused across sessions.
FallbackSame-level backup model, used when the primary fails — without escalating cost unnecessarily.
HARD-GATEMandatory stop point that requires explicit confirmation before moving on.
Degraded modeReduced but functional operation when .agents or context is missing.
Anti-compaction re-hydrationRestoration of invariants (pt-BR language and Memflow identity) when history gets compacted.
MCPModel Context Protocol — integration with code, contextual memory, and external docs.
Live plans/plan plans whose tasks are marked by status and execution mode, updated as work progresses.

A real example

Implementing a medium-complexity feature with active memory:

1. /context              → Loads .agents and existing memory
2. /workflow             → Detects previous decision, reuses if score is high
3. /plan                 → Required due to complexity/risk
4. /execute              → Implements with validations and tests; scores session relevance
5. /memory-save          → Records the decision with category, impact, and score
6. /review               → Checks quality, security, and architecture
7. /review-code          → Deep technical validation
8. /review-enforce-rules → Strict final gate (OK or BLOCKED) — optional, recommended

When scope or approach is unclear, insert /brainstorm after /workflow (step 3 becomes exploration and approval, then /prd, /spec, or /plan).


Supported tools

ToolStatusNotes
OpenCode✅Main platform. Full slash command and SDLC support.
VSCode✅Installed via --target vscode as prompt files in .github/prompts.
Cursor✅Installed via --target cursor as commands in .cursor/commands/memflow.
Claude Code✅Installed via --target claude as commands in .claude/commands/memflow.
Antigravity⏳Pending validation.

Philosophy

Workflow decides. Model executes. Rules protect.

Operating principles:

  • Start cheap, escalate when needed. Don't burn the strongest model on a one-line fix.
  • No execution without a decision. Context and workflow come first, always.
  • No silent progress. Each step waits for explicit user confirmation.
  • Don't lose learning. Important decisions become structured memory.
  • No "approval by feeling". Validation is explicit and traceable.

Documentation

DocWhat's inside
First 10 minutesStep-by-step walkthrough with real examples
Advanced installationNon-interactive install, update, check, uninstall, scope details, bootstrap pinning
SDLC guide (English)Conceptual guide to the Memflow SDLC
SDLC guide (Português)pt-BR version
End-to-end examplesReal usage scenarios with full command flows
ChangelogVersion history
Model policyModel selection and escalation strategy
Command specs/context · /workflow · /brainstorm · /execute · /review-code · /review-enforce-rules

Who is this for?

  • Teams standardizing AI-assisted SDLC with governance
  • Projects suffering from inconsistent decisions across sessions
  • Environments balancing model cost and technical quality
  • Flows with high architectural and security compliance requirements
  • Engineering orgs adopting AI without sacrificing predictability

Roadmap

  • Provide stack-based templates for faster onboarding
  • Add effectiveness metrics (lead time, rework, cost per task)
  • Expand command specs with adaptive memory hints

Contributing

This project follows Conventional Commits 1.0.0. Commit messages are validated in CI for pull requests and pushes to main.

Allowed types: feat, fix, docs, style, refactor, perf, test, chore, build, ci.

Source and distribution

If you're going to touch the command code, mind how the project is organized (this reduces token cost in production prompts while keeping authoring in pt-BR):

  • developer/ is the authoring source in Portuguese (pt-BR).
  • src/ is the distribution payload in English used by installers.
  • Installer targets (opencode, cursor, vscode, claude) continue to consume src/.

When command behavior changes, keep both trees synchronized and preserve the same file structure between developer/ and src/.

People

This project evolves with contributions from people who believe in disciplined, practical, and auditable AI software engineering.

Want to show up here too? Open an issue, suggest improvements, or send a PR.

Support

Open a GitHub issue. Bug reports, feature requests, and usage questions are welcome.

License

MIT. See LICENSE for full terms.


Ver o original no GitHub

Bom para

Relacionados