feat: Adds a miner mode for git log entries.#98
Conversation
PR Review: feat: Adds a miner mode for git log entriesExecutive Summary
Affected Areas: Business Impact: Unlocks a new ingest source — git history becomes searchable memory. Good feature direction. Flow Changes: New Ratings
PR Health
High Priority Issues(Must fix before merge) 🏗️ #1: Direct
|
web3guru888
left a comment
There was a problem hiding this comment.
✨ Review of #98 — feat: Adds a miner mode for git log entries.
Scope: +654/−3 · 3 file(s)
mempalace/cli.py(modified: +33/−3)mempalace/git_miner.py(added: +429/−0)tests/test_git_miner.py(added: +192/−0)
Technical Analysis
- 🪟 Windows compatibility — verify path handling works cross-platform
Suggestions
- Magic number(s) 2025 — consider extracting to named constant(s)
Strengths
- ✅ Includes test coverage
🟢 Approved — clean, well-structured PR. Good work @MrDys!
🏛️ Reviewed by MemPalace-AGI · Autonomous research system with perfect memory · Showcase: Truth Palace of Atlantis
Draft plugin specification for source adapters, mirroring RFC 001's role for storage backends. Formalizes the contract six community ingester PRs (#274, #23, #169, #232, #567, #98, #702) plus #981's metadata-only mode have been reinventing ad-hoc, so adapter authors can build to a stable surface. Key decisions: - Single ingest() method; lazy adapters yield SourceItemMetadata ahead of drawers, eager adapters interleave - Declared-transformation model (§1.4) replaces informal verbatim promise with a verifiable one; byte_preserving adapters declare the empty set, declared_lossy adapters enumerate. Existing miner.py and the convo_miner+normalize pipeline map cleanly - Palace is the incremental cursor via is_current(item, metadata); no sidecar persistence - Routing is adapter-owned; detect_room/detect_hall move into the filesystem adapter - Flat metadata per ChromaDB (RFC 001 §1.4) — entity hints as json_string field, KG triples route to SQLite knowledge graph - Closets stay core-built as a post-step; adapters may emit flat closet_hints. Closes existing gap where convo drawers get no closets - No per-drawer field renames: source_file, filed_at, source_mtime, added_by, normalize_version, entities, ingest_mode all preserved. Spec adds adapter_name, adapter_version, privacy_class §9 enumerates the cleanup PR prerequisites (mempalace/sources/ module, PalaceContext facade, KnowledgeGraph.add_triple gaining backwards-compatible source_drawer_id + adapter_name params). Tracking issue: #989
|
Hi, thanks for the contribution. This PR has merge conflicts with Could you rebase onto If this change is no longer relevant, feel free to close the PR. (This message is part of a periodic backlog pass, sent to all open PRs that match this state.) |
What does this PR do?
This adds support for mining git log metadata (commit messages, hashes, file paths, etc.):
How to test
mempalace mine . --mode git-log --dry-run— should list commits with detected roomsmempalace mine . --mode git-log --dry-run --since 2025-01-01— date filteringmempalace mine . --mode git-log— actually store, thenmempalace search "some commit message"to verify retrievalmempalace status— should show git-log drawers in the countsChecklist
python -m pytest tests/ -v)ruff check .)