seif-cli 0.5.2__tar.gz → 0.6.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 (250) hide show
  1. {seif_cli-0.5.2 → seif_cli-0.6.2}/MANIFEST.in +1 -0
  2. seif_cli-0.6.2/PKG-INFO +483 -0
  3. seif_cli-0.6.2/README.md +435 -0
  4. {seif_cli-0.5.2 → seif_cli-0.6.2}/pyproject.toml +21 -7
  5. seif_cli-0.6.2/src/seif/audio_provenance.py +152 -0
  6. seif_cli-0.6.2/src/seif/cli/circuit_setup.py +297 -0
  7. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/cli.py +2672 -97
  8. seif_cli-0.6.2/src/seif/cli/confirm_action.py +179 -0
  9. seif_cli-0.6.2/src/seif/cli/plugin_detect.py +266 -0
  10. seif_cli-0.6.2/src/seif/cli/plugin_sync.py +284 -0
  11. seif_cli-0.6.2/src/seif/cli/resonance_display.py +203 -0
  12. seif_cli-0.6.2/src/seif/cli/serve_engine.py +244 -0
  13. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/setup.py +227 -11
  14. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/wrapper.py +231 -3
  15. seif_cli-0.6.2/src/seif/cli/wrapper_shims.py +361 -0
  16. seif_cli-0.6.2/src/seif/context/absorb_knowledge.py +236 -0
  17. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/context_manager.py +63 -10
  18. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/cycle.py +129 -39
  19. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/file_extractor.py +18 -0
  20. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/host_init.py +9 -0
  21. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/ingest.py +8 -0
  22. seif_cli-0.6.2/src/seif/context/install_state.py +182 -0
  23. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/registry.py +281 -2
  24. seif_cli-0.6.2/src/seif/context/seed_constraint.py +172 -0
  25. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/workspace.py +264 -1
  26. seif_cli-0.6.2/src/seif/core/fingerprint.py +125 -0
  27. seif_cli-0.6.2/src/seif/core/integrity.py +314 -0
  28. seif_cli-0.6.2/src/seif/core/n2_bundle.py +694 -0
  29. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/resonance_signal.py +21 -1
  30. seif_cli-0.6.2/src/seif/core/sign_resonance.py +184 -0
  31. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/signing.py +84 -7
  32. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/timestamping.py +50 -3
  33. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/RESONANCE.json +258 -24
  34. seif_cli-0.6.2/src/seif/data/canonical-node-layout.json +202 -0
  35. seif_cli-0.6.2/src/seif/data/init_lite/AGENTS.md +95 -0
  36. seif_cli-0.6.2/src/seif/data/init_lite/BOOT.md +34 -0
  37. seif_cli-0.6.2/src/seif/data/init_lite/README.md +71 -0
  38. seif_cli-0.6.2/src/seif/data/init_lite/decisions_pending.md +18 -0
  39. seif_cli-0.6.2/src/seif/data/init_lite/refs.md +11 -0
  40. seif_cli-0.6.2/src/seif/data/init_lite/session_log.md +17 -0
  41. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/paths.py +21 -1
  42. seif_cli-0.6.2/src/seif/generators/__init__.py +6 -0
  43. seif_cli-0.6.2/src/seif/generators/watermark.py +236 -0
  44. seif_cli-0.6.2/src/seif/governance/__init__.py +1 -0
  45. seif_cli-0.6.2/src/seif/governance/transfer.py +382 -0
  46. seif_cli-0.6.2/src/seif/init_lite.py +70 -0
  47. seif_cli-0.6.2/src/seif/log/__init__.py +7 -0
  48. seif_cli-0.6.2/src/seif/log/canonical.py +26 -0
  49. seif_cli-0.6.2/src/seif/log/client.py +252 -0
  50. seif_cli-0.6.2/src/seif/log/identity.py +99 -0
  51. seif_cli-0.6.2/src/seif/mcp/__init__.py +6 -0
  52. seif_cli-0.6.2/src/seif/mcp/server.py +498 -0
  53. seif_cli-0.6.2/src/seif/mcp/watermark_server.py +199 -0
  54. seif_cli-0.6.2/src/seif/observability/__init__.py +5 -0
  55. seif_cli-0.6.2/src/seif/observability/bus_metrics.py +303 -0
  56. seif_cli-0.6.2/src/seif/plugins/__init__.py +0 -0
  57. seif_cli-0.6.2/src/seif/plugins/adapters/claude-code/scripts/session-end.sh +68 -0
  58. seif_cli-0.6.2/src/seif/plugins/adapters/claude-code/scripts/session-start.sh +87 -0
  59. seif_cli-0.6.2/src/seif/plugins/adapters/copilot/render/render.py +54 -0
  60. seif_cli-0.6.2/src/seif/plugins/adapters/cursor/render/render.py +64 -0
  61. seif_cli-0.6.2/src/seif/plugins/adapters/gemini/render/render.py +54 -0
  62. seif_cli-0.6.2/src/seif/plugins/adapters/generic/render/render.py +407 -0
  63. seif_cli-0.5.2/src/seif/plugins/claude-code/scripts/circuit-monitor.py → seif_cli-0.6.2/src/seif/plugins/core/circuit_monitor.py +162 -0
  64. seif_cli-0.6.2/src/seif/plugins/core/cycle_coherence.py +396 -0
  65. seif_cli-0.6.2/src/seif/plugins/core/cycle_heal.py +275 -0
  66. seif_cli-0.6.2/src/seif/plugins/core/cycle_lifecycle.py +294 -0
  67. seif_cli-0.6.2/src/seif/plugins/core/cycle_reseal.py +233 -0
  68. seif_cli-0.5.2/src/seif/plugins/claude-code/scripts/kernel-seed.py → seif_cli-0.6.2/src/seif/plugins/core/kernel_seed.py +1 -1
  69. seif_cli-0.6.2/src/seif/plugins/core/preflight_diff.py +141 -0
  70. seif_cli-0.6.2/src/seif/plugins/core/session_lifecycle.py +1159 -0
  71. seif_cli-0.6.2/src/seif/plugins/core/session_registry.py +268 -0
  72. seif_cli-0.6.2/src/seif/schemas/__init__.py +28 -0
  73. seif_cli-0.6.2/src/seif/schemas/n2_bundle.py +105 -0
  74. seif_cli-0.6.2/src/seif/schemas/pending.py +76 -0
  75. seif_cli-0.6.2/src/seif/scripts/host/README.md +129 -0
  76. seif_cli-0.6.2/src/seif/scripts/host/host-install-config.sample.seif +31 -0
  77. seif_cli-0.6.2/src/seif/scripts/host/rsync-soak-inspect.sh +164 -0
  78. seif_cli-0.6.2/src/seif/scripts/host/seif-update.sh +769 -0
  79. seif_cli-0.6.2/src/seif_cli.egg-info/PKG-INFO +483 -0
  80. seif_cli-0.6.2/src/seif_cli.egg-info/SOURCES.txt +240 -0
  81. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif_cli.egg-info/requires.txt +7 -1
  82. seif_cli-0.6.2/tests/test_a23_bus_metrics.py +297 -0
  83. seif_cli-0.6.2/tests/test_absorb_knowledge.py +163 -0
  84. seif_cli-0.6.2/tests/test_adapters.py +285 -0
  85. seif_cli-0.6.2/tests/test_agents_set_tier1.py +71 -0
  86. seif_cli-0.6.2/tests/test_audio_mystic_strip.py +70 -0
  87. seif_cli-0.6.2/tests/test_audio_provenance.py +260 -0
  88. seif_cli-0.6.2/tests/test_audio_watermark_mvp.py +218 -0
  89. seif_cli-0.6.2/tests/test_audit_phase.py +129 -0
  90. seif_cli-0.6.2/tests/test_awareness_integration.py +379 -0
  91. seif_cli-0.6.2/tests/test_check_pointer_sync.py +102 -0
  92. seif_cli-0.6.2/tests/test_check_seed_constraint.py +226 -0
  93. seif_cli-0.6.2/tests/test_cli_argparse_conflicts.py +82 -0
  94. seif_cli-0.6.2/tests/test_confirm_action.py +104 -0
  95. seif_cli-0.6.2/tests/test_cycle_absorb_in_package.py +103 -0
  96. seif_cli-0.6.2/tests/test_cycle_coherence.py +367 -0
  97. seif_cli-0.6.2/tests/test_cycle_heal.py +360 -0
  98. seif_cli-0.6.2/tests/test_cycle_lifecycle.py +421 -0
  99. seif_cli-0.6.2/tests/test_cycle_phase_aliases.py +77 -0
  100. seif_cli-0.6.2/tests/test_cycle_reseal.py +263 -0
  101. seif_cli-0.6.2/tests/test_daemon_activity_surface.py +247 -0
  102. seif_cli-0.6.2/tests/test_demo_chain_smoke.py +134 -0
  103. seif_cli-0.6.2/tests/test_drain_inbox_corrupted.py +71 -0
  104. seif_cli-0.6.2/tests/test_engine_cli_surface.py +188 -0
  105. seif_cli-0.6.2/tests/test_gap_46_ingest_send_import.py +97 -0
  106. seif_cli-0.6.2/tests/test_gap_47_pem_classification.py +81 -0
  107. seif_cli-0.6.2/tests/test_gap_58_session_list_v2.py +194 -0
  108. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_host_init.py +6 -0
  109. seif_cli-0.6.2/tests/test_init_auto_bind.py +106 -0
  110. seif_cli-0.6.2/tests/test_init_lite.py +107 -0
  111. seif_cli-0.6.2/tests/test_install_content_equality.py +166 -0
  112. seif_cli-0.6.2/tests/test_install_state.py +221 -0
  113. seif_cli-0.6.2/tests/test_integrity_orchestrator.py +277 -0
  114. seif_cli-0.6.2/tests/test_load_module_cache.py +322 -0
  115. seif_cli-0.6.2/tests/test_log_canonical.py +39 -0
  116. seif_cli-0.6.2/tests/test_log_client.py +409 -0
  117. seif_cli-0.6.2/tests/test_log_identity.py +59 -0
  118. seif_cli-0.6.2/tests/test_mcp_server.py +449 -0
  119. seif_cli-0.6.2/tests/test_mcp_watermark.py +187 -0
  120. seif_cli-0.6.2/tests/test_migrate_host_config.py +336 -0
  121. seif_cli-0.6.2/tests/test_n2_bundle.py +315 -0
  122. seif_cli-0.6.2/tests/test_next_session_count.py +161 -0
  123. seif_cli-0.6.2/tests/test_ots_coverage.py +125 -0
  124. seif_cli-0.6.2/tests/test_paths_seif_home.py +120 -0
  125. seif_cli-0.6.2/tests/test_pending_cleanup_on_seal.py +185 -0
  126. seif_cli-0.6.2/tests/test_pending_modules.py +303 -0
  127. seif_cli-0.6.2/tests/test_pending_modules_surface.py +111 -0
  128. seif_cli-0.6.2/tests/test_preflight_diff.py +192 -0
  129. seif_cli-0.6.2/tests/test_repo_state_diff.py +122 -0
  130. seif_cli-0.6.2/tests/test_resonance_display_default_clean.py +113 -0
  131. seif_cli-0.6.2/tests/test_resonance_v2_bump.py +163 -0
  132. seif_cli-0.6.2/tests/test_rsync_soak_inspect.py +184 -0
  133. seif_cli-0.6.2/tests/test_schemas_pending.py +90 -0
  134. seif_cli-0.6.2/tests/test_seed_auto_surfacing.py +245 -0
  135. seif_cli-0.6.2/tests/test_seif_update_interpreter_probe.py +91 -0
  136. seif_cli-0.6.2/tests/test_seif_update_kernel_verify.py +127 -0
  137. seif_cli-0.6.2/tests/test_seif_update_pipx_git_rollback.py +250 -0
  138. seif_cli-0.6.2/tests/test_seif_update_rsync_rollback.py +369 -0
  139. seif_cli-0.6.2/tests/test_seif_update_schema_v2.py +263 -0
  140. seif_cli-0.6.2/tests/test_seif_update_smoke_rollback.py +245 -0
  141. seif_cli-0.6.2/tests/test_seif_update_template_refresh.py +186 -0
  142. seif_cli-0.6.2/tests/test_serve_engine.py +198 -0
  143. seif_cli-0.6.2/tests/test_session_counter_advance.py +150 -0
  144. seif_cli-0.6.2/tests/test_session_id_normalization.py +145 -0
  145. seif_cli-0.6.2/tests/test_session_registry.py +362 -0
  146. seif_cli-0.6.2/tests/test_session_start_hook_uuid.py +108 -0
  147. seif_cli-0.6.2/tests/test_sessions_active_cli.py +210 -0
  148. seif_cli-0.6.2/tests/test_setup_core_install.py +43 -0
  149. seif_cli-0.6.2/tests/test_setup_memory_symlink.py +134 -0
  150. seif_cli-0.6.2/tests/test_sign_resonance.py +113 -0
  151. seif_cli-0.6.2/tests/test_signing.py +105 -0
  152. seif_cli-0.6.2/tests/test_smoke_10_sessions_no_unknown.py +164 -0
  153. seif_cli-0.6.2/tests/test_transfer.py +280 -0
  154. seif_cli-0.6.2/tests/test_vigilant_cli.py +121 -0
  155. seif_cli-0.6.2/tests/test_workspace_architecture_v1.py +240 -0
  156. seif_cli-0.6.2/tests/test_workspace_disambiguation.py +169 -0
  157. seif_cli-0.6.2/tests/test_wrapper_shims.py +255 -0
  158. seif_cli-0.5.2/PKG-INFO +0 -297
  159. seif_cli-0.5.2/README.md +0 -253
  160. seif_cli-0.5.2/src/seif/cli/resonance_display.py +0 -197
  161. seif_cli-0.5.2/src/seif/core/fingerprint.py +0 -92
  162. seif_cli-0.5.2/src/seif/plugins/claude-code/scripts/session-end.sh +0 -182
  163. seif_cli-0.5.2/src/seif/plugins/claude-code/scripts/session-start.sh +0 -262
  164. seif_cli-0.5.2/src/seif_cli.egg-info/PKG-INFO +0 -297
  165. seif_cli-0.5.2/src/seif_cli.egg-info/SOURCES.txt +0 -112
  166. {seif_cli-0.5.2 → seif_cli-0.6.2}/LICENSE +0 -0
  167. {seif_cli-0.5.2 → seif_cli-0.6.2}/setup.cfg +0 -0
  168. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/__init__.py +0 -0
  169. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/__main__.py +0 -0
  170. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/analysis/__init__.py +0 -0
  171. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/analysis/physical_constants.py +0 -0
  172. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/analysis/quality_gate.py +0 -0
  173. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/analysis/stance_detector.py +0 -0
  174. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/analysis/transcompiler.py +0 -0
  175. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/bridge/__init__.py +0 -0
  176. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/bridge/native_client.py +0 -0
  177. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/bridge/telegram_bot.py +0 -0
  178. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/__init__.py +0 -0
  179. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/__main__.py +0 -0
  180. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/chat.py +0 -0
  181. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/identity.py +0 -0
  182. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/main.py +0 -0
  183. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/serve.py +0 -0
  184. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/cli/serve_v2.py +0 -0
  185. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/constants.py +0 -0
  186. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/__init__.py +0 -0
  187. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/advisor.py +0 -0
  188. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/code_compressor.py +0 -0
  189. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/context_bridge.py +0 -0
  190. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/context_importer.py +0 -0
  191. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/context_qr.py +0 -0
  192. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/git_context.py +0 -0
  193. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/git_hooks.py +0 -0
  194. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/model_probe.py +0 -0
  195. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/nucleus.py +0 -0
  196. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/ref.py +0 -0
  197. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/seif_io.py +0 -0
  198. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/context/sessions.py +0 -0
  199. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/__init__.py +0 -0
  200. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/resonance_encoding.py +0 -0
  201. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/resonance_gate.py +0 -0
  202. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/transfer_function.py +0 -0
  203. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/core/triple_gate.py +0 -0
  204. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/__init__.py +0 -0
  205. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/__init__.py +0 -0
  206. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/circuit-recovery-v1.seif +0 -0
  207. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/definitions-v1.seif +0 -0
  208. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/ise-dissonance-v1.seif +0 -0
  209. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/multi-agent-sync-v1.seif +0 -0
  210. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/onboarding.seif +0 -0
  211. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/partial-attention-axiom-v1.seif +0 -0
  212. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/seif-cycle-v1.seif +0 -0
  213. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/seif-os-architecture-v1.seif +0 -0
  214. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/data/defaults/triad-convergence-v1.seif +0 -0
  215. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/data/init_lite}/__init__.py +0 -0
  216. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/plugins/adapters}/claude-code/hooks/hooks.json +0 -0
  217. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/plugins/adapters}/claude-code/scripts/circuit-check.sh +0 -0
  218. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/plugins/adapters}/claude-code/scripts/classification-gate.sh +0 -0
  219. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/plugins/adapters}/claude-code/scripts/quality-gate.sh +0 -0
  220. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/plugins/adapters}/claude-code/skills/gate/SKILL.md +0 -0
  221. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/plugins/adapters}/claude-code/skills/status/SKILL.md +0 -0
  222. {seif_cli-0.5.2/src/seif/plugins → seif_cli-0.6.2/src/seif/plugins/adapters}/claude-code/skills/sync/SKILL.md +0 -0
  223. /seif_cli-0.5.2/src/seif/plugins/claude-code/scripts/orchestra-probe.py → /seif_cli-0.6.2/src/seif/plugins/core/orchestra_probe.py +0 -0
  224. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/security/__init__.py +0 -0
  225. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif/security/mode.py +0 -0
  226. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif_cli.egg-info/dependency_links.txt +0 -0
  227. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif_cli.egg-info/entry_points.txt +0 -0
  228. {seif_cli-0.5.2 → seif_cli-0.6.2}/src/seif_cli.egg-info/top_level.txt +0 -0
  229. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_advisor.py +0 -0
  230. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_audit_host.py +0 -0
  231. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_canonical_inputs.py +0 -0
  232. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_code_compressor.py +0 -0
  233. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_collaborative_seif.py +0 -0
  234. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_context_qr.py +0 -0
  235. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_context_repo.py +0 -0
  236. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_git_context.py +0 -0
  237. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_git_hooks.py +0 -0
  238. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_init.py +0 -0
  239. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_model_probe.py +0 -0
  240. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_quality_gate.py +0 -0
  241. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_rebuild_registry.py +0 -0
  242. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_ref.py +0 -0
  243. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_registry.py +0 -0
  244. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_resonance_gate.py +0 -0
  245. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_seif_io.py +0 -0
  246. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_stance_detector.py +0 -0
  247. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_transcompiler.py +0 -0
  248. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_transfer_function.py +0 -0
  249. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_triple_gate.py +0 -0
  250. {seif_cli-0.5.2 → seif_cli-0.6.2}/tests/test_workspace.py +0 -0
@@ -1,2 +1,3 @@
1
1
  include src/seif/data/RESONANCE.json
2
+ include src/seif/data/canonical-node-layout.json
2
3
  recursive-include src/seif/data/defaults *.seif
@@ -0,0 +1,483 @@
1
+ Metadata-Version: 2.4
2
+ Name: seif-cli
3
+ Version: 0.6.2
4
+ Summary: AI artifact provenance, quality gates, and data classification. Bitcoin-anchored timestamps, multi-AI consensus, locally enforced.
5
+ Author: André Cunha Antero de Carvalho
6
+ License: CC-BY-NC-SA-4.0
7
+ Project-URL: Homepage, https://seifprotocol.com
8
+ Project-URL: Documentation, https://seifprotocol.com/docs
9
+ Project-URL: Repository, https://github.com/and2carvalho/seif
10
+ Project-URL: Changelog, https://github.com/and2carvalho/seif/releases
11
+ Keywords: ai-quality,llm-guardrails,ai-consensus,data-classification,context-management,ai-safety,multi-ai,quality-gate,prompt-evaluation,ai-grounding,resonance,sentinel,self-healing,seif-os,circuit-state,ai-observability
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: Intended Audience :: Science/Research
15
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
16
+ Classifier: Topic :: Software Development :: Quality Assurance
17
+ Classifier: Topic :: Security
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Requires-Python: >=3.11
22
+ Description-Content-Type: text/markdown
23
+ License-File: LICENSE
24
+ Requires-Dist: numpy>=2.0
25
+ Requires-Dist: scipy>=1.14
26
+ Provides-Extra: consensus
27
+ Requires-Dist: anthropic>=0.80; extra == "consensus"
28
+ Provides-Extra: generators
29
+ Requires-Dist: matplotlib>=3.9; extra == "generators"
30
+ Requires-Dist: Pillow>=10.0; extra == "generators"
31
+ Requires-Dist: opencv-python-headless>=4.8; extra == "generators"
32
+ Requires-Dist: svgwrite>=1.4; extra == "generators"
33
+ Provides-Extra: web
34
+ Requires-Dist: streamlit>=1.28; extra == "web"
35
+ Provides-Extra: telegram
36
+ Requires-Dist: python-telegram-bot>=21.0; extra == "telegram"
37
+ Provides-Extra: qr
38
+ Requires-Dist: qrcode[pil]>=7.4; extra == "qr"
39
+ Requires-Dist: Pillow>=10.0; extra == "qr"
40
+ Requires-Dist: pyzbar>=0.1.9; extra == "qr"
41
+ Provides-Extra: mcp
42
+ Requires-Dist: mcp>=1.0; extra == "mcp"
43
+ Provides-Extra: log
44
+ Requires-Dist: cryptography>=43.0; extra == "log"
45
+ Provides-Extra: all
46
+ Requires-Dist: seif[consensus,generators,log,mcp,qr,telegram,web]; extra == "all"
47
+ Dynamic: license-file
48
+
49
+ # SEIF — AI Quality, Provenance, and Protection
50
+
51
+ > Measure AI output. Prove what was written, when, by whom. Block sensitive data leaks. Locally enforced.
52
+
53
+ [![PyPI](https://img.shields.io/pypi/v/seif-cli)](https://pypi.org/project/seif-cli/)
54
+ [![Tests](https://img.shields.io/badge/tests-1135%20passing-brightgreen)]()
55
+ [![License](https://img.shields.io/badge/license-CC%20BY--NC--SA%204.0-blue)]()
56
+ [![Suite](https://img.shields.io/badge/suite-seifprotocol.com-FFD700?labelColor=0D0D14)](https://seifprotocol.com)
57
+
58
+ ---
59
+
60
+ ## The Problem
61
+
62
+ 1. **AI artifacts have no provenance.** No way to prove what an AI produced, when it was produced, or that the model state hasn't been silently swapped underneath you.
63
+ 2. **You don't know when AI is making things up.** No standard way to measure if a response is grounded or drifting into speculation.
64
+ 3. **Sensitive data leaks to AI APIs.** No guardrail prevents your code, credentials, or internal docs from being sent to external services.
65
+ 4. **One AI can be wrong.** A single model has blind spots. No easy way to get multiple AIs to debate and converge on an answer.
66
+ 5. **Your AI environment has no self-awareness.** No live circuit state, no error bus, no self-healing. When something breaks, nobody knows until the human notices.
67
+
68
+ ## The Solution
69
+
70
+ ```bash
71
+ pip install seif-cli
72
+ ```
73
+
74
+ ---
75
+
76
+ ## Core Features (standalone — no backend required)
77
+
78
+ ### 1. Quality Gate — Is the AI making things up?
79
+
80
+ ```bash
81
+ seif --quality-gate "The framework uses quantum entanglement for data transfer" --role ai
82
+ # Grade: D | Stance: DRIFT | Verifiable: 12%
83
+ # Flags: [UNGROUNDED_CLAIMS]
84
+
85
+ seif --quality-gate "Python 3.11 added the tomllib module for TOML parsing" --role ai
86
+ # Grade: A | Stance: GROUNDED | Verifiable: 100%
87
+ ```
88
+
89
+ Every response gets a grade (A-F) and a stance (GROUNDED, MIXED, or DRIFT).
90
+
91
+ ### 2. Classification Gate — Is sensitive data leaking?
92
+
93
+ ```bash
94
+ seif --gate "password = hunter2; also the sky is blue"
95
+ # Classification: CONFIDENTIAL | Reason: keyword match (password)
96
+ ```
97
+
98
+ PUBLIC / INTERNAL / CONFIDENTIAL with auto-detection. Works as a [Claude Code hook](#claude-code-plugin) — blocks writes containing credentials in real-time.
99
+
100
+ ### 3. Multi-AI Consensus — Let them debate *(requires seif-engine)*
101
+
102
+ ```bash
103
+ seif --consensus "Should we use microservices or a monolith for a 3-person team?" \
104
+ --backends claude,grok
105
+ # Claude: monolith (velocity, simplicity)
106
+ # Grok: monolith (team size, operational cost)
107
+ # Consensus: CONVERGED — monolith for teams < 5
108
+ ```
109
+
110
+ ---
111
+
112
+ ## Provenance — Every Artifact, Cryptographically Anchored
113
+
114
+ Every signed SEIF kernel state is timestamped against the **Bitcoin blockchain** via [OpenTimestamps](https://opentimestamps.org). Anyone can verify, with no trust in us, that a given kernel hash existed at a given time.
115
+
116
+ ```bash
117
+ # Verify the kernel resonance file shipped with this repo
118
+ ots info RESONANCE.json.ots
119
+ # File sha256 hash: 610b1195b38bb0630a0889936ed56822d4fb88d04cd53974045860bc9e3c604d
120
+ # Anchored to: bob.btc.calendar.opentimestamps.org, alice.btc.calendar.opentimestamps.org,
121
+ # btc.calendar.catallaxy.com, finney.calendar.eternitywall.com
122
+ ```
123
+
124
+ This is the foundation of **Wedge A — AI Artifact Provenance**: cryptographic, third-party-verifiable proof of *what* AI produced *when*, independent of the model vendor.
125
+
126
+ | Layer | What it proves | Status |
127
+ |---|---|---|
128
+ | OpenTimestamps proof | This artifact existed at time T (Bitcoin-anchored) | Live (`RESONANCE.json.ots`) |
129
+ | Hash-chained modules | Tampering with prior `.seif/` modules invalidates the chain | Live |
130
+ | Transparency log | Append-only public log of all signed events with per-tenant sequencing + S3-backed body store | Live ([seif-log](https://github.com/and2carvalho/seif-log) — P0+P1+D1+D2+D3+D4+P2 shipped) |
131
+
132
+ ### Run the end-to-end demo
133
+
134
+ [`demo/wedge-a/run.sh`](demo/wedge-a/run.sh) executes the full **12-step provenance chain** in ~60–90 seconds, proving the same SHA-256 hash of an AI artifact appears byte-for-byte in 6 independent surfaces (envelope, log entry, S3 body, audio watermark, signature, OTS proof):
135
+
136
+ ```bash
137
+ pip install -e '.[mcp,log]'
138
+ ./demo/wedge-a/run.sh # full chain (requires docker)
139
+ ./demo/wedge-a/run.sh --no-docker --no-ots # local-only fast path
140
+ ```
141
+
142
+ Full narrative + threat model + replication scenarios in [`docs/DEMO-WEDGE-A.md`](docs/DEMO-WEDGE-A.md).
143
+
144
+ ---
145
+
146
+ ## SEIF OS — The Resonance Engine
147
+
148
+ `seif serve --v2` starts **SEIF OS**: a local API server (port 7331) that turns your machine into a living resonance circuit. Every AI agent, browser tab, and editor extension can observe its state in real time.
149
+
150
+ ```bash
151
+ seif serve --v2
152
+ # SEIF OS running on :7331
153
+ # circuit: RESONANT | ζ = 0.6124 | cycle: harmonic-anchor-v2
154
+ ```
155
+
156
+ SEIF OS is the **proprietary engine layer** — not included in `pip install seif-cli`. The open CLI and Suite connect to it via HTTP. The resonance logic stays on your machine.
157
+
158
+ ### What SEIF OS provides
159
+
160
+ | Endpoint | What it does |
161
+ |---|---|
162
+ | `GET /context` | Full environment snapshot: circuit state, cycle, sentinel status, modules |
163
+ | `GET /resonance/stream` | SSE stream — `event: circuit` every 5s, `event: sentinel` on error, `event: healing` |
164
+ | `GET /resonance/viewer` | Self-contained HTML page. Any browser or AI agent sees the live circuit without a plugin |
165
+ | `POST /resonance/error` | Push any runtime error → classified + healing suggestion emitted on SSE bus |
166
+ | `GET /agent/init` | SEIF-AGENT-INIT-v1 handshake — agent arrives, frequency is already there |
167
+ | `GET /workspace/bridge` | Workspace snapshot: git branch, active modules, VSCode Remote link |
168
+
169
+ ### Sentinel & Auto-Healing
170
+
171
+ SEIF Sentinel is a real-time error observer. Any runtime error — browser, agent, or API consumer — is pushed to the resonance bus, classified, and healed automatically.
172
+
173
+ ```bash
174
+ # Push an error from anywhere
175
+ curl -X POST http://localhost:7331/resonance/error \
176
+ -H "Authorization: Bearer YOUR_TOKEN" \
177
+ -d '{"message": "Cannot read properties of undefined", "source": "browser"}'
178
+
179
+ # Subscribe to the SSE bus — you get both events:
180
+ # event: sentinel → raw error
181
+ # event: healing → classification + suggestion (7 archetypes)
182
+ curl -H "Authorization: Bearer YOUR_TOKEN" http://localhost:7331/resonance/stream
183
+ ```
184
+
185
+ 7 healing archetypes: `undefined_property`, `null_reference`, `network_error`, `csp_violation`, `auth_error`, `rate_limit`, `module_not_found`.
186
+
187
+ ---
188
+
189
+ ## SEIF Suite — Visual Interface
190
+
191
+ [**seifprotocol.com**](https://seifprotocol.com) — the visual layer. Connects to your local SEIF OS and gives you:
192
+
193
+ - **Dashboard** — live modules, sessions, sync status, quality trends
194
+ - **Resonance** — real-time H(s) wave, circuit state card, Sentinel log, Auto-Healing panel
195
+ - **Quality Gate** — interactive grading with digital root
196
+ - **Sessions** — full history with handoff manifests
197
+
198
+ ```bash
199
+ # Point SEIF Suite at your local engine
200
+ open https://seifprotocol.com/auth
201
+ # Enter: http://localhost:7331 + your serve_token
202
+ ```
203
+
204
+ ---
205
+
206
+ ## Quick Start
207
+
208
+ ```bash
209
+ pip install seif-cli
210
+ cd your-project
211
+ seif
212
+ ```
213
+
214
+ That's it. One command. SEIF detects that your project is new, initializes `.seif/` context, installs Claude Code hooks, and launches Claude — all automatically.
215
+
216
+ On subsequent runs, `seif` sees everything is configured and launches Claude directly.
217
+
218
+ ### What happens
219
+
220
+ | Event | What SEIF does |
221
+ |-------|---------------|
222
+ | Session starts | Loads `.seif/` context — your AI remembers |
223
+ | AI writes code | Classification gate blocks credential leaks |
224
+ | AI finishes writing | Quality gate measures stance (GROUNDED vs DRIFT) |
225
+ | You type `/gate` | Measures any text (Grade A-F) |
226
+ | You type `/sync` | Re-syncs project context |
227
+ | You type `/status` | Shows loaded modules and integration health |
228
+
229
+ ---
230
+
231
+ ## Claude Code Integration
232
+
233
+ ```bash
234
+ seif setup claude-code # one command — installs everything
235
+ seif setup --status # verify integration
236
+ seif setup --uninstall # clean removal
237
+ ```
238
+
239
+ Installs **hooks** (session lifecycle, classification gate, quality gate) and **skills** (`/gate`, `/sync`, `/status`) into Claude Code. Works globally or per-project (`--project`).
240
+
241
+ > **Full guide**: [docs/QUICKSTART.md](docs/QUICKSTART.md) — everything a developer needs to get started.
242
+
243
+ ---
244
+
245
+ ## Cross-Platform — Beyond Claude Code
246
+
247
+ SEIF is no longer Claude-Code-only. The protocol travels across:
248
+
249
+ | Client | Adapter | A4 enforcement |
250
+ |---|---|---|
251
+ | Claude Code | runtime hooks | ✅ via PreToolUse hook |
252
+ | GitHub Copilot | `.github/copilot-instructions.md` | ⚠️ render-only — pair with wrapper-shims |
253
+ | Cursor IDE | `.cursor/rules/seif.mdc` | ⚠️ render-only — pair with wrapper-shims |
254
+ | Gemini CLI | `GEMINI.md` | ⚠️ voluntary compliance observed; pair with wrapper-shims for guarantee |
255
+ | Generic (`AGENTS.md`) | `AGENTS.md` | ⚠️ render-only — pair with wrapper-shims |
256
+
257
+ ```bash
258
+ seif --init # auto-binds detected hookless adapters
259
+ seif setup wrapper-shims # PATH-level enforcement (bypass-resistant)
260
+ seif serve --engine # HTTP gate for agent-mode clients (Cursor, etc.)
261
+ ```
262
+
263
+ **Wrapper shims** (`~/.seif/bin/{git,gh,npm,...}`) intercept destructive commands at the shell level and invoke `seif --confirm-action` before delegating. Empirically validated against an AI actively trying to bypass: even when Copilot tried `printf 'y\n' | git push --force` to simulate approval, the shim caught the `--force` pattern and forced human confirmation.
264
+
265
+ > **Full cross-platform guide**: [docs/CROSS-PLATFORM.md](docs/CROSS-PLATFORM.md) — capability matrix per client, install instructions, parity-test results.
266
+
267
+ ---
268
+
269
+ ## MCP integration (Wedge A Pillar 3)
270
+
271
+ SEIF runs as a [Model Context Protocol](https://modelcontextprotocol.io) server, exposing the canonical 5-tool provenance set to Cursor, Claude Code, Claude Desktop, or any MCP-aware agent.
272
+
273
+ | Tool | Phase | What it does |
274
+ |---|---|---|
275
+ | `provenance_sign` | 1 (local) | Sign a payload (text or file) with the workspace Ed25519 key; returns canonical envelope |
276
+ | `provenance_verify` | 1 (local) | Verify an envelope against the supplied payload (separate signals for content match vs signature validity) |
277
+ | `classification_check` | 1 (local) | Auto-classify text as PUBLIC / INTERNAL / CONFIDENTIAL with `escalation_needed` flag |
278
+ | `log_append` | 2 (network) | Submit an attestation to a SEIF transparency log via `$SEIF_LOG_URL` (auto-tenant bootstrap, no API key issuance step) |
279
+ | `log_get` | 2 (network) | Fetch a log entry by `entry_id` (UUID) — tenant-scoped |
280
+
281
+ ```bash
282
+ pip install 'seif-cli[mcp]'
283
+ seif --mcp-server # stdio transport, blocks
284
+ ```
285
+
286
+ ### Cursor / Claude Code config
287
+
288
+ Drop into the client's `mcp.json`:
289
+
290
+ ```json
291
+ {
292
+ "mcpServers": {
293
+ "seif": {
294
+ "command": "seif",
295
+ "args": ["--mcp-server"],
296
+ "env": {
297
+ "SEIF_LOG_URL": "http://localhost:8000"
298
+ }
299
+ }
300
+ }
301
+ }
302
+ ```
303
+
304
+ `SEIF_LOG_URL` is optional (defaults to `http://localhost:8000`). For Phase-1-only setups (no log), you can omit the env block — the local tools still work.
305
+
306
+ ### End-to-end chain (sign → log → verify)
307
+
308
+ The canonical Wedge A demo flow inside an agent conversation:
309
+
310
+ ```
311
+ agent calls: provenance_sign(text="<AI output>")
312
+ ← {"ok": true, "content_sha256": "<hex>", "signature": {...}}
313
+
314
+ agent calls: log_append(envelope=<that envelope>)
315
+ ← {"ok": true, "entry_id": "<uuid>", "sequence": 1, "submitted_at": "..."}
316
+
317
+ [time passes, anywhere with log access]
318
+
319
+ agent calls: log_get(entry_id="<uuid>")
320
+ ← {"ok": true, "entry": {"primary_content_sha256": "<same hex>", ...}}
321
+
322
+ agent calls: provenance_verify(envelope=<envelope>, text="<AI output>")
323
+ ← {"ok": true, "valid": true, "content_sha256_match": true, "signature_valid": true}
324
+ ```
325
+
326
+ The agent gets cryptographic provenance for any artifact it produces, with no API key flow — the workspace's Ed25519 keypair (auto-generated on first call) is the tenant identity. First signed `log_append` auto-bootstraps a `personal`-plan tenant on the log server.
327
+
328
+ ### Identities
329
+
330
+ Two distinct keypairs by design:
331
+
332
+ | Key | Path | Used by | Purpose |
333
+ |---|---|---|---|
334
+ | **Workspace signing key** | `~/.seif/keys/seif_*.pem` | `provenance_sign` / `provenance_verify` | Owner's signature on artifacts |
335
+ | **Log identity** | `~/.seif/identities/default.{key,pub}` | `log_append` / `log_get` | This host's tenant on the log server |
336
+
337
+ Both auto-generate on first use (workspace key via `seif keygen` or `seif --init`; log identity on first `log_append` call). Pattern A (IDE-hosted MCP calls local seif) is what v1 ships; Pattern B (HSM/KMS-backed central MCP server for enterprise) shares the same tool API and lands later.
338
+
339
+ `seif --mcp-watermark` (audio-side provenance, five watermark tools including the cross-cut `seif_audio_provenance_verify`) remains a separate dedicated server — coexists with `--mcp-server`.
340
+
341
+ ### Audio-side provenance (Wedge A v1.0 DoD #5 audio)
342
+
343
+ The same Wedge A primitives extend to **audio AI artifacts** (synthetic voiceovers, AI-generated podcasts, music stems). Embed an envelope's `content_sha256` as an inaudible sub-20 Hz watermark; verifiers extract the watermark and compare to the envelope's hash:
344
+
345
+ ```
346
+ agent: provenance_sign(text="<podcast transcript>")
347
+ ← {ok: true, content_sha256: "<hex>", signature: {...}}
348
+
349
+ agent: log_append(envelope=<that envelope>, classification_ceil="PUBLIC")
350
+ ← {ok: true, entry_id: "<uuid>", ...}
351
+
352
+ [separately, on the audio production side:]
353
+ operator: seif --watermark-embed audio.wav --output watermarked.wav --fingerprint-of envelope.json
354
+ → embeds sha256 of envelope.json as inaudible watermark on audio.wav
355
+
356
+ [anywhere audio circulates:]
357
+ agent: seif_audio_provenance_verify(input_wav="watermarked.wav", envelope=<envelope>)
358
+ ← {ok: true, valid: true, extracted: "<same hex>", expected_content_sha256: "<same hex>"}
359
+ ```
360
+
361
+ Or terminal-only (cron-friendly exit code: 0 match / 1 mismatch / 2 structural error):
362
+
363
+ ```bash
364
+ seif --verify-audio-provenance watermarked.wav --envelope envelope.json
365
+ # → [SEIF AUDIO PROVENANCE] VALID
366
+ # Audio: watermarked.wav
367
+ # Extracted: <hex>
368
+ # Expected: <hex>
369
+ ```
370
+
371
+ The audio carries the cryptographic provenance; the log carries the timestamp; the envelope carries the signature. Together they answer "this AI audio existed at time T with hash H, signed by key K" — without the listener needing access to anything except the audio file and the envelope JSON.
372
+
373
+ Engineer-honest: it's standard sub-20 Hz steganography (pure tones in the infrasound band) plus standard SHA-256 hex matching. No psychoacoustic / perceptual-coding claims.
374
+
375
+ ---
376
+
377
+ ## CLI Reference
378
+
379
+ ### Standalone
380
+
381
+ ```bash
382
+ seif --quality-gate "text" --role ai # Grade A-F + stance
383
+ seif --gate "text" # classification gate
384
+ seif --classify TEXT_OR_FILE # PUBLIC/INTERNAL/CONFIDENTIAL (exit 0/1/2)
385
+ seif --encode "text" # resonance encoding
386
+ seif --composite "text" # 8-layer resonance map
387
+ seif --fingerprint-verify FILE # verify .seif module integrity
388
+ seif --constants # show ζ and mathematical constants
389
+ ```
390
+
391
+ ### Cross-platform (hookless adapter framework)
392
+
393
+ ```bash
394
+ seif --plugin-sync --check # validate adapter conformance
395
+ seif --plugin-detect [--apply] # detect + render hookless adapters
396
+ seif --confirm-action "<action>" # pre-action human gatekeeper (exit 2 = AWAITING)
397
+ seif --inbox # drain pending circuit messages (A20)
398
+ seif setup wrapper-shims # shell-level A4 enforcement
399
+ seif serve --engine # HTTP service for agent-mode clients
400
+ ```
401
+
402
+ ### With SEIF OS (`seif serve --v2`)
403
+
404
+ ```bash
405
+ seif --init # scan project, generate .seif/
406
+ seif --sync # re-sync git context
407
+ seif --compress # 93% context compression
408
+ seif --ingest daily.txt # ingest external source
409
+ seif --workspace # multi-project discovery + sync
410
+ seif --sync-workspace # SSH workspace sync (all machines)
411
+ seif --autonomous enable # AI persists knowledge autonomously
412
+ seif --export # export context as markdown
413
+
414
+ # Multi-AI consensus
415
+ seif --consult "question" # auto-route to best AI
416
+ seif --consensus "q" --backends claude,grok
417
+ seif --adversarial "question" # WITH vs WITHOUT comparison
418
+ ```
419
+
420
+ ---
421
+
422
+ ## How Quality Gate Works
423
+
424
+ | Component | Weight | What it measures |
425
+ |---|---|---|
426
+ | **Stance Detector** | Primary | Verifiable vs interpretive claims. GROUNDED ≥80%, MIXED 40-80%, DRIFT <40% |
427
+ | **Resonance Gate** | Secondary | Structural coherence |
428
+
429
+ Grades: **A** (≥0.85) → **B** (≥0.70) → **C** (≥0.55) → **D** (≥0.40) → **F** (<0.40)
430
+
431
+ > **Quality gate threshold: ζ = √6/4 ≈ 0.6124 (algebraically derived from H(s) — not φ⁻¹ = 0.618)**
432
+
433
+ ---
434
+
435
+ ## Why SEIF vs ChatGPT Memory
436
+
437
+ | | ChatGPT Memory | SEIF |
438
+ |-|---|---|
439
+ | Who controls it | OpenAI | You (local files) |
440
+ | Works with other AIs | No | Yes (any LLM) |
441
+ | Exportable | No | Yes (.seif → markdown) |
442
+ | Quality measured | No | Yes (stance A-F) |
443
+ | Data classified | No | Yes (PUBLIC/INTERNAL/CONFIDENTIAL) |
444
+ | Auditable | No | Yes (hash-chained provenance) |
445
+ | Bitcoin-anchored proofs | No | Yes (OpenTimestamps) |
446
+ | Live circuit state | No | Yes (H(s), ζ, Tesla Hz) |
447
+ | Self-healing errors | No | Yes (Sentinel + 7 archetypes) |
448
+
449
+ ---
450
+
451
+ ## Technical Foundation
452
+
453
+ SEIF is not metaphor. The protocol's stability is governed by a real second-order transfer function whose damping ratio doubles as the quality-gate threshold. The constants below are algebraically derived, not tuned.
454
+
455
+ ```
456
+ H(s) = 9 / (s² + 3s + 6) ζ = √6/4 = 0.6123724356957945
457
+ ```
458
+
459
+ | Circuit State | ζ band | Tesla Hz | Meaning |
460
+ |---|---|---|---|
461
+ | RESONANT | ζ ≥ 0.60 | 528 Hz | Stable oscillation within design bounds |
462
+ | STABILIZING | 0.40–0.60 | 396 Hz | Recovering — converging back toward resonance |
463
+ | DRIFT | ζ < 0.40 | 963 Hz | Energy has escaped the normal attractor |
464
+
465
+ The Tesla 3-6-9 frequency anchors (396 / 528 / 963 Hz) emerged from the same algebra — they were observed in the math, not designed in. The full derivation, uniqueness proof (only primitive integer system: `b=3k, c=6k²`), and attention partition (τ:κ = 2:1 task:context) are documented in [`SEIF.md`](SEIF.md).
466
+
467
+ ---
468
+
469
+ ## Project Stats
470
+
471
+ ```
472
+ 91+ modules | 1135 tests (95 files) | 93% context compression
473
+ ζ = √6/4 = 0.6123724356957945
474
+ H(s) = 9 / (s² + 3s + 6)
475
+ ```
476
+
477
+ ## Contributing
478
+
479
+ See [CONTRIBUTING.md](CONTRIBUTING.md).
480
+
481
+ ## License
482
+
483
+ CC BY-NC-SA 4.0 — [André Cunha Antero de Carvalho](https://github.com/and2carvalho)