# Project export: The Memory Pod

This document was generated by HackStack to give an AI agent context about a hackathon project. Sections are labeled with their provenance; content marked as truncated was cut to keep this document small.

## Project metadata

- Hackathon: UC Berkeley AI Hackathon 2026
- Tagline: Every AI remembers you — on their servers, in their silo. Memory Pod remembers you on yours: a local-first context layer you carry into any AI, sharing only what you choose.
- Devpost: https://devpost.com/software/the-memory-pods
- GitHub: https://github.com/Lingke-H/memory-pod.git
- Team: 3 GitHub contributor(s) — zid5306137YixingSun (32 commits), Lingke-H (21 commits), Claude Opus 4.8 (16 commits)

## Devpost submission (written by the team)

No Devpost description available.

## README (from the GitHub repository)

# Memory Pod

[中文版本](#中文文档)

> **Own your Pod. Dock it anywhere. Share only what you choose.**

Built for the **2026 AI Hackathon at UC Berkeley**, Memory Pod explores a simple
idea: the useful context an AI learns about you should not be trapped inside one
AI product.

## Overview

### The problem

AI assistants become more useful when they know how you work, what you care
about, and what context matters to the task. Today, that memory usually stays
inside one provider's account. Moving to another model often means starting over
or manually rebuilding the same context.

Sharing useful working knowledge has a similar problem. A checklist or review
framework may be valuable, but copying an opaque mega-prompt gives the receiver
little visibility into what they are adopting or sending onward.

### What Memory Pod does

Memory Pod keeps explicit context in local, inspectable containers and lets you
use that context with different AI products. You can keep your own private
memory, receive a separate shared playbook, choose what is relevant, and review
the exact material before it becomes part of a prompt.

The project does not copy a person or transfer tacit expertise. It carries
written facts, preferences, examples, principles, and checklists that remain
visible and under the user's control.

### The experience in three steps

1. **Own or receive context.** Build a private memory from local notes, or
   inspect and import a portable Shared Pod.
2. **Dock and review.** Select your Base Pod and an optional Shared Pod; Memory
   Pod retrieves only the context relevant to the current request.
3. **Use it anywhere.** Deselect anything you do not want to share, then copy or
   paste the furnished prompt into the AI product you choose. Memory Pod never
   submits it automatically.

## Project Status

Memory Pod is a working hackathon MVP v1.1, not a production-hardened service.
The local engine, Portable Pods, CLI, onboarding, review-first macOS Pod Dock,
explicit write-back, optional local polishing, demo tooling, and automated tests
are implemented.

The primary path is deliberately review-first. OS-level in-place injection is
available as an optional macOS demonstration, but the reliable fallback is
always the visible copy-and-paste flow.

## Key Concepts

| Term | Meaning |
| --- | --- |
| **Base Pod** | Your private, writable memory. |
| **Shared Pod** | A playbook, checklist, task lens, or example set designed to be shared. Imported Shared Pods are read-only. |
| **Pod Dock** | The control that activates one Base Pod and, in this MVP, at most one Shared Pod for a task. |
| **`.mpod`** | A readable portable file for carrying a Shared Pod without embeddings or absolute local paths. |
| **Furnished prompt** | Your request plus the relevant context you reviewed and approved. |

The current product boundary is defined by
[PROJECT_DESCRIPTION_V4.md](PROJECT_DESCRIPTION_V4.md).

## Quick Start

Create a private My Pod from a short onboarding flow, install the starter Shared
Pods, and open the review-first Pod Dock:

```bash
git clone https://github.com/Lingke-H/memory-pod.git
cd memory-pod
python3 -m venv .venv
source .venv/bin/activate
make setup
make onboard
make popup
```

Press `Option + Enter`, choose a Base Pod and an optional Shared Pod, enter a
request, review the retrieved context, and copy the furnished prompt. The popup
does not submit anything to an AI service.

## Core Workflows

### Create and Ingest a Private Base Pod

```bash
memory-pod pod create --name "Jiahan" --id jiahan --kind private
memory-pod ingest --pod jiahan ~/Documents/notes
memory-pod remember --pod jiahan --tag preference \
  "Prefer concise explanations with concrete examples."
```

Only `.md` and `.txt` files are ingested. Re-ingesting a source reconciles its
stored chunks while preserving explicit manual memories.

### Create and Export a Shared Pod

```bash
memory-pod pod create \
  --name "Senior Architecture Review" \
  --id senior-review \
  --kind shared \
  --author "Alice" \
  --purpose "Architecture and pull-request review"

memory-pod ingest --pod senior-review ./architecture-playbook.md
memory-pod pod export senior-review --output Senior-Review.mpod
```

A locally authored Shared Pod should contain material intended for sharing.
Private Base Pods cannot be exported as Shared Pods.

### Inspect and Import a Shared Pod

```bash
memory-pod pod inspect Senior-Review.mpod
memory-pod pod import Senior-Review.mpod
memory-pod pod list
```

Inspect an `.mpod` before importing it. Use `--replace` only when intentionally
replacing an imported Pod with the same ID. Imported content is re-embedded
locally and remains read-only.

### Dock Context and Furnish a Prompt

```bash
memory-pod augment \
  --base-pod jiahan \
  --shared-pod senior-review \
  --debug \
  "Review this API design"
```

`--debug` shows the retrieved records and scores. Omit `--shared-pod` for a
Base-only request. The legacy `--profile` option remains a Base Pod alias.

To copy legacy repository profile stores into the current Application Support
location without deleting the sources, run:

```bash
memory-pod pod migrate-legacy
```

## Desktop Interaction on macOS

### Review-First Pod Dock

```bash
make popup
```

The Pod Dock supports Pod selection, `.mpod` import and export, retrieval
inspection, per-record deselection, explicit remembering, and copying. `Polish
Locally` may use a local Ollama instance to rewrite the reviewed prompt; if
Ollama is unavailable or fails, the inspected furnished prompt remains
unchanged.

The popup's **Confirm → Hotkey** action stores the active Pod selection locally
for a running OS loop.

### Optional In-Place Injection

```bash
make demo-setup
make os-loop

# Override the frozen demo Pods:
make os-loop BASE_POD=jiahan SHARED_POD=senior-review
```

Focus one AI text box and press `Option + Enter`. The loop cuts the focused
text, furnishes it, and pastes it back without pressing Enter or submitting.
Use one target site at a time, grant Accessibility permission in advance, and
keep a recording as a presentation fallback.

While the loop is running, `Control + Shift + Enter` explicitly saves focused
text to the private Base Pod. This path copies rather than cuts, restores the
clipboard, and does not paste, submit, or learn in the background.

## CLI Reference

| Command | Purpose |
| --- | --- |
| `memory-pod ingest [--pod ID] PATH` | Ingest local `.md` and `.txt` sources. |
| `memory-pod augment [--base-pod ID] [--shared-pod ID] [--debug] PROMPT` | Retrieve context and furnish a prompt. |
| `memory-pod compare [--debug] [--reingest] PROMPT` | Run the legacy Alice/Bob comparison demo. |
| `memory-pod remember [--pod ID] [--tag TAG] TEXT` | Explicitly write local memory; `--tag` may be repeated. |
| `memory-pod pod create ...` | Create a private or shared local Pod. |
| `memory-pod pod list` | List available Pods. |
| `memory-pod pod inspect FILE.mpod` | Preview a portable Shared Pod. |
| `memory-pod pod import [--replace] FILE.mpod` | Import a Shared Pod read-only. |
| `memory-pod pod export POD_ID --output FILE.mpod` | Export a locally authored Shared Pod. |
| `memory-pod pod migrate-legacy` | Copy legacy demo stores into the current Pod home. |

Run `memory-pod COMMAND --help` or `memory-pod pod COMMAND --help` for complete
arguments.

## Demo Commands

| Command | Demonstrates |
| --- | --- |
| `make onboard` | First-run private memory and starter Shared Pods. |
| `make pod-demo` | Isolated Own → Carry → Dock → selective retrieval flow. |
| `make demo-setup` | Persistent Pods for the popup and OS-loop demo. |
| `make judge` | Frozen presentation sequence. |
| `make demo` | The same prompt with different private memories. |
| `make demo-reingest` | Legacy comparison with forced source refresh. |
| `make demo-learn` | Explicit local write-back followed by retrieval. |

Presentation guidance and fallbacks are in
[docs/DEMO_RUNBOOK.md](docs/DEMO_RUNBOOK.md).

## How It Works

```

[README truncated for size]

## Detected evidence (automated analysis)

Indexed codebase: 75 recognized source files, 304 KB.
- Python (language) — detected in the code
- Ollama (technology) — claimed on Devpost, not found in the code
- AI coding agent: Claude Code — evidence: commit authorship or trailers

## Codebase structure (from repository index)

### Files (80 of 80)

```
.env.example
.github/ISSUE_TEMPLATE/config.yml
.github/ISSUE_TEMPLATE/demo_task.md
.github/ISSUE_TEMPLATE/engine_task.md
.github/ISSUE_TEMPLATE/interaction_task.md
.github/pull_request_template.md
.gitignore
data/experts/accountant.md
data/experts/financial-advisor.md
data/experts/hr-specialist.md
data/experts/lawyer.md
data/experts/management-consultant.md
data/experts/marketing-strategist.md
data/profiles/alice/memory.md
data/profiles/bob/memory.md
docs/COLLABORATION.md
docs/DEMO_RUNBOOK.md
docs/HANDOFF_TEMPLATE.md
docs/superpowers/plans/2026-06-21-mvp-hardening-v1-1.md
docs/superpowers/plans/2026-06-23-project-audit-readme-hardening.md
docs/superpowers/plans/2026-06-23-readme-audience-structure-refresh.md
docs/superpowers/plans/2026-06-23-readme-chinese-language-polish.md
docs/superpowers/specs/2026-06-21-mvp-hardening-design.md
docs/superpowers/specs/2026-06-23-project-audit-readme-hardening-design.md
docs/superpowers/specs/2026-06-23-readme-audience-structure-refresh-design.md
docs/superpowers/specs/2026-06-23-readme-chinese-language-polish-design.md
docs/TASK_BOARD.md
Makefile
PROJECT_DESCRIPTION_V3.md
PROJECT_DESCRIPTION_V4.md
pyproject.toml
README.md
requirements.txt
ROADMAP.md
scripts/demo_learn.py
scripts/download_model.py
scripts/judge_demo.py
scripts/onboard.py
scripts/pod_demo.py
scripts/seed_demo_profiles.py
scripts/seed_experts.py
scripts/seed_pod_demo.py
src/memory_pod/__init__.py
src/memory_pod/active_dock.py
src/memory_pod/augment.py
src/memory_pod/cli.py
src/memory_pod/config.py
src/memory_pod/embeddings.py
src/memory_pod/hotkey_popup.py
src/memory_pod/ingest.py
src/memory_pod/llm.py
src/memory_pod/memory_store.py
src/memory_pod/onboarding.py
src/memory_pod/os_loop.py
src/memory_pod/pods.py
src/memory_pod/prompt_assembly.py
src/memory_pod/radar.py
src/memory_pod/remember.py
src/memory_pod/retrieval.py
src/memory_pod/rewriter.py
tests/test_active_dock.py
tests/test_augment.py
tests/test_cli_pods.py
tests/test_cli_remember.py
tests/test_cli.py
tests/test_demo_setup.py
tests/test_documentation.py
tests/test_ingest.py
tests/test_makefile_defaults.py
tests/test_memory_store.py
tests/test_onboarding.py
tests/test_os_loop.py
tests/test_pod_stack.py
tests/test_pods.py
tests/test_popup_helpers.py
tests/test_prompt_assembly.py
tests/test_radar.py
tests/test_remember.py
tests/test_retrieval.py
tests/test_rewriter.py
```

### Dependencies

- pyproject.toml: numpy@>=2.0.0, pynput@>=1.8.0, pyperclip@>=1.9.0, pytest@>=8.0.0, sentence-transformers@>=3.0.0
- requirements.txt: numpy@>=2.0.0, pynput@>=1.8.0, pyperclip@>=1.9.0, pytest@>=8.0.0, sentence-transformers@>=3.0.0

### Recent commits (newest first)

- docs: polish Chinese readme language
- docs: plan Chinese readme polish
- docs: design Chinese readme polish
- docs: clarify readme story and navigation
- docs: plan readme audience refresh
- docs: design readme audience refresh
- test: cover radar scope boundary
- docs: publish bilingual project reference
- build: prefer repository virtualenv
- chore: ignore local worktrees
- docs: plan project audit and readme hardening
- docs: define project hardening audit
- Merge pull request #23 from Lingke-H/codex/final-freeze-shared-pod-context
- [freeze] Align hidden shared pod wording
- Merge pull request #22 from Lingke-H/codex/demo-freeze-os-loop-default
- [product] Center shared pod wording
- [product] Clarify shared pods as playbooks
- [demo] Stabilize os-loop defaults
- Merge pull request #21 from Lingke-H/feat/industry-experts-and-hotkey-control
- Polish hotkey output, add popup→hotkey control, swap to industry experts

## Key source files (fetched from GitHub, selected and truncated for size)

### PROJECT_DESCRIPTION_V4.md

```markdown
# Memory Pod — Product Constitution v4

> Source of truth for MVP v1.1: Portable Pods + Pod Dock.

## Product Thesis

Memory Pod is a local-first, inspectable context layer that works across AI
models. It does not claim to copy a person, transfer tacit expertise, or generate
better prompts by itself. It retrieves the right explicit context, shows the
user what will be shared, and packages that context for any model.

> **Own your Pod. Dock it anywhere. Share only what you choose.**

## Product Language

- **Pod:** a bounded local context container.
- **Base Pod:** the user's writable private memory.
- **Shared Pod:** an explicit, shareable playbook; imported copies are read-only.
- **Pod Dock:** the control that activates a Base Pod and optional Shared Pod.
- **Docked Pods:** the context sources active for the current task.
- **`.mpod`:** a transparent portable Shared Pod file.

Avoid “share your brain,” “AI thinks like me,” and “transfer ten years of
experience.” A Shared Pod carries written principles, examples, checklists, and
decision frameworks—not identity or tacit judgment.

## MVP v1.1 Workflow

1. Create a private Base Pod and ingest local `.md` / `.txt` files.
2. Create a separate Shared Pod containing an explicit playbook or task lens.
3. Export the Shared Pod as an inspectable `.mpod` file.
4. Send it through AirDrop or any ordinary file channel.
5. The recipient previews it, imports it read-only, and re-embeds it locally.
6. Dock it beside their Base Pod.
7. Memory Pod retrieves relevant context from both Pods.
8. The user deselects anything they do not want to share, then copies the
   furnished prompt into ChatGPT, Claude, Cursor, or another AI.

## Trust Boundary

- The Pod database, embeddings, and retrieval stay local.
- Memory Pod never reads third-party cloud memory or login sessions.
- `.mpod` files never contain embeddings or absolute local source paths.
- `.mpod` author metadata is self-declared and not cryptographically verified.
- Imported Shared Pods are read-only.
- `remember()` writes only to the user's Base Pod.
- When the user sends a furnished prompt to an AI provider, the approved context
  snippets in that prompt leave the machine. Local-first is not end-to-end
  secrecy after the user chooses to send content.

## Stable Product Contracts

```python
augment(raw_prompt: str) -> str
augment_for_profile(...) -> AugmentResult
augment_for_stack(raw_prompt: str, stack: PodStack, ...) -> AugmentResult
furnish_selected(raw_prompt: str, memories, stack, ...) -> str
```

The original `augment()` and profile APIs remain backward compatible. The MVP
supports one Base Pod plus at most one Shared Pod. Focus Pods and larger Pod
Stacks are future work.

## Demo Proof

The primary demo must prove all four claims:

1. **Own:** the context exists as local records.
2. **Carry:** a Shared Pod exports as a readable `.mpod` with no vectors or
   private paths.
3. **Dock:** the recipient imports and retrieves it locally beside their Base
[truncated — 595 more characters]
```

### ROADMAP.md

```markdown
# Memory Pod — Historical Optimization and Delegation Roadmap

> **Status:** Historical hackathon planning document. Several items below have
> already been implemented, and individual status notes may not reflect the final
> repository state. Use [PROJECT_DESCRIPTION_V4.md](PROJECT_DESCRIPTION_V4.md)
> for current product scope and [README.md](README.md) for verified setup and usage.

## Context

Tier 0 (the local memory engine) is complete and working (commit `70659bb`).
The guiding architectural seam for everything below is the **`augment()`
contract** (`src/memory_pod/augment.py`). Everything *behind* it (retrieval,
embeddings, assembly, storage) is one person's domain; everything that *calls* it
(CLI, popup, clipboard loop) is the other's. This matches the constitution's
rule: "keep agent work separated by files/modules."

---

## Part 1 — Optimizations (correctness + speed)

### 1.1 Fix the embedder-mismatch hazard (HIGHEST PRIORITY — protects the demo)
`embeddings.get_embedder()` falls back to `HashingEmbedder` when the
`all-MiniLM-L6-v2` model isn't cached locally. If a profile was **ingested** with
one embedder and later **queried** with a different one, the vectors live in
different spaces → retrieval returns garbage with no error. On stage this looks
like "the personalization broke."
- **Fix:** stamp each record with the embedder identity at ingest time (add an
  `embedder` field to `MemoryRecord` in `memory_store.py`, set in `ingest.py`).
  In `retrieval.py`, detect a mismatch between the active embedder and stored
  records and either (a) re-embed on the fly or (b) emit a loud warning telling
  the user to re-ingest. Reuse the existing `get_embedder()` and `MemoryRecord`
  plumbing.
- **Status:** implemented after this roadmap was fetched. Mismatched records are
  re-embedded on the fly so retrieval stays correct even if the local model cache
  changes between ingest and query.

### 1.2 Stop `compare` from re-ingesting every run
`cli._ensure_demo_profiles_ingested()` re-ingests (and re-embeds) alice + bob on
**every** `compare` call. It's idempotent (content-hashed IDs in
`ingest.make_record_id`) but wasteful and adds latency to the marquee demo.
- **Fix:** skip ingest when the store already exists and the source `memory.md`
  is unchanged (compare file mtime vs. `store_path` mtime via
  `memory_store.store_path`). Keep a `--reingest` flag to force it for the "it
  just learned" demo.
- **Status:** implemented. `compare` skips unchanged demo stores and supports
  `--reingest` for forced refreshes.

### 1.3 Cache the per-profile memory matrix
`retrieval._memory_vectors()` rebuilds and re-normalizes the full NumPy matrix on
every call, even though stored embeddings are already normalized. Cheap to cache.
- **Fix:** memoize the stacked matrix per `(profile, store mtime)` so repeated
  popup/CLI calls are instant.

### 1.4 Minor depth (optional, only if ahead)
- Add chunk overlap in `ingest.chunk_text` (currently hard splits at 900 chars
[truncated — 5836 more characters]
```

### requirements.txt

```
pynput>=1.8.0
pyperclip>=1.9.0
numpy>=2.0.0
sentence-transformers>=3.0.0
pytest>=8.0.0

```

### pyproject.toml

```
[build-system]
requires = ["setuptools>=68"]
build-backend = "setuptools.build_meta"

[project]
name = "memory-pod"
version = "0.1.0"
description = "Local-first personal memory engine for AI prompt furnishing."
readme = "README.md"
requires-python = ">=3.11"
dependencies = [
  "numpy>=2.0.0",
  "pyperclip>=1.9.0",
  "pynput>=1.8.0",
  "sentence-transformers>=3.0.0",
]

[project.optional-dependencies]
dev = ["pytest>=8.0.0"]

[project.scripts]
memory-pod = "memory_pod.cli:main"

[tool.setuptools.packages.find]
where = ["src"]


```

### src/memory_pod/cli.py

```python
"""Command-line interface for the Memory Pod hackathon demo."""

from __future__ import annotations

import argparse
from pathlib import Path

from memory_pod.augment import augment_for_profile, augment_for_stack
from memory_pod.config import DEFAULT_PROFILE, DEMO_PROFILES_DIR, PROFILES_DIR
from memory_pod.ingest import ingest_path
from memory_pod.memory_store import store_path
from memory_pod.pods import (
    PodStack,
    create_pod,
    export_pod,
    import_pod,
    inspect_pod,
    list_pods,
    migrate_legacy_profiles,
)
from memory_pod.remember import remember


def main() -> None:
    parser = argparse.ArgumentParser(prog="memory-pod")
    subparsers = parser.add_subparsers(dest="command", required=True)

    ingest_parser = subparsers.add_parser("ingest", help="Ingest local .md/.txt memory files.")
    ingest_parser.add_argument("path", type=Path)
    ingest_parser.add_argument("--profile", "--pod", dest="profile", default=DEFAULT_PROFILE)

    augment_parser = subparsers.add_parser("augment", help="Furnish a prompt with local memory.")
    augment_parser.add_argument("prompt")
    augment_parser.add_argument("--profile", default=None, help="Legacy alias for --base-pod.")
    augment_parser.add_argument("--base-pod", default=None)
    augment_parser.add_argument("--shared-pod", default=None)
    augment_parser.add_argument("--debug", action="store_true")

    compare_parser = subparsers.add_parser(
        "compare",
        help="Run the same prompt against alice and bob demo profiles.",
    )
    compare_parser.add_argument("prompt")
    compare_parser.add_argument("--debug", action="store_true")
    compare_parser.add_argument("--reingest", action="store_true")

    remember_parser = subparsers.add_parser(
        "remember",
        help="Save a new local memory into a profile (write-back).",
    )
    remember_parser.add_argument("text")
    remember_parser.add_argument("--profile", "--pod", dest="profile", default=DEFAULT_PROFILE)
    remember_parser.add_argument(
        "--tag",
        action="append",
        dest="tags",
        help="Optional tag for this memory; repeat for multiple tags.",
    )

    pod_parser = subparsers.add_parser("pod", help="Create, inspect, and carry Memory Pods.")
    pod_subparsers = pod_parser.add_subparsers(dest="pod_command", required=True)

    pod_create = pod_subparsers.add_parser("create", help="Create a local Pod.")
    pod_create.add_argument("--name", required=True)
    pod_create.add_argument("--id", dest="pod_id", default=None)
    pod_create.add_argument("--kind", choices=("private", "shared"), default="private")
    pod_create.add_argument("--author", default="")
    pod_create.add_argument("--purpose", default="")

    pod_subparsers.add_parser("list", help="List local and imported Pods.")

    pod_inspect = pod_subparsers.add_parser("inspect", help="Preview a portable .mpod file.")
    pod_inspect.add_argument("path", type=Path)

    pod_import = pod_subparsers.add_parser("import", help="Import a portable .mpod file.")
    pod_import.add_argument("path", type=Path)
    pod_import.add_argument("--replace", action="store_true")

    pod_export = pod_subparsers.add_parser("export", help="Export a local Shared Pod.")
    pod_export.add_argument("pod_id")
    pod_export.add_argument("--output", type=Path, required=True)

    pod_subparsers.add_parser(
        "migrate-legacy",
        help="Copy legacy repo profile stores into Application Support.",
    )

    args = parser.parse_args()

    if args.command == "ingest":
        result = ingest_path(profile=args.profile, source_path=args.path)
        print(f"Ingested {result.records_written} chunks for profile '{result.profile}'.")
        print(f"Store: {result.store_path}")
        return

    if args.command == "augment":
        base_pod = args.base_pod or args.profile or DEFAULT_PROFILE
        result = (
            augment_for_stack(
                args.prompt,
                stack=PodStack(base_pod=base_pod, shared_pod=args.shared_pod),
            )
            if args.shared_pod
            else augment_for_profile(args.prompt, profile=base_pod)
        )
        print(result.debug_text() if args.debug else result.furnished_prompt)
        return

    if args.command == "remember":
        record = remember(args.text, profile=args.profile, tags=args.tags or [])
        print(f"✓ Remembered for '{args.profile}': {record.id}")
        print(f"  {record.text}")
        return

    if args.command == "compare":
        run_compare(args.prompt, debug=args.debug, reingest=args.reingest)
        return

    if args.command == "pod":
        _run_pod_command(args)


def run_compare(prompt: str, *, debug: bool = True, reingest: bool = False) -> None:
    """Run the marquee "same prompt, different memory" demo for alice and bob.

    Shared entry point so the judge demo (scripts/judge_demo.py) produces output
    identical to `make demo`.
    """
    _ensure_demo_profiles_ingested(force=reingest)
    print("#" * 72)
    print("# MEMORY POD — same prompt, different memory")
    print(f'# Prompt: "{prompt}"')
    print("#" * 72)
    print()
    for profile in ("alice", "bob"):
        result = augment_for_profile(prompt, profile=profile)
        print("=" * 72)
        print(f"PROFILE: {profile}")
        print("=" * 72)
        print(result.debug_text() if debug else result.furnished_prompt)
        print()


def _ensure_demo_profiles_ingested(force: bool = False, profiles_root: Path = PROFILES_DIR) -> None:
    for profile in ("alice", "bob"):
        memory_file = DEMO_PROFILES_DIR / profile / "memory.md"
        if memory_file.exists() and (force or _needs_ingest(profile, memory_file, profiles_root)):
            ingest_path(profile=profile, source_path=memory_file, profiles_root=profiles_root)


def _needs_ingest(profile: str, memory_file: Path, profiles_root: Path = PROFILES_DIR) -> bool:
    path = store_path(profile, profiles_root)
    return not path.exists() or path.
[truncated — 2060 more characters]
```

### tests/test_radar.py

```python
from memory_pod.radar import resonance_report


def test_resonance_report_points_to_current_pod_workflows():
    report = resonance_report()

    assert "current MVP scope" in report
    assert "Base Pod and Shared Pod workflows" in report
    assert "Tier 0" not in report

```

### scripts/seed_experts.py

```python
"""Seed bundled starter Shared Pods into the local Pod store.

    make seed-experts
"""

from __future__ import annotations

from memory_pod.onboarding import seed_experts


def main() -> None:
    seeded = seed_experts()
    print("Seeded starter Shared Pods: " + ", ".join(seeded))


if __name__ == "__main__":
    main()

```

### scripts/download_model.py

```python
"""Pre-download the local embedding model for demo day."""

from __future__ import annotations

from sentence_transformers import SentenceTransformer

from memory_pod.config import DEFAULT_MODEL_NAME


def main() -> None:
    SentenceTransformer(DEFAULT_MODEL_NAME)
    print(f"Downloaded or verified local cache for {DEFAULT_MODEL_NAME}.")


if __name__ == "__main__":
    main()


```

### tests/test_makefile_defaults.py

```python
from pathlib import Path


def test_os_loop_defaults_match_demo_setup_pods():
    makefile = Path("Makefile").read_text(encoding="utf-8")

    assert "BASE_POD ?= jiahan" in makefile
    assert "SHARED_POD ?= senior-review" in makefile


def test_makefile_prefers_repo_virtualenv_with_system_fallback():
    makefile = Path("Makefile").read_text(encoding="utf-8")

    assert (
        "PYTHON ?= $(if $(wildcard .venv/bin/python),.venv/bin/python,python)"
        in makefile
    )

```

### scripts/seed_demo_profiles.py

```python
"""Re-ingest the checked-in alice/bob memory.md demo profiles."""

from __future__ import annotations

from memory_pod.config import DEMO_PROFILES_DIR, PROFILES_DIR
from memory_pod.ingest import ingest_path


def main() -> None:
    for profile in ("alice", "bob"):
        result = ingest_path(
            profile,
            DEMO_PROFILES_DIR / profile / "memory.md",
            profiles_root=PROFILES_DIR,
        )
        print(f"{profile}: {result.records_written} chunks -> {result.store_path}")


if __name__ == "__main__":
    main()

```

[66 more indexed source files omitted to keep this export small. The full file list is in the Codebase structure section above.]