Skip to main content

ccboard_core/
lib.rs

1//! ccboard-core - Core library for ccboard
2//!
3//! Provides parsers, models, store, and file watcher for Claude Code data.
4
5pub mod analytics;
6pub mod cache;
7pub mod error;
8pub mod event;
9pub mod export;
10pub mod graph;
11pub mod hook_event;
12pub mod hook_state;
13pub mod live_monitor;
14pub mod models;
15pub mod parsers;
16pub mod preferences;
17pub mod pricing;
18pub mod quota;
19pub mod store;
20pub mod usage_estimator;
21pub mod watcher;
22
23pub use analytics::{
24    compute_trends, detect_patterns, discover_call_llm, discover_collect_sessions,
25    discover_patterns, forecast_usage, generate_insights, run_discover, AnalyticsData,
26    DiscoverConfig, DiscoverSessionData, DiscoverSuggestion, ForecastData, LlmSuggestion, Period,
27    SuggestionCategory, TrendDirection, TrendsData, UsagePatterns,
28};
29pub use cache::{AggregateStats, SearchResult, StoredAlert};
30pub use error::{CoreError, DegradedState, LoadReport};
31pub use event::{DataEvent, EventBus};
32pub use export::{
33    export_billing_blocks_to_csv, export_billing_blocks_to_json, export_billing_blocks_to_markdown,
34    export_sessions_to_csv, export_sessions_to_json, export_sessions_to_markdown,
35    export_stats_to_csv, export_stats_to_json, export_stats_to_markdown,
36};
37pub use hook_event::{status_from_event, HookPayload};
38pub use hook_state::{
39    make_session_key, HookSession, HookSessionStatus, LiveSessionFile, SessionKey,
40};
41pub use live_monitor::{
42    detect_live_sessions, merge_live_sessions, LiveSession, LiveSessionDisplayStatus,
43    MergedLiveSession, SessionType,
44};
45pub use models::activity::{
46    ActivitySummary, Alert, AlertCategory, AlertSeverity, BashCommand, FileAccess, FileOperation,
47    NetworkCall, NetworkTool, ToolCall as ActivityToolCall,
48};
49pub use quota::{calculate_quota_status, AlertLevel, QuotaStatus};
50pub use store::{DataStore, ProjectLeaderboardEntry};
51pub use usage_estimator::{calculate_usage_estimate, SubscriptionPlan, UsageEstimate};
52pub use watcher::FileWatcher;