causalsieve 0.1.0__py3-none-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- causalsieve/__init__.py +113 -0
- causalsieve/__init__.pyi +131 -0
- causalsieve/__main__.py +8 -0
- causalsieve/_native.py +1976 -0
- causalsieve/adapters.py +1063 -0
- causalsieve/causalsieve.dll +0 -0
- causalsieve/cli.py +432 -0
- causalsieve/digest.py +852 -0
- causalsieve/mcp_server.py +968 -0
- causalsieve/py.typed +0 -0
- causalsieve/swarm.py +657 -0
- causalsieve-0.1.0.dist-info/METADATA +229 -0
- causalsieve-0.1.0.dist-info/RECORD +18 -0
- causalsieve-0.1.0.dist-info/WHEEL +5 -0
- causalsieve-0.1.0.dist-info/entry_points.txt +3 -0
- causalsieve-0.1.0.dist-info/licenses/LICENSE +21 -0
- causalsieve-0.1.0.dist-info/licenses/NOTICE +65 -0
- causalsieve-0.1.0.dist-info/top_level.txt +1 -0
causalsieve/__init__.py
ADDED
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
"""CausalSieve — Sub-millisecond SIMD online multivariate causal discovery & stream digests.
|
|
2
|
+
|
|
3
|
+
Zero runtime dependencies. Uses PEP 562 lazy attribute loading with zero
|
|
4
|
+
top-level stdlib imports so CLI startup adds <1 ms of package overhead.
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
__version__ = "0.1.0"
|
|
8
|
+
CAUSALSIEVE_ABI_VERSION = 1
|
|
9
|
+
|
|
10
|
+
__all__ = [
|
|
11
|
+
"CAUSALSIEVE_ABI_VERSION",
|
|
12
|
+
"__version__",
|
|
13
|
+
"CSConfig",
|
|
14
|
+
"CSTickResult",
|
|
15
|
+
"CSVAnalysisResult",
|
|
16
|
+
"CausalBlackboard",
|
|
17
|
+
"CausalDigest",
|
|
18
|
+
"CausalEdge",
|
|
19
|
+
"CausalSieve",
|
|
20
|
+
"CausalSieveError",
|
|
21
|
+
"CausalSieveLibraryError",
|
|
22
|
+
"CausalSnapshot",
|
|
23
|
+
"ConsensusReport",
|
|
24
|
+
"EngineState",
|
|
25
|
+
"GrangerResult",
|
|
26
|
+
"HypothesisRecord",
|
|
27
|
+
"MCPServer",
|
|
28
|
+
"PLACompression",
|
|
29
|
+
"PLATrajectory",
|
|
30
|
+
"PrecisionResult",
|
|
31
|
+
"RawSlice",
|
|
32
|
+
"RootAttribution",
|
|
33
|
+
"RootAttributionItem",
|
|
34
|
+
"RootRow",
|
|
35
|
+
"ScreenedActiveGraph",
|
|
36
|
+
"ScreenedBatchResult",
|
|
37
|
+
"ScreenedSieve",
|
|
38
|
+
"StreamStore",
|
|
39
|
+
"TickResult",
|
|
40
|
+
"analyze_csv",
|
|
41
|
+
"analyze_dataframe",
|
|
42
|
+
"analyze_prometheus",
|
|
43
|
+
"build_digest",
|
|
44
|
+
"compute_stream_id",
|
|
45
|
+
"default_stream_store",
|
|
46
|
+
"estimate_raw_tokens",
|
|
47
|
+
"estimate_tokens",
|
|
48
|
+
"library_path",
|
|
49
|
+
"load_library",
|
|
50
|
+
"parse_slice_handle",
|
|
51
|
+
"rcaeval_rca",
|
|
52
|
+
"recover_handle",
|
|
53
|
+
"recover_slice",
|
|
54
|
+
"register_stream",
|
|
55
|
+
"simd_isa",
|
|
56
|
+
]
|
|
57
|
+
|
|
58
|
+
_LAZY_MAP = {
|
|
59
|
+
"CSConfig": ("causalsieve._native", "CSConfig"),
|
|
60
|
+
"CSTickResult": ("causalsieve._native", "CSTickResult"),
|
|
61
|
+
"CSVAnalysisResult": ("causalsieve._native", "CSVAnalysisResult"),
|
|
62
|
+
"CausalSieve": ("causalsieve._native", "CausalSieve"),
|
|
63
|
+
"CausalSieveError": ("causalsieve._native", "CausalSieveError"),
|
|
64
|
+
"CausalSieveLibraryError": ("causalsieve._native", "CausalSieveLibraryError"),
|
|
65
|
+
"EngineState": ("causalsieve._native", "EngineState"),
|
|
66
|
+
"GrangerResult": ("causalsieve._native", "GrangerResult"),
|
|
67
|
+
"PLACompression": ("causalsieve._native", "PLACompression"),
|
|
68
|
+
"PrecisionResult": ("causalsieve._native", "PrecisionResult"),
|
|
69
|
+
"RawSlice": ("causalsieve._native", "RawSlice"),
|
|
70
|
+
"RootAttribution": ("causalsieve._native", "RootAttribution"),
|
|
71
|
+
"RootAttributionItem": ("causalsieve._native", "RootAttributionItem"),
|
|
72
|
+
"ScreenedActiveGraph": ("causalsieve._native", "ScreenedActiveGraph"),
|
|
73
|
+
"ScreenedBatchResult": ("causalsieve._native", "ScreenedBatchResult"),
|
|
74
|
+
"ScreenedSieve": ("causalsieve._native", "ScreenedSieve"),
|
|
75
|
+
"TickResult": ("causalsieve._native", "TickResult"),
|
|
76
|
+
"analyze_csv": ("causalsieve._native", "analyze_csv"),
|
|
77
|
+
"library_path": ("causalsieve._native", "library_path"),
|
|
78
|
+
"load_library": ("causalsieve._native", "load_library"),
|
|
79
|
+
"simd_isa": ("causalsieve._native", "simd_isa"),
|
|
80
|
+
"analyze_dataframe": ("causalsieve.adapters", "analyze_dataframe"),
|
|
81
|
+
"analyze_prometheus": ("causalsieve.adapters", "analyze_prometheus"),
|
|
82
|
+
"rcaeval_rca": ("causalsieve.adapters", "rcaeval_rca"),
|
|
83
|
+
"CausalDigest": ("causalsieve.digest", "CausalDigest"),
|
|
84
|
+
"CausalEdge": ("causalsieve.digest", "CausalEdge"),
|
|
85
|
+
"PLATrajectory": ("causalsieve.digest", "PLATrajectory"),
|
|
86
|
+
"RootRow": ("causalsieve.digest", "RootRow"),
|
|
87
|
+
"StreamStore": ("causalsieve.digest", "StreamStore"),
|
|
88
|
+
"build_digest": ("causalsieve.digest", "build_digest"),
|
|
89
|
+
"compute_stream_id": ("causalsieve.digest", "compute_stream_id"),
|
|
90
|
+
"default_stream_store": ("causalsieve.digest", "default_stream_store"),
|
|
91
|
+
"estimate_raw_tokens": ("causalsieve.digest", "estimate_raw_tokens"),
|
|
92
|
+
"estimate_tokens": ("causalsieve.digest", "estimate_tokens"),
|
|
93
|
+
"parse_slice_handle": ("causalsieve.digest", "parse_slice_handle"),
|
|
94
|
+
"recover_handle": ("causalsieve.digest", "recover_handle"),
|
|
95
|
+
"recover_slice": ("causalsieve.digest", "recover_slice"),
|
|
96
|
+
"register_stream": ("causalsieve.digest", "register_stream"),
|
|
97
|
+
"CausalBlackboard": ("causalsieve.swarm", "CausalBlackboard"),
|
|
98
|
+
"CausalSnapshot": ("causalsieve.swarm", "CausalSnapshot"),
|
|
99
|
+
"ConsensusReport": ("causalsieve.swarm", "ConsensusReport"),
|
|
100
|
+
"HypothesisRecord": ("causalsieve.swarm", "HypothesisRecord"),
|
|
101
|
+
"MCPServer": ("causalsieve.mcp_server", "MCPServer"),
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
def __getattr__(name: str) -> object:
|
|
106
|
+
target = _LAZY_MAP.get(name)
|
|
107
|
+
if target is None:
|
|
108
|
+
raise AttributeError(f"module 'causalsieve' has no attribute {name!r}")
|
|
109
|
+
module_name, attr_name = target
|
|
110
|
+
mod = __import__(module_name, fromlist=[attr_name])
|
|
111
|
+
val = getattr(mod, attr_name)
|
|
112
|
+
globals()[name] = val
|
|
113
|
+
return val
|
causalsieve/__init__.pyi
ADDED
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
from causalsieve._native import (
|
|
2
|
+
CausalSieve as CausalSieve,
|
|
3
|
+
)
|
|
4
|
+
from causalsieve._native import (
|
|
5
|
+
CausalSieveError as CausalSieveError,
|
|
6
|
+
)
|
|
7
|
+
from causalsieve._native import (
|
|
8
|
+
CausalSieveLibraryError as CausalSieveLibraryError,
|
|
9
|
+
)
|
|
10
|
+
from causalsieve._native import (
|
|
11
|
+
CSConfig as CSConfig,
|
|
12
|
+
)
|
|
13
|
+
from causalsieve._native import (
|
|
14
|
+
CSTickResult as CSTickResult,
|
|
15
|
+
)
|
|
16
|
+
from causalsieve._native import (
|
|
17
|
+
CSVAnalysisResult as CSVAnalysisResult,
|
|
18
|
+
)
|
|
19
|
+
from causalsieve._native import (
|
|
20
|
+
EngineState as EngineState,
|
|
21
|
+
)
|
|
22
|
+
from causalsieve._native import (
|
|
23
|
+
GrangerResult as GrangerResult,
|
|
24
|
+
)
|
|
25
|
+
from causalsieve._native import (
|
|
26
|
+
PLACompression as PLACompression,
|
|
27
|
+
)
|
|
28
|
+
from causalsieve._native import (
|
|
29
|
+
PrecisionResult as PrecisionResult,
|
|
30
|
+
)
|
|
31
|
+
from causalsieve._native import (
|
|
32
|
+
RawSlice as RawSlice,
|
|
33
|
+
)
|
|
34
|
+
from causalsieve._native import (
|
|
35
|
+
RootAttribution as RootAttribution,
|
|
36
|
+
)
|
|
37
|
+
from causalsieve._native import (
|
|
38
|
+
RootAttributionItem as RootAttributionItem,
|
|
39
|
+
)
|
|
40
|
+
from causalsieve._native import (
|
|
41
|
+
ScreenedActiveGraph as ScreenedActiveGraph,
|
|
42
|
+
)
|
|
43
|
+
from causalsieve._native import (
|
|
44
|
+
ScreenedBatchResult as ScreenedBatchResult,
|
|
45
|
+
)
|
|
46
|
+
from causalsieve._native import (
|
|
47
|
+
ScreenedSieve as ScreenedSieve,
|
|
48
|
+
)
|
|
49
|
+
from causalsieve._native import (
|
|
50
|
+
TickResult as TickResult,
|
|
51
|
+
)
|
|
52
|
+
from causalsieve._native import (
|
|
53
|
+
analyze_csv as analyze_csv,
|
|
54
|
+
)
|
|
55
|
+
from causalsieve._native import (
|
|
56
|
+
library_path as library_path,
|
|
57
|
+
)
|
|
58
|
+
from causalsieve._native import (
|
|
59
|
+
load_library as load_library,
|
|
60
|
+
)
|
|
61
|
+
from causalsieve._native import (
|
|
62
|
+
simd_isa as simd_isa,
|
|
63
|
+
)
|
|
64
|
+
from causalsieve.adapters import (
|
|
65
|
+
analyze_dataframe as analyze_dataframe,
|
|
66
|
+
)
|
|
67
|
+
from causalsieve.adapters import (
|
|
68
|
+
analyze_prometheus as analyze_prometheus,
|
|
69
|
+
)
|
|
70
|
+
from causalsieve.adapters import (
|
|
71
|
+
rcaeval_rca as rcaeval_rca,
|
|
72
|
+
)
|
|
73
|
+
from causalsieve.digest import (
|
|
74
|
+
CausalDigest as CausalDigest,
|
|
75
|
+
)
|
|
76
|
+
from causalsieve.digest import (
|
|
77
|
+
CausalEdge as CausalEdge,
|
|
78
|
+
)
|
|
79
|
+
from causalsieve.digest import (
|
|
80
|
+
PLATrajectory as PLATrajectory,
|
|
81
|
+
)
|
|
82
|
+
from causalsieve.digest import (
|
|
83
|
+
RootRow as RootRow,
|
|
84
|
+
)
|
|
85
|
+
from causalsieve.digest import (
|
|
86
|
+
StreamStore as StreamStore,
|
|
87
|
+
)
|
|
88
|
+
from causalsieve.digest import (
|
|
89
|
+
build_digest as build_digest,
|
|
90
|
+
)
|
|
91
|
+
from causalsieve.digest import (
|
|
92
|
+
compute_stream_id as compute_stream_id,
|
|
93
|
+
)
|
|
94
|
+
from causalsieve.digest import (
|
|
95
|
+
default_stream_store as default_stream_store,
|
|
96
|
+
)
|
|
97
|
+
from causalsieve.digest import (
|
|
98
|
+
estimate_raw_tokens as estimate_raw_tokens,
|
|
99
|
+
)
|
|
100
|
+
from causalsieve.digest import (
|
|
101
|
+
estimate_tokens as estimate_tokens,
|
|
102
|
+
)
|
|
103
|
+
from causalsieve.digest import (
|
|
104
|
+
parse_slice_handle as parse_slice_handle,
|
|
105
|
+
)
|
|
106
|
+
from causalsieve.digest import (
|
|
107
|
+
recover_handle as recover_handle,
|
|
108
|
+
)
|
|
109
|
+
from causalsieve.digest import (
|
|
110
|
+
recover_slice as recover_slice,
|
|
111
|
+
)
|
|
112
|
+
from causalsieve.digest import (
|
|
113
|
+
register_stream as register_stream,
|
|
114
|
+
)
|
|
115
|
+
from causalsieve.mcp_server import MCPServer as MCPServer
|
|
116
|
+
from causalsieve.swarm import (
|
|
117
|
+
CausalBlackboard as CausalBlackboard,
|
|
118
|
+
)
|
|
119
|
+
from causalsieve.swarm import (
|
|
120
|
+
CausalSnapshot as CausalSnapshot,
|
|
121
|
+
)
|
|
122
|
+
from causalsieve.swarm import (
|
|
123
|
+
ConsensusReport as ConsensusReport,
|
|
124
|
+
)
|
|
125
|
+
from causalsieve.swarm import (
|
|
126
|
+
HypothesisRecord as HypothesisRecord,
|
|
127
|
+
)
|
|
128
|
+
|
|
129
|
+
__version__: str
|
|
130
|
+
CAUSALSIEVE_ABI_VERSION: int
|
|
131
|
+
__all__: list[str]
|