File size: 1,344 Bytes
dbb04e4
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# MnemoCore Core

## Beta Notice

This core implementation is in beta.
Behavior, interfaces, and internals may change without backward compatibility guarantees.

## Purpose

`src/core` contains the runtime memory engine and foundational primitives:
- vector encoding,
- memory node lifecycle,
- tier placement,
- synaptic associations,
- configuration and storage adapters.

## Main Modules

- `engine.py` – Core orchestration for store/query and conceptual proxy operations.
- `binary_hdv.py` – Binary vector operations and text encoding utilities.
- `tier_manager.py` – HOT/WARM/COLD movement and persistence strategy.
- `node.py` – Memory node data model and access/LTP-related behavior.
- `synapse.py` – Synaptic edge model and reinforcement dynamics.
- `config.py` – Typed config loading (`config.yaml` + `HAIM_*` overrides).
- `async_storage.py` – Async Redis metadata and stream support.

## Example

```python

from mnemocore.core.engine import HAIMEngine



engine = HAIMEngine()

memory_id = engine.store("The quick brown fox")

results = engine.query("quick fox", top_k=3)

print(memory_id, results)

```

## Testing

Run from repo root:

```bash

python -m pytest tests -v

```

## More Docs

- `docs/ARCHITECTURE.md`
- `docs/ROADMAP.md`