sqac 0.1.0__py3-none-any.whl
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.
- sqac/__init__.py +99 -0
- sqac/__main__.py +4 -0
- sqac/autobuild.py +615 -0
- sqac/cli.py +268 -0
- sqac/continuity.py +279 -0
- sqac/dms.py +224 -0
- sqac/encoder.py +259 -0
- sqac/format.py +471 -0
- sqac/ingest.py +158 -0
- sqac/injection.py +430 -0
- sqac/kvcache.py +166 -0
- sqac/mcp_setup.py +254 -0
- sqac/offloader.py +554 -0
- sqac/rack.py +522 -0
- sqac/server.py +584 -0
- sqac/skills.py +454 -0
- sqac/static_encoder.py +282 -0
- sqac/store.py +714 -0
- sqac-0.1.0.dist-info/METADATA +1059 -0
- sqac-0.1.0.dist-info/RECORD +25 -0
- sqac-0.1.0.dist-info/WHEEL +5 -0
- sqac-0.1.0.dist-info/entry_points.txt +4 -0
- sqac-0.1.0.dist-info/licenses/LICENSE +72 -0
- sqac-0.1.0.dist-info/top_level.txt +2 -0
- sqac_mcp.py +800 -0
sqac/__init__.py
ADDED
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
"""SQAC — hot-swappable VSA memory cartridges.
|
|
2
|
+
|
|
3
|
+
Public API:
|
|
4
|
+
SqacStore — hybrid exact + fuzzy memory store
|
|
5
|
+
ContextOffloader — ephemeral turn bucket (observe/save/recall)
|
|
6
|
+
CartridgeRack — named cartridges + kind-based routing
|
|
7
|
+
BSCEncoder — zero-dependency binary spatter-code encoder
|
|
8
|
+
read/write — .sqac binary format v1
|
|
9
|
+
extract_project_units / build_store / track_once / track
|
|
10
|
+
— project auto-build and realtime tracking
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
from .autobuild import (
|
|
14
|
+
build_store,
|
|
15
|
+
extract_project_units,
|
|
16
|
+
track,
|
|
17
|
+
track_once,
|
|
18
|
+
_sync_rack,
|
|
19
|
+
)
|
|
20
|
+
from .continuity import ContinuityStore, bootstrap_packet, detect_host, server_instructions
|
|
21
|
+
from .dms import DMS, UtilityWeights
|
|
22
|
+
from .encoder import BSCEncoder
|
|
23
|
+
from .format import CartridgeHeader, read_cartridge, write_cartridge
|
|
24
|
+
from .offloader import ContextOffloader
|
|
25
|
+
from .rack import CartridgeRack, GradedExchange, RackError, graduation_pass
|
|
26
|
+
from .store import (
|
|
27
|
+
KIND_DOC,
|
|
28
|
+
KIND_FACT,
|
|
29
|
+
KIND_GENERIC,
|
|
30
|
+
KIND_NAMES,
|
|
31
|
+
KIND_SKILL,
|
|
32
|
+
KIND_TURN,
|
|
33
|
+
Hit,
|
|
34
|
+
SqacStore,
|
|
35
|
+
resolve_kind,
|
|
36
|
+
)
|
|
37
|
+
|
|
38
|
+
__version__ = "0.1.0"
|
|
39
|
+
|
|
40
|
+
_KVCACHE_NAMES = frozenset(
|
|
41
|
+
{
|
|
42
|
+
"KVEstimate",
|
|
43
|
+
"estimate_sparse_recall",
|
|
44
|
+
"estimate_sweep",
|
|
45
|
+
"known_models",
|
|
46
|
+
"kv_bytes_per_token",
|
|
47
|
+
"model_kv_bytes_per_token",
|
|
48
|
+
"table",
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
def __getattr__(name: str):
|
|
54
|
+
"""Lazily import sqac.kvcache names so `python -m sqac.kvcache` stays clean
|
|
55
|
+
(eager import would pre-load the submodule and trigger a benign CPython
|
|
56
|
+
'found in sys.modules' RuntimeWarning)."""
|
|
57
|
+
if name in _KVCACHE_NAMES:
|
|
58
|
+
from . import kvcache
|
|
59
|
+
|
|
60
|
+
return getattr(kvcache, name)
|
|
61
|
+
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
|
|
62
|
+
|
|
63
|
+
__all__ = [
|
|
64
|
+
"SqacStore",
|
|
65
|
+
"ContextOffloader",
|
|
66
|
+
"CartridgeRack",
|
|
67
|
+
"BSCEncoder",
|
|
68
|
+
"DMS",
|
|
69
|
+
"UtilityWeights",
|
|
70
|
+
"KVEstimate",
|
|
71
|
+
"estimate_sparse_recall",
|
|
72
|
+
"estimate_sweep",
|
|
73
|
+
"known_models",
|
|
74
|
+
"kv_bytes_per_token",
|
|
75
|
+
"model_kv_bytes_per_token",
|
|
76
|
+
"CartridgeHeader",
|
|
77
|
+
"read_cartridge",
|
|
78
|
+
"write_cartridge",
|
|
79
|
+
"GradedExchange",
|
|
80
|
+
"RackError",
|
|
81
|
+
"graduation_pass",
|
|
82
|
+
"KIND_DOC",
|
|
83
|
+
"KIND_FACT",
|
|
84
|
+
"KIND_SKILL",
|
|
85
|
+
"KIND_TURN",
|
|
86
|
+
"KIND_GENERIC",
|
|
87
|
+
"KIND_NAMES",
|
|
88
|
+
"Hit",
|
|
89
|
+
"resolve_kind",
|
|
90
|
+
"extract_project_units",
|
|
91
|
+
"build_store",
|
|
92
|
+
"track_once",
|
|
93
|
+
"track",
|
|
94
|
+
"_sync_rack",
|
|
95
|
+
"ContinuityStore",
|
|
96
|
+
"bootstrap_packet",
|
|
97
|
+
"detect_host",
|
|
98
|
+
"server_instructions",
|
|
99
|
+
]
|
sqac/__main__.py
ADDED