lorevell

agent
Guvenlik Denetimi
Gecti
Health Gecti
  • License — License: MIT
  • Description — Repository has a description
  • Active repo — Last push 0 days ago
  • Community trust — 25 GitHub stars
Code Gecti
  • Code scan — Scanned 12 files during light audit, no dangerous patterns found
Permissions Gecti
  • Permissions — No dangerous permissions requested

Bu listing icin henuz AI raporu yok.

SUMMARY

Local knowledge for humans and agents. Plain Markdown. Yours to keep.

README.md

Memori 2.0

A local Markdown knowledge vault that agents can search, learn from and consolidate.

Markdown is the source of truth. SQLite is a disposable index. Claude Code or Codex provides the reasoning: Memori does not implement another agent runtime, learning model or orchestration framework.

flowchart LR
    Agent[Claude Code / Codex] --> CLI[Memori CLI]
    CLI --> Vault[Markdown notes + Git]
    Vault --> Index[Rebuildable SQLite index]
    Index --> Search[Rust FTS5 + local vectors + RRF]
    Search --> Agent
    Dream[Same agent, headless] -->|consolidation skill| Vault

Install from this checkout

These instructions describe the breaking 2.0 interface. The branch does not publish or migrate an existing 1.x installation automatically. Python 3.9+ and a Rust toolchain are required for a source build; Python 3.13 is used in local verification.

python3 -m venv .venv
.venv/bin/python -m pip install maturin pytest
(cd memori-python && VIRTUAL_ENV="$PWD/../.venv" ../.venv/bin/maturin develop --release)
export PATH="$PWD/.venv/bin:$PATH"
memori --version

Local embedding inference uses AllMiniLM-L6-V2 and may download its model on first use. --text-only avoids model inference and supports an offline literal-search workflow.

Start a vault

export MEMORI_VAULT="$PWD/memory"
memori init
memori add 'Use a transaction for multi-statement writes that must succeed together.' --type procedure --tag sqlite
memori search 'atomic database updates'
memori show <id>

--vault <directory> overrides MEMORI_VAULT; without either, the directory is ./memory. init creates the directory, ignores caches and initializes a dedicated Git repository. It does not change your Git identity. init --no-git supports a plain vault; dream requires a dedicated Git repository rooted at the vault.

Each note is ordinary Markdown:

---
id: retry-procedure
type: procedure
tags: [http, debugging]
---
# Retry a transient request

Honor Retry-After. Otherwise use bounded backoff with jitter.
Automatically retry only idempotent operations.

## Related
- [[rate-limit-investigation]]

add generates a UUID and filename. Files can be renamed or organized into subdirectories without changing their IDs. To write multiline procedures, use add --file body.md or add - with stdin. Unknown frontmatter fields are preserved; id is required, while type and tags are optional. Every active .md file must have valid frontmatter and a nonempty body.

Recall and maintain

Command Behavior
add <body> / add --file <path> Write a new atomic note; no semantic overwrite
update <id> --content <body> Replace the body, preserving its stable ID
update <id> --meta '{"verified":true}' Merge top-level frontmatter fields
search "query" --limit 5 --graph-limit 3 Hybrid matches plus at most three extra one-hop notes
show <id> --limit 5 Source note, outgoing links, backlinks and unresolved links
index Incrementally synchronize hashes, embeddings and links from Markdown
archive <id> Preserve the original bytes in archive/; remove it from active retrieval
delete <id> Alias for archive, not permanent deletion
setup --agent codex --project . Install learning and dream skills under .agents/skills/
setup --agent claude --project . Install the same skills under .claude/skills/
dream --agent codex Run bounded consolidation with the installed headless runtime

--json emits structured output, with errors on stderr and a nonzero exit. IDs accept unique prefixes. --type filters search; --min-similarity gates raw cosine on the semantic leg, while literal matches remain eligible. The returned ranking score is not confidence or factual truth.

Wiki links resolve by exact stable ID, then vault-relative filename without .md, then unique basename. [[path/note#heading|label]] is supported. Links in fenced blocks and ordinary inline code are ignored. Backlinks are derived; there is no second file write for each relationship. Missing or ambiguous targets are diagnostics, not invented edges. Graph context is explicit one-hop navigation and is returned separately from ranked matches.

Human edits become searchable after index; CLI reads and mutations also synchronize automatically. Native Vault / PyVault callers explicitly call index after mutations or external edits before querying links or search. The index lives in .memori/index.sqlite. Close other Memori processes and remove that cache to rebuild it from files. Hidden directories, symlinks and the root archive/ directory are excluded. Malformed active notes or duplicate IDs abort indexing and preserve the prior cache.

Let the agent learn

Run setup in the project where the agent works. The shared skill asks it to search before investigating, then retain one or two verified reusable lessons after a meaningful discovery. Routine work can save nothing. Commands, their preconditions and evidence belong in ordinary procedure notes. No automatic session recording, transcript ingestion or skill generation is involved.

Skill installation refuses to overwrite customized instructions unless --force is explicit. The canonical files are skills/memori and skills/dream; identical packaged copies support installed wheels.

Consolidate with an existing headless agent

# Configure a Git identity normally if this machine has none.
memori dream --agent codex --dry-run
memori dream --agent codex --max-notes 20 --timeout 300
# Or use an installed Claude Code CLI:
memori dream --agent claude

A dream run processes a bounded batch of files changed since the last successful run. Memori snapshots pending knowledge in Git, invokes one agent, validates/reindexes its edits, and commits the result. The agent improves notes, extracts useful procedures, repairs links and flags uncertainty. Superseded originals must remain in archive/ or a byte-preserving rename. Validation checks structure, scope and retained originals; it cannot prove semantic truth.

Failures and timeouts leave edits available for inspection and do not acknowledge the batch. Pending batches remain pending. .memori/dream-last.log records the child output locally. Concurrent dream runs are rejected. Run no other writers during consolidation: the MVP does not merge concurrent native edits.

Successful changes are reversible with git -C "$MEMORI_VAULT" revert <consolidation-commit>, followed by memori index. There is no scheduler service; invoke the command manually or through a scheduler you choose and authorize. Runtime authentication and normal agent permissions remain the responsibility of the existing installed CLI. Memori never passes bypass-permission flags.

Architecture and verification

cargo fmt --all -- --check
cargo clippy --workspace --all-targets -- -D warnings
cargo test -p memori-ai-core --release
cargo test -p memori-ai-core --no-default-features --release --test vault_test --test relevance_test --test freshness_test
python3 scripts/sync-skills.py --check
PATH="$PWD/.venv/bin:$PATH" .venv/bin/python -m pytest memori-python/tests -v

Tests use real temporary files, SQLite, the native extension and CLI subprocesses. Launcher contract tests use controlled child processes; actual headless Codex runs and the small held-out retrieval experiment are recorded separately. A passing structural check is not proof of autonomous semantic correctness.

Breaking changes

2.0 replaces --db, store, the old multi-section context, setup snippet and dashboard with the vault-first interface. It never reads or modifies ~/.claude/memori.db. Export important 1.x records using the 1.x binary before switching, then turn selected records into atomic Markdown notes; an automatic migration is not included. The old low-level Memori / PyMemori database engine remains as retrieval plumbing, not as an alternative canonical store for 2.0 vaults.

MIT licensed. No graph database, hosted vector store, custom LLM API or orchestration framework is required.

Yorumlar (0)

Sonuc bulunamadi