Shared core for the witan MCP servers (witan-council + witan-code)
Project description
witan-core
Shared core for the two witan MCP servers — witan (dist witan-council,
mcp/servers/witan) and witan-code (mcp/servers/witan-code). It is the third
shared packages/ sibling alongside
agent-config-kit, wired into both servers via
a [tool.uv.sources] editable path (dev/CI) plus a published PyPI version range.
Why
The two servers were built copy-paste-and-diverge and carried an explicit "deliberately duplicated — no cross-package import" convention. As the shared surface grew, fixes had to be applied twice and silently drifted — including code that is contractually required to stay identical (the repo-key canonicalizer behind the cross-layer symbol join key; the pinned omnigraph binary version, kept in lockstep by a fragile Renovate custom manager).
witan-core deliberately reverses that convention. The full rationale, scope,
and per-extraction contracts live in
docs/design/witan-core-extraction-spec.md.
Invariant
witan_core imports neither witan nor witan_code. It is a leaf below
both, preserving the one-directional witan → witan_code optional-mount DAG
(witan mounts witan-code as witan code; witan-code never imports witan).
Dependencies
The base package is stdlib-only. Heavier concerns are gated behind extras so neither server pulls weight it doesn't use:
witan-core[cli]→cyclopts,rich(CLI scaffolding, styled installer output)witan-core[mcp]→fastmcp(MCP elicitation primitives)
What's here
Extracted so far (each deletes the duplicated copies from both servers):
_detach.popen_detached— cross-platform detached subprocess spawningomnigraph_install— the pinned-omnigraph-binary installer (single source of the version;richimported lazily)elicit— theconfirm/textMCP elicitation primitives (needs themcpextra; not re-exported from the package root)repo_key—normalise+find_git_config, the cross-layer repo-key canonicalizer, with a golden contract testtimeutil.now_isomaintenance— the throttled-optimize stamp/interval/due mechanicsomnigraph.OmnigraphClient— the omnigraph-CLI subprocess wrapper base (write lock, retry/repair, admission-cap backoff); each server subclasses it (witan addsapply_schema; witan-code adds branch ops + bulkload)
Still local to each server (intentionally): the CLI scaffolding — its extraction coordinates with the in-flight multi-user deployment work (see the spec).
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file witan_core-0.2.0.tar.gz.
File metadata
- Download URL: witan_core-0.2.0.tar.gz
- Upload date:
- Size: 111.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fd7ab79fe9ba9a4750728a961ffd61c11e1e400106919594bd744ae732269647
|
|
| MD5 |
12fbeeb1beeaf38e64bdef737f45d9b6
|
|
| BLAKE2b-256 |
4d3d9a69b4b4a764986533fb07b4b9d336145b46cc892c923895ad668dcc0f1e
|
Provenance
The following attestation bundles were made for witan_core-0.2.0.tar.gz:
Publisher:
publish-witan-core.yml on mitodl/agent-kit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
witan_core-0.2.0.tar.gz -
Subject digest:
fd7ab79fe9ba9a4750728a961ffd61c11e1e400106919594bd744ae732269647 - Sigstore transparency entry: 2186969352
- Sigstore integration time:
-
Permalink:
mitodl/agent-kit@3be5850050af662fb1139fedd3505df64cda6520 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mitodl
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-witan-core.yml@3be5850050af662fb1139fedd3505df64cda6520 -
Trigger Event:
push
-
Statement type:
File details
Details for the file witan_core-0.2.0-py3-none-any.whl.
File metadata
- Download URL: witan_core-0.2.0-py3-none-any.whl
- Upload date:
- Size: 25.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ed35913d5866d0c02f3d144a02795f0d2fdf9d9463758e82493e96e07355a15b
|
|
| MD5 |
1255f5afce61fdd3ac9e888770966496
|
|
| BLAKE2b-256 |
7d4641b9bb0e147b87e6ced4d4ae1fe786f7d5e77059abfec23aafd5a59cb9db
|
Provenance
The following attestation bundles were made for witan_core-0.2.0-py3-none-any.whl:
Publisher:
publish-witan-core.yml on mitodl/agent-kit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
witan_core-0.2.0-py3-none-any.whl -
Subject digest:
ed35913d5866d0c02f3d144a02795f0d2fdf9d9463758e82493e96e07355a15b - Sigstore transparency entry: 2186969357
- Sigstore integration time:
-
Permalink:
mitodl/agent-kit@3be5850050af662fb1139fedd3505df64cda6520 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mitodl
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-witan-core.yml@3be5850050af662fb1139fedd3505df64cda6520 -
Trigger Event:
push
-
Statement type: