1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
//! Workspace-internal safe libcugraph execution component for Algeon.
//!
//! Published as an Algeon implementation dependency. Applications use
//! [`algeon-datafusion`](https://docs.rs/algeon-datafusion); workspace code
//! uses this crate for its component contracts. See the
//! [API documentation boundary](https://algeon.dev/design#api-documentation).
//!
//! Algeon integrations enter through a runtime-bound [`ResourceHandle`], use
//! the prepared transfer contracts in [`cudf_interop`], and retain explicit
//! producer readiness and consumer completion ordering. Native failures are
//! preserved as structured [`Error`] values.
//!
//! # Key concepts
//!
//! - **[`cudf_interop`]**: canonical prepared cuDF graph ingress and result
//! egress for the Algeon engine.
//! - **[`ResourceHandle`]**: long-lived owner of GPU execution provenance
//! (bound device, retained runtime, cuGraph resource handle). Not
//! thread-safe.
//! - **[`EnteredContext`]**: short-lived execution session created by
//! [`ResourceHandle::enter`]. GPU-capable APIs require this token.
//! - **[`DeviceArray<T>`]**: owning GPU array with compile-time element type.
//! Freed on drop. Create views via [`DeviceArray::view()`].
//! - **[`GraphBuilder`]**: low-level builder for constructing a [`Graph`] from
//! pre-materialized device edge lists. Validates inputs before crossing the
//! FFI boundary.
//! - **[`Graph<T>`]**: graph container parameterized by transposition state
//! ([`Forward`] or [`Transposed`]). Algorithm methods are constrained by the
//! required layout.
//!
//! # Type-state encoding
//!
//! The [`Graph<T>`] type parameter encodes whether storage is in forward or
//! transposed layout. Algorithms enforce their required layout at compile time:
//!
//! - **[`Forward`]**: required by [`Graph::bfs`] and [`Graph::louvain`]
//! - **[`Transposed`]**: required by [`Graph::pagerank`],
//! [`Graph::in_degrees`], [`Graph::degrees`]
//! - **Generic** (`T: Transposition`): [`Graph::betweenness_centrality`],
//! [`Graph::force_atlas2`], [`Graph::out_degrees`]
//!
//! # cudf interop
//!
//! The [`cudf_interop`] module owns single-GPU prepared graph construction
//! from cudf tables and result-to-DataFrame conversion. The prepared export
//! contract is the canonical Algeon ingress path.
// ═══════════════════════════════════════════════════════════════════════════
// Crate-root re-exports; foundational cross-cutting types only
// ═══════════════════════════════════════════════════════════════════════════
// Arrays
pub use ;
// Error handling
pub use ;
// Graph construction and type-state
pub use ;
// Infrastructure
pub use ;
// Unified cross-module vertex input model
pub use VertexSelection;