telryn 0.9.2__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 (159) hide show
  1. telryn-0.9.2/.gitignore +17 -0
  2. telryn-0.9.2/LICENSE +202 -0
  3. telryn-0.9.2/PKG-INFO +63 -0
  4. telryn-0.9.2/README.md +40 -0
  5. telryn-0.9.2/examples/__init__.py +0 -0
  6. telryn-0.9.2/examples/agent_release/__init__.py +1 -0
  7. telryn-0.9.2/examples/agent_release/__main__.py +50 -0
  8. telryn-0.9.2/examples/agent_release/bridge.py +121 -0
  9. telryn-0.9.2/examples/agent_release/suite.json +14 -0
  10. telryn-0.9.2/examples/complaints_pilot/README.md +32 -0
  11. telryn-0.9.2/examples/complaints_pilot/__init__.py +1 -0
  12. telryn-0.9.2/examples/complaints_pilot/__main__.py +547 -0
  13. telryn-0.9.2/examples/complaints_pilot/answers.csv +18 -0
  14. telryn-0.9.2/examples/complaints_pilot/channels.csv +7 -0
  15. telryn-0.9.2/examples/complaints_pilot/clock-policy.json +27 -0
  16. telryn-0.9.2/examples/complaints_pilot/conversations.csv +20 -0
  17. telryn-0.9.2/examples/complaints_pilot/intercom-archive.json +222 -0
  18. telryn-0.9.2/examples/complaints_pilot/intercom-ledger.json +44 -0
  19. telryn-0.9.2/examples/complaints_pilot/intercom.py +275 -0
  20. telryn-0.9.2/examples/complaints_pilot/native.sql +32 -0
  21. telryn-0.9.2/examples/complaints_pilot/onboarding.csv +7 -0
  22. telryn-0.9.2/examples/complaints_pilot/owner-episodes.csv +10 -0
  23. telryn-0.9.2/examples/complaints_pilot/owner-events.csv +13 -0
  24. telryn-0.9.2/examples/complaints_pilot/prior-contacts.json +53 -0
  25. telryn-0.9.2/examples/complaints_pilot/protocol.toml +12 -0
  26. telryn-0.9.2/examples/complaints_pilot/register.csv +5 -0
  27. telryn-0.9.2/examples/complaints_pilot/signals.py +50 -0
  28. telryn-0.9.2/examples/complaints_pilot/staff-minutes.csv +5 -0
  29. telryn-0.9.2/examples/fintech/README.md +55 -0
  30. telryn-0.9.2/examples/fintech/__init__.py +1 -0
  31. telryn-0.9.2/examples/fintech/__main__.py +98 -0
  32. telryn-0.9.2/examples/fintech/development-cases.csv +50 -0
  33. telryn-0.9.2/examples/fintech/development-grades.csv +49 -0
  34. telryn-0.9.2/examples/fintech/development-ordinary.csv +2 -0
  35. telryn-0.9.2/examples/fintech/development.toml +9 -0
  36. telryn-0.9.2/examples/fintech/held-out-primary-grades.json +22 -0
  37. telryn-0.9.2/examples/fintech/held-out-serious-grades.json +22 -0
  38. telryn-0.9.2/examples/fintech/held-out.json +102 -0
  39. telryn-0.9.2/examples/fintech/held-out.toml +36 -0
  40. telryn-0.9.2/examples/fintech/live.sql +3 -0
  41. telryn-0.9.2/examples/fintech/ordinary-reviews.csv +3 -0
  42. telryn-0.9.2/examples/fintech/population.csv +11 -0
  43. telryn-0.9.2/examples/fintech/shadow-template.json +28 -0
  44. telryn-0.9.2/examples/fintech/signals.csv +11 -0
  45. telryn-0.9.2/examples/fintech/staged-grades.csv +9 -0
  46. telryn-0.9.2/examples/fintech/transcripts.jsonl +2 -0
  47. telryn-0.9.2/examples/fintech/week.toml +9 -0
  48. telryn-0.9.2/examples/policy_packs/control.json +11 -0
  49. telryn-0.9.2/examples/policy_packs/population.csv +3 -0
  50. telryn-0.9.2/examples/policy_packs/reviewed.csv +1 -0
  51. telryn-0.9.2/examples/policy_packs/week.toml +9 -0
  52. telryn-0.9.2/examples/public_demo/NOTICE.md +13 -0
  53. telryn-0.9.2/examples/public_demo/__init__.py +1 -0
  54. telryn-0.9.2/examples/public_demo/__main__.py +93 -0
  55. telryn-0.9.2/examples/public_demo/annotations.csv +201 -0
  56. telryn-0.9.2/examples/public_demo/rebuild.py +35 -0
  57. telryn-0.9.2/examples/refunds/__init__.py +0 -0
  58. telryn-0.9.2/examples/refunds/app.py +356 -0
  59. telryn-0.9.2/examples/refunds/baseline.py +344 -0
  60. telryn-0.9.2/examples/refunds/comparison.toml +28 -0
  61. telryn-0.9.2/examples/refunds/cutoff.json +4843 -0
  62. telryn-0.9.2/examples/refunds/hold.toml +28 -0
  63. telryn-0.9.2/examples/refunds/known-grades.json +2040 -0
  64. telryn-0.9.2/examples/refunds/review-ledger.json +84 -0
  65. telryn-0.9.2/examples/refunds/rules.py +26 -0
  66. telryn-0.9.2/examples/refunds/shadow.toml +32 -0
  67. telryn-0.9.2/examples/refunds/weekend.toml +32 -0
  68. telryn-0.9.2/examples/support-qa/batches.toml +13 -0
  69. telryn-0.9.2/examples/support-qa/candidate.sql +4 -0
  70. telryn-0.9.2/examples/support-qa/comparison.toml +35 -0
  71. telryn-0.9.2/examples/support-qa/cutoff-inputs.csv +13 -0
  72. telryn-0.9.2/examples/support-qa/defect-grades.json +102 -0
  73. telryn-0.9.2/examples/support-qa/eligible.csv +13 -0
  74. telryn-0.9.2/examples/support-qa/intake.toml +26 -0
  75. telryn-0.9.2/examples/support-qa/legacy.toml +29 -0
  76. telryn-0.9.2/examples/support-qa/live.sql +4 -0
  77. telryn-0.9.2/examples/support-qa/mapping.toml +14 -0
  78. telryn-0.9.2/examples/support-qa/picks.csv +9 -0
  79. telryn-0.9.2/examples/support-qa/pilot-record.json +35 -0
  80. telryn-0.9.2/examples/support-qa/revised.sql +4 -0
  81. telryn-0.9.2/examples/support-qa/revised.toml +35 -0
  82. telryn-0.9.2/examples/support-qa/rules.py +11 -0
  83. telryn-0.9.2/examples/support-qa/serious-grades.json +30 -0
  84. telryn-0.9.2/examples/support-qa/shadow-observations.json +57 -0
  85. telryn-0.9.2/examples/support-qa/synthetic-evidence.json +6 -0
  86. telryn-0.9.2/pyproject.toml +48 -0
  87. telryn-0.9.2/telryn/__init__.py +3 -0
  88. telryn-0.9.2/telryn/__main__.py +21 -0
  89. telryn-0.9.2/telryn/artifacts.py +36 -0
  90. telryn-0.9.2/telryn/audit_trust.py +311 -0
  91. telryn-0.9.2/telryn/benchmark.py +139 -0
  92. telryn-0.9.2/telryn/cli.py +501 -0
  93. telryn-0.9.2/telryn/complaints.py +607 -0
  94. telryn-0.9.2/telryn/contracts.py +259 -0
  95. telryn-0.9.2/telryn/control.py +429 -0
  96. telryn-0.9.2/telryn/decision.py +169 -0
  97. telryn-0.9.2/telryn/desk.html +70 -0
  98. telryn-0.9.2/telryn/desk.js +288 -0
  99. telryn-0.9.2/telryn/desk.py +428 -0
  100. telryn-0.9.2/telryn/episodes.py +320 -0
  101. telryn-0.9.2/telryn/grades.py +436 -0
  102. telryn-0.9.2/telryn/intake.py +314 -0
  103. telryn-0.9.2/telryn/integrations.py +497 -0
  104. telryn-0.9.2/telryn/integrations_coverage.py +302 -0
  105. telryn-0.9.2/telryn/integrations_http.py +145 -0
  106. telryn-0.9.2/telryn/integrations_sierra.py +172 -0
  107. telryn-0.9.2/telryn/integrations_sources.py +501 -0
  108. telryn-0.9.2/telryn/integrations_transcripts.py +389 -0
  109. telryn-0.9.2/telryn/lineage.py +110 -0
  110. telryn-0.9.2/telryn/model_endpoints.py +219 -0
  111. telryn-0.9.2/telryn/packs.py +157 -0
  112. telryn-0.9.2/telryn/planning.py +438 -0
  113. telryn-0.9.2/telryn/policy.py +362 -0
  114. telryn-0.9.2/telryn/policy_packs/cfpb-company-portal@1.0.0.json +44 -0
  115. telryn-0.9.2/telryn/policy_packs/fca-disp@1.0.0.json +65 -0
  116. telryn-0.9.2/telryn/policy_packs/firm-example@1.0.0.json +38 -0
  117. telryn-0.9.2/telryn/policy_packs/us-reg-e@1.0.0.json +73 -0
  118. telryn-0.9.2/telryn/proposal.py +290 -0
  119. telryn-0.9.2/telryn/replay.py +329 -0
  120. telryn-0.9.2/telryn/report.py +488 -0
  121. telryn-0.9.2/telryn/screen.py +276 -0
  122. telryn-0.9.2/telryn/seed.py +263 -0
  123. telryn-0.9.2/telryn/session.py +249 -0
  124. telryn-0.9.2/telryn/shadow.py +185 -0
  125. telryn-0.9.2/telryn/transcripts.py +482 -0
  126. telryn-0.9.2/telryn/weekly.py +817 -0
  127. telryn-0.9.2/telryn/weekly_mail.py +52 -0
  128. telryn-0.9.2/telryn/weekly_report.py +860 -0
  129. telryn-0.9.2/telryn/weekly_review.py +336 -0
  130. telryn-0.9.2/tests/__init__.py +0 -0
  131. telryn-0.9.2/tests/audit_support.py +10 -0
  132. telryn-0.9.2/tests/browser_desk.py +332 -0
  133. telryn-0.9.2/tests/fixtures/weekly-v1.html +30 -0
  134. telryn-0.9.2/tests/qualification.py +1398 -0
  135. telryn-0.9.2/tests/test_complaint_control.py +358 -0
  136. telryn-0.9.2/tests/test_complaints.py +317 -0
  137. telryn-0.9.2/tests/test_complaints_pilot.py +194 -0
  138. telryn-0.9.2/tests/test_decision_metrics.py +163 -0
  139. telryn-0.9.2/tests/test_decision_review.py +285 -0
  140. telryn-0.9.2/tests/test_desk.py +432 -0
  141. telryn-0.9.2/tests/test_episode_policy.py +390 -0
  142. telryn-0.9.2/tests/test_integrations.py +591 -0
  143. telryn-0.9.2/tests/test_integrations_coverage.py +746 -0
  144. telryn-0.9.2/tests/test_integrations_sierra.py +160 -0
  145. telryn-0.9.2/tests/test_intercom_rehearsal.py +111 -0
  146. telryn-0.9.2/tests/test_model_endpoints.py +361 -0
  147. telryn-0.9.2/tests/test_policy_packs.py +339 -0
  148. telryn-0.9.2/tests/test_proposal_lineage.py +281 -0
  149. telryn-0.9.2/tests/test_report_review.py +106 -0
  150. telryn-0.9.2/tests/test_seed_release.py +127 -0
  151. telryn-0.9.2/tests/test_transcript_citations.py +99 -0
  152. telryn-0.9.2/tests/test_transcripts.py +260 -0
  153. telryn-0.9.2/tests/test_weekly_engine.py +364 -0
  154. telryn-0.9.2/tests/test_weekly_planning.py +341 -0
  155. telryn-0.9.2/tests/test_weekly_proposal.py +351 -0
  156. telryn-0.9.2/tests/test_weekly_report.py +443 -0
  157. telryn-0.9.2/tests/test_weekly_trust.py +390 -0
  158. telryn-0.9.2/tests/test_weekly_workflow.py +173 -0
  159. telryn-0.9.2/tests/test_workflow_review.py +301 -0
@@ -0,0 +1,17 @@
1
+ __pycache__/
2
+ *.py[cod]
3
+ .venv/
4
+ .DS_Store
5
+ .env
6
+ .env.*
7
+ runs/
8
+ *.sqlite
9
+ *.sqlite-*
10
+ *.db
11
+ *.db-*
12
+ audit.key
13
+ ledger.sqlite3*
14
+ .*.checkpoint/
15
+ dist/
16
+ build/
17
+ *.egg-info/
telryn-0.9.2/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
telryn-0.9.2/PKG-INFO ADDED
@@ -0,0 +1,63 @@
1
+ Metadata-Version: 2.5
2
+ Name: telryn
3
+ Version: 0.9.2
4
+ Summary: Audit how lenders and payments teams handle complaints across human and AI support.
5
+ Project-URL: Homepage, https://github.com/davidahma/telryn
6
+ Project-URL: Documentation, https://github.com/davidahma/telryn/blob/main/docs/weekly-qa.md
7
+ Project-URL: Issues, https://github.com/davidahma/telryn/issues
8
+ Project-URL: Releases, https://github.com/davidahma/telryn/releases
9
+ License-Expression: Apache-2.0
10
+ License-File: LICENSE
11
+ Classifier: Environment :: Console
12
+ Classifier: Operating System :: MacOS :: MacOS X
13
+ Classifier: Operating System :: POSIX :: Linux
14
+ Classifier: Programming Language :: Python :: 3 :: Only
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Programming Language :: Python :: 3.13
17
+ Classifier: Programming Language :: Python :: 3.14
18
+ Classifier: Programming Language :: Python :: 3.15
19
+ Requires-Python: >=3.12
20
+ Provides-Extra: bedrock
21
+ Requires-Dist: boto3==1.44.9; extra == 'bedrock'
22
+ Description-Content-Type: text/markdown
23
+
24
+ # Telryn
25
+
26
+ Telryn helps a complaints lead at a lender or payments company find closed support conversations that should have reached the complaints register. It brings human and AI support contacts, policy deadlines, register entries and owner actions into one local report. Reviewers get a separate, blinded grading packet.
27
+
28
+ In the synthetic rehearsal, Mira tells the Fin agent about a duplicate charge on 4 August. “Even with a refund I want to know how this happened.” Fin refunds her and closes the chat. Two weeks later she calls, and an agent records a query. In October the lead can trace both contacts to the same charge, read Mira’s original words and see what the case manager still owes her. Under the example firm’s policy, the eight-week final-response deadline was 29 September. Registration has its own clock. [Open the worked report](https://github.com/davidahma/telryn/releases/download/v0.9.2/synthetic-complaints-audit.html)
29
+
30
+ ## Install
31
+
32
+ For an analyst on Linux or macOS, use pipx with CPython 3.12–3.15 and SQLite. The base CLI has no third-party runtime dependencies. Run the two-week rehearsal from any directory. Choose a new output directory each time.
33
+
34
+ ```sh
35
+ pipx install telryn
36
+ telryn demo --complaints --out runs/complaints-pilot
37
+ ```
38
+
39
+ Open `runs/complaints-pilot/2026-10-05/report.html` and find case **C108**. The report lists which channels the team could see. An incomplete register or an ambiguous match leaves a case unresolved. [PyPI package](https://pypi.org/project/telryn/) · [Rehearsal inputs and results](https://github.com/davidahma/telryn/blob/v0.9.2/examples/complaints_pilot/README.md)
40
+
41
+ For a managed deployment, IT can import the signed Linux image for amd64 or arm64. Windows users can run it through Docker Desktop with Linux containers. The weekly job runs with networking disabled. The security review pack includes the data flow, outbound connections, storage responsibilities and an SPDX software inventory for each architecture. [Container instructions](https://github.com/davidahma/telryn/blob/v0.9.2/docs/container.md) · [Download the security review pack](https://github.com/davidahma/telryn/releases/download/v0.9.2/telryn-security-review.tar.gz)
42
+
43
+ ## Run a week with your team
44
+
45
+ Start the private browser desk with `telryn desk --out runs/desk`. For a scheduled job, use `telryn weekly /path/to/week.toml --out /path/to/new-run`. Keep the team signing key and revision registry in persistent private storage. [Weekly operating guide and scheduler example](https://github.com/davidahma/telryn/blob/v0.9.2/docs/weekly-qa.md#schedule-a-weekly-run)
46
+
47
+ 1. **Set the scope.** Support operations supplies closed conversations. QA supplies completed human reviews. The contact centre and AI agent owner supply transcript references and handoff records. Complaints supplies the dated register and action history. Record missing channels and who owns each gap.
48
+ 2. **Issue the sample.** The policy owner approves the rubric, clock rules and calendar. Choose a versioned FCA DISP, US Regulation E or CFPB Company Portal starter, or use the firm’s own policy. Preview what the grading budget can detect. Telryn draws from both flagged and unflagged conversations that ordinary QA left unreviewed. [Policy packs](https://github.com/davidahma/telryn/blob/v0.9.2/docs/policy-packs.md)
49
+ 3. **Grade and follow up.** Reviewers decide whether a case qualifies before seeing the register finding. Record second reviews and settle disagreements. The lead can verify the signed report, follow a case to its source passages, and check the deadline, register coverage and owner action. [Evidence formats](https://github.com/davidahma/telryn/blob/v0.9.2/docs/complaint-records.md) · [Report verification](https://github.com/davidahma/telryn/blob/v0.9.2/docs/trust.md)
50
+
51
+ ## What the evidence supports
52
+
53
+ A clean sample can miss rare failures. If exactly 25 of 5,000 unreviewed conversations qualify and reviewers recognize every one, a uniform random sample of 50 has a 22.3% chance of finding at least one. Reaching 95% takes 564 first grades. [Sampling assumptions](https://github.com/davidahma/telryn/blob/v0.9.2/docs/statistics.md)
54
+
55
+ The rehearsal compares Telryn with a saved SQL search using the same records and staff budget. Across its 1,350 possible two-week draws, the saved search finds at least as many owner-accepted episodes in 96% of draws. The cases and staff times are synthetic. The field protocol measures whether either method brings action forward or saves staff time on a real queue. [Field protocol](https://github.com/davidahma/telryn/blob/v0.9.2/docs/evaluation.md#two-weeks-on-one-complaints-queue)
56
+
57
+ ## AI agents and integrations
58
+
59
+ - **Before an agent release**, send synthetic complaints through the test agent and check its test register independently. A missing, late or unverifiable entry keeps the release gate closed. [Agent test and adapter contract](https://github.com/davidahma/telryn/blob/v0.9.2/docs/agent-release.md)
60
+ - **For transcript screening**, use structured signals or select Ollama, Azure OpenAI or regional Amazon Bedrock. Each definite extracted fact needs a cited passage. Bedrock users can install the AWS SDK with `pipx install 'telryn[bedrock]'`. [Model setup and data handling](https://github.com/davidahma/telryn/blob/v0.9.2/docs/transcripts.md)
61
+ - **For intake and handoff**, use helpdesk connectors or approved exports. The integration guide lists the evidence each provider exposes, including when the team must supply a lifecycle ledger. [Supported integrations](https://github.com/davidahma/telryn/blob/v0.9.2/docs/integrations.md)
62
+
63
+ Run `telryn qualify` to exercise the bundled checks. [Architecture](https://github.com/davidahma/telryn/blob/v0.9.2/docs/architecture.md) · [Public support dataset](https://github.com/davidahma/telryn/blob/v0.9.2/examples/public_demo/NOTICE.md) · [Contributing](https://github.com/davidahma/telryn/blob/v0.9.2/CONTRIBUTING.md) · [Apache-2.0](https://github.com/davidahma/telryn/blob/v0.9.2/LICENSE)
telryn-0.9.2/README.md ADDED
@@ -0,0 +1,40 @@
1
+ # Telryn
2
+
3
+ Telryn helps a complaints lead at a lender or payments company find closed support conversations that should have reached the complaints register. It brings human and AI support contacts, policy deadlines, register entries and owner actions into one local report. Reviewers get a separate, blinded grading packet.
4
+
5
+ In the synthetic rehearsal, Mira tells the Fin agent about a duplicate charge on 4 August. “Even with a refund I want to know how this happened.” Fin refunds her and closes the chat. Two weeks later she calls, and an agent records a query. In October the lead can trace both contacts to the same charge, read Mira’s original words and see what the case manager still owes her. Under the example firm’s policy, the eight-week final-response deadline was 29 September. Registration has its own clock. [Open the worked report](https://github.com/davidahma/telryn/releases/download/v0.9.2/synthetic-complaints-audit.html)
6
+
7
+ ## Install
8
+
9
+ For an analyst on Linux or macOS, use pipx with CPython 3.12–3.15 and SQLite. The base CLI has no third-party runtime dependencies. Run the two-week rehearsal from any directory. Choose a new output directory each time.
10
+
11
+ ```sh
12
+ pipx install telryn
13
+ telryn demo --complaints --out runs/complaints-pilot
14
+ ```
15
+
16
+ Open `runs/complaints-pilot/2026-10-05/report.html` and find case **C108**. The report lists which channels the team could see. An incomplete register or an ambiguous match leaves a case unresolved. [PyPI package](https://pypi.org/project/telryn/) · [Rehearsal inputs and results](https://github.com/davidahma/telryn/blob/v0.9.2/examples/complaints_pilot/README.md)
17
+
18
+ For a managed deployment, IT can import the signed Linux image for amd64 or arm64. Windows users can run it through Docker Desktop with Linux containers. The weekly job runs with networking disabled. The security review pack includes the data flow, outbound connections, storage responsibilities and an SPDX software inventory for each architecture. [Container instructions](https://github.com/davidahma/telryn/blob/v0.9.2/docs/container.md) · [Download the security review pack](https://github.com/davidahma/telryn/releases/download/v0.9.2/telryn-security-review.tar.gz)
19
+
20
+ ## Run a week with your team
21
+
22
+ Start the private browser desk with `telryn desk --out runs/desk`. For a scheduled job, use `telryn weekly /path/to/week.toml --out /path/to/new-run`. Keep the team signing key and revision registry in persistent private storage. [Weekly operating guide and scheduler example](https://github.com/davidahma/telryn/blob/v0.9.2/docs/weekly-qa.md#schedule-a-weekly-run)
23
+
24
+ 1. **Set the scope.** Support operations supplies closed conversations. QA supplies completed human reviews. The contact centre and AI agent owner supply transcript references and handoff records. Complaints supplies the dated register and action history. Record missing channels and who owns each gap.
25
+ 2. **Issue the sample.** The policy owner approves the rubric, clock rules and calendar. Choose a versioned FCA DISP, US Regulation E or CFPB Company Portal starter, or use the firm’s own policy. Preview what the grading budget can detect. Telryn draws from both flagged and unflagged conversations that ordinary QA left unreviewed. [Policy packs](https://github.com/davidahma/telryn/blob/v0.9.2/docs/policy-packs.md)
26
+ 3. **Grade and follow up.** Reviewers decide whether a case qualifies before seeing the register finding. Record second reviews and settle disagreements. The lead can verify the signed report, follow a case to its source passages, and check the deadline, register coverage and owner action. [Evidence formats](https://github.com/davidahma/telryn/blob/v0.9.2/docs/complaint-records.md) · [Report verification](https://github.com/davidahma/telryn/blob/v0.9.2/docs/trust.md)
27
+
28
+ ## What the evidence supports
29
+
30
+ A clean sample can miss rare failures. If exactly 25 of 5,000 unreviewed conversations qualify and reviewers recognize every one, a uniform random sample of 50 has a 22.3% chance of finding at least one. Reaching 95% takes 564 first grades. [Sampling assumptions](https://github.com/davidahma/telryn/blob/v0.9.2/docs/statistics.md)
31
+
32
+ The rehearsal compares Telryn with a saved SQL search using the same records and staff budget. Across its 1,350 possible two-week draws, the saved search finds at least as many owner-accepted episodes in 96% of draws. The cases and staff times are synthetic. The field protocol measures whether either method brings action forward or saves staff time on a real queue. [Field protocol](https://github.com/davidahma/telryn/blob/v0.9.2/docs/evaluation.md#two-weeks-on-one-complaints-queue)
33
+
34
+ ## AI agents and integrations
35
+
36
+ - **Before an agent release**, send synthetic complaints through the test agent and check its test register independently. A missing, late or unverifiable entry keeps the release gate closed. [Agent test and adapter contract](https://github.com/davidahma/telryn/blob/v0.9.2/docs/agent-release.md)
37
+ - **For transcript screening**, use structured signals or select Ollama, Azure OpenAI or regional Amazon Bedrock. Each definite extracted fact needs a cited passage. Bedrock users can install the AWS SDK with `pipx install 'telryn[bedrock]'`. [Model setup and data handling](https://github.com/davidahma/telryn/blob/v0.9.2/docs/transcripts.md)
38
+ - **For intake and handoff**, use helpdesk connectors or approved exports. The integration guide lists the evidence each provider exposes, including when the team must supply a lifecycle ledger. [Supported integrations](https://github.com/davidahma/telryn/blob/v0.9.2/docs/integrations.md)
39
+
40
+ Run `telryn qualify` to exercise the bundled checks. [Architecture](https://github.com/davidahma/telryn/blob/v0.9.2/docs/architecture.md) · [Public support dataset](https://github.com/davidahma/telryn/blob/v0.9.2/examples/public_demo/NOTICE.md) · [Contributing](https://github.com/davidahma/telryn/blob/v0.9.2/CONTRIBUTING.md) · [Apache-2.0](https://github.com/davidahma/telryn/blob/v0.9.2/LICENSE)
File without changes
@@ -0,0 +1 @@
1
+ """Rehearse a release check using a synthetic agent and register."""
@@ -0,0 +1,50 @@
1
+ """Exercise the public seed command against two synthetic agent revisions."""
2
+
3
+ import json
4
+ import os
5
+ import subprocess
6
+ import sys
7
+ from pathlib import Path
8
+ from tempfile import TemporaryDirectory
9
+
10
+
11
+ def main():
12
+ here = Path(__file__).resolve().parent
13
+ suite = json.loads((here / "suite.json").read_text())
14
+ with TemporaryDirectory() as temp:
15
+ tmp = Path(temp)
16
+ for revision, expected in (("demo-prompt-v1", 1), ("demo-prompt-v2", 0)):
17
+ suite["agent_revision"] = revision
18
+ plan = tmp / "suite.json"
19
+ plan.write_text(json.dumps(suite))
20
+ bridge = str(here / "bridge.py")
21
+ result = subprocess.run(
22
+ [
23
+ sys.executable,
24
+ "-m",
25
+ "telryn",
26
+ "seed",
27
+ str(plan),
28
+ "--run-id",
29
+ revision,
30
+ "--agent-adapter",
31
+ bridge,
32
+ "--register-adapter",
33
+ bridge,
34
+ ],
35
+ env={
36
+ **os.environ,
37
+ "TELRYN_SEED_DEMO_DB": str(tmp / "lab.db"),
38
+ "TELRYN_DEMO_AGENT_REVISION": revision,
39
+ },
40
+ capture_output=True,
41
+ text=True,
42
+ )
43
+ print(f"Synthetic workspace · {revision}", flush=True)
44
+ print(result.stdout, end="")
45
+ if result.returncode != expected:
46
+ sys.exit(result.stderr or "Unexpected release result")
47
+
48
+
49
+ if __name__ == "__main__":
50
+ main()
@@ -0,0 +1,121 @@
1
+ """Local synthetic support agent and independently readable SQLite register."""
2
+
3
+ import hashlib
4
+ import json
5
+ import os
6
+ import sqlite3
7
+ import sys
8
+ from pathlib import Path
9
+
10
+
11
+ def digest(value):
12
+ encoded = json.dumps(
13
+ value, ensure_ascii=True, sort_keys=True, separators=(",", ":")
14
+ )
15
+ return hashlib.sha256(encoded.encode("ascii")).hexdigest()
16
+
17
+
18
+ def main():
19
+ request = json.load(sys.stdin)
20
+ revision = os.environ.get("TELRYN_DEMO_AGENT_REVISION", "demo-prompt-v2")
21
+ if revision not in {"demo-prompt-v1", "demo-prompt-v2"}:
22
+ raise ValueError("unknown simulated agent revision")
23
+ scope = {
24
+ "workspace": "local-synthetic-lab",
25
+ "agent_revision": revision,
26
+ "policy_revision": "demo-complaints-v1",
27
+ "handoff_revision": "demo-register-v1",
28
+ }
29
+ response = {
30
+ "schema": 1,
31
+ "environment": "test",
32
+ "scope": scope,
33
+ "request_digest": digest(request),
34
+ }
35
+ operation = request["operation"]
36
+ path = Path(os.environ["TELRYN_SEED_DEMO_DB"]).resolve()
37
+ if operation == "identify":
38
+ response["role"] = request["role"]
39
+ elif request["scope"] != scope or request["environment"] != "test":
40
+ raise ValueError("wrong synthetic deployment")
41
+ elif operation == "submit":
42
+ with sqlite3.connect(path) as db:
43
+ db.execute("BEGIN IMMEDIATE")
44
+ db.execute(
45
+ "CREATE TABLE IF NOT EXISTS runs (id TEXT PRIMARY KEY, suite TEXT NOT NULL)"
46
+ )
47
+ db.execute(
48
+ "CREATE TABLE IF NOT EXISTS messages (marker TEXT PRIMARY KEY, conversation TEXT UNIQUE, received TEXT)"
49
+ )
50
+ db.execute(
51
+ "CREATE TABLE IF NOT EXISTS register (id TEXT PRIMARY KEY, marker TEXT, conversation TEXT, recorded TEXT)"
52
+ )
53
+ db.execute(
54
+ "INSERT OR IGNORE INTO runs VALUES (?, ?)",
55
+ (request["run_id"], request["suite_digest"]),
56
+ )
57
+ (saved,) = db.execute(
58
+ "SELECT suite FROM runs WHERE id=?", (request["run_id"],)
59
+ ).fetchone()
60
+ if saved != request["suite_digest"]:
61
+ raise ValueError("a run ID was reused for another suite")
62
+ marker = request["marker"]
63
+ existing = db.execute(
64
+ "SELECT conversation, received FROM messages WHERE marker=?", (marker,)
65
+ ).fetchone()
66
+ if existing:
67
+ conversation, received = existing
68
+ else:
69
+ conversation = "conversation-" + marker
70
+ received = "2026-10-05T09:00:00Z"
71
+ db.execute(
72
+ "INSERT INTO messages VALUES (?, ?, ?)",
73
+ (marker, conversation, received),
74
+ )
75
+ phrases = ["third time", "ombudsman", "still unhappy"]
76
+ if revision == "demo-prompt-v2":
77
+ phrases.append("can't read the letters")
78
+ if any(phrase in request["phrase"].casefold() for phrase in phrases):
79
+ db.execute(
80
+ "INSERT INTO register VALUES (?, ?, ?, ?)",
81
+ (
82
+ "record-" + marker,
83
+ marker,
84
+ conversation,
85
+ "2026-10-05T09:15:00Z",
86
+ ),
87
+ )
88
+ response.update(
89
+ marker=marker, conversation_id=conversation, received_at=received
90
+ )
91
+ elif operation == "read_register":
92
+ with sqlite3.connect(path.as_uri() + "?mode=ro", uri=True) as db:
93
+ marks = request["markers"]
94
+ placeholders = ",".join("?" for _ in marks)
95
+ rows = db.execute(
96
+ "SELECT id, marker, conversation, recorded FROM register "
97
+ f"WHERE marker IN ({placeholders}) ORDER BY id",
98
+ marks,
99
+ )
100
+ response.update(
101
+ source_ref="synthetic-register-snapshot",
102
+ as_of="2026-10-05T12:00:00Z",
103
+ complete_through="2026-10-05T12:00:00Z",
104
+ entries=[
105
+ dict(
106
+ zip(
107
+ ("entry_id", "marker", "conversation_id", "recorded_at"),
108
+ row,
109
+ strict=True,
110
+ )
111
+ )
112
+ for row in rows
113
+ ],
114
+ )
115
+ else:
116
+ raise ValueError("unsupported synthetic operation")
117
+ print(json.dumps(response))
118
+
119
+
120
+ if __name__ == "__main__":
121
+ main()
@@ -0,0 +1,14 @@
1
+ {
2
+ "schema": 1,
3
+ "environment": "test",
4
+ "workspace": "local-synthetic-lab",
5
+ "agent_revision": "demo-prompt-v2",
6
+ "policy_revision": "demo-complaints-v1",
7
+ "handoff_revision": "demo-register-v1",
8
+ "cases": [
9
+ {"id":"repeat","phrase":"This is the third time I've asked about the duplicate charge.","registration_minutes":60},
10
+ {"id":"external","phrase":"I'll take this to the ombudsman.","registration_minutes":60},
11
+ {"id":"refund","phrase":"I received the refund and I'm still unhappy with how you treated me.","registration_minutes":60},
12
+ {"id":"vulnerability","phrase":"I can't read the letters you keep sending. How am I supposed to sort this out?","registration_minutes":60}
13
+ ]
14
+ }
@@ -0,0 +1,32 @@
1
+ # Rehearse a two-week complaints check
2
+
3
+ Mira asks a payments bot why it charged her twice. Fin refunds the debit and closes the chat. Two weeks later she calls. The agent records a query. On 6 October she calls again. Could the complaints lead show a reviewer when the clock started, whether a complaint was registered and who still needs to act?
4
+
5
+ Run the invented case from the repository root. Each dated output folder contains a signed local report and one blinded grading packet.
6
+
7
+ ```sh
8
+ python3 -m examples.complaints_pilot --out runs/complaints-pilot
9
+ python3 -m telryn weekly runs/complaints-pilot/2026-10-05/report.html --format json
10
+ ```
11
+
12
+ Open **C108** in the first report. It links the October contact to the August Fin chat and phone call through the same customer and payment references. The clock starts on 4 August at *“Even with a refund I want to know how this happened.”* This fictional firm's policy makes registration due on 7 August and a final response due on 29 September. At the 12 October cutoff there is no register entry or cited final response. On 12 October at 11:00 UTC the case manager receives a request. The case awaits acceptance, with a review due on 16 October. The two August contacts supply evidence for the October case and count as one episode. [Dated passages](prior-contacts.json) · [Example clock policy](clock-policy.json) · [Owner history](owner-events.csv)
13
+
14
+ ## What the comparison found
15
+
16
+ Both methods could select five cases per week and spend 80 total staff minutes. Both saw the same conversations, linked history, refund notes, completed human reviews, register and owner ledger as of each cutoff. The native SQL ranks repeat contacts, hardship, ombudsman references, investigation requests and unresolved dissatisfaction after a refund. Telryn applies a transparent screen to the source evidence, then randomly selects four flagged cases and one unflagged case. A neutral question about the ombudsman's address can trigger either screen. The human grade decides whether it meets the firm's policy. [Protocol](protocol.toml) · [Native query](native.sql) · [Telryn screen](signals.py)
17
+
18
+ | First recorded draw | Native accepted episodes / staff minutes | Telryn accepted episodes / staff minutes |
19
+ | --- | ---: | ---: |
20
+ | Week of 5 October | 3 / 62 | 3 / 71 |
21
+ | Week of 12 October | 2 / 63 | 3 / 60 |
22
+ | Two weeks | **5 / 125** | **6 / 131** |
23
+
24
+ Five accepted episodes overlapped. On this draw Telryn selected C207, where a refund left the customer unhappy. SQL also recognized the case, but higher-ranked cases and a tie on priority filled its five slots. Staged operator help fell from eight minutes to three. The comparison charges both methods for every selected case's first and second review, including overlaps. Recorded time to action begins at the common cutoff. A shared case has one observed action time. [Staged grades and review time](answers.csv) · [Staff time by activity](staff-minutes.csv) · [Accepted episode identities](owner-episodes.csv)
25
+
26
+ **The first draw was unusually favorable to Telryn.** For the six authored episodes with a later acceptance, there are 1,350 equally likely two-week selections at the frozen sampling rates. Telryn finds more accepted episodes than the fixed SQL in 54 selections (4%), the same number in 324 (24%) and fewer in 972 (72%). The program calculates this distribution after grading. It leaves the issued assignments in place. A different team key can produce a different first draw. Neither customer benefit nor staff savings has been measured. The earlier demonstration used a smaller fixture and a narrower SQL query, so its totals measure a different comparison.
27
+
28
+ ## Read the weekly statement
29
+
30
+ For the first recorded draw, the week of 5 October has six distinct shortlisted conversations. At cutoff the register lacked a required entry for one verified episode, Mira’s, and for three other conversations without a verified episode link. One of the three conversations had an entry by 14 October. Two still lacked an entry, as did Mira’s episode. Seven days had elapsed since C108 closed. The single later registration was recorded 142 hours after that conversation closed. The statement names the gaps in source coverage, including partial phone coverage and uncovered email, disputes and social sources. Its estimates apply to the combined shortlists only. A queue-wide estimate needs a probability sample of the full unreviewed queue. [Channel inventory](channels.csv)
31
+
32
+ The program freezes both selections before opening the answers. Simulated independent reviewers grade one mixed packet. The signed report reconciles those grades with the dated register and owner actions. An action marked completed without a recorded acceptance keeps its completion timestamp and stays outside the accepted-episode count. The terminal JSON includes the selections, commitments, staff minutes, weekly statements and selection sensitivity. Retain it and the team trust store to verify the comparison. [Conversation export](conversations.csv) · [Dated register](register.csv) · [Team onboarding minutes](onboarding.csv) · [Field protocol and decision criteria](../../docs/evaluation.md#two-weeks-on-one-complaints-queue)
@@ -0,0 +1 @@
1
+ """Two-week synthetic rehearsal for the complaints field comparison."""