baseplate 0.2.1

Shared substrate for agentic-harness tooling — model registry, trace types, path resolution, a cxpak MCP client, and Java-test detection
Documentation

baseplate

CI Crates.io docs.rs ghcr.io License

The shared substrate for agentic-harness tooling — the small, dependency-light crate that verification, planning, and measurement tools sit on so they don't each re-implement the same floor.

baseplate is deliberately not a tool with a behavioral contract of its own. It is the common floor underneath the components that verify, plan, and measure an agentic coding loop: the model registry, the trace/finding types they exchange, root/path resolution, a cxpak MCP client, and Java-test detection. Depend on it and use only the pieces you need.

Part of the Barnett Studios agentic-harness toolkit → cxpak · commitward · abproof · cascadr · cordon · slicr · baseplate

What's inside

Module Responsibility
model The model registry — canonical model identifiers and their tiers/aliases.
trace The shared trace/finding value types tools exchange (a turn's observed edits).
paths Root resolution — $BASEPLATE_HOME-anchored, git-tree aware, with no hard-coded home.
registry Loading and merging YAML registries (promises, checkpoints) with a stable schema.
cxpak A thin rmcp client for the cxpak MCP server (child-process transport).
java_test Detection of Java test files (unit *Test.java, integration *IT.java, system *SIT.java).
patterns Shared regex primitives compiled once, reused across tools.

Use

[dependencies]
baseplate = "0.2"
use baseplate::{model, registry, trace};

// Load a YAML registry (promises/checkpoints) from an explicit path.
let reg = registry::load(std::path::Path::new("registry.yaml"), None)?;

Root resolution honours $BASEPLATE_HOME (the distribution-safe anchor for a binary installed outside a git tree), else the git tree the binary lives in, else the current directory — no hard-coded $HOME path. It pulls a small, boring dependency set (serde, regex, tokio, rmcp) and nothing language-model-specific.

The query CLI — the invocable ops as a one-shot container

baseplate's dominant value is the shared types other crates compile against — a role that has no runtime surface and stays a compile-time crate dependency. But a subset of its modules have genuinely-invocable ops, and those ship as a self-contained CLI (a cli feature) packaged as a container image, so any harness can use them without linking the crate. Each op reads a JSON request on stdin and writes an ADR-0052 envelope ({schema_version, status, body}) on stdout, network-free:

$ echo '{"paths":["src/test/java/x/FooTest.java","src/main/java/x/Foo.java"]}' \
    | docker run --rm -i --network none ghcr.io/barnett-studios/baseplate java-test analyze
{"schema_version":"1","status":"ok","body":{"results":[{"path":"src/test/java/x/FooTest.java","is_java_test":true},...]}}
Op Request Answers
java-test analyze {paths: [String]} which paths are Java test files
patterns match {pattern, content, case_insensitive?} does a regex compile, and where it matches
registry load {registry_yaml, overrides_yaml?} parse + summarize a promise registry (valid? version, promises)

An uncompilable pattern or invalid registry is a result (compiles: false / valid: false), not a failure; only a malformed request yields status: "error" + a non-zero exit, so a consumer falls back to its in-process path rather than trusting an empty result.

Honest scope. model/trace (shared types) and the cxpak client (needs a live MCP server) have no mount-free surface and are intentionally not exposed here — this image is baseplate's consumable face, not its primary role, which stays a linked crate. The image is standalone: no other component derives FROM it. Build the binary from source with cargo build --release --features cli; it's also on the Homebrew tap (brew install barnett-studios/tap/baseplate).

Stability

Pre-1.0: the surface may change between minor versions. The cxpak client tracks the cxpak MCP tool contract (op-parameterized intent tools); a breaking change there is called out in the release notes. Downstream tools pin a compatible minor.

License

Licensed under either of MIT or Apache-2.0 at your option. Unless you explicitly state otherwise, any contribution you intentionally submit for inclusion in the work shall be dual-licensed as above, without any additional terms.


Built by Barnett Studios — the substrate under cxpak · commitward · cascadr · abproof · cordon · slicr.