syntri-contracts 0.3.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.
Files changed (50) hide show
  1. syntri_contracts-0.3.1/LICENSE +8 -0
  2. syntri_contracts-0.3.1/PKG-INFO +197 -0
  3. syntri_contracts-0.3.1/README.md +169 -0
  4. syntri_contracts-0.3.1/pyproject.toml +84 -0
  5. syntri_contracts-0.3.1/setup.cfg +4 -0
  6. syntri_contracts-0.3.1/syntri_contracts/__init__.py +10 -0
  7. syntri_contracts-0.3.1/syntri_contracts/capabilities/__init__.py +32 -0
  8. syntri_contracts-0.3.1/syntri_contracts/capabilities/py.typed +0 -0
  9. syntri_contracts-0.3.1/syntri_contracts/capabilities/registry.py +339 -0
  10. syntri_contracts-0.3.1/syntri_contracts/capabilities/replay.py +349 -0
  11. syntri_contracts-0.3.1/syntri_contracts/cli/__init__.py +6 -0
  12. syntri_contracts-0.3.1/syntri_contracts/cli/commands/__init__.py +10 -0
  13. syntri_contracts-0.3.1/syntri_contracts/cli/commands/pack.py +290 -0
  14. syntri_contracts-0.3.1/syntri_contracts/cli/fmt.py +28 -0
  15. syntri_contracts-0.3.1/syntri_contracts/cli/main.py +28 -0
  16. syntri_contracts-0.3.1/syntri_contracts/cli/py.typed +0 -0
  17. syntri_contracts-0.3.1/syntri_contracts/contracts/__init__.py +27 -0
  18. syntri_contracts-0.3.1/syntri_contracts/contracts/capability.py +238 -0
  19. syntri_contracts-0.3.1/syntri_contracts/contracts/connector.py +0 -0
  20. syntri_contracts-0.3.1/syntri_contracts/contracts/example_pack/README.md +37 -0
  21. syntri_contracts-0.3.1/syntri_contracts/contracts/example_pack/__init__.py +8 -0
  22. syntri_contracts-0.3.1/syntri_contracts/contracts/example_pack/fixtures/01-check-balance-basic.json +11 -0
  23. syntri_contracts-0.3.1/syntri_contracts/contracts/example_pack/manifest.yaml +12 -0
  24. syntri_contracts-0.3.1/syntri_contracts/contracts/example_pack/pack.py +122 -0
  25. syntri_contracts-0.3.1/syntri_contracts/contracts/py.typed +0 -0
  26. syntri_contracts-0.3.1/syntri_contracts/experience/__init__.py +41 -0
  27. syntri_contracts-0.3.1/syntri_contracts/experience/py.typed +0 -0
  28. syntri_contracts-0.3.1/syntri_contracts/experience/schema.py +300 -0
  29. syntri_contracts-0.3.1/syntri_contracts/nlu/__init__.py +15 -0
  30. syntri_contracts-0.3.1/syntri_contracts/nlu/pipeline.py +454 -0
  31. syntri_contracts-0.3.1/syntri_contracts/nlu/py.typed +0 -0
  32. syntri_contracts-0.3.1/syntri_contracts/policy/__init__.py +31 -0
  33. syntri_contracts-0.3.1/syntri_contracts/policy/audit.py +144 -0
  34. syntri_contracts-0.3.1/syntri_contracts/policy/engine.py +216 -0
  35. syntri_contracts-0.3.1/syntri_contracts/policy/floors.py +86 -0
  36. syntri_contracts-0.3.1/syntri_contracts/policy/py.typed +0 -0
  37. syntri_contracts-0.3.1/syntri_contracts/store/__init__.py +31 -0
  38. syntri_contracts-0.3.1/syntri_contracts/store/base.py +247 -0
  39. syntri_contracts-0.3.1/syntri_contracts/store/jsonl.py +418 -0
  40. syntri_contracts-0.3.1/syntri_contracts/store/py.typed +0 -0
  41. syntri_contracts-0.3.1/syntri_contracts.egg-info/PKG-INFO +197 -0
  42. syntri_contracts-0.3.1/syntri_contracts.egg-info/SOURCES.txt +48 -0
  43. syntri_contracts-0.3.1/syntri_contracts.egg-info/dependency_links.txt +1 -0
  44. syntri_contracts-0.3.1/syntri_contracts.egg-info/entry_points.txt +2 -0
  45. syntri_contracts-0.3.1/syntri_contracts.egg-info/requires.txt +8 -0
  46. syntri_contracts-0.3.1/syntri_contracts.egg-info/top_level.txt +1 -0
  47. syntri_contracts-0.3.1/tests/test_contracts.py +168 -0
  48. syntri_contracts-0.3.1/tests/test_jsonl_store.py +495 -0
  49. syntri_contracts-0.3.1/tests/test_policy.py +409 -0
  50. syntri_contracts-0.3.1/tests/test_store_contract.py +447 -0
@@ -0,0 +1,8 @@
1
+ Copyright (c) 2026 Domani Labs. All rights reserved.
2
+
3
+ This software and associated documentation files (the "Software") are
4
+ proprietary and confidential. Unauthorized copying, distribution,
5
+ modification, or use of this Software, in whole or in part, without
6
+ prior written permission from Domani Labs is strictly prohibited.
7
+
8
+ For licensing enquiries: info@domanimedia.com
@@ -0,0 +1,197 @@
1
+ Metadata-Version: 2.4
2
+ Name: syntri-contracts
3
+ Version: 0.3.1
4
+ Summary: Public contracts and building blocks for Syntri capability packs
5
+ Author: Domani Labs
6
+ License: Proprietary
7
+ Project-URL: Homepage, https://github.com/DomaniLabs/Syntri
8
+ Project-URL: Documentation, https://github.com/DomaniLabs/Syntri/contracts
9
+ Keywords: agent,orchestration,capability,nlp
10
+ Classifier: Development Status :: 3 - Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: Programming Language :: Python :: 3.10
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Topic :: Software Development :: Libraries
17
+ Requires-Python: >=3.10
18
+ Description-Content-Type: text/markdown
19
+ License-File: LICENSE
20
+ Requires-Dist: pydantic>=2.9
21
+ Requires-Dist: click>=8.1
22
+ Provides-Extra: dev
23
+ Requires-Dist: pytest>=8; extra == "dev"
24
+ Requires-Dist: pyyaml>=6; extra == "dev"
25
+ Requires-Dist: ruff>=0.7; extra == "dev"
26
+ Requires-Dist: mypy>=1.13; extra == "dev"
27
+ Dynamic: license-file
28
+
29
+ <p align="center">
30
+ <strong>Agent infrastructure for production AI.</strong><br/>
31
+ Build, train, deploy and continuously improve domain-specific AI agents.
32
+ </p>
33
+
34
+ <p align="center">
35
+ <a href="https://syntri.ai">syntri.ai</a> &nbsp;·&nbsp;
36
+ <a href="mailto:hello@domani.studio">Request access</a> &nbsp;·&nbsp;
37
+ Built by <a href="https://domani.studio">Domani</a>
38
+ </p>
39
+
40
+ ---
41
+
42
+ ## What it is
43
+
44
+ Most AI integrations are wrappers around a language model. You call an API, get a completion, and hope it does the right thing. When it doesn't, you have no visibility into why — and no way to make it better without starting over.
45
+
46
+ Syntri is different. It is infrastructure for building AI agents that are **measurable, improvable, and production-safe** — agents that get better the longer they run, without requiring you to trust a black box.
47
+
48
+ ## Two modules, one platform
49
+
50
+ **Syntri Agent** — Build and operate domain-specific AI agents. Define what your agent understands, train models on your own data, connect your systems through capability packs, and enforce policies that keep sensitive operations safe. Language models are optional; custom-trained models are first-class.
51
+
52
+ **Syntri Observe** — AI-native observability. Not just logs — decision logs. See intent accuracy over time, entity extraction failure rates by field, outcome-weighted performance across capabilities, and where your agent is degrading before your users tell you.
53
+
54
+ ## How it works
55
+
56
+ Your data → Train your models → Deploy your agent → Collect experience → Improve
57
+
58
+
59
+ Every agent instance trains on its own data. Syntri provides the infrastructure — the training pipeline, the evaluation harness, the runtime, the observability layer. You bring the domain knowledge.
60
+
61
+ ```yaml
62
+ # An agent instance is configuration, not code
63
+ agent:
64
+ name: your-agent
65
+ locales: [en, sw, pcm]
66
+
67
+ capabilities:
68
+ - payments
69
+ - flights
70
+ - customer-support
71
+
72
+ learning:
73
+ level: 3 # classical ML — intent + entity models
74
+ retrain_every_days: 14
75
+ ```
76
+
77
+ ## What makes it different
78
+
79
+ **Decision-level observability.** Existing tools tell you an API call succeeded. Syntri tells you the agent routed to `send_money` at 0.61 confidence, the bank extractor has an 18% error rate on three-word institution names, and session abandonment on the flight booking capability jumped 12 points this week.
80
+
81
+ **Custom-trained models.** The failure modes that matter most — local bank aliases, pidgin shorthand, currency formats, SMS abbreviations — are coverage problems. They are fixed by training on your distribution, not by engineering prompts. Syntri makes that trainable.
82
+
83
+ **Learns from experience.** Every production turn is a training candidate. Corrections, completions, abandonments — all become supervision signal. The agent improves on a gated, offline cadence. Nothing updates live.
84
+
85
+ **LLM-optional.** Language models are one component in the stack, not the foundation. An agent running at learning level 3 uses a trained intent classifier (~10ms, no API cost) and falls back to an LLM only for low-confidence or unmapped cases. At level 4 and above, a fine-tuned transformer handles everything.
86
+
87
+ **Safe by design.** Money-moving operations are typed as `irreversible` in the taxonomy. The runtime refuses to execute them locally — they are requests to your backend, not commands. No configuration or capability pack can override this.
88
+
89
+ ## Status
90
+
91
+ Private beta. Infinitswap is our first production deployment — a WhatsApp-native financial platform operating across Nigeria, Ghana, Tanzania and South Africa.
92
+
93
+ [Request access →](mailto:hello@domani.studio)
94
+
95
+ ---
96
+
97
+ ## Connecting to Syntri
98
+
99
+ Syntri runs as a standalone service. Your application calls it over HTTP — no Python required on your side.
100
+
101
+ ```bash
102
+ # Understand a message
103
+ POST /v1/understand
104
+ { "text": "send 5k to my uba account", "session_id": "...", "user_id": "..." }
105
+
106
+ # Full agent turn
107
+ POST /v1/turn
108
+ { "text": "...", "session_id": "...", "channel": "whatsapp" }
109
+
110
+ # Return tool results
111
+ POST /v1/tool-results
112
+ { "session_id": "...", "results": [...] }
113
+
114
+ # Send outcome feedback (closes the learning loop)
115
+ POST /v1/feedback
116
+ { "session_id": "...", "outcome": "completed" }
117
+ ```
118
+
119
+ An SDK and CLI are in development. See [`/contracts`](/contracts) for the full API schema.
120
+
121
+ ## Building capability packs
122
+
123
+ A **capability pack** is a small Python package that teaches an agent how to
124
+ handle one job — checking a balance, booking a flight, opening a ticket. Packs
125
+ declare tools and decision logic; the customer's backend does the execution.
126
+ Money-moving operations can never run in the agent — the contract enforces it.
127
+
128
+ ```bash
129
+ pip install syntri-contracts
130
+ ```
131
+
132
+ ```python
133
+ from syntri_contracts.contracts.capability import (
134
+ CapabilityManifest, CapabilityPack, Decision, WorkflowStatus,
135
+ )
136
+
137
+ class CheckBalancePack(CapabilityPack):
138
+ manifest = CapabilityManifest(
139
+ name="my-check-balance", display_name="Check Balance",
140
+ version="0.1.0", description="Reports the user's balance.",
141
+ author="you@example.com", intents=["check_balance"],
142
+ required_entities=[], entry_point="my_pack.pack:CheckBalancePack",
143
+ )
144
+
145
+ def tools(self):
146
+ ... # declare a ToolSpec, e.g. "balance.fetch" (executor=BACKEND)
147
+
148
+ def advance(self, session_id, slots, understanding, tool_results, turn_count):
149
+ if not tool_results:
150
+ return Decision(action="request_tool", tool="balance.fetch",
151
+ arguments={}, status=WorkflowStatus.EXECUTING)
152
+ data = tool_results[-1].data or {}
153
+ return Decision(action="reply",
154
+ message=f"Your balance is {data.get('balance')}.",
155
+ status=WorkflowStatus.COMPLETED)
156
+ ```
157
+
158
+ Full guide: [`contracts/README.md`](/contracts/README.md). Working template:
159
+ [`contracts/example_pack/`](/contracts/example_pack). Validate a pack with
160
+ `syntri pack validate ./my-pack/`.
161
+
162
+ ## Deployment
163
+
164
+ Self-hosted first. Syntri runs inside your infrastructure — your data never leaves your environment.
165
+
166
+ Your infrastructure
167
+ ├── Your application (Node, Python, anything)
168
+ ├── Syntri Agent ← runs here, calls back to your app for tool execution
169
+ └── Your database
170
+
171
+
172
+ Docker image and Helm chart coming with the beta release.
173
+
174
+ ---
175
+
176
+ ## Roadmap
177
+
178
+ - [x] Experience schema — Observation, Interpretation, Judgment, Episode
179
+ - [x] Config-driven taxonomy with risk tiers and slot rules
180
+ - [x] PII tokenisation at ingestion
181
+ - [x] Plugin discovery — connectors, capabilities, noise packs
182
+ - [x] Model registry with lineage and promotion gates
183
+ - [ ] Corpus builder and synthetic augmentation
184
+ - [ ] Intent classifier + entity extractor training pipeline
185
+ - [ ] Infinitswap connector (first production adapter)
186
+ - [ ] Shadow mode deployment on Infinitswap traffic
187
+ - [ ] Flight booking capability pack
188
+ - [x] Public capability-pack contract (`syntri-contracts`) — *Phase 5, in progress*
189
+ - [ ] `syntri pack validate` and marketplace submission
190
+ - [ ] CLI: `syntri init`, `syntri train`, `syntri evaluate`, `syntri serve`
191
+ - [ ] Syntri Observe dashboard
192
+
193
+ ---
194
+
195
+ <p align="center">
196
+ <sub>Built by <a href="https://domani.studio">Domani</a> · © 2026 Domani Labs · All rights reserved</sub>
197
+ </p>
@@ -0,0 +1,169 @@
1
+ <p align="center">
2
+ <strong>Agent infrastructure for production AI.</strong><br/>
3
+ Build, train, deploy and continuously improve domain-specific AI agents.
4
+ </p>
5
+
6
+ <p align="center">
7
+ <a href="https://syntri.ai">syntri.ai</a> &nbsp;·&nbsp;
8
+ <a href="mailto:hello@domani.studio">Request access</a> &nbsp;·&nbsp;
9
+ Built by <a href="https://domani.studio">Domani</a>
10
+ </p>
11
+
12
+ ---
13
+
14
+ ## What it is
15
+
16
+ Most AI integrations are wrappers around a language model. You call an API, get a completion, and hope it does the right thing. When it doesn't, you have no visibility into why — and no way to make it better without starting over.
17
+
18
+ Syntri is different. It is infrastructure for building AI agents that are **measurable, improvable, and production-safe** — agents that get better the longer they run, without requiring you to trust a black box.
19
+
20
+ ## Two modules, one platform
21
+
22
+ **Syntri Agent** — Build and operate domain-specific AI agents. Define what your agent understands, train models on your own data, connect your systems through capability packs, and enforce policies that keep sensitive operations safe. Language models are optional; custom-trained models are first-class.
23
+
24
+ **Syntri Observe** — AI-native observability. Not just logs — decision logs. See intent accuracy over time, entity extraction failure rates by field, outcome-weighted performance across capabilities, and where your agent is degrading before your users tell you.
25
+
26
+ ## How it works
27
+
28
+ Your data → Train your models → Deploy your agent → Collect experience → Improve
29
+
30
+
31
+ Every agent instance trains on its own data. Syntri provides the infrastructure — the training pipeline, the evaluation harness, the runtime, the observability layer. You bring the domain knowledge.
32
+
33
+ ```yaml
34
+ # An agent instance is configuration, not code
35
+ agent:
36
+ name: your-agent
37
+ locales: [en, sw, pcm]
38
+
39
+ capabilities:
40
+ - payments
41
+ - flights
42
+ - customer-support
43
+
44
+ learning:
45
+ level: 3 # classical ML — intent + entity models
46
+ retrain_every_days: 14
47
+ ```
48
+
49
+ ## What makes it different
50
+
51
+ **Decision-level observability.** Existing tools tell you an API call succeeded. Syntri tells you the agent routed to `send_money` at 0.61 confidence, the bank extractor has an 18% error rate on three-word institution names, and session abandonment on the flight booking capability jumped 12 points this week.
52
+
53
+ **Custom-trained models.** The failure modes that matter most — local bank aliases, pidgin shorthand, currency formats, SMS abbreviations — are coverage problems. They are fixed by training on your distribution, not by engineering prompts. Syntri makes that trainable.
54
+
55
+ **Learns from experience.** Every production turn is a training candidate. Corrections, completions, abandonments — all become supervision signal. The agent improves on a gated, offline cadence. Nothing updates live.
56
+
57
+ **LLM-optional.** Language models are one component in the stack, not the foundation. An agent running at learning level 3 uses a trained intent classifier (~10ms, no API cost) and falls back to an LLM only for low-confidence or unmapped cases. At level 4 and above, a fine-tuned transformer handles everything.
58
+
59
+ **Safe by design.** Money-moving operations are typed as `irreversible` in the taxonomy. The runtime refuses to execute them locally — they are requests to your backend, not commands. No configuration or capability pack can override this.
60
+
61
+ ## Status
62
+
63
+ Private beta. Infinitswap is our first production deployment — a WhatsApp-native financial platform operating across Nigeria, Ghana, Tanzania and South Africa.
64
+
65
+ [Request access →](mailto:hello@domani.studio)
66
+
67
+ ---
68
+
69
+ ## Connecting to Syntri
70
+
71
+ Syntri runs as a standalone service. Your application calls it over HTTP — no Python required on your side.
72
+
73
+ ```bash
74
+ # Understand a message
75
+ POST /v1/understand
76
+ { "text": "send 5k to my uba account", "session_id": "...", "user_id": "..." }
77
+
78
+ # Full agent turn
79
+ POST /v1/turn
80
+ { "text": "...", "session_id": "...", "channel": "whatsapp" }
81
+
82
+ # Return tool results
83
+ POST /v1/tool-results
84
+ { "session_id": "...", "results": [...] }
85
+
86
+ # Send outcome feedback (closes the learning loop)
87
+ POST /v1/feedback
88
+ { "session_id": "...", "outcome": "completed" }
89
+ ```
90
+
91
+ An SDK and CLI are in development. See [`/contracts`](/contracts) for the full API schema.
92
+
93
+ ## Building capability packs
94
+
95
+ A **capability pack** is a small Python package that teaches an agent how to
96
+ handle one job — checking a balance, booking a flight, opening a ticket. Packs
97
+ declare tools and decision logic; the customer's backend does the execution.
98
+ Money-moving operations can never run in the agent — the contract enforces it.
99
+
100
+ ```bash
101
+ pip install syntri-contracts
102
+ ```
103
+
104
+ ```python
105
+ from syntri_contracts.contracts.capability import (
106
+ CapabilityManifest, CapabilityPack, Decision, WorkflowStatus,
107
+ )
108
+
109
+ class CheckBalancePack(CapabilityPack):
110
+ manifest = CapabilityManifest(
111
+ name="my-check-balance", display_name="Check Balance",
112
+ version="0.1.0", description="Reports the user's balance.",
113
+ author="you@example.com", intents=["check_balance"],
114
+ required_entities=[], entry_point="my_pack.pack:CheckBalancePack",
115
+ )
116
+
117
+ def tools(self):
118
+ ... # declare a ToolSpec, e.g. "balance.fetch" (executor=BACKEND)
119
+
120
+ def advance(self, session_id, slots, understanding, tool_results, turn_count):
121
+ if not tool_results:
122
+ return Decision(action="request_tool", tool="balance.fetch",
123
+ arguments={}, status=WorkflowStatus.EXECUTING)
124
+ data = tool_results[-1].data or {}
125
+ return Decision(action="reply",
126
+ message=f"Your balance is {data.get('balance')}.",
127
+ status=WorkflowStatus.COMPLETED)
128
+ ```
129
+
130
+ Full guide: [`contracts/README.md`](/contracts/README.md). Working template:
131
+ [`contracts/example_pack/`](/contracts/example_pack). Validate a pack with
132
+ `syntri pack validate ./my-pack/`.
133
+
134
+ ## Deployment
135
+
136
+ Self-hosted first. Syntri runs inside your infrastructure — your data never leaves your environment.
137
+
138
+ Your infrastructure
139
+ ├── Your application (Node, Python, anything)
140
+ ├── Syntri Agent ← runs here, calls back to your app for tool execution
141
+ └── Your database
142
+
143
+
144
+ Docker image and Helm chart coming with the beta release.
145
+
146
+ ---
147
+
148
+ ## Roadmap
149
+
150
+ - [x] Experience schema — Observation, Interpretation, Judgment, Episode
151
+ - [x] Config-driven taxonomy with risk tiers and slot rules
152
+ - [x] PII tokenisation at ingestion
153
+ - [x] Plugin discovery — connectors, capabilities, noise packs
154
+ - [x] Model registry with lineage and promotion gates
155
+ - [ ] Corpus builder and synthetic augmentation
156
+ - [ ] Intent classifier + entity extractor training pipeline
157
+ - [ ] Infinitswap connector (first production adapter)
158
+ - [ ] Shadow mode deployment on Infinitswap traffic
159
+ - [ ] Flight booking capability pack
160
+ - [x] Public capability-pack contract (`syntri-contracts`) — *Phase 5, in progress*
161
+ - [ ] `syntri pack validate` and marketplace submission
162
+ - [ ] CLI: `syntri init`, `syntri train`, `syntri evaluate`, `syntri serve`
163
+ - [ ] Syntri Observe dashboard
164
+
165
+ ---
166
+
167
+ <p align="center">
168
+ <sub>Built by <a href="https://domani.studio">Domani</a> · © 2026 Domani Labs · All rights reserved</sub>
169
+ </p>
@@ -0,0 +1,84 @@
1
+ [build-system]
2
+ requires = ["setuptools>=61", "wheel"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "syntri-contracts"
7
+ version = "0.3.1"
8
+ description = "Public contracts and building blocks for Syntri capability packs"
9
+ readme = "README.md"
10
+ requires-python = ">=3.10"
11
+ license = { text = "Proprietary" }
12
+ authors = [{ name = "Domani Labs" }]
13
+ keywords = ["agent", "orchestration", "capability", "nlp"]
14
+ classifiers = [
15
+ "Development Status :: 3 - Alpha",
16
+ "Intended Audience :: Developers",
17
+ "Programming Language :: Python :: 3",
18
+ "Programming Language :: Python :: 3.10",
19
+ "Programming Language :: Python :: 3.11",
20
+ "Programming Language :: Python :: 3.12",
21
+ "Topic :: Software Development :: Libraries",
22
+ ]
23
+ # Read from the imports of the extracted modules, not guessed:
24
+ # pydantic — contracts, experience.schema, and everything typed on them
25
+ # click — the CLI (cli.fmt, cli.commands.pack, cli.main)
26
+ dependencies = [
27
+ "pydantic>=2.9",
28
+ "click>=8.1",
29
+ ]
30
+
31
+ [project.optional-dependencies]
32
+ dev = ["pytest>=8", "pyyaml>=6", "ruff>=0.7", "mypy>=1.13"]
33
+
34
+ [project.urls]
35
+ Homepage = "https://github.com/DomaniLabs/Syntri"
36
+ Documentation = "https://github.com/DomaniLabs/Syntri/contracts"
37
+
38
+ # NOT named `syntri`: that console script belongs to syntri-core, and a second
39
+ # package claiming it would shadow the real CLI depending on install order.
40
+ [project.scripts]
41
+ syntri-pack = "syntri_contracts.cli.main:main"
42
+
43
+ [tool.setuptools]
44
+ packages = [
45
+ "syntri_contracts",
46
+ "syntri_contracts.contracts",
47
+ "syntri_contracts.contracts.example_pack",
48
+ "syntri_contracts.experience",
49
+ "syntri_contracts.store",
50
+ "syntri_contracts.policy",
51
+ "syntri_contracts.nlu",
52
+ "syntri_contracts.capabilities",
53
+ "syntri_contracts.cli",
54
+ "syntri_contracts.cli.commands",
55
+ ]
56
+
57
+ [tool.setuptools.package-data]
58
+ # PEP 561. The packages are annotated; without this marker every consumer's
59
+ # type checker silently treats the whole contract as Any, which is the
60
+ # opposite of what a published contract is for.
61
+ "syntri_contracts.contracts" = ["py.typed", "example_pack/manifest.yaml", "example_pack/fixtures/*.json", "example_pack/README.md"]
62
+ "syntri_contracts.experience" = ["py.typed"]
63
+ "syntri_contracts.store" = ["py.typed"]
64
+ "syntri_contracts.policy" = ["py.typed"]
65
+ "syntri_contracts.nlu" = ["py.typed"]
66
+ "syntri_contracts.capabilities" = ["py.typed"]
67
+ "syntri_contracts.cli" = ["py.typed"]
68
+
69
+ [tool.pytest.ini_options]
70
+ testpaths = ["tests"]
71
+
72
+ [tool.ruff]
73
+ line-length = 100
74
+ target-version = "py310"
75
+
76
+ # Same rule set syntri-core selects, so the extracted modules lint identically
77
+ # on both sides. E501 (long lines) is confined to prose docstrings.
78
+ [tool.ruff.lint]
79
+ select = ["E", "F", "I", "UP"]
80
+ ignore = ["E501", "UP017", "UP042"]
81
+
82
+ [tool.mypy]
83
+ python_version = "3.10"
84
+ ignore_missing_imports = true
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,10 @@
1
+ """Public contracts and building blocks for Syntri capability packs.
2
+
3
+ Everything third-party developers need to build, validate and run a capability
4
+ pack, with no dependency on private syntri-core: the pack contract, the
5
+ experience schema, the Store interface and its JsonlStore backend, the policy
6
+ engine, the base NLU pipeline, the pack registry/replay machinery, and the
7
+ `syntri-pack` CLI.
8
+ """
9
+
10
+ __version__ = "0.3.1"
@@ -0,0 +1,32 @@
1
+ """Capability pack machinery: registration and fixture replay.
2
+
3
+ Both modules are built on the public `contracts` package and nothing else.
4
+ `CapabilityRegistry` runs the startup checks the platform would (duplicate
5
+ intents, money-on-agent, empty manifests); `replay_pack` drives a pack's
6
+ fixtures through `advance()` with no server, network or model. Together they
7
+ are what `syntri pack validate` runs.
8
+ """
9
+
10
+ from syntri_contracts.capabilities.registry import (
11
+ ENTRY_POINT_GROUP,
12
+ CapabilityRegistry,
13
+ default_registry,
14
+ )
15
+ from syntri_contracts.capabilities.replay import (
16
+ FixtureOutcome,
17
+ ReplayReport,
18
+ TurnOutcome,
19
+ replay_fixture,
20
+ replay_pack,
21
+ )
22
+
23
+ __all__ = [
24
+ "ENTRY_POINT_GROUP",
25
+ "CapabilityRegistry",
26
+ "FixtureOutcome",
27
+ "ReplayReport",
28
+ "TurnOutcome",
29
+ "default_registry",
30
+ "replay_fixture",
31
+ "replay_pack",
32
+ ]