refactor: split gateway into a Cargo workspace member#4
Merged
Conversation
Move the single `beyond-ai` crate into `crates/gateway/` and turn the repo root into a virtual Cargo workspace, so additional AI components (an agent harness, etc.) can live beside the gateway without entangling its deps/build. Behavior-neutral: package `beyond-ai` and lib `beyond_ai` are unchanged, so every `use beyond_ai::…` and `CARGO_BIN_EXE_beyond-ai` keeps working. - root Cargo.toml -> [workspace]: members = ["crates/*"], resolver = 3, hoisted lints to [workspace.lints], [profile.release] at root, and [workspace.dependencies] for deps shared with future crates. - crates/gateway/Cargo.toml: inherits workspace lints/edition/shared deps; gateway-specific deps (pingora, store, rustls…) stay local. - Dockerfile: build line -> `cargo build --release -p beyond-ai --bin beyond-ai`. - mise.toml: example task -> `cargo run -p beyond-ai --example mint_dev_key`. - README: quick-start paths point at crates/gateway/. Verified: build · clippy -D warnings · cargo fmt --all --check · dprint check · 99 unit · 21 integration · benches compile · docker image builds and runs. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Moves the single
beyond-aicrate intocrates/gateway/and turns the repo root into a virtual Cargo workspace, so additional open-source AI components (an agent harness, etc.) can live beside the gateway without entangling its deps/build.This is M0 of a larger effort — the structural "make room for crates" step. No agent code yet.
Behavior-neutral
Package
beyond-aiand libbeyond_aiare unchanged, so everyuse beyond_ai::…andCARGO_BIN_EXE_beyond-aikeeps working. The diff is almost entirelygit mvrenames plus four small manifest/doc edits.Changes
Cargo.toml→[workspace]:members = ["crates/*"],resolver = "3", lints hoisted to[workspace.lints](so theunsafe/panic-surface denies apply to every future crate root),[profile.release]at root, and[workspace.dependencies]for deps shared with future crates.crates/gateway/Cargo.toml: inherits workspace lints/edition/shared deps; gateway-specific deps (pingora, store, rustls…) stay local.Dockerfile: build line →cargo build --release -p beyond-ai --bin beyond-ai.mise.toml: example task →cargo run -p beyond-ai --example mint_dev_key.README: quick-start paths point atcrates/gateway/.Verification
cargo build·clippy --all-targets -D warnings·cargo fmt --all --check·dprint check· 99 unit · 21 integration (+10 smoke ignored) · benches compile · docker image builds and--helpruns.🤖 Generated with Claude Code