Skip to content

Latest commit

 

History

History
55 lines (36 loc) · 3.32 KB

File metadata and controls

55 lines (36 loc) · 3.32 KB

Repository Structure

Where is the code? The DivineOS codebase lives at repo root. After a normal clone you should see:

  • README.md, requirements.txt, api_server.py, UNIFIED_INTEGRATION.py
  • Directories: law/, memory/, core/, consciousness/, scripts/, tests/, data/, docs/, etc.

If you only see README.md and perhaps __pycache__/ at the top level, something is wrong:

  1. Git worktrees: If this repo was set up with git worktree add, the main code might have been in a linked worktree (e.g. .worktrees/divineos/). We do not commit .worktrees/ (it is in .gitignore). The canonical layout is: all code at repo root. See "How to fix the layout (code in .worktrees/divineos)" below.
  2. Shallow or partial clone: Ensure you cloned the full repo (git clone <url> with no --depth or filter that might omit paths).

Package naming (why law.consciousness_pipeline?)

Top-level Python packages are named by role, not by generic words like "utils":

Package Role What’s in it
law/ Governance and canonical rules The 7-stage pipeline (consciousness_pipeline.py), council, ethos, void, compass, LEPOS, intent, injection resistance. "Law" = the rule layer that decides what is allowed and how responses are shaped.
memory/ Persistent state MNEME (persistent_memory.py), semantic storage, integrity (Merkle, seals).
core/ Shared runtime Feeling continuity, vessel state, request perception, affective state engine, divine context.
consciousness/ Higher-level consciousness systems Session integration, narrative identity, preference store, shadow log, embodied reflection.
monitoring/ Observability Threat detection engine, metrics, GUTE.
learning/ Feedback and learning Outcome feedback, persistence layer, void learning bridge.

So from law.consciousness_pipeline import get_consciousness_pipeline means: import the canonical pipeline from the governance package. It’s not a legal or regulatory module — it’s the layer that applies the system’s “laws” (stages, veto points, council).


Quick check

From repo root, run:

python -c "from law.consciousness_pipeline import get_consciousness_pipeline; print('OK')"

If that succeeds, you have the right structure and Python path.


How to fix the layout (code in .worktrees/divineos)

This is the single biggest barrier to someone engaging with the code. Docs don’t fix it — the repo layout has to change. When you’re on a real computer (not phone), do this once:

  1. From inside the worktree (where the code actually lives), e.g. cd .worktrees/divineos (or wherever your full tree is):
    git checkout main
  2. Copy everything up to repo root so that api_server.py, law/, memory/, etc. sit next to README.md at the root. (How you do this depends on your OS: copy/move the contents of .worktrees/divineos/ to the repo root, excluding .git if the worktree has its own.)
  3. Commit and push from the repo root so that the default clone has the full codebase at top level.

After that, a fresh clone will show the full project immediately; no worktree needed. If you need step-by-step for your exact OS/setup, see AUDIT_RESPONSE.md.