pre-reasoning 2.5.0__py3-none-any.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.
@@ -0,0 +1,61 @@
1
+ """Public package API for Pre-Reasoning."""
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+
7
+ from .pre_reasoning_v2_5 import ReasoningEngineV25
8
+
9
+ ReasoningEngine = ReasoningEngineV25
10
+
11
+ __all__ = [
12
+ "ReasoningEngineV25",
13
+ "ReasoningEngine",
14
+ "analyze",
15
+ "pulse",
16
+ "get_engine",
17
+ ]
18
+
19
+
20
+ def get_engine(
21
+ *,
22
+ checkpoint_path: Optional[str] = None,
23
+ device: str = "auto",
24
+ ) -> ReasoningEngineV25:
25
+ """Create a reasoning engine.
26
+
27
+ The package-level default is auto mode: use neural perception when the
28
+ optional dependencies are installed, otherwise fall back to deterministic
29
+ graph reasoning without torch.
30
+ """
31
+ return ReasoningEngineV25(
32
+ checkpoint_path=checkpoint_path,
33
+ device=device,
34
+ )
35
+
36
+
37
+ def analyze(
38
+ text: str,
39
+ *,
40
+ checkpoint_path: Optional[str] = None,
41
+ device: str = "auto",
42
+ ) -> dict:
43
+ """Analyze problem text and return a structural trace result."""
44
+ return get_engine(
45
+ checkpoint_path=checkpoint_path,
46
+ device=device,
47
+ ).analyze(text)
48
+
49
+
50
+ def pulse(
51
+ original_problem: str,
52
+ response: str,
53
+ *,
54
+ checkpoint_path: Optional[str] = None,
55
+ device: str = "auto",
56
+ ) -> dict:
57
+ """Check whether a draft response addresses detected root blockers."""
58
+ return get_engine(
59
+ checkpoint_path=checkpoint_path,
60
+ device=device,
61
+ ).pulse(original_problem, response)
@@ -0,0 +1 @@
1
+ """Bundled weights for optional neural perception."""
pre_reasoning/cli.py ADDED
@@ -0,0 +1,9 @@
1
+ """Console entry point for Pre-Reasoning."""
2
+
3
+ from .pre_reasoning_v2_5 import main
4
+
5
+ __all__ = ["main"]
6
+
7
+
8
+ if __name__ == "__main__":
9
+ main()