Skip to main content

brep_mcp/
lib.rs

1//! brep_mcp — the BREP MCP automation server, hosted headlessly.
2//!
3//! The server itself lives in `brep_mcp_core`. This crate re-exports its
4//! main modules (`server`, `http`, `host`, `session`, `tools`, `schema`,
5//! `validate`, `script`, `program`, `runner`, `image`, `render_mesh`,
6//! `generate`, `plm_fixture`), so `brep_mcp::server::BrepServer` is the same
7//! type the app embeds behind `brep-app --mcp`. It adds what needs the app
8//! compiled in:
9//!
10//! - the [`headless`] host — the whole `BrepApp` under `egui_kittest` on a
11//!   wgpu device — and [`headless_backend`], the backend every `brep-mcp`
12//!   server runs on (one headless app per session);
13//! - [`command_descriptions`], the application's static command metadata;
14//! - the [`annotate`] overlay the documentation walkthroughs are drawn with;
15//! - the `brep-mcp` binary (`serve`, `schema`, `test`, `shot`, `render-mesh`,
16//!   `skills`).
17//!
18//! See the README for installation, client configuration and the tool groups.
19pub use brep_mcp_core::{
20    generate, host, http, image, plm_fixture, program, render_mesh, runner, schema, script, server, session, tools, validate,
21};
22
23pub mod annotate;
24pub mod headless;
25
26/// The backend every `brep-mcp` server runs on: one headless app per session.
27pub fn headless_backend() -> host::Backend {
28    host::Backend::Spawn { name: "headless", spawn: std::sync::Arc::new(|cfg| headless::spawn(cfg)) }
29}
30
31/// Static application command metadata; discovery does not create a GPU.
32pub fn command_descriptions() -> serde_json::Value { brep_app::automation::command::describe() }