Expand description
LC (LLM Client) Library
This library provides the core functionality for the LC CLI tool, including configuration management, provider handling, and chat functionality.
§Platform Differences
This crate includes platform-specific features that are only available on certain operating systems:
§Unix Socket Support
Unix socket functionality is only available on Unix-like systems (Linux, macOS, BSD, WSL2) and requires
the unix-sockets feature to be enabled.
§MCP Daemon
The MCP (Model Context Protocol) daemon functionality uses Unix domain sockets for inter-process communication and is therefore only available on Unix systems:
- Unix systems (Linux, macOS, WSL2): Full MCP daemon support with persistent connections
- Windows: MCP daemon is not supported; direct MCP connections work on all platforms
§Usage Statistics
Usage statistics functionality works on all platforms (Windows, macOS, Linux, WSL2). It uses SQLite database which has full cross-platform support.
§Feature Flags
unix-sockets: Enables Unix socket functionality (default on Unix systems)pdf: Enables PDF processing support (default)
To build without Unix socket support:
cargo build --no-default-features --features pdfTo build with all features:
cargo build --features "unix-sockets,pdf"Re-exports§
pub use core::chat;pub use core::completion;pub use core::http_client;pub use core::provider;pub use core::provider_installer;pub use data::config;pub use data::database;pub use data::keys;pub use data::vector_db;pub use models::cache as models_cache;pub use models::dump_metadata;pub use models::metadata as model_metadata;pub use models::unified_cache;pub use services::mcp;pub use services::proxy;pub use services::mcp_daemon;pub use services::webchatproxy;pub use utils::audio as audio_utils;pub use utils::image as image_utils;pub use utils::input;pub use utils::template_processor;pub use utils::test as test_utils;pub use utils::token as token_utils;pub use analytics::usage_stats;pub use config::CachedToken;pub use config::Config;pub use config::ProviderConfig;pub use provider::ChatRequest;pub use provider::Message;pub use provider::OpenAIClient;
Modules§
- analytics
- cli
- CLI module - organized by domain
- core
- data
- error
- models
- readers
- search
- services
- sync
- Synchronization functionality for lc configurations
- utils
Macros§
- debug_
log - test_
with_ cleanup - Macro to wrap test functions with automatic setup and cleanup