Expand description
§cargo-context-core
Core engine for cargo-context: assembles Rust project context packs for
LLM consumption with token budgeting, macro expansion, and secret scrubbing.
The crate has no async runtime dependency and no terminal I/O. It is designed to be embedded in CLIs, editor plugins, MCP servers, and build scripts alike.
Re-exports§
pub use budget::Budget;pub use budget::BudgetStrategy;pub use config::PackProfile;pub use config::ProjectConfig;pub use error::Error;pub use error::Result;pub use expand::ExpandMode;pub use impact::Finding;pub use impact::filter_and_sort as filter_findings;pub use impact::parse_envelope;pub use impact::unique_paths;pub use options::PackOptions;pub use pack::Format;pub use pack::Pack;pub use pack::PackBuilder;pub use pack::Preset;pub use pack::Section;pub use tokenize::Tokenizer;
Modules§
- budget
- Token budget allocation.
- collect
- Source collection: compiler errors, git diff, cargo metadata, entry points, and related tests.
- config
- Project-level
.cargo-context/config.yamlsupport. - error
- expand
cargo expandintegration.- impact
cargo-impactenvelope parsing and finding filters.- options
- pack
- scrub
- Secret scrubber.
- tokenize
- Tokenizers.