Skip to content

Existing Codebase

You don't need a greenfield project to use SDTK. This workflow builds a docs baseline and a local knowledge graph from code you already have — so agents (and humans) stop rediscovering the same architecture every session.

Prerequisite: npm install -g sdtk-kit and an initialized project (Installation).

1. Build the knowledge graph

bash
sdtk-wiki init --no-open      # index the existing docs into the atlas graph
sdtk-wiki search "<topic>"    # grounded search over the indexed corpus

init/atlas build index your repository's own docs in place into a local knowledge graph — nothing is copied or rewritten. (The old ingest/compile pipeline is deprecated; that job moved to the standalone sdtk-brain tool.)

2. Explore it

bash
sdtk-wiki atlas build   # pure Node, zero dependencies
sdtk-wiki atlas open    # browser viewer — stays alive until Ctrl+C

The Atlas viewer gives you the graph view, docs view, and detail panels. Search and query from the CLI too:

bash
sdtk-wiki search "payment retry"
sdtk-wiki query "<graph query>"

Ask a question and get the passages that answer it, each cited to its source. Pro turns those passages into a written answer:

bash
sdtk-wiki ask "How does the payment flow handle retries?"

3. Docs baseline with Project Intelligence Pro

Where the wiki builds a graph, sdtk-spec project builds and maintains a docs baseline:

bash
sdtk-spec project ingest    # generate the baseline from the code
sdtk-spec project audit     # find gaps and drift
sdtk-spec project refresh   # keep it current as the code evolves

4. Keep it alive

Memory is only useful if it stays current:

bash
sdtk-wiki maintain --mode safe    # lint-only health pass
sdtk-wiki lint                    # check wiki health
sdtk-brain discover --plan        # propose what to document next (standalone sdtk-brain)

Re-run sdtk-brain ingest + sdtk-brain compile --apply (the standalone second-brain pipeline) and sdtk-wiki atlas build after significant changes, or leave sdtk-wiki atlas watch running during a work session.

5. Then work normally

With memory in place, every other SDTK workflow gets sharper: discovery sessions reference real architecture, /arch reads actual constraints, and reviews check against documented intent. From here:

Boundaries

  • The graph is built from your local repo — no web fetch in this release.
  • sdtk-wiki ask needs a built graph. Free returns the ranked, cited passages with no model call at all; Pro synthesizes an answer from them, and that tier is the explicit external call.
  • Nothing destructive runs without an explicit apply.

Where to go next

SDTK — governed, auditable, resumable AI-assisted engineering.