> For the complete documentation index, see [llms.txt](https://docs.gameplan.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.gameplan.io/tech-specs/core-concepts/social-graph-and-off-chain-data-management.md).

# Social Graph and Off-Chain Data Management

#### **Managing Social Interactions**

Gameplan adopts a hybrid approach to managing social interactions, balancing the benefits of **scalability**, **privacy**, and **verifiability** between on-chain and off-chain storage.

* **Scalability**: By storing large and frequently changing social data (e.g., messages, followers, and interactions) **off-chain**, Gameplan reduces the costs and constraints of on-chain storage. Only necessary cryptographic proofs are stored **on-chain**, ensuring that the platform can handle increasing user activity without becoming prohibitively expensive or resource-intensive.
* **Privacy**: Sensitive social data, such as user connections and interaction histories, remains **off-chain** to protect user privacy. The public blockchain only stores cryptographic hashes or proofs, preventing exposure of personal data while ensuring the integrity and authenticity of interactions when needed.

#### **Verifiable Off-Chain Data**

Gameplan ensures that off-chain data remains verifiable and consistent through the use of on-chain cryptographic proofs.

* **Cryptographic Hashes**: Social data updates (e.g., follower lists or interactions) are hashed and stored **on-chain**, keeping the bulk of the data **off-chain** while ensuring its integrity through verifiable on-chain proofs.
* **Tamper-Proof Updates**: Each off-chain update is recorded on-chain as an immutable, tamper-proof cryptographic hash, safeguarding the integrity of social interactions.
* **Merkle Trees & Proofs**: Gameplan uses **Merkle trees** to validate off-chain data against on-chain proofs, ensuring consistency and accuracy of social data such as follower counts or interactions.

This integration ensures that Gameplan’s social data is secure, verifiable, and scalable across both on-chain and off-chain systems.

#### **Decentralized Data Storage**

Gameplan's decentralized storage uses a network of distributed nodes to store and replicate off-chain data securely.

* **Distributed Data Storage**: Data is stored across multiple nodes to ensure availability and resilience. Users can choose where their data is stored and manage their encryption keys.
* **Consensus Mechanism**: A consensus system ensures data consistency across nodes, and blockchain integration anchors critical metadata on-chain.
* **Privacy and Access Control**: Both private and public data are managed securely, with customizable rules for sharing data as needed.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.gameplan.io/tech-specs/core-concepts/social-graph-and-off-chain-data-management.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
