MCPcopy Create free account
hub / github.com/TelegramMessenger/cocoon

github.com/TelegramMessenger/cocoon @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
2,522 symbols 5,190 edges 213 files 297 documented · 12% updated 54d ago★ 85540 open issues

Browse by type

Functions 2,150 Types & classes 372
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Confidential Compute Open Network (COCOON) – Decentralized AI Inference on TON

COCOON enables running AI models in trusted execution environments, while earning TON cryptocurrency for compute services.

  • GPU owners earn TON by serving models
  • App developers plug into low-cost, secure and verifiable AI compute
  • Users enjoy AI seamlessly, with full privacy and confidentiality

This repository contains all the necessary tools and documentation to both serve and access models via COCOON.

Quick Links

For Workers: offering GPUs for computation

For Developers: requiring secure AI compute

  • Build Instructions: See below for reproducing worker distribution from source

Reproducible Build

Anyone can verify the worker distribution by rebuilding from source. Note that this step is not needed to run your own workers.

# 1. Build the VM image (reproducible)
./scripts/build-image prod

# 2. Generate distribution
./scripts/prepare-worker-dist ../cocoon-worker-dist

# 3. Verify the TEE image matches the published release
cd ../cocoon-worker-dist
sha256sum images/prod/{OVMF.fd,image.vmlinuz,image.initrd,image.cmdline}
# Compare with the published checksums

The same goes for model images:

# 1. This will generate a model tar file with the full model name, which includes hash and commit.
./scripts/build-model Qwen/Qwen3-0.6B
# Compare with the published model name

License

See LICENSE file.

Core symbols most depended-on inside this repo

Shape

Method 1,668
Function 482
Class 347
Enum 25

Languages

C++91%
Python9%
Go1%

Modules by API surface

runners/BaseRunner.hpp116 symbols
runners/helpers/ValidateRequest.cpp106 symbols
runners/BaseRunner.cpp77 symbols
runners/proxy/ProxyRunner.cpp59 symbols
tl/generate/tl_writer_java.cpp53 symbols
mt-tools/src/mt/translate.py48 symbols
tdport/td/net/SslStream.cpp43 symbols
tl/generate/tl_writer_hpp.cpp42 symbols
runners/smartcontracts/RootContractConfig.hpp41 symbols
tl/generate/tl_writer_cpp.cpp40 symbols
runners/proxy/ProxyClientInfo.h40 symbols
tee/cocoon/sev/PKI.cpp38 symbols

For agents

$ claude mcp add cocoon \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page