mcp-osiris 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.
Files changed (47) hide show
  1. mcp_osiris-0.1.0.dist-info/METADATA +384 -0
  2. mcp_osiris-0.1.0.dist-info/RECORD +47 -0
  3. mcp_osiris-0.1.0.dist-info/WHEEL +4 -0
  4. mcp_osiris-0.1.0.dist-info/entry_points.txt +4 -0
  5. mcp_osiris-0.1.0.dist-info/licenses/LICENSE +21 -0
  6. osiris/__init__.py +9 -0
  7. osiris/__main__.py +28 -0
  8. osiris/audit.py +366 -0
  9. osiris/bench/__init__.py +4 -0
  10. osiris/bench/fixtures/src/Profile.psm1 +359 -0
  11. osiris/bench/fixtures/tests/Profile.Tests.ps1 +36 -0
  12. osiris/bench/run_bench.py +569 -0
  13. osiris/cli.py +175 -0
  14. osiris/config.py +171 -0
  15. osiris/core/__init__.py +24 -0
  16. osiris/core/adaptive.py +213 -0
  17. osiris/core/compaction.py +126 -0
  18. osiris/core/compass.py +147 -0
  19. osiris/core/db.py +218 -0
  20. osiris/core/errors.py +27 -0
  21. osiris/core/events.py +275 -0
  22. osiris/core/fileops.py +94 -0
  23. osiris/core/handoff.py +166 -0
  24. osiris/core/ids.py +89 -0
  25. osiris/core/invariants.py +195 -0
  26. osiris/core/ledger.py +303 -0
  27. osiris/core/loopguard.py +276 -0
  28. osiris/core/manifest.py +70 -0
  29. osiris/core/memory.py +162 -0
  30. osiris/core/policy.py +105 -0
  31. osiris/core/prefix.py +374 -0
  32. osiris/core/pressure.py +101 -0
  33. osiris/core/prune.py +215 -0
  34. osiris/core/query.py +277 -0
  35. osiris/core/redact.py +83 -0
  36. osiris/core/refs.py +251 -0
  37. osiris/core/runtime.py +191 -0
  38. osiris/core/task_state.py +311 -0
  39. osiris/core/tokens.py +58 -0
  40. osiris/dashboard/__init__.py +8 -0
  41. osiris/dashboard/server.py +825 -0
  42. osiris/dashboard/web/app.js +420 -0
  43. osiris/dashboard/web/index.html +144 -0
  44. osiris/dashboard/web/logo.svg +21 -0
  45. osiris/dashboard/web/styles.css +196 -0
  46. osiris/server.py +1597 -0
  47. osiris/tools/__init__.py +39 -0
@@ -0,0 +1,384 @@
1
+ Metadata-Version: 2.5
2
+ Name: mcp-osiris
3
+ Version: 0.1.0
4
+ Summary: OSIRIS — context engine cache-aware pour agents IA (serveur MCP local, provider-agnostic).
5
+ Project-URL: Homepage, https://github.com/MlkBlk-IT/osiris
6
+ Project-URL: Repository, https://github.com/MlkBlk-IT/osiris
7
+ Project-URL: Issues, https://github.com/MlkBlk-IT/osiris/issues
8
+ Project-URL: Changelog, https://github.com/MlkBlk-IT/osiris/blob/main/CHANGELOG.md
9
+ Author: Malik Belkacemi
10
+ License-Expression: MIT
11
+ License-File: LICENSE
12
+ Keywords: agents,context-engine,cost,mcp,memory,osiris,prompt-cache
13
+ Classifier: Development Status :: 4 - Beta
14
+ Classifier: Intended Audience :: Developers
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
18
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
19
+ Requires-Python: >=3.12
20
+ Requires-Dist: fastmcp>=2.0.0
21
+ Requires-Dist: httpx>=0.27.0
22
+ Requires-Dist: mcp>=1.2.0
23
+ Requires-Dist: pydantic>=2.0.0
24
+ Requires-Dist: pyyaml>=6.0
25
+ Requires-Dist: rich>=13.0.0
26
+ Requires-Dist: tiktoken>=0.7.0
27
+ Provides-Extra: dev
28
+ Requires-Dist: pytest-asyncio>=0.23.0; extra == 'dev'
29
+ Requires-Dist: pytest>=8.0.0; extra == 'dev'
30
+ Requires-Dist: ruff>=0.5.0; extra == 'dev'
31
+ Description-Content-Type: text/markdown
32
+
33
+ <p align="center">
34
+ <img src="https://raw.githubusercontent.com/MlkBlk-IT/osiris/main/docs/mlkblk-banner-v2.svg" width="100%" alt="OSIRIS — Cache-aware context engine & state governor for AI agents" />
35
+ </p>
36
+
37
+ # OSIRIS
38
+
39
+ **Cache-aware context engine & state governor for AI agents.** Standard MCP server, local-first, independent of any model provider.
40
+
41
+ > OSIRIS makes AI agents cheaper, faster, and more reliable: fewer tokens, fewer loops, zero unnecessary tools, and zero loss of context.
42
+
43
+ OSIRIS does not replace your other MCP servers (filesystem, Git, GitHub, shell, browser…). It **coexists** alongside them and drastically cuts what they cost in prompt context.
44
+
45
+ ---
46
+
47
+ ## 1. The Core Architectural Constraint
48
+
49
+ An MCP server **never sees** the final prompt assembled by the client host. It only sees what the agent sends to it. Therefore, OSIRIS cannot:
50
+
51
+ | What we would want | What a standard MCP server can actually do |
52
+ |---|---|
53
+ | Write directly into the prompt | Produce canonical state and **have the agent carry it** |
54
+ | Erase past conversation turns | Decide what to externalize **for future turns** |
55
+ | Hide another MCP server's tools | **Recommend** via Tool Compass |
56
+ | Hard-cap prompt tokens | Block an **action** (invariants, budget enforcement) |
57
+
58
+ The promise is honest: OSIRIS provides **stable state and an enforceable safety contract**, not a client prompt builder.
59
+
60
+ ---
61
+
62
+ ## 2. Sealed Manifest — The Core Design
63
+
64
+ `osiris.plan` returns a deterministic block (~120 tokens) that the agent carries at a fixed position in its context window:
65
+
66
+ ```text
67
+ OSIRIS/1 task=7c3f obj="fix PowerShell profile bug" plan=3/7
68
+ inv=4 files=6 refs=9 dec=2 budget=ok
69
+ SEAL=sha256:3f9a1c…c21b
70
+ ```
71
+
72
+ The `SEAL` is a SHA256 digest of stable zones. The agent passes it on every turn to `osiris.observe`: OSIRIS recomputes and detects any state drift immediately.
73
+
74
+ **This is OSIRIS's passive transport**: even if the agent stops calling tools, it carries the essential state cleanly.
75
+
76
+ ### Three Hashes Because Prompt Cache is Prefix-Based
77
+
78
+ ```
79
+ head_hash = sha256(system_head ‖ rules) immutable
80
+ zoneB_hash = sha256(objective ‖ global_plan ‖ tool_contract) quasi-stable
81
+ tail_hash = sha256(constraints ‖ pinned_decisions) append-only
82
+ prefix_hash = sha256(head_hash ‖ zoneB_hash) ← cached prefix
83
+ zoneA_hash = sha256(head_hash ‖ tail_hash) ← full ZONE A
84
+ ```
85
+
86
+ | Change | Verdict | Cache Cost |
87
+ |---|---|---|
88
+ | `head_hash` | **CRITICAL DRIFT** | Full re-prefill |
89
+ | `zoneB_hash` | Minor drift | Re-prefill delta only |
90
+ | `tail_hash` (append) | **Normal growth** | Re-prefill delta only |
91
+ | Pinned item **rewritten** | **CRITICAL DRIFT (semantic)** | Cache intact, task state corrupted |
92
+
93
+ > **Appending** a constraint or decision changes `tail_hash` but **not** `prefix_hash`: the prompt cache holds, only the new tokens are prefilled.
94
+ >
95
+ > **Rewriting** a pinned decision is explicitly caught: OSIRIS checks collection identity, flagging a semantic break (`semantic_break: true`, `cause: pinned_rewrite`).
96
+
97
+ ---
98
+
99
+ ## 3. The 6 MCP Tools
100
+
101
+ Access footprint: **1,019 tokens** of schemas and descriptions in model context (measured via `bench/run_bench.py`). Paid on task start, amortized across the session — pays off on the very first turn with ≥800 token payloads.
102
+
103
+ | Tool | Role | Typical Response |
104
+ |---|---|---|
105
+ | `osiris.plan` | Start / update / resume / status of a task; produces sealed manifest | ~160 tok |
106
+ | `osiris.precheck` | Authorize or deny an action (invariants, budget, deduplication) | ~70 tok |
107
+ | `osiris.observe` | Log actions, loop detection, offload large data, update memory | ~50 tok |
108
+ | `osiris.recall` | Rehydrate refs (**server-side filtered**: grep, range, outline) | variable |
109
+ | `osiris.checkpoint` | Snapshot, resume, completion report, reversible compaction | ~80 tok |
110
+ | `osiris.handoff` | Executable delegation contracts and structured results | ~200 tok |
111
+
112
+ `osiris.observe` combines logging, loop protection, payload externalization, memory registry, and automated pruning in a single call so the agent always reports back seamlessly.
113
+
114
+ ### Extended Operations
115
+
116
+ | Call | Behavior |
117
+ |---|---|
118
+ | `osiris.observe(kind="dropped", result=<ref>)` | **Drop receipt**: agent confirms payload was evicted from prompt → token savings are **proven** and credited |
119
+ | `osiris.observe(kind="head"\|"contract", result=…)` | Records system prompt head / client contract and detects cache-busting volatile tokens (timestamps, UUIDs) |
120
+ | `osiris.recall(op="grep"\|"range"\|"head"\|"tail"\|"outline"\|"aggregate"\|"jsonl")` | **Server-side filtering**: only requested matches enter the context window |
121
+ | `osiris.plan(mode="status")` | Context pressure breakdown (measured vs declared vs unknown) |
122
+ | `osiris.checkpoint(mode="compact"\|"trim"\|"clear")` | Reversible session compaction preparation |
123
+ | `osiris.precheck` → `suggest_alternative` | Active collision resolution for duplicate operations |
124
+
125
+ ### Resources & Prompts
126
+
127
+ - `osiris://task/{task_id}/manifest` — Active zones, drift status, objective
128
+ - `osiris://task/{task_id}/status` — Real-time context pressure
129
+ - `osiris://ref/{ref}` — Raw byte content of any referenced payload
130
+ - Prompt `osiris/task-resume` — Clean agent recovery template after crashes
131
+
132
+ ---
133
+
134
+ ## 4. Architecture
135
+
136
+ ```
137
+ ┌──────────────────────────────────────────────────────────────┐
138
+ │ Agent (Claude Code, Cursor, MiniMax Code, Codex, Cline…) │
139
+ │ Context: system │ tools │ OSIRIS MANIFEST │ history │
140
+ └───────────────────────────┬──────────────────────────────────┘
141
+ │ MCP stdio — 6 tools, ~1,019 tok schema
142
+ ▼
143
+ ┌──────────────────────────────────────────────────────────────┐
144
+ │ osiris-mcp (server.py) │
145
+ │ plan · precheck · observe · recall · checkpoint · handoff │
146
+ └───────────────────────────┬──────────────────────────────────┘
147
+ │
148
+ ┌───────────────────────────▼──────────────────────────────────┐
149
+ │ core/ │
150
+ │ task_state Typed TaskState (objective, plan, decisions) │
151
+ │ memory Typed memory registry by kind and scope │
152
+ │ refs Content-addressed store (verified on read) │
153
+ │ prefix Zones, 3-hash system, drift, PrefillPlan │
154
+ │ prune Reversible externalization, 4 modes │
155
+ │ query Server-side payload filtering (grep, range...) │
156
+ │ compaction trim / compact / clear (lossless) │
157
+ │ pressure Context pressure metrics & tracking │
158
+ │ loopguard Fingerprinting, 5 loop patterns detection │
159
+ │ invariants TOML rule engine (guard rails) │
160
+ │ compass Tool Compass (dynamic relevance scoring) │
161
+ │ handoff Executable agent delegation contracts │
162
+ │ events Append-only event journal + checkpoints │
163
+ │ ledger Tokens / cost / savings / OSIRIS overhead │
164
+ │ fileops Sandboxed file inspection (roots, size limits) │
165
+ │ redact Secret scrubbing before any hashing │
166
+ │ policy Budget policies & token enforcement │
167
+ └───────────────────────────┬──────────────────────────────────┘
168
+ ▼
169
+ ~/.osiris/osiris.db + ~/.osiris/reports/
170
+ ```
171
+
172
+ ---
173
+
174
+ ## 5. Memory Model
175
+
176
+ Deterministic, typed, content-addressable memory — **not** an opaque vector database.
177
+
178
+ ```
179
+ TaskState
180
+ ├── objective immutable
181
+ ├── constraints[] append-only
182
+ ├── decisions[] append-only, pinned verbatim
183
+ ├── plan completed / active / remaining steps
184
+ ├── files{} path, SHA-256 hash, mtime, last access, ref
185
+ ├── tool_results{} cache_key, ref, size, token cost, TTL
186
+ ├── failures{} error signature, tool, args hash, attempts, lesson
187
+ ├── lessons[] general behavioral rules learned
188
+ ├── handoffs{} cross-agent delegation contracts
189
+ └── budget estimated vs consumed tokens and cost
190
+ ```
191
+
192
+ Scopes: `task` → `project` → `agent` → `global`.
193
+
194
+ ---
195
+
196
+ ## 6. Cache-Aware Pruning
197
+
198
+ **Security Invariant: Pruning moves payload data to content-addressed refs (`mem://sha256:…`). It NEVER deletes.**
199
+
200
+ ```
201
+ ZONE_A_pruning_cost = pruned_tokens
202
+ ZONE_C_or_D_pruning_cost = 0 ← always zero cost
203
+ net_savings = pruned_tokens − (prefix_tokens × P(cache_dead) × prefix_pruned)
204
+ ```
205
+
206
+ | Mode | Trigger | Evicts | Cache Impact | Use Case |
207
+ |---|---|---|---|---|
208
+ | `cache_ttl` (default) | `Δt > TTL` | C/D, and A/B only if cache expired | Neutral | **Recommended default** |
209
+ | `conservative` | Very high threshold | Working zone (C/D) only | Zero | High-cost API models |
210
+ | `balanced` | Moderate threshold | C/D + cold historical turns | Zero | Standard agent workflows |
211
+ | `aggressive` | Low threshold | Everything rehydratable | Minor prefill risk | Fast local LLMs |
212
+
213
+ ---
214
+
215
+ ## 7. LoopGuard Protection
216
+
217
+ ```
218
+ fingerprint = sha256(tool ‖ canonical_args ‖ result_signature)
219
+ ```
220
+
221
+ | Detection | Trigger Signal | Verdict |
222
+ |---|---|---|
223
+ | Exact duplicate | Identical fingerprint | `suggest_alternative` |
224
+ | Repeated failure | Same error signature (≥3 times) | `block` + `required_action` |
225
+ | Loop pattern | Same error across varying args | `warn` |
226
+ | Oscillation | Alternating A/B/A/B pattern | `warn` |
227
+ | Runaway | N calls with zero state progress | `warn` / `block` |
228
+
229
+ ---
230
+
231
+ ## 8. Invariants (Guard Rails)
232
+
233
+ Define project safety rules in `.osiris/invariants.toml`:
234
+
235
+ ```toml
236
+ [[invariant]]
237
+ id = "tests-before-commit"
238
+ when = { tool = "git.commit" }
239
+ require = { state = "tests_passed" }
240
+ message = "Cannot commit while tests are failing"
241
+
242
+ [[invariant]]
243
+ id = "no-test-edit"
244
+ when = { path_glob = "tests/**" }
245
+ verdict = "block"
246
+ message = "Modifying test suites requires explicit approval"
247
+ ```
248
+
249
+ ---
250
+
251
+ ## 9. Lossless Verification & Non-Loss Proof
252
+
253
+ OSIRIS guarantees full auditability for offloaded data:
254
+
255
+ 1. **Self-verifying refs**: `mem://sha256:<hash>`. Reads re-verify data integrity against the hash before returning.
256
+ 2. **Zero deletion paths**: data is relocated to the local store, never pruned permanently.
257
+ 3. **Reproducible audit**:
258
+ ```bash
259
+ python -m osiris audit --task <task_id>
260
+ ```
261
+ Outputs cryptographic proof of non-loss:
262
+ ```json
263
+ {"lossless": true, "items_externalized": 14, "items_verified": 14, "items_missing": 0, "integrity_violations": []}
264
+ ```
265
+
266
+ ---
267
+
268
+ ## 10. Verified Benchmarks
269
+
270
+ Real measurements from `python bench\run_bench.py` running an automated coding workflow:
271
+
272
+ | Payload Size | Baseline Context | Fixed OSIRIS | Adaptive OSIRIS | Net Improvement | OSIRIS Mode | Overhead |
273
+ |---|---|---|---|---|---|---|
274
+ | **200 tok** | 1,583 | 2,687 | **1,651** | **−4.30%** | bystander | 34 tok |
275
+ | **800 tok** | 3,851 | 3,755 | **3,261** | **+15.32%** | light | 1,810 tok |
276
+ | **2,000 tok** | 9,015 | 5,229 | **5,233** | **+41.95%** | standard | 2,492 tok |
277
+ | **5,000 tok** | 20,979 | 8,171 | **8,168** | **+61.07%** | standard | 2,439 tok |
278
+ | **20,000 tok** | 82,135 | 23,427 | **23,440** | **+71.46%** | full | 2,422 tok |
279
+
280
+ - **Access Cost**: 1,019 tokens of schemas, amortized across session tasks.
281
+ - **Session Net Gate**: PASS (Worst-case net across full suite: **+951 tokens**).
282
+ - **At 20,000 tokens**: **+71.46% net savings** on context usage.
283
+
284
+ ---
285
+
286
+ ## 11. Quick Start
287
+
288
+ ```powershell
289
+ cd D:\MCP-Osiris
290
+ uv venv --python 3.12 .venv
291
+ uv pip install --python .venv\Scripts\python.exe -e ".[dev]"
292
+ ```
293
+
294
+ ### CLI Verification
295
+
296
+ ```powershell
297
+ .venv\Scripts\python.exe -m pytest tests -q # Run test suite (76 passed)
298
+ .venv\Scripts\python.exe -m ruff check src tests # Code linting
299
+ .venv\Scripts\python.exe -m osiris health # Server health check
300
+ .venv\Scripts\python.exe -m osiris audit --task t_1 # Cryptographic non-loss proof
301
+ .venv\Scripts\python.exe bench\run_bench.py # Reproduce benchmarks
302
+ ```
303
+
304
+ ### Registration as MCP Server
305
+
306
+ Add to your client configuration (`mcp.json`):
307
+
308
+ ```json
309
+ {
310
+ "mcpServers": {
311
+ "osiris": {
312
+ "command": "D:\\mcp-osiris\\.venv\\Scripts\\python.exe",
313
+ "args": ["-m", "osiris"],
314
+ "env": {
315
+ "OSIRIS_HOME": "C:\\Users\\Tech\\.osiris",
316
+ "OSIRIS_ROOTS": "D:\\mcp-osiris"
317
+ }
318
+ }
319
+ }
320
+ }
321
+ ```
322
+
323
+ ---
324
+
325
+ ## 12. Installation
326
+
327
+ ### From PyPI (recommended)
328
+
329
+ ```bash
330
+ pip install mcp-osiris # or: uv pip install mcp-osiris
331
+ mcp-osiris # runs the MCP server on stdio
332
+ osiris health # CLI verification
333
+ osiris-dashboard --port 8770 # Control Plane (dashboard)
334
+ ```
335
+
336
+ ### From npm (no Python setup)
337
+
338
+ ```bash
339
+ npx -y osiris-mcp
340
+ ```
341
+
342
+ The npm package is a stdio launcher. It resolves the Python runtime in this
343
+ order — `OSIRIS_PYTHON` → `uvx` → `python3` → `python` — and runs the PyPI
344
+ package `mcp-osiris`.
345
+
346
+ ### From source
347
+
348
+ ```powershell
349
+ git clone https://github.com/MlkBlk-IT/osiris.git
350
+ cd osiris
351
+ uv venv --python 3.12 .venv
352
+ uv pip install --python .venv\Scripts\python.exe -e ".[dev]"
353
+ ```
354
+
355
+ ### MCP client configuration
356
+
357
+ ```json
358
+ {
359
+ "mcpServers": {
360
+ "osiris": {
361
+ "command": "npx",
362
+ "args": ["-y", "osiris-mcp"],
363
+ "env": {
364
+ "OSIRIS_HOME": "~/.osiris",
365
+ "OSIRIS_ROOTS": "/path/to/project"
366
+ }
367
+ }
368
+ }
369
+ }
370
+ ```
371
+
372
+ | Variable | Default | Role |
373
+ |---|---|---|
374
+ | `OSIRIS_HOME` | `~/.osiris` | SQLite database, reports, caches |
375
+ | `OSIRIS_ROOTS` | *(empty)* | Roots allowed for file reading (`;` separated) |
376
+ | `OSIRIS_CACHE_TTL_S` | `300` | Cache TTL (seconds) |
377
+ | `OSIRIS_PRUNE_THRESHOLD_TOKENS` | `40000` | Prune threshold |
378
+ | `OSIRIS_DISPATCH_ONLY` | `0` | `1` → exposes only `osiris.call` |
379
+
380
+ ---
381
+
382
+ ## License
383
+
384
+ MIT © 2026 Malik Belkacemi (MLKBLK-IT)
@@ -0,0 +1,47 @@
1
+ osiris/__init__.py,sha256=hIkGDI346pRDo2xFmty6fGBjuNNBN1RmaG0zfc2Mqvw,233
2
+ osiris/__main__.py,sha256=DQB4IBXvPaCYpyNyEGOlxp9ZJqalccb_7Zyuu_Qz9GU,646
3
+ osiris/audit.py,sha256=D76vJzzKWx-5qOCSp_MAh_AVMNWksEjCQoN9RKfwztA,14572
4
+ osiris/cli.py,sha256=hj2za2ce860sfVKO36tRdLANp_1bb3z9ibuhJU4Nzno,5489
5
+ osiris/config.py,sha256=2O9OCagE5Yf8oNIjDuMMWAgZoYCdtyqI_tZAy_fIG68,5736
6
+ osiris/server.py,sha256=wHdoUdaCi6loovqtqEu3TLWX0YgCSFiXyoon9rLDyHw,58479
7
+ osiris/core/__init__.py,sha256=a5t5mx-n4ihQMc_JDeP8SG20B_2tztl_hP2p7oAYLaU,380
8
+ osiris/core/adaptive.py,sha256=io1pS5ufdrJVCtHTuJghrK755jikyF2m5Cf6rDmOLtc,8849
9
+ osiris/core/compaction.py,sha256=vs-Xywjmx0jC6Sp97Yh_AWX6FNuSmFqNAp4soKLQ3oI,4189
10
+ osiris/core/compass.py,sha256=NIQ9TUEuR_LAqlSxVLKddbk60sgOzfqJeUYo7bibldY,4654
11
+ osiris/core/db.py,sha256=X4s_Jd7FaV0H2NOFVYwYtoOPRUY0hZUR4pSTDmUvcjQ,6459
12
+ osiris/core/errors.py,sha256=XN574I-fJMStAnKiKbRGIo0Khwa3nTSaFQ71vgROXm8,531
13
+ osiris/core/events.py,sha256=uljEPcHFuWKXWg_1REmQuzE1gWq9VX1ZGcatBv6XnbE,8052
14
+ osiris/core/fileops.py,sha256=MLdWLyRTEgcalwycBxdkdVfC-tSXpSVarNOSI3tCSOg,3009
15
+ osiris/core/handoff.py,sha256=_6dTztUyMPe5X_zSgOUvVU1FmIDJlS1I4MIxPbXPr74,5514
16
+ osiris/core/ids.py,sha256=qjFc2zlpb9ch5DNA9ZTBpsWBFHuCDKThHz0e9_Y5j4c,2775
17
+ osiris/core/invariants.py,sha256=-1jW3o6WnoMfJhWLNm5Rhr6u_j5n6W4DDsbET5R1Vq4,6126
18
+ osiris/core/ledger.py,sha256=HbBdLicZQLDW-KGJiqwfzkUMy4ZiGjmZsBoUO8CNegk,9564
19
+ osiris/core/loopguard.py,sha256=abDzNCF7sTOi-YdLU_jdmE13kn5DBcWb6cLfu7wHdmo,9393
20
+ osiris/core/manifest.py,sha256=JMuIDIZbCe_dZIivgapzhunemYkptKSqONiBDUA63G8,1981
21
+ osiris/core/memory.py,sha256=5q0-FZXfUe9nKK1nRkd7Cy6gcCyV77VYK2-E2_Tbt9E,4405
22
+ osiris/core/policy.py,sha256=RARguVv5oZeGHt3L9vfmx0Fj8M03-hbS79B4fbA0SHk,3225
23
+ osiris/core/prefix.py,sha256=_LEQ_F96a2zQeBFL_L06gcqZYfDzaN3XNqIXdi60pbE,13091
24
+ osiris/core/pressure.py,sha256=kMdNTjvthIyUs2pfmTx3kGDRfLSgsJet3Wm2-WL7s34,3801
25
+ osiris/core/prune.py,sha256=bPLjlNMTuoibbplRpiesuM1SaVN1o82mIZEtdXbQIqs,7385
26
+ osiris/core/query.py,sha256=ly673JLtd70J_nPSvLxwJqZqml1Kz2DTjt6BeezMrO4,8977
27
+ osiris/core/redact.py,sha256=sltjnymqXUeLN_APVVyi3BvFq-FYQkJzn-tqyMor7hE,2580
28
+ osiris/core/refs.py,sha256=ZssvuUJ5ut2jENXcMAgrTcUb866S12AltiuF8H5ej1Y,7864
29
+ osiris/core/runtime.py,sha256=A1NH8PRVBruGGbtwIVC7_wFPE8KGXjohD4oIVFr5oog,5461
30
+ osiris/core/task_state.py,sha256=MZzSWbsZUTsfEBXLiQf3I7Eg8bxTlF-jTIycf3hJPQ4,10855
31
+ osiris/core/tokens.py,sha256=dCuMczIGT-RdTUPml19vcKEjFqrmrK9qQvCTpjL_tAs,1524
32
+ osiris/tools/__init__.py,sha256=KnPx-9NuujnNcQ1reLiqCfP1T9HjfeDv912Z2N7l3hM,1303
33
+ osiris/bench/__init__.py,sha256=cqjQfAyklkJy_Hp6J95rUXaCPO0r1pEScVoEi0FmSnI,139
34
+ osiris/bench/run_bench.py,sha256=xJEbcEz2VHJYzsAPrFovhnxZNt7HKXV9xKXYjykJY4U,20902
35
+ osiris/dashboard/__init__.py,sha256=lER6miniv9v5fFKLuVZ0GYLgSPcvjZ-YdCtk7CPTu3c,290
36
+ osiris/dashboard/server.py,sha256=9zXfVJ3Rd4E15XoCc4ZPhFqw0xEYiP6DtNc3fxkJHMk,31666
37
+ osiris/dashboard/web/app.js,sha256=ZB7ie9V5-jovCY9R4T_3AbcbLQ1esHo5AQPJHlbYbvo,44598
38
+ osiris/dashboard/web/index.html,sha256=-wc23VqSMmZSYANMPtD2zL1CMNKK5LmiuFoWlGrUS2M,6442
39
+ osiris/dashboard/web/logo.svg,sha256=_vptdDwlHMGZyrL4HVgFuLClZrqH6nRraLe8FMbWDrA,1234
40
+ osiris/dashboard/web/styles.css,sha256=Qd2_WbR3H-P3qvXB7GnTPAB5aFxWrV9WFeVYK6iWJew,14989
41
+ osiris/bench/fixtures/src/Profile.psm1,sha256=RVhYNPNQl-Y11ZVXAUdnefaabD-VoONl3vsOyf8MH60,8549
42
+ osiris/bench/fixtures/tests/Profile.Tests.ps1,sha256=bnFGT4qxVC8UrEm2qeqmZ6GC-Ce1AINZp8S4hjR_Caw,1102
43
+ mcp_osiris-0.1.0.dist-info/METADATA,sha256=Qzvd8QEJrS9SjigpXC9T7uE8jV-_OXj6PP0N8gOjewg,15939
44
+ mcp_osiris-0.1.0.dist-info/WHEEL,sha256=2iZrJkDIkeDh0k9SikKMqFuRP-ua6mb4Ir1AsER4BEw,87
45
+ mcp_osiris-0.1.0.dist-info/entry_points.txt,sha256=nOaXY6qF8Q2ger80Nnt3P8wA6s816U5NUE4Mv5kdMco,123
46
+ mcp_osiris-0.1.0.dist-info/licenses/LICENSE,sha256=wVul2ls1DM9HmmqTDHQmiuJx5wUC5H6LFhgJiU-WGZE,1084
47
+ mcp_osiris-0.1.0.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: hatchling 1.33.0
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,4 @@
1
+ [console_scripts]
2
+ mcp-osiris = osiris.server:main
3
+ osiris = osiris.cli:main
4
+ osiris-dashboard = osiris.dashboard.server:main
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Malik Belkacemi (MLKBLK-IT)
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
osiris/__init__.py ADDED
@@ -0,0 +1,9 @@
1
+ """OSIRIS — context engine cache-aware pour agents IA.
2
+
3
+ Serveur MCP standard, local-first, independant de tout provider.
4
+ """
5
+
6
+ from osiris.config import settings
7
+
8
+ __version__ = settings.version
9
+ __all__ = ["settings", "__version__"]
osiris/__main__.py ADDED
@@ -0,0 +1,28 @@
1
+ """Point d'entree : `python -m osiris` (serveur MCP) ou `python -m osiris <cmd>` (CLI)."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import sys
6
+
7
+
8
+ def main() -> int:
9
+ # Sans argument : serveur MCP en stdio.
10
+ # Avec un argument : CLI locale (health, tasks, audit, report, bench).
11
+ if len(sys.argv) > 1 and sys.argv[1] in {
12
+ "health",
13
+ "tasks",
14
+ "audit",
15
+ "report",
16
+ "bench",
17
+ }:
18
+ from osiris.cli import main as cli_main
19
+
20
+ return cli_main(sys.argv[1:])
21
+ from osiris.server import main as server_main
22
+
23
+ server_main()
24
+ return 0
25
+
26
+
27
+ if __name__ == "__main__":
28
+ raise SystemExit(main())