Skip to main content

CLI and MCP server for the DKE-Forge deterministic code intelligence engine

Project description

dke-forge

Python CLI and MCP server for DKE-Forge — a deterministic, graph-native code intelligence engine.

This package is a thin HTTP client over the Forge API. The reasoning engine itself (graph construction, pattern learning, provenance tracking, impact analysis) runs server-side at dke-forge.com. Your code is ingested into a private graph; every query returns grounded, provenance-tagged answers — no LLM guessing.

Install

pip install dke-forge              # CLI only
pip install 'dke-forge[mcp]'       # CLI + MCP stdio server

Configure

Sign up at dke-forge.com to get an API key, then:

dke-forge config set api_key fga_your_key

Or set environment variables (overrides the config file):

export FORGE_URL=https://dke-forge.com
export FORGE_API_KEY=fga_your_key

The config file lives at ~/.config/dke-forge/config.json (chmod 600).

CLI

dke-forge health                          # server status
dke-forge graph stats                     # node/edge counts
dke-forge graph function main             # look up a function
dke-forge graph callers authenticate      # who calls authenticate?
dke-forge graph impact login              # what breaks if login changes?
dke-forge scan /path/to/repo              # ingest a repo (polls to completion)
dke-forge scan /path/to/repo --no-wait    # returns scan_id; poll separately
dke-forge scan-status <scan_id>           # check async scan progress

Run dke-forge --help for the full command tree.

MCP — Claude Code, VS Code, Cursor, any MCP client

Install with the [mcp] extra, then add this to your MCP client config.

Claude Code (.mcp.json at project root, or ~/.mcp.json for global):

{
  "mcpServers": {
    "forge": {
      "command": "dke-forge-mcp",
      "env": {
        "FORGE_URL": "https://dke-forge.com",
        "FORGE_API_KEY": "fga_your_key"
      }
    }
  }
}

Cursor / VS Code (via settings.json):

{
  "mcp.servers": {
    "forge": {
      "command": "dke-forge-mcp",
      "env": {
        "FORGE_URL": "https://dke-forge.com",
        "FORGE_API_KEY": "fga_your_key"
      }
    }
  }
}

The server advertises 27 tools over stdio. Your assistant will discover them automatically and invoke them when it needs structural facts about your code.

27 Tools, 10 Categories

Category Tools
Foundation forge_graph_stats
Navigation forge_query_function, forge_callers_of, forge_callees_of, forge_depends_on, forge_impact_analysis, forge_callgraph_reachable, forge_find_implementers
Architecture forge_dead_code, forge_subgraph
Rules forge_rules, forge_check_rules
Provenance forge_contradictions, forge_last_modified, forge_provenance, forge_reasoning_trace
Patterns forge_patterns, forge_pattern_catalog, forge_pattern_detail, forge_learn_patterns
Generation-prep forge_envelope
Ingestion forge_scan, forge_scan_status, forge_ingest
Generation forge_generate
Meta forge_health, forge_auth_verify

Full tool reference: dke-forge.com/mcp.html

What Makes Forge Different

Every MCP tool answer is provenance-tagged — you can ask where a claim came from. Queries are deterministic — same graph, same answer. Contradictions in the graph are surfaced, not hidden. Pattern discovery has a lifecycle (proposed → supported → confirmed) with confidence propagation. This is the set of things a graph-native reasoning engine can do that LLM-plus-grep fundamentally cannot.

Requirements

  • Python 3.8+
  • A DKE-Forge account with an API key (sign up)

License

MIT. See LICENSE.

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dke_forge-0.2.0.tar.gz (22.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dke_forge-0.2.0-py3-none-any.whl (17.2 kB view details)

Uploaded Python 3

File details

Details for the file dke_forge-0.2.0.tar.gz.

File metadata

  • Download URL: dke_forge-0.2.0.tar.gz
  • Upload date:
  • Size: 22.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.2

File hashes

Hashes for dke_forge-0.2.0.tar.gz
Algorithm Hash digest
SHA256 8b813493527021f964edc86d6b1bb007c59a0223796d6000eb045b0fa9c47161
MD5 cc65879bb358283d5afe377bc5b43fb0
BLAKE2b-256 d02971c6c1da45bc7ed312d4842f8f6637a0312e174e062e2721ea186e1a2556

See more details on using hashes here.

File details

Details for the file dke_forge-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: dke_forge-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 17.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.2

File hashes

Hashes for dke_forge-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 daade15122258705895dbc70208b3b716243d58a494a55c75f3d3a77ae01a19c
MD5 12fcb850d76c8dc87af05cf6ea7b81a3
BLAKE2b-256 b2ca031af65aa7d2aa7bcd9e40df78f084e3e016a2513758b38df005696b871e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page