Phase 1 shipped · vision v2.0

Build it once.
Then compose forever.

Your organisation already solved this problem. BricoWerx captures that work as versioned pieces — code, prompts, skills, evals, pipelines — and serves it to your team through a CLI and to your AI assistants through MCP.

brico — from bricolage /bʁi.kɔ.laʒ/, French: to build with what you already have in your hands. werx — where it gets made.

one static binary zero runtime deps git is the source of truth offline-first
live · brico cli

Extract → capture → add → doctor. The full lifecycle, shipping today.

token economics
0

tokens to answer “do we have JWT auth?” — against tens of thousands for a repo-indexing assistant.

piece kinds
6

code · prompt · skill · eval · dataset · pipeline — one manifest field, zero engine changes.

the name

Brico — from the French bricolage: building with what you already have in your hands. Werx — the workshop where it happens.

brico extract find what's reusable brico capture bottle the craftsmanship brico add snap it into a new app brico mcp serve it to any assistant brico eval regression-test your prompts brico graph query the relationships brico stats prove the token savings
01 The problem

Repositories are the unit of storage. A terrible unit of reuse.

The auth module your team perfected two projects ago is entangled with that project's dependencies, invisible to search, and unversioned as an asset in its own right. The same is now true of prompts, evals and agent skills — valuable, untested, trapped.

🗄
3.1 · trapped knowledge

Answers that can't be found

Teams answer “how do we build this?” over and over, when the real question should be “do we already have a piece for this?” Prompts live in Notion, eval scripts rot in scratch folders, agent configs are copy-pasted between repos and silently drift apart.

🔁
3.2 · rediscovery tax

AI regenerates instead of retrieving

Assistants index whole repositories and stuff context windows to answer what the organisation already answered. Regenerating an auth module costs more than tokens: review time, subtle bugs, and a fourth slightly different implementation.

3.3 · why now

Two trends just converged

Context efficiency became a first-class engineering concern — teams track token spend like cloud spend. And MCP standardised how assistants consume external knowledge. Both point at a curated, versioned store of an organisation's best work.

generation treated as free

Regenerate

  • Scans the whole codebase for context
  • Writes novel code that must be reviewed
  • Introduces a fourth auth implementation
  • Tens of thousands of tokens per answer
reuse made the cheapest path

Retrieve

  • Asks a librarian, not the whole library
  • Installs a verified, versioned piece
  • Wiring steps and decisions travel with it
  • ≈300 tokens for “do we have JWT auth?”
02 The vision

Pieces — not repositories — become the unit of engineering knowledge.

A piece is a versioned engineering asset: source files, a manifest describing its behaviour, and a set of derived knowledge representations. Everything else follows.

01Reuse engineering knowledge, not only codeDesign decisions, wiring, trade-offs and evaluations travel with the asset.
02Cut AI context costRetrieve only relevant pieces, at the cheapest sufficient fidelity.
03Preserve organisational memoryAcross teams and projects, in the organisation's own git — never locked into a vendor database.
04Enable semantic discovery“Something like rate limiting for our stack” — not keyword-only search.
05Make relationships queryabledepends on · replaces · similar to · inspired by — facts, not tribal knowledge.
🪶

Capture stays one command

Knowledge systems die when the cost of contributing exceeds the value of retrieving — the fate of every abandoned internal wiki. Every representation beyond the raw files is derived and optional: generated at capture time or backfilled later, never demanded from the contributor.

Git remains the source of truth

Anything that looks like a database is a rebuildable projection of the Vault. That single rule buys database power — vector, full-text, graph — with none of the database liabilities: no migrations-as-truth, no sync conflicts, no server between a developer and their knowledge.

03 The representation ladder

Serve knowledge at the cheapest sufficient fidelity.

Every piece carries a ladder of representations, each derived at capture time and stored as plain files in its version directory. Consumers climb only as far as the task requires.

Card~50 tokens
Search results · “do we have something for X?”
Surface~200–400
Deciding fit · writing code that calls the piece
Summary~500
Understanding why the piece works the way it does
Full sourcecode cost
Modifying or extending the piece
what the consumer receives
// card — the whole thing
{
  "name": "auth",
  "kind": "code",
  "description": "JWT auth with Passport & bcrypt",
  "tags": ["security", "jwt"],
  "framework": "nest",
  "latest": "0.2.0"
}

Name, description, tags, kind, compatibility. Enough to answer existence questions across an entire Vault for the price of a sentence.

cost~50
// surface — signatures, no bodies (from the AST)
export class AuthService {
  signIn(dto: SignInDto): Promise<Session>
  verify(token: string): Promise<Claims>
}
env   JWT_SECRET, JWT_EXPIRES_IN
wire  add AuthModule to AppModule imports

Exported types, function signatures, env vars and wiring steps — extracted from the AST, bodies omitted. Everything needed to call the piece correctly.

cost~200–400
# summary.md — generated at capture
## Why it works this way
Refresh tokens are rotated on every use and stored
hashed, so a leaked token is single-use.

## Trade-offs
Stateful refresh store (Redis) was accepted to gain
revocation; a pure-JWT design cannot revoke.

Design decisions, trade-offs, architecture notes — the reasoning a senior engineer would otherwise have to be interrupted for.

cost~500
// the files themselves
auth.service.ts        auth.module.ts
auth.controller.ts     jwt.strategy.ts
refresh-token.store.ts lego.manifest.json

The top rung is rarely needed. And the largest saving isn't on this ladder at all: not generating code in the first place. brico add installs a verified, versioned piece for zero generation tokens, zero review of novel code, zero new bugs.

costfull

“Do we have JWT auth for NestJS?”

The same question, answered two ways. Multiplied across every retrieval an assistant makes in a working day, this is the difference between AI that grazes the whole codebase and AI that asks a librarian.

BricoWerx Vaulta few cards + one surface
0
Repo-indexing assistantscanning source files
0
1–2orders of magnitude cut on retrieval-heavy workflows
~40 MBof vectors for a mature 10,000-piece Vault — smaller than one node_modules
brico statslogs which pieces are served, turning the saving into a dashboard
04 AI as a client

One command turns the Vault into an MCP server.

brico mcp exposes the Vault over the Model Context Protocol, making every MCP-capable assistant — Claude, IDE agents, internal copilots — a consumer of your organisation's proven work. A thin protocol layer over the same engine and index the CLI already uses.

search_pieces(query, kind?)Semantic + keyword search over the Vault; returns cards.
get_piece(name, level)Returns the requested rung: card, surface, summary, or source.
plan_reuse(task)Given a task description, returns candidate pieces with fit rationale.
get_relations(name, kind?)Graph neighbourhood: dependencies, dependents, replacements, similar pieces.

All tools serve ladder representations — never raw repository scans.

assistant ⇄ brico mcp
dev“Add payments to the new service.”
toolplan_reuse("add payments to a NestJS service")
vault2 candidates · payments@0.1.2 (stripe, proven in 3 projects)
· billing-webhooks@0.3.0  — 94 tokens
toolget_piece("payments", level: "surface")
vaultsignatures · env: STRIPE_SECRET, STRIPE_WEBHOOK_SECRET · wiring: 2 steps  — 210 tokens
agentRecommends brico add payments — wiring steps included.
Zero generation tokens. Zero novel code to review.
05 Beyond code

The set of things worth versioning has grown.

We do not build ML infrastructure — we version AI engineering assets. Model registries and experiment tracking are owned territory; the unowned gap sits next to it: the day-to-day assets teams scatter across wikis, gists and repos. The extension is a single kind field and new adapters. The engine core does not change.

codeshipping

Modules with their wiring

Files, dependencies, env vars and framework wiring steps — captured, versioned, snappable.

The discipline: immutable versions; publish refuses to overwrite.
promptphase B

Prompts with evaluation cases

Template file, input variables, target models, and attached evaluation cases.

The discipline: a prompt with versioned evals is to prompts what a module with tests is to code — prompt changes gain regression tests.
skillphase B

Agent skills

Instructions plus scripts, in the emerging industry format.

The discipline: structurally identical to code pieces — captured and served over MCP, the Vault becomes a skill registry almost for free.
evalphase C

Benchmark suites

Cases, scoring criteria, harness configuration — standalone and reusable.

The discipline: the shared yardstick that lets versions be compared honestly. A harness, deliberately not a platform.
datasetphase C

Pointers, never blobs

URI, content hash, schema, license — identity and provenance without the payload.

The discipline: the pointer rule keeps the Vault fast and clones cheap while still versioning what matters.
pipelinephase C

Compositions of other pieces

RAG and agent configurations that reference other pieces by name and version.

The discipline: makes the relationship graph load-bearing — “which pipelines break if we bump the chunking prompt?” becomes a query.
06 Storage architecture

Truth, index, and scale — in that order.

Files in git are the source of truth.
Every database is a derived, rebuildable projection.

1truth

The Vault — a git directory

Each version directory holds the piece's files, its manifest, and derived knowledge: summary.md, surface.json, and embeddings as raw float32 vectors with a sidecar recording the embedding model — because vectors from different models are not comparable.

offline · auditable
2index

One embedded SQLite file

A single database at ~/.brico/index.db, compiled into the binary — still one static binary, still zero runtime dependencies. It replaces index.json and provides every query capability the first draft wanted five separate systems for.

boring on purpose
3scale

A hosted tier — Postgres only, later

pgvector, full-text, recursive CTEs. One well-understood database instead of five, entered only when team Vaults demand it. Because of the source-of-truth rule it stays a projection: if the hosted database dies, it is rebuilt from the repositories.

demand-gated
semantic search

sqlite-vec — brute-force cosine is already single-digit milliseconds at 10k vectors.

“Something like rate limiting for our stack”

keyword search

FTS5 full-text index with ranking.

“stripe”, “jwt”, tag and description matches

graph queries

Relational tables plus recursive CTEs — a few lines of SQL.

“What breaks if redis is replaced?”

Any index can be deleted and rebuilt with one command — brico reindex — the same philosophy as today's self-healing index.json, scaled up. Embedding generation is the only place a network touches the pipeline, so it is fenced: always skippable, and brico reindex --embed backfills later. Offline-first stays a hard guarantee, not an asterisk.

07 The knowledge graph

Questions that required a senior engineer's memory become one-line queries.

Relationships are declared where everything else about a piece is declared: in the manifest. The local index aggregates them into queryable tables — no graph database, no new mental model for contributors.

depends_onWhat breaks if we replace the cache piece?
replacesWhat superseded the old mailer, and why?
similar_toIs there anything close to this already?
inspired_byWhere did this design come from?
used_byWhich pipelines are downstream of this prompt?

Because pipeline pieces reference their components by name and version, the graph naturally spans code and AI assets — impact analysis works identically whether the changed piece is a Redis client or a chunking prompt.

prompt chunking-v3 pipeline rag-search pipeline ingest code cache eval recall@10 used_by used_by similar_to depends_on
08 Roadmap

Four phases, each gated on the last one shipping.

Each phase preserves the one-binary, git-first identity. Everything heavier waits for the demand that justifies it.

Phase A

Knowledge layer

Weeks
  • Representation ladder at capture
  • Semantic search over local vectors
  • brico mcp with four core tools
  • SQLite index replacing index.json
Exit criterionAn MCP-connected assistant answers “do we have a piece for X?” in under a second.
Phase B

AI piece kinds

1–2 months
  • kind field in the manifest
  • Prompt and skill adapters
  • brico eval harness
  • 3–4 polished example pieces
Exit criterionA prompt change is flagged by a failing versioned eval — regression testing for prompts, end to end.
Phase C

Accounting & graph

1–2 months
  • brico stats token accounting
  • Relationship fields + brico graph
  • Eval and dataset kinds
  • Pipeline kind with cross-references
Exit criterionA team can show measured token savings and run impact analysis across code and AI pieces.
Phase D

Team scale

When pulled by real teams
  • Remote / team Vaults, git-based first
  • Postgres-backed hosted tier, if scale demands
  • Registry / marketplace groundwork
Exit criterionFirst external team runs a shared Vault in production.

Deliberately absent: “autonomous assembly of systems from verified pieces.” It remains the long-range north star — the natural consequence of a Vault an AI can query, trust, and wire — but it is a research direction, not a committed phase.

09 Positioning

Not a code generator. Not a boilerplate. Not an AI product.

BricoWerx is an Engineering Knowledge Operating System — it structures, versions, relates, and preserves engineering craftsmanship, serving it to humans through a CLI and cockpit, and to AI through MCP.

CategoryRepresentativesOur differentiation
Repo-indexing AI assistantsSourcegraph/Cody, GitHub indexing, internal RAGThey retrieve from everything ever written; we retrieve from a curated Vault of proven pieces at ladder fidelity. Recall of the best, not of the most.
Prompt management SaaSLangSmith, PromptLayer, HumanloopSaaS-first and heavyweight. Our wedge: offline, git-native, one binary — prompts versioned next to the code pieces they serve, which none of them do.
ML infrastructureMLflow, Weights & Biases, Hugging FaceNot competed with. We version AI engineering assets around their artifacts; dataset pieces point to them rather than replacing them.
Package registriesnpm, PyPI, internal registriesRegistries distribute libraries; the Vault captures your modules with wiring, environment, decisions and evals attached — knowledge a package cannot carry.

The through-line in every row: our moat is not a model or an index — it is the discipline of the Vault and the trust it earns. Models will churn; a decade of versioned organisational craftsmanship only appreciates.

10 What success looks like

Measurable, phase-aligned, honest about what each number can prove.

Adoption

Time from download to first captured piece stays under five minutes; weekly active Vaults grow phase over phase.

Reuse rate

brico add events per Vault per month — the direct measure of “reuse beats regeneration” happening.

Token economics

brico stats shows measured tokens served vs. full-file baseline; target 1–2 orders of magnitude.

AI asset discipline

Share of prompt pieces carrying eval cases; eval pass-rate history visible across versions.

Knowledge preservation

Pieces reused by someone other than their author — the truest signal that organisational memory is being built.

A new engineer joins, connects their assistant to the team Vault, and ships production-quality work on day one using pieces they did not write and decisions they did not have to re-make. When that story is routine, the Engineering Knowledge Operating System exists.

11 Documentation

From zero to first piece in five minutes.

# build the engine — one static binary cd engine && go build -o ../brico ./cmd/brico && cd .. # capture your first piece ./brico extract ./brico capture auth -y -d "JWT auth with Passport & bcrypt" -t security,jwt # browse, then compose into a new project ./brico list ./brico --cwd ../new-service add auth -y ./brico doctor
CommandStatusWhat it does
brico extractworkingX-rays a NestJS or Next.js project, surfaces reusable candidates ranked by confidence
brico captureworkingSnapshots a module into an immutable, semver'd piece with a manifest
brico addworkingResolves a version, copies files, merges env vars, prints wiring steps
brico list / searchworkingFinds any piece by name, tag, or description via a self-healing index
brico doctorworkingValidates engine, adapters, Vault, and project
brico uiworkingFull-screen terminal cockpit over the Vault
brico publishworkingPushes the Vault or a single piece to a GitHub repo
brico mcpphase AExposes the Vault as a Model Context Protocol server
brico evalphase BRuns versioned evaluation cases for prompt pieces
brico statsphase CLocal, opt-in token-savings accounting
brico graphphase CQueries the relationship graph — depends_on, replaces, similar_to
# push the whole Vault to your main GitHub repo ./brico publish # publish a single piece — merges with what the target already holds ./brico publish auth # publish to a different repo entirely ./brico publish -l ./brico publish --repo git@github.com:you/team-vault.git

The main repo is asked for once and saved to your global config — override with --repo/-l or the LEGO_PUBLISH_REPO environment variable. Pushes use your ambient git credentials.

# expose the Vault to any MCP-capable assistant ./brico mcp # tools served: search_pieces(query, kind?) → cards get_piece(name, level) → card | surface | summary | source plan_reuse(task) → candidates with fit rationale get_relations(name, kind?) → graph neighbourhood

Days of work, not months — a thin protocol layer over the same engine and index the CLI already uses.

Stop rebuilding.
Start composing.

Your next answer is already sitting in your last project. Reuse beats regeneration — enforced by making reuse the cheapest path.