Skip to content

Concept packs

A concept pack adds topics, tiers and prerequisites to Eklavya’s built-in git, node-backend, react and web-auth graphs. Use a pack for another technology or concepts specific to your codebase.

/eklavya:pack rust
/eklavya:pack this repo

The command asks for scope, checks existing concepts, writes the pack, then runs eklavya doctor to apply it. It does not start a lesson; use /eklavya:learn <topic> for that.

Where they live

PathScope
~/.eklavya/packs/*.jsonYou, across projects.
~/.eklavya/projects/<checkout>/packs/*.jsonYou, in one codebase and its worktrees.
<repo>/.eklavya/packs/*.jsonLegacy location: still read, never written or moved automatically.

New packs live under your home directory. To share one, distribute the JSON and have each developer copy it into their own pack directory.

Packs apply when a process opens the database and detects changed pack files. The MCP server is long-lived, so a pack written mid-session needs eklavya doctor, which reapplies packs unconditionally.

What a pack looks like

{
"pack": "acme-billing",
"version": "1.0.0",
"domain": "acme",
"concepts": [
{
"slug": "idempotency-keys",
"name": "Idempotency keys",
"tier": 2,
"description": "Why billing writes use a key to make retries safe."
},
{
"slug": "ledger-append-only",
"name": "The ledger is append-only",
"tier": 3,
"description": "Why corrections create new ledger entries."
}
],
"edges": [
{
"from": "idempotency-keys",
"to": "ledger-append-only",
"relation": "prerequisite_of"
}
]
}
FieldRequirements
packRequired nonempty identifier.
versionOptional version string.
domainRequired domain for grouping concepts.
concepts[]Lowercase hyphenated slug, name, tier from 1–5; optional description and per-concept domain.
edges[]from, to, and relation: prerequisite_of, related_to or part_of.

Edges can refer to concepts outside this file, including shipped concepts. Missing endpoints are dropped and counted by doctor. See Levels and tiers for tier meanings.

Merge rules

Packs extend the graph rather than replacing it. Later definitions of the same slug win, in this order:

  1. Shipped concepts.
  2. Global packs.
  3. Legacy packs in the repository.
  4. Personal project packs.

Files within each directory load alphabetically. Overrides affect your shared concept graph across projects, even when loaded from a project pack. Leaving that project does not restore a previous definition.

Removing a pack file stops future applications but keeps its concepts and your answers. A malformed pack is skipped without preventing other packs or Eklavya from loading.

Checking a pack

Terminal window
eklavya doctor

The report names loaded packs, their scope and version, invalid packs and missing edge endpoints. If a new domain is absent from your profile, check domains_enabled; it can filter the profile even when a concept remains available for an explicit quiz.

Packs contain concepts and relationships, not question wording or translated tutor instructions.