vouch-kb 0.1.0__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 (182) hide show
  1. vouch_kb-0.1.0/.github/ISSUE_TEMPLATE/bug.md +41 -0
  2. vouch_kb-0.1.0/.github/ISSUE_TEMPLATE/config.yml +8 -0
  3. vouch_kb-0.1.0/.github/ISSUE_TEMPLATE/feature.md +28 -0
  4. vouch_kb-0.1.0/.github/ISSUE_TEMPLATE/vep.md +37 -0
  5. vouch_kb-0.1.0/.github/PULL_REQUEST_TEMPLATE.md +34 -0
  6. vouch_kb-0.1.0/.github/dependabot.yml +20 -0
  7. vouch_kb-0.1.0/.github/workflows/ci.yml +65 -0
  8. vouch_kb-0.1.0/.github/workflows/release.yml +42 -0
  9. vouch_kb-0.1.0/.github/workflows/schema-check.yml +62 -0
  10. vouch_kb-0.1.0/.gitignore +13 -0
  11. vouch_kb-0.1.0/.pre-commit-config.yaml +13 -0
  12. vouch_kb-0.1.0/.vouch/.gitignore +3 -0
  13. vouch_kb-0.1.0/.vouch/audit.log.jsonl +9 -0
  14. vouch_kb-0.1.0/.vouch/claims/vouch-uses-a-review-gated-proposal-workflow-agents-propose-c.yaml +22 -0
  15. vouch_kb-0.1.0/.vouch/config.yaml +7 -0
  16. vouch_kb-0.1.0/.vouch/decided/20260521-055206-7d6d92d6.yaml +25 -0
  17. vouch_kb-0.1.0/.vouch/sources/06d8519f8dcf4149d23c8a48984541b2e9365ec364e7e58192e28ed149a2c47c/content +6 -0
  18. vouch_kb-0.1.0/.vouch/sources/06d8519f8dcf4149d23c8a48984541b2e9365ec364e7e58192e28ed149a2c47c/meta.yaml +12 -0
  19. vouch_kb-0.1.0/.vouch/sources/67478e72acfb8fac3a059143e95c95f5cc6f7e8d4dccc05fbcea8dbccb8a4eba/content +236 -0
  20. vouch_kb-0.1.0/.vouch/sources/67478e72acfb8fac3a059143e95c95f5cc6f7e8d4dccc05fbcea8dbccb8a4eba/meta.yaml +12 -0
  21. vouch_kb-0.1.0/CHANGELOG.md +85 -0
  22. vouch_kb-0.1.0/CODE_OF_CONDUCT.md +39 -0
  23. vouch_kb-0.1.0/CONTRIBUTING.md +67 -0
  24. vouch_kb-0.1.0/GOVERNANCE.md +65 -0
  25. vouch_kb-0.1.0/LICENSE +21 -0
  26. vouch_kb-0.1.0/MANIFEST.in +15 -0
  27. vouch_kb-0.1.0/Makefile +49 -0
  28. vouch_kb-0.1.0/PKG-INFO +315 -0
  29. vouch_kb-0.1.0/README.md +275 -0
  30. vouch_kb-0.1.0/ROADMAP.md +62 -0
  31. vouch_kb-0.1.0/SECURITY.md +78 -0
  32. vouch_kb-0.1.0/SPEC.md +426 -0
  33. vouch_kb-0.1.0/adapters/README.md +50 -0
  34. vouch_kb-0.1.0/adapters/claude-code/.mcp.json +11 -0
  35. vouch_kb-0.1.0/adapters/claude-code/CLAUDE.md.snippet +43 -0
  36. vouch_kb-0.1.0/adapters/claude-code/README.md +71 -0
  37. vouch_kb-0.1.0/adapters/codex/README.md +39 -0
  38. vouch_kb-0.1.0/adapters/codex/config.toml +6 -0
  39. vouch_kb-0.1.0/adapters/continue/README.md +30 -0
  40. vouch_kb-0.1.0/adapters/continue/config.yaml +6 -0
  41. vouch_kb-0.1.0/adapters/cursor/README.md +44 -0
  42. vouch_kb-0.1.0/adapters/cursor/mcp.json +11 -0
  43. vouch_kb-0.1.0/adapters/generic-mcp/README.md +61 -0
  44. vouch_kb-0.1.0/adapters/jsonl-shell/README.md +82 -0
  45. vouch_kb-0.1.0/adapters/jsonl-shell/example-pipeline.sh +36 -0
  46. vouch_kb-0.1.0/benchmarks/README.md +69 -0
  47. vouch_kb-0.1.0/benchmarks/fixtures/gen_kb.py +80 -0
  48. vouch_kb-0.1.0/docs/README.md +38 -0
  49. vouch_kb-0.1.0/docs/banner.svg +214 -0
  50. vouch_kb-0.1.0/docs/bundles.md +136 -0
  51. vouch_kb-0.1.0/docs/demo.gif +0 -0
  52. vouch_kb-0.1.0/docs/demo.tape +86 -0
  53. vouch_kb-0.1.0/docs/embeddings.md +39 -0
  54. vouch_kb-0.1.0/docs/example-session.md +178 -0
  55. vouch_kb-0.1.0/docs/faq.md +153 -0
  56. vouch_kb-0.1.0/docs/getting-started.md +138 -0
  57. vouch_kb-0.1.0/docs/multi-agent.md +117 -0
  58. vouch_kb-0.1.0/docs/object-model.md +159 -0
  59. vouch_kb-0.1.0/docs/retrieval.md +123 -0
  60. vouch_kb-0.1.0/docs/review-gate.md +162 -0
  61. vouch_kb-0.1.0/docs/superpowers/plans/2026-05-20-semantic-search.md +3769 -0
  62. vouch_kb-0.1.0/docs/superpowers/specs/2026-05-20-semantic-search-design.md +258 -0
  63. vouch_kb-0.1.0/docs/transports.md +121 -0
  64. vouch_kb-0.1.0/examples/README.md +34 -0
  65. vouch_kb-0.1.0/examples/decision-log/README.md +32 -0
  66. vouch_kb-0.1.0/examples/decision-log/vouch/claims/free-tier-100-req-superseded.yaml +14 -0
  67. vouch_kb-0.1.0/examples/decision-log/vouch/claims/free-tier-500-req.yaml +15 -0
  68. vouch_kb-0.1.0/examples/decision-log/vouch/claims/incident-response-15min-sla.yaml +16 -0
  69. vouch_kb-0.1.0/examples/decision-log/vouch/claims/use-postgres-for-billing.yaml +16 -0
  70. vouch_kb-0.1.0/examples/tiny/README.md +49 -0
  71. vouch_kb-0.1.0/examples/tiny/vouch/audit.log.jsonl +13 -0
  72. vouch_kb-0.1.0/examples/tiny/vouch/claims/auth-uses-jwt.yaml +18 -0
  73. vouch_kb-0.1.0/examples/tiny/vouch/claims/jwt-rs256-only.yaml +18 -0
  74. vouch_kb-0.1.0/examples/tiny/vouch/claims/refresh-tokens-rotate.yaml +17 -0
  75. vouch_kb-0.1.0/examples/tiny/vouch/claims/session-ttl-15min.yaml +16 -0
  76. vouch_kb-0.1.0/examples/tiny/vouch/config.yaml +9 -0
  77. vouch_kb-0.1.0/examples/tiny/vouch/decided/prop-001.yaml +15 -0
  78. vouch_kb-0.1.0/examples/tiny/vouch/pages/auth-design.md +58 -0
  79. vouch_kb-0.1.0/examples/tiny/vouch/sources/3e2f1b8e7a4c9f5e0b2d6c1a4f8e9d3b7c5a2e1f0d8b6c4a3e2f1b8e7a4c9f5e/meta.yaml +13 -0
  80. vouch_kb-0.1.0/examples/tiny/vouch/sources/9b1ac6d4f8e3b7a1c5e2d8f4a9b3c7e1d5f8a2c4b9e7d3f1a5c8b2e6d4f9a3c7/meta.yaml +14 -0
  81. vouch_kb-0.1.0/proposals/README.md +74 -0
  82. vouch_kb-0.1.0/proposals/VEP-0001-review-gate.md +150 -0
  83. vouch_kb-0.1.0/proposals/VEP-0002-jsonl-transport.md +112 -0
  84. vouch_kb-0.1.0/proposals/VEP-0003-content-hashed-sources.md +119 -0
  85. vouch_kb-0.1.0/proposals/VEP-TEMPLATE.md +66 -0
  86. vouch_kb-0.1.0/pyproject.toml +96 -0
  87. vouch_kb-0.1.0/schemas/README.md +64 -0
  88. vouch_kb-0.1.0/schemas/audit-event.schema.json +54 -0
  89. vouch_kb-0.1.0/schemas/bundle.manifest.schema.json +58 -0
  90. vouch_kb-0.1.0/schemas/capabilities.schema.json +63 -0
  91. vouch_kb-0.1.0/schemas/claim.schema.json +162 -0
  92. vouch_kb-0.1.0/schemas/context-item.schema.json +60 -0
  93. vouch_kb-0.1.0/schemas/context-pack.schema.json +164 -0
  94. vouch_kb-0.1.0/schemas/context-quality.schema.json +68 -0
  95. vouch_kb-0.1.0/schemas/entity.schema.json +90 -0
  96. vouch_kb-0.1.0/schemas/evidence.schema.json +86 -0
  97. vouch_kb-0.1.0/schemas/jsonl-envelope.schema.json +62 -0
  98. vouch_kb-0.1.0/schemas/page.schema.json +99 -0
  99. vouch_kb-0.1.0/schemas/proposal.schema.json +122 -0
  100. vouch_kb-0.1.0/schemas/relation.schema.json +76 -0
  101. vouch_kb-0.1.0/schemas/session.schema.json +70 -0
  102. vouch_kb-0.1.0/schemas/source.schema.json +117 -0
  103. vouch_kb-0.1.0/scripts/gen_schemas.py +71 -0
  104. vouch_kb-0.1.0/spec/2026-05-21/README.md +19 -0
  105. vouch_kb-0.1.0/spec/2026-05-21/SPEC.md +426 -0
  106. vouch_kb-0.1.0/spec/2026-05-21/audit-vocabulary.md +116 -0
  107. vouch_kb-0.1.0/spec/2026-05-21/methods.md +265 -0
  108. vouch_kb-0.1.0/spec/2026-05-21/retrieval.md +134 -0
  109. vouch_kb-0.1.0/spec/2026-05-21/review-gate.md +147 -0
  110. vouch_kb-0.1.0/spec/2026-05-21/transports.md +143 -0
  111. vouch_kb-0.1.0/spec/README.md +27 -0
  112. vouch_kb-0.1.0/spec/audit-vocabulary.md +116 -0
  113. vouch_kb-0.1.0/spec/methods.md +265 -0
  114. vouch_kb-0.1.0/spec/retrieval.md +134 -0
  115. vouch_kb-0.1.0/spec/review-gate.md +147 -0
  116. vouch_kb-0.1.0/spec/transports.md +143 -0
  117. vouch_kb-0.1.0/src/vouch/__init__.py +3 -0
  118. vouch_kb-0.1.0/src/vouch/audit.py +83 -0
  119. vouch_kb-0.1.0/src/vouch/bundle.py +370 -0
  120. vouch_kb-0.1.0/src/vouch/capabilities.py +78 -0
  121. vouch_kb-0.1.0/src/vouch/cli.py +788 -0
  122. vouch_kb-0.1.0/src/vouch/context.py +162 -0
  123. vouch_kb-0.1.0/src/vouch/embeddings/__init__.py +39 -0
  124. vouch_kb-0.1.0/src/vouch/embeddings/base.py +60 -0
  125. vouch_kb-0.1.0/src/vouch/embeddings/cache.py +83 -0
  126. vouch_kb-0.1.0/src/vouch/embeddings/dedup.py +90 -0
  127. vouch_kb-0.1.0/src/vouch/embeddings/fastembed_bge.py +45 -0
  128. vouch_kb-0.1.0/src/vouch/embeddings/fusion.py +86 -0
  129. vouch_kb-0.1.0/src/vouch/embeddings/hyde.py +27 -0
  130. vouch_kb-0.1.0/src/vouch/embeddings/migration.py +65 -0
  131. vouch_kb-0.1.0/src/vouch/embeddings/rerank.py +60 -0
  132. vouch_kb-0.1.0/src/vouch/embeddings/scorer.py +81 -0
  133. vouch_kb-0.1.0/src/vouch/embeddings/st_minilm.py +41 -0
  134. vouch_kb-0.1.0/src/vouch/embeddings/st_mpnet.py +48 -0
  135. vouch_kb-0.1.0/src/vouch/health.py +212 -0
  136. vouch_kb-0.1.0/src/vouch/index_db.py +435 -0
  137. vouch_kb-0.1.0/src/vouch/jsonl_server.py +571 -0
  138. vouch_kb-0.1.0/src/vouch/lifecycle.py +148 -0
  139. vouch_kb-0.1.0/src/vouch/models.py +376 -0
  140. vouch_kb-0.1.0/src/vouch/onboarding.py +82 -0
  141. vouch_kb-0.1.0/src/vouch/proposals.py +360 -0
  142. vouch_kb-0.1.0/src/vouch/server.py +665 -0
  143. vouch_kb-0.1.0/src/vouch/sessions.py +144 -0
  144. vouch_kb-0.1.0/src/vouch/storage.py +634 -0
  145. vouch_kb-0.1.0/src/vouch/verify.py +75 -0
  146. vouch_kb-0.1.0/templates/README.md +37 -0
  147. vouch_kb-0.1.0/templates/claim.template.yaml +24 -0
  148. vouch_kb-0.1.0/templates/config.template.yaml +21 -0
  149. vouch_kb-0.1.0/templates/entity.template.yaml +12 -0
  150. vouch_kb-0.1.0/templates/evidence.template.yaml +11 -0
  151. vouch_kb-0.1.0/templates/page.template.md +23 -0
  152. vouch_kb-0.1.0/templates/proposal.template.yaml +26 -0
  153. vouch_kb-0.1.0/templates/relation.template.yaml +12 -0
  154. vouch_kb-0.1.0/templates/session.template.yaml +11 -0
  155. vouch_kb-0.1.0/templates/source.meta.template.yaml +17 -0
  156. vouch_kb-0.1.0/tests/__init__.py +0 -0
  157. vouch_kb-0.1.0/tests/embeddings/__init__.py +1 -0
  158. vouch_kb-0.1.0/tests/embeddings/_fakes.py +52 -0
  159. vouch_kb-0.1.0/tests/embeddings/conftest.py +37 -0
  160. vouch_kb-0.1.0/tests/embeddings/test_cli.py +87 -0
  161. vouch_kb-0.1.0/tests/embeddings/test_core.py +65 -0
  162. vouch_kb-0.1.0/tests/embeddings/test_dedup.py +58 -0
  163. vouch_kb-0.1.0/tests/embeddings/test_fusion.py +59 -0
  164. vouch_kb-0.1.0/tests/embeddings/test_hyde.py +17 -0
  165. vouch_kb-0.1.0/tests/embeddings/test_integration.py +80 -0
  166. vouch_kb-0.1.0/tests/embeddings/test_migration.py +68 -0
  167. vouch_kb-0.1.0/tests/embeddings/test_rerank.py +34 -0
  168. vouch_kb-0.1.0/tests/embeddings/test_scorer.py +42 -0
  169. vouch_kb-0.1.0/tests/embeddings/test_search.py +171 -0
  170. vouch_kb-0.1.0/tests/embeddings/test_storage.py +172 -0
  171. vouch_kb-0.1.0/tests/test_audit.py +30 -0
  172. vouch_kb-0.1.0/tests/test_bundle.py +312 -0
  173. vouch_kb-0.1.0/tests/test_capabilities.py +17 -0
  174. vouch_kb-0.1.0/tests/test_cli.py +174 -0
  175. vouch_kb-0.1.0/tests/test_context.py +99 -0
  176. vouch_kb-0.1.0/tests/test_health.py +54 -0
  177. vouch_kb-0.1.0/tests/test_index.py +49 -0
  178. vouch_kb-0.1.0/tests/test_jsonl_server.py +196 -0
  179. vouch_kb-0.1.0/tests/test_onboarding.py +64 -0
  180. vouch_kb-0.1.0/tests/test_sessions.py +112 -0
  181. vouch_kb-0.1.0/tests/test_storage.py +358 -0
  182. vouch_kb-0.1.0/tests/test_verify.py +95 -0
@@ -0,0 +1,41 @@
1
+ ---
2
+ name: Bug report
3
+ about: vouch did something it shouldn't
4
+ labels: bug
5
+ ---
6
+
7
+ ## What happened
8
+
9
+ <!-- One sentence: what went wrong. -->
10
+
11
+ ## What you expected
12
+
13
+ <!-- One sentence: what should have happened. -->
14
+
15
+ ## Reproduction
16
+
17
+ <!-- Minimum sequence to reproduce. Ideally a shell transcript. -->
18
+
19
+ ```bash
20
+ $ vouch ...
21
+ ```
22
+
23
+ ## Environment
24
+
25
+ - vouch version: `vouch --version`
26
+ - Python version: `python3 --version`
27
+ - OS:
28
+ - Host (Claude Code / Cursor / Codex / standalone CLI / something else):
29
+
30
+ ## `.vouch/` state
31
+
32
+ <!-- If relevant, paste the output of `vouch doctor`. Redact anything
33
+ sensitive. -->
34
+
35
+ ```
36
+ $ vouch doctor
37
+ ```
38
+
39
+ ## Anything else
40
+
41
+ <!-- Logs, stderr, hypotheses, what you tried. -->
@@ -0,0 +1,8 @@
1
+ blank_issues_enabled: false
2
+ contact_links:
3
+ - name: Security issue
4
+ url: https://github.com/plind-junior/vouch/security/advisories/new
5
+ about: Please report security issues privately via GitHub Security Advisories, not as a public issue. See SECURITY.md.
6
+ - name: Question
7
+ url: https://github.com/plind-junior/vouch/discussions
8
+ about: General questions, ideas, and discussions belong in Discussions, not Issues.
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: Feature request
3
+ about: An idea for something vouch should do
4
+ labels: enhancement
5
+ ---
6
+
7
+ ## What you're trying to do
8
+
9
+ <!-- Describe the problem from your seat. "When I'm doing X, I want
10
+ to Y, because Z." Concrete examples help. -->
11
+
12
+ ## What you've tried
13
+
14
+ <!-- Existing vouch features you tried; why they didn't fit. -->
15
+
16
+ ## Suggested shape
17
+
18
+ <!-- If you have one. A method name, a CLI flag, a config option.
19
+ "Add `vouch foo` that does bar" is fine. -->
20
+
21
+ ## Compatibility considerations
22
+
23
+ <!-- Would this break existing KBs? Would it require a VEP (surface
24
+ change), or is it additive? -->
25
+
26
+ ## Alternatives
27
+
28
+ <!-- Other ways the same problem could be solved. -->
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: VEP intent (before writing a full proposal)
3
+ about: Float a surface change before drafting a VEP
4
+ labels: vep, design
5
+ ---
6
+
7
+ <!-- This issue is for socialising a surface-level idea before you sit
8
+ down to write a full VEP. If you already know what you want and
9
+ are ready to write the doc, skip this and open a PR adding
10
+ proposals/VEP-NNNN-your-slug.md directly. -->
11
+
12
+ ## What part of the surface
13
+
14
+ <!-- Tick all that apply. -->
15
+
16
+ - [ ] Object model (Source/Claim/Page/Entity/Relation/Evidence/Proposal/Session/AuditEvent)
17
+ - [ ] `kb.*` method surface
18
+ - [ ] On-disk layout under `.vouch/`
19
+ - [ ] Bundle format
20
+ - [ ] Audit-log shape
21
+ - [ ] `config.yaml` defaults
22
+ - [ ] New transport
23
+
24
+ ## Sketch
25
+
26
+ <!-- 3-5 sentences. Just enough that a maintainer can tell whether
27
+ it's worth a full VEP. -->
28
+
29
+ ## Use case
30
+
31
+ <!-- What user task does this enable? Or what user pain does it
32
+ solve? -->
33
+
34
+ ## What you're unsure about
35
+
36
+ <!-- Open questions. The maintainers will weigh in before you invest
37
+ in a full VEP. -->
@@ -0,0 +1,34 @@
1
+ <!--
2
+ Thanks for sending a PR! Before opening, please skim CONTRIBUTING.md.
3
+
4
+ Surface changes (object model, kb.* methods, on-disk layout, bundle
5
+ format, audit-log shape) need a VEP first; see proposals/README.md.
6
+ -->
7
+
8
+ ## What changed
9
+
10
+ <!-- One paragraph. The *what*, briefly. -->
11
+
12
+ ## Why
13
+
14
+ <!-- One paragraph. The *why* — what problem this solves, what it
15
+ enables, or what it fixes. Link the issue if any. -->
16
+
17
+ ## What might break
18
+
19
+ <!-- Be honest. For users with an existing .vouch/ directory:
20
+ - Will any file move?
21
+ - Will any field on disk change shape?
22
+ - Will any kb.* method behave differently?
23
+ If yes to anything, flag it as a breaking change. -->
24
+
25
+ ## VEP
26
+
27
+ <!-- If this is a surface change, link the accepted VEP here.
28
+ If you're not sure whether you needed one, ask. -->
29
+
30
+ ## Tests
31
+
32
+ - [ ] `make check` passes locally (lint + mypy + pytest)
33
+ - [ ] New / changed behaviour has a test
34
+ - [ ] `CHANGELOG.md` updated under `## [Unreleased]`
@@ -0,0 +1,20 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: pip
4
+ directory: "/"
5
+ schedule:
6
+ interval: weekly
7
+ open-pull-requests-limit: 5
8
+ labels: ["dependencies"]
9
+ commit-message:
10
+ prefix: "chore"
11
+ include: scope
12
+
13
+ - package-ecosystem: github-actions
14
+ directory: "/"
15
+ schedule:
16
+ interval: monthly
17
+ labels: ["dependencies", "ci"]
18
+ commit-message:
19
+ prefix: "chore"
20
+ include: scope
@@ -0,0 +1,65 @@
1
+ name: ci
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+
8
+ jobs:
9
+ test:
10
+ name: test (py${{ matrix.python }})
11
+ runs-on: ubuntu-latest
12
+ strategy:
13
+ fail-fast: false
14
+ matrix:
15
+ python: ["3.11", "3.12", "3.13"]
16
+ steps:
17
+ - uses: actions/checkout@v4
18
+
19
+ - uses: actions/setup-python@v5
20
+ with:
21
+ python-version: ${{ matrix.python }}
22
+ cache: pip
23
+
24
+ - name: install
25
+ run: |
26
+ python -m pip install --upgrade pip
27
+ pip install -e '.[dev]'
28
+
29
+ - name: lint
30
+ run: python -m ruff check src tests
31
+
32
+ - name: type
33
+ run: python -m mypy src
34
+
35
+ - name: test
36
+ run: python -m pytest --cov=vouch --cov-report=xml
37
+
38
+ - name: upload coverage
39
+ if: matrix.python == '3.12'
40
+ uses: actions/upload-artifact@v7
41
+ with:
42
+ name: coverage
43
+ path: coverage.xml
44
+
45
+ build:
46
+ name: build sdist + wheel
47
+ runs-on: ubuntu-latest
48
+ needs: test
49
+ steps:
50
+ - uses: actions/checkout@v4
51
+
52
+ - uses: actions/setup-python@v5
53
+ with:
54
+ python-version: "3.12"
55
+
56
+ - name: build
57
+ run: |
58
+ python -m pip install --upgrade pip build
59
+ python -m build
60
+
61
+ - name: upload artifacts
62
+ uses: actions/upload-artifact@v7
63
+ with:
64
+ name: dist
65
+ path: dist/
@@ -0,0 +1,42 @@
1
+ name: release
2
+
3
+ # Publish to PyPI on a version tag (e.g. v0.1.0).
4
+ # Uses PyPI Trusted Publishing (OIDC) — no API token stored.
5
+ # One-time setup on PyPI: add a trusted publisher for project `vouch-kb`
6
+ # pointing at vouchdev/vouch, workflow `release.yml`, environment `pypi`.
7
+
8
+ on:
9
+ push:
10
+ tags:
11
+ - "v*"
12
+
13
+ permissions:
14
+ contents: read
15
+
16
+ jobs:
17
+ build:
18
+ runs-on: ubuntu-latest
19
+ steps:
20
+ - uses: actions/checkout@v4
21
+ - uses: actions/setup-python@v5
22
+ with:
23
+ python-version: "3.12"
24
+ - run: python -m pip install --upgrade build
25
+ - run: python -m build
26
+ - uses: actions/upload-artifact@v7
27
+ with:
28
+ name: dist
29
+ path: dist/
30
+
31
+ publish:
32
+ needs: build
33
+ runs-on: ubuntu-latest
34
+ environment: pypi
35
+ permissions:
36
+ id-token: write # required for trusted publishing
37
+ steps:
38
+ - uses: actions/download-artifact@v7
39
+ with:
40
+ name: dist
41
+ path: dist/
42
+ - uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,62 @@
1
+ name: schema-check
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ paths:
8
+ - "src/vouch/models.py"
9
+ - "schemas/**"
10
+
11
+ # Regenerate schemas from pydantic models and fail if the result
12
+ # differs from what's committed. This catches the "I edited models.py
13
+ # but forgot to regenerate schemas/" PR.
14
+ jobs:
15
+ check:
16
+ runs-on: ubuntu-latest
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+
20
+ - uses: actions/setup-python@v5
21
+ with:
22
+ python-version: "3.12"
23
+
24
+ - name: install
25
+ run: |
26
+ python -m pip install --upgrade pip
27
+ pip install -e '.[dev]'
28
+
29
+ - name: regenerate schemas
30
+ run: |
31
+ python3 - <<'PY'
32
+ import json, sys
33
+ sys.path.insert(0, 'src')
34
+ from vouch.models import (
35
+ Source, Evidence, Claim, Entity, Relation, Page,
36
+ Session, AuditEvent, Proposal,
37
+ ContextItem, ContextQuality, ContextPack, Capabilities,
38
+ )
39
+ models = {
40
+ 'source': Source, 'evidence': Evidence, 'claim': Claim,
41
+ 'entity': Entity, 'relation': Relation, 'page': Page,
42
+ 'session': Session, 'audit-event': AuditEvent,
43
+ 'proposal': Proposal, 'context-item': ContextItem,
44
+ 'context-quality': ContextQuality, 'context-pack': ContextPack,
45
+ 'capabilities': Capabilities,
46
+ }
47
+ for slug, m in models.items():
48
+ s = m.model_json_schema()
49
+ s['$schema'] = 'https://json-schema.org/draft/2020-12/schema'
50
+ s['$id'] = f'https://vouch.dev/schemas/{slug}.schema.json'
51
+ open(f'schemas/{slug}.schema.json', 'w').write(
52
+ json.dumps(s, indent=2, sort_keys=True)
53
+ )
54
+ PY
55
+
56
+ - name: assert no drift
57
+ run: |
58
+ if ! git diff --exit-code schemas/; then
59
+ echo "::error::schemas/ is out of sync with src/vouch/models.py."
60
+ echo "Run the regenerate snippet in schemas/README.md and commit."
61
+ exit 1
62
+ fi
@@ -0,0 +1,13 @@
1
+ __pycache__/
2
+ *.py[cod]
3
+ *.egg-info/
4
+ .venv/
5
+ .pytest_cache/
6
+ .mypy_cache/
7
+ .ruff_cache/
8
+ .coverage
9
+ htmlcov/
10
+ dist/
11
+ build/
12
+ *.swp
13
+ .DS_Store
@@ -0,0 +1,13 @@
1
+ repos:
2
+ - repo: https://github.com/astral-sh/ruff-pre-commit
3
+ rev: v0.11.0
4
+ hooks:
5
+ - id: ruff
6
+ args: [--fix]
7
+ - id: ruff-format
8
+
9
+ - repo: https://github.com/pre-commit/mirrors-mypy
10
+ rev: v1.15.0
11
+ hooks:
12
+ - id: mypy
13
+ additional_dependencies: [types-pyyaml]
@@ -0,0 +1,3 @@
1
+ proposed/
2
+ state.db
3
+ state.db-*
@@ -0,0 +1,9 @@
1
+ {"actor":"a","created_at":"2026-05-20T12:34:59.663398Z","data":{},"dry_run":false,"event":"kb.init","id":"0dfce4809698401cbbc490bf8e71f953","object_ids":[],"reversible":true}
2
+ {"actor":"a","created_at":"2026-05-21T05:51:53.568471Z","data":{},"dry_run":false,"event":"source.add","id":"f38a5315877047b09155df4cef62fdfb","object_ids":["06d8519f8dcf4149d23c8a48984541b2e9365ec364e7e58192e28ed149a2c47c"],"reversible":true}
3
+ {"actor":"a","created_at":"2026-05-21T05:52:06.487422Z","data":{"slug_hint":"vouch-uses-a-review-gated-proposal-workflow-agents-propose-c"},"dry_run":false,"event":"proposal.claim.create","id":"bc066c732d9d45a5a8038aebdf737a02","object_ids":["20260521-055206-7d6d92d6"],"reversible":true}
4
+ {"actor":"a","created_at":"2026-05-21T05:52:34.380239Z","data":{"reason":"Verified by source code inspection"},"dry_run":false,"event":"proposal.claim.approve","id":"119f617462cd4c1d9427148d7986d96c","object_ids":["20260521-055206-7d6d92d6","vouch-uses-a-review-gated-proposal-workflow-agents-propose-c"],"reversible":true}
5
+ {"actor":"vouch-verify","created_at":"2026-05-21T06:04:28.109538Z","data":{"checked":1,"failed":0},"dry_run":false,"event":"source.verify","id":"0f0aaac0a9d741edb7782a4b01b44f8e","object_ids":[],"reversible":true}
6
+ {"actor":"a","created_at":"2026-05-21T06:05:28.018745Z","data":{},"dry_run":false,"event":"kb.init","id":"803be831d1114cdc8466e85fa0b9e9b6","object_ids":[],"reversible":true}
7
+ {"actor":"a","created_at":"2026-05-21T06:05:54.067884Z","data":{},"dry_run":false,"event":"source.add","id":"0b451622d85246089a1d04c45d56c007","object_ids":["67478e72acfb8fac3a059143e95c95f5cc6f7e8d4dccc05fbcea8dbccb8a4eba"],"reversible":true}
8
+ {"actor":"a","created_at":"2026-05-21T06:06:58.649209Z","data":{},"dry_run":false,"event":"source.add","id":"b72feb84d842486490bb7616c616a08c","object_ids":["67478e72acfb8fac3a059143e95c95f5cc6f7e8d4dccc05fbcea8dbccb8a4eba"],"reversible":true}
9
+ {"actor":"a","created_at":"2026-05-21T06:07:08.973490Z","data":{"slug_hint":"vouch-enforces-a-review-gate-on-agent-writes"},"dry_run":false,"event":"proposal.claim.create","id":"9ef38f6a9d8c4e02ad3fd196c49bcc6f","object_ids":["20260521-060708-2b81cdab"],"reversible":true}
@@ -0,0 +1,22 @@
1
+ id: vouch-uses-a-review-gated-proposal-workflow-agents-propose-c
2
+ text: 'Vouch uses a review-gated proposal workflow: agents propose claims citing evidence
3
+ sources, and proposals must be explicitly approved (kb_approve) before becoming
4
+ durable artifacts in the knowledge base. This prevents hallucinated or low-quality
5
+ knowledge from persisting without human oversight.'
6
+ type: observation
7
+ status: working
8
+ confidence: 0.9
9
+ evidence:
10
+ - 06d8519f8dcf4149d23c8a48984541b2e9365ec364e7e58192e28ed149a2c47c
11
+ entities: []
12
+ supersedes: []
13
+ superseded_by: null
14
+ contradicts: []
15
+ scope: project
16
+ tags:
17
+ - architecture
18
+ - review-gate
19
+ created_at: '2026-05-21T05:52:34.267699Z'
20
+ updated_at: '2026-05-21T05:52:34.267705Z'
21
+ last_confirmed_at: null
22
+ approved_by: a
@@ -0,0 +1,7 @@
1
+ version: 1
2
+ review:
3
+ require_human_approval: true
4
+ retrieval:
5
+ backends:
6
+ - fts5
7
+ - substring
@@ -0,0 +1,25 @@
1
+ id: 20260521-055206-7d6d92d6
2
+ kind: claim
3
+ proposed_by: a
4
+ session_id: null
5
+ proposed_at: '2026-05-21T05:52:06.481764Z'
6
+ payload:
7
+ id: vouch-uses-a-review-gated-proposal-workflow-agents-propose-c
8
+ text: 'Vouch uses a review-gated proposal workflow: agents propose claims citing
9
+ evidence sources, and proposals must be explicitly approved (kb_approve) before
10
+ becoming durable artifacts in the knowledge base. This prevents hallucinated or
11
+ low-quality knowledge from persisting without human oversight.'
12
+ type: observation
13
+ confidence: 0.9
14
+ evidence:
15
+ - 06d8519f8dcf4149d23c8a48984541b2e9365ec364e7e58192e28ed149a2c47c
16
+ entities: []
17
+ tags:
18
+ - architecture
19
+ - review-gate
20
+ rationale: Verified by reading the source code in src/vouch/proposals.py and src/vouch/server.py
21
+ — the propose/approve separation is a core architectural decision.
22
+ status: approved
23
+ decided_at: '2026-05-21T05:52:34.378311Z'
24
+ decided_by: a
25
+ decision_reason: Verified by source code inspection
@@ -0,0 +1,6 @@
1
+ This conversation explored the vouch project source code to understand how the MCP server works.
2
+ Key findings: vouch exposes 40 MCP tools via FastMCP stdio transport, organized into read tools,
3
+ write/proposal tools (review-gated), lifecycle management, session management, and maintenance tools.
4
+ Sources are de-duplicated by SHA256 content hash. Claims require at least one evidence citation and
5
+ go through a proposal → approve/reject workflow before becoming durable artifacts. All mutations are
6
+ audit-logged to .vouch/audit.log.jsonl.
@@ -0,0 +1,12 @@
1
+ id: 06d8519f8dcf4149d23c8a48984541b2e9365ec364e7e58192e28ed149a2c47c
2
+ type: transcript
3
+ locator: /tmp/vouch-conversation-source.txt
4
+ title: Claude Code conversation — vouch exploration
5
+ hash: 06d8519f8dcf4149d23c8a48984541b2e9365ec364e7e58192e28ed149a2c47c
6
+ immutable: true
7
+ scope: project
8
+ byte_size: 539
9
+ media_type: text/plain
10
+ created_at: '2026-05-21T05:51:53.562157Z'
11
+ metadata: {}
12
+ tags: []