pactree 0.0.1__tar.gz

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,157 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ *.egg-info/
24
+ .installed.cfg
25
+ *.egg
26
+
27
+ # PyInstaller
28
+ *.manifest
29
+ *.spec
30
+
31
+ # Installer logs
32
+ pip-log.txt
33
+ pip-delete-this.txt
34
+
35
+ # Unit test / coverage reports
36
+ htmlcov/
37
+ .tox/
38
+ .coverage
39
+ .coverage.*
40
+ .cache
41
+ nosetests.xml
42
+ coverage.xml
43
+ *.cover
44
+ .hypothesis/
45
+ .pytest_cache/
46
+
47
+ # Translations
48
+ *.mo
49
+ *.pot
50
+
51
+ # Django stuff:
52
+ *.log
53
+ local_settings.py
54
+ db.sqlite3
55
+
56
+ # Flask stuff:
57
+ instance/
58
+ .webassets-cache
59
+
60
+ # Scrapy stuff:
61
+ .scrapy
62
+
63
+ # Sphinx documentation
64
+ docs/_build/
65
+
66
+ # PyBuilder
67
+ target/
68
+
69
+ # Jupyter Notebook
70
+ .ipynb_checkpoints
71
+
72
+ # pyenv
73
+ .python-version
74
+
75
+ # celery beat schedule file
76
+ celerybeat-schedule
77
+
78
+ # SageMath parsed files
79
+ *.sage.py
80
+
81
+ # Environments
82
+ .env
83
+ .venv
84
+ env/
85
+ venv/
86
+ ENV/
87
+ env.bak/
88
+ venv.bak/
89
+
90
+ # Spyder project settings
91
+ .spyderproject
92
+ .spyproject
93
+
94
+ # Rope project settings
95
+ .ropeproject
96
+
97
+ # mkdocs documentation
98
+ /site
99
+
100
+ # mypy
101
+ .mypy_cache/
102
+
103
+ # PyCharm
104
+ .idea/
105
+ *.iml
106
+
107
+ # Claude AI context files
108
+ CLAUDE.md
109
+ CLAUDE.local.md
110
+
111
+ # VS Code
112
+ .vscode/
113
+ *.code-workspace
114
+
115
+ # macOS
116
+ .DS_Store
117
+
118
+ # Windows
119
+ Thumbs.db
120
+ ehthumbs.db
121
+ Desktop.ini
122
+
123
+ # Claude AI context files
124
+ CLAUDE.md
125
+ CLAUDE.local.md
126
+ AGENTS.md
127
+
128
+ # Documentation and planning (hidden)
129
+ .docs/
130
+
131
+ # Test runs and behavior observation (hidden)
132
+ .samples/
133
+ internal/*
134
+ # Archived tests (not part of CI/CD)
135
+ archived_tests/
136
+
137
+ .tmp/
138
+
139
+ tests/tmp/
140
+
141
+ .tools/
142
+
143
+ # Auto-generated model settings files
144
+ **/model_settings.json
145
+ **/bundled_models.json
146
+ .comprehensive_test_runs/
147
+ .internal/
148
+ .checkpoints/
149
+ .claude/
150
+ screenshots/
151
+ # In-tree provider extension packages — each has its own git repo and
152
+ # ships as a standalone pip-installable package. Parent repo doesn't
153
+ # track them. See providers/claude-code/ for the first one.
154
+ egregore/providers/claude-code/
155
+ egregore/providers/opencode/
156
+ egregore/providers/codex/
157
+ graphify-out/
pactree-0.0.1/PKG-INFO ADDED
@@ -0,0 +1,42 @@
1
+ Metadata-Version: 2.4
2
+ Name: pactree
3
+ Version: 0.0.1
4
+ Summary: Deterministic context trees for AI agents and applications.
5
+ Project-URL: Homepage, https://github.com/earldennison/egregore-v2
6
+ Project-URL: Repository, https://github.com/earldennison/egregore-v2
7
+ Author: Earl Dennison Tan
8
+ License-Expression: MIT
9
+ Keywords: agent,context,pact,pactree,tree
10
+ Classifier: Development Status :: 2 - Pre-Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: MIT License
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Programming Language :: Python :: 3.13
17
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
18
+ Requires-Python: >=3.11
19
+ Description-Content-Type: text/markdown
20
+
21
+ # Pactree
22
+
23
+ Pactree is a deterministic context-tree substrate for AI agents and
24
+ applications. It is designed to make context explicit: ordered, queryable,
25
+ branchable, compact on disk, and stable across Python and Rust runtimes.
26
+
27
+ The project centers on the `.pact` file format and a Rust engine for
28
+ context trees, operations, selectors, projections, traces, and rewind/fork
29
+ workflows. The Python package provides the ergonomic host API that applications
30
+ use to build, inspect, and persist those trees.
31
+
32
+ Core goals:
33
+
34
+ - deterministic tree layout for agent context
35
+ - compact content-addressed storage
36
+ - branch, rewind, and what-if workflows
37
+ - provider-facing projections without losing substrate structure
38
+ - a clean Python API backed by a canonical Rust implementation
39
+
40
+ This is an early `0.0.x` release while the standalone package is being split
41
+ out. The public namespace is available now; the Pactree engine binary and Python
42
+ bindings will land in the next extraction releases.
@@ -0,0 +1,22 @@
1
+ # Pactree
2
+
3
+ Pactree is a deterministic context-tree substrate for AI agents and
4
+ applications. It is designed to make context explicit: ordered, queryable,
5
+ branchable, compact on disk, and stable across Python and Rust runtimes.
6
+
7
+ The project centers on the `.pact` file format and a Rust engine for
8
+ context trees, operations, selectors, projections, traces, and rewind/fork
9
+ workflows. The Python package provides the ergonomic host API that applications
10
+ use to build, inspect, and persist those trees.
11
+
12
+ Core goals:
13
+
14
+ - deterministic tree layout for agent context
15
+ - compact content-addressed storage
16
+ - branch, rewind, and what-if workflows
17
+ - provider-facing projections without losing substrate structure
18
+ - a clean Python API backed by a canonical Rust implementation
19
+
20
+ This is an early `0.0.x` release while the standalone package is being split
21
+ out. The public namespace is available now; the Pactree engine binary and Python
22
+ bindings will land in the next extraction releases.
@@ -0,0 +1,30 @@
1
+ [build-system]
2
+ requires = ["hatchling>=1.26"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "pactree"
7
+ version = "0.0.1"
8
+ description = "Deterministic context trees for AI agents and applications."
9
+ readme = "README.md"
10
+ requires-python = ">=3.11"
11
+ license = "MIT"
12
+ authors = [{ name = "Earl Dennison Tan" }]
13
+ keywords = ["context", "tree", "agent", "pact", "pactree"]
14
+ classifiers = [
15
+ "Development Status :: 2 - Pre-Alpha",
16
+ "Intended Audience :: Developers",
17
+ "License :: OSI Approved :: MIT License",
18
+ "Programming Language :: Python :: 3",
19
+ "Programming Language :: Python :: 3.11",
20
+ "Programming Language :: Python :: 3.12",
21
+ "Programming Language :: Python :: 3.13",
22
+ "Topic :: Software Development :: Libraries :: Python Modules",
23
+ ]
24
+
25
+ [project.urls]
26
+ Homepage = "https://github.com/earldennison/egregore-v2"
27
+ Repository = "https://github.com/earldennison/egregore-v2"
28
+
29
+ [tool.hatch.build.targets.wheel]
30
+ packages = ["src/pactree"]
@@ -0,0 +1,18 @@
1
+ """Pactree Python shim.
2
+
3
+ The real Pactree runtime is being extracted from Egregore. This package is a
4
+ small, import-safe placeholder for the future standalone API.
5
+ """
6
+
7
+ from __future__ import annotations
8
+
9
+ from ._version import __version__
10
+ from .context import Context
11
+ from .engine import EngineUnavailableError, engine_available
12
+
13
+ __all__ = [
14
+ "Context",
15
+ "EngineUnavailableError",
16
+ "__version__",
17
+ "engine_available",
18
+ ]
@@ -0,0 +1,3 @@
1
+ """Package version."""
2
+
3
+ __version__ = "0.0.1"
@@ -0,0 +1,16 @@
1
+ """Context facade placeholder."""
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Any
6
+
7
+ from .engine import EngineUnavailableError
8
+
9
+
10
+ class Context:
11
+ """Placeholder for the Pactree context API."""
12
+
13
+ def __init__(self, *_: Any, **__: Any) -> None:
14
+ raise EngineUnavailableError(
15
+ "pactree 0.0.1 exposes the package namespace; the Pactree engine is not bundled yet"
16
+ )
@@ -0,0 +1,13 @@
1
+ """Pactree engine availability."""
2
+
3
+ from __future__ import annotations
4
+
5
+
6
+ class EngineUnavailableError(RuntimeError):
7
+ """Raised when an early package release needs the Pactree engine."""
8
+
9
+
10
+ def engine_available() -> bool:
11
+ """Return whether the Pactree engine is bundled with this Python package."""
12
+
13
+ return False
@@ -0,0 +1,25 @@
1
+ """File API placeholder for `.pact` storage."""
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Any
6
+
7
+ from .engine import EngineUnavailableError
8
+
9
+
10
+ def _not_wired() -> EngineUnavailableError:
11
+ return EngineUnavailableError(
12
+ "pactree 0.0.1 exposes the package namespace; the Pactree engine is not bundled yet"
13
+ )
14
+
15
+
16
+ def info(*_: Any, **__: Any) -> dict[str, Any]:
17
+ raise _not_wired()
18
+
19
+
20
+ def materialize(*_: Any, **__: Any) -> dict[str, Any]:
21
+ raise _not_wired()
22
+
23
+
24
+ def validate(*_: Any, **__: Any) -> dict[str, Any]:
25
+ raise _not_wired()
@@ -0,0 +1 @@
1
+
@@ -0,0 +1,20 @@
1
+ from __future__ import annotations
2
+
3
+ import pytest
4
+
5
+ import pactree
6
+ from pactree import file
7
+ from pactree.engine import EngineUnavailableError
8
+
9
+
10
+ def test_shim_import_surface() -> None:
11
+ assert pactree.__version__ == "0.0.1"
12
+ assert pactree.engine_available() is False
13
+
14
+
15
+ def test_runtime_calls_are_explicitly_unavailable() -> None:
16
+ with pytest.raises(EngineUnavailableError):
17
+ pactree.Context()
18
+
19
+ with pytest.raises(EngineUnavailableError):
20
+ file.info("session.pact")
pactree-0.0.1/uv.lock ADDED
@@ -0,0 +1,8 @@
1
+ version = 1
2
+ revision = 3
3
+ requires-python = ">=3.11"
4
+
5
+ [[package]]
6
+ name = "pactree"
7
+ version = "0.0.1"
8
+ source = { editable = "." }