Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 52 additions & 0 deletions .graphifyignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Graphify input exclusions
# Purpose: keep Graphify as an intentional map, not a recursive/bloated corpus.

# Graphify's own outputs and transient files
graphify-out/
.graphify_*
*.graphml
cypher.txt

# Archives and historical snapshots: query intentionally, do not re-index by default
archive/
archives/
.archives/
conductor/archive/
conductor/archives/
.archive/

# Agent/workflow generated state and logs
.archon/run/
.worktrees/
.worktree/
logs/
*.log
*.tmp
*.bak

# Dependencies/build artifacts
.git/
node_modules/
.venv/
venv/
__pycache__/
dist/
build/
.next/
.cache/
.pytest_cache/
.coverage

# Sensitive/local configuration
.env
.env.*
*.pem
*.key
*.sqlite
*.sqlite3

# Protected sync folders: require explicit per-request approval
Sync/
sync/
**/Sync/**
**/sync/**
58 changes: 58 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Elume Agent Instructions

This is the canonical instruction file for agents working in this repository.
`CLAUDE.md` and `GEMINI.md` should be symlinks to this file.

## Project Frame

- ALWAYS treat Elume as an independent Python library and cognitive substrate.
- NEVER frame Elume as a Dionysus Core component or require Dionysus knowledge for first-use documentation.
- ALWAYS make the primary quickstart a clean, standalone tutorial that runs without Dionysus, FastAPI, Graphiti, Neo4j, MemEvolve, or any agent framework.
- NEVER list adjacent systems in beginner-facing quickstart copy just to say they are not required. Say only what the user needs.
- ALWAYS place Dionysus as an optional downstream demonstration or advanced integration example, subordinate to the library-first user path.
- ALWAYS verify public API examples against the local repo before publishing tutorial claims.

## Code And Documentation Work

- ALWAYS check the worktree before editing and preserve unrelated local files.
- ALWAYS use existing Elume APIs and tests as the source of truth for examples.
- NEVER claim release readiness, test counts, or package status from old notes without refreshing live repo state.
- For docs-only changes, run at least `git diff --check`; when a tutorial includes runnable code, smoke-test that code.
- For code changes, run focused tests first, then broader tests when the blast radius justifies it.

## Reflection Practice

- ALWAYS do some reflection after a correction from Dr. Mani changes the frame of the work.
- Reflect about the reflection honestly: identify whether the mistake was a fact error, a framing error, an audience error, or an execution error.
- If the mistake is durable and likely to recur, add the lesson to this file in plain language before wrapping the session.
- Keep reflection practical. The goal is better next-session behavior, not apology text.

## Knowledge Captured

- 2026-05-06: Elume's public story is library-first. Dionysus Core consuming `elume` is evidence that Elume works as a downstream dependency, but it is not the main onboarding story. The main onboarding story should show a clean user building with Elume directly from PyPI.
- 2026-05-06: The quickstart should demonstrate Elume's deterministic memory/replay value without requiring Dionysus. Dionysus belongs in a later "integration example" section.
- 2026-05-06: Beginner-facing quickstart copy should not name unrelated adjacent libraries or frameworks. The reader is agnostic and should only see the tools needed for the tutorial.
- 2026-05-06: `linoss-dynamics` is its own domain-agnostic numerical runtime. Elume may delegate raw oscillator stepping to it, but Elume owns `LinOSSEncoder`, trajectory records, belief/basin meaning, and replay/memory semantics. Do not push Elume-specific encoders into `linoss-dynamics`.
- 2026-05-06: Today's main miss was a framing error, not a lack of code context. I kept pulling explanations toward Dionysus, MemEvolve, and LinOSS because those were salient from recent work. Dr. Mani's correction was that beginner-facing Elume material should start from the user's task and only introduce names the user needs right now.
- 2026-05-06: Reflection on that reflection: the first reflection can still be too self-centered if it only says "I over-mentioned adjacent systems." The operational rule is sharper: before writing a quickstart, ask what the reader is trying to do in the first five minutes, then remove every proper noun that does not help that action.

## Graphify

This project has a Graphify knowledge graph at `graphify-out/`.

Rules:
- Before answering architecture or codebase questions, read `graphify-out/GRAPH_REPORT.md` for god nodes and community structure.
- If `graphify-out/wiki/index.md` exists, navigate it instead of reading raw files.
- For cross-module "how does X relate to Y" questions, prefer `graphify query "<question>"`, `graphify path "<A>" "<B>"`, or `graphify explain "<concept>"` over grep. These traverse the graph's extracted and inferred edges instead of scanning files.
- After modifying code files in this session, run `graphify update .` to keep the graph current.

## Graphify Boundary

Graphify is a project map, not ambient source context.

- Do not read or re-index `graphify-out/` during normal agent work.
- Do not treat Graphify output as campaign or source truth unless a run manifest explicitly authorizes it.
- Use `.graphifyignore` before running Graphify.
- Prefer `graphify update .` over full rebuilds.
- Historical graph snapshots belong under `conductor/archive/graphs/` only at meaningful milestones, and should be linked from track closure notes rather than pasted into active tracks.
- Do not index archives, generated runs, worktrees, Sync directories, secrets, or dependency/build artifacts.
1 change: 1 addition & 0 deletions CLAUDE.md
1 change: 1 addition & 0 deletions GEMINI.md
63 changes: 63 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,69 @@ Requires Python `>=3.11`.
pip install elume
```

## Quickstart

This example shows Elume's core value in one small script: a memory strategy can
change, and the change is still replayable. The same input produces the same
result and the same post-state hash, which gives you an audit trail for agent
memory instead of an opaque update.

Create `elume_quickstart.py`:

```python
from elume.envelope.ops import resolve
from elume.envelope.protocol import SCHEMA_VERSION, EnvelopeInput, Verdict
from elume.envelope.snapshot import serialize_strategies
from elume.models import Strategy


strategies = (
Strategy(name="careful", genotype={"temperature": 0.2}, created_at=1.0),
Strategy(name="balanced", genotype={"temperature": 0.6}, created_at=1.0),
Strategy(name="bold", genotype={"temperature": 0.9}, created_at=1.0),
)

scenario = EnvelopeInput(
schema_version=SCHEMA_VERSION,
scenario_id="quickstart.evolution_step",
run_id="run-1",
seed=123,
operation="evolution.step",
operation_args={
"fitness": {"careful": 0.2, "balanced": 0.8, "bold": 0.5},
"elite_k": 1,
"operator_config": {"kind": "jitter", "scale": 0.05},
},
provider_snapshot=serialize_strategies(strategies),
)

operation = resolve("evolution.step")
first = operation.run(scenario)
second = operation.run(scenario)

assert first.verdict is Verdict.PASS
assert first.result == second.result
assert first.post_state_hash == second.post_state_hash

children = list(first.result["children"])
print("verdict:", first.verdict)
print("new children:", [child["name"] for child in children])
print("population:", first.result["population_ids"])
print("post-state hash:", first.post_state_hash)
print("replay matched:", first.post_state_hash == second.post_state_hash)
```

Run it:

```bash
python elume_quickstart.py
```

The important line is `replay matched: True`. Elume created new child memory
strategies, then proved that the same scenario can be replayed exactly.

For a fuller walkthrough, see [docs/quickstart.md](./docs/quickstart.md).

## Quickstart (development)

For local development, use [`uv`](https://github.com/astral-sh/uv) and an editable install:
Expand Down
20 changes: 20 additions & 0 deletions conductor/archive/graphs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Graphify Snapshot Archive

Store only selected historical Graphify snapshots here.

Use this archive for milestones with historical value, such as:

- major architecture transitions
- before/after migrations
- Conductor track closure points
- release or recovery milestones

Recommended snapshot contents:

- `GRAPH_REPORT.md`
- `graph.json`
- `graph.html` only when visual inspection matters

Do not archive every run. Keep the active current map in the project root `graphify-out/` and use `graphify update .` for routine refreshes.

Agents should not read this archive unless a task or run manifest explicitly authorizes that snapshot.
Loading
Loading