> ## Documentation Index
> Fetch the complete documentation index at: https://harisfazillah.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# DSOM Automated State Sync

> Governance rules for Semantic Compaction via GitHub Actions. Deep State of Mind framework. Deep State of Mind framework. Deep State of Mind framework.

## 1. Vectorized Memory Tiering

Instead of pushing an entire project history into every prompt, DSOM categorises information into distinct operational layers:

* **Active Layer**: Houses only the immediate, high-priority variables for the current task.
* **Compressed Layer**: Stores foundational rules and past decisions as dense, key-value indices (`.agents/brain/current_state.dsom`).
* **Archival Layer**: Offloads long-term data to the Git history and Sovereign Markdown Palace.

## 2. Semantic Compaction (Token Distillation)

DSOM applies a "distillation loop" using an automated GitHub Action.
When a Pull Request is merged, `.github/workflows/dsom-pr-sync.yml` triggers `.github/scripts/action_update_dsom.py`.
This script calls an LLM (e.g. OpenAI) to review the PR diff and update `.agents/brain/current_state.dsom` strictly in OKF v0.1 format, eliminating redundant conversational fluff and appending only critical architectural decisions.

## 3. Configuration

* Ensure the `OPENAI_API_KEY` secret is available to the GitHub Action.
* The state is persisted in `.agents/brain/current_state.dsom`.

***

*Deep State of Mind (DSOM) For My AI Protocol | Harisfazillah Jamel (LinuxMalaysia) | 2026-08-14*
*Standard: UK English | DBP-standard Bahasa Melayu Malaysia (Piawai) | GNU General Public License v3.0*


## Related topics

- [DSOM State Sync Skill](/skills/dsom-state-sync.md)
- [Mintlify One-Way Docs Sync & Safety Guards Specification](/governance/mintlify-one-way-sync-pipeline.md)
- [HOWTO: audit-pre-flight - Intelligence Integrity Sync](/tools/howto-audit-pre-flight.md)
- [🧠 The Tri-Phasic Mind: DSOM Cognitive Architecture and Functional Subsystems](/governance/dsom-tri-phasic-cognitive-architecture.md)
- [[AGENT] DSOM Cognitive Digital Twin: Project Operational Protocol (v2.0)](/governance/ai-cognitive-twin-protocol.md)
