Skip to main content

bittensor

Project description

Bittensor

Pushing Image to Docker Discord Chat PyPI version License: MIT

Internet-scale Neural Networks

DiscordDocsNetworkResearchCode

Bittensor is a p2p-market that rewards the production of machine intelligence with a digital token called Tao. Peers in the system train models by mining knowledge from unsupervised datasets to share with others. Consumers access the network and distill what they learn into production models. The network is collectively-run, open-source, open-access, decentralized, and incentivized to produce state-of-the-art intelligence. For more info, read our paper.

Install

$ pip3 install bittensor

Client Open In Colab

import bittensor
import torch
wallet = bittensor.wallet().create()
graph = bittensor.metagraph().load().sync().save()
text = torch.tensor([bittensor.tokenizer().encode( "The quick brown fox jumped over the lazy dog" )], dtype=torch.int64)
representations, _ = bittensor.dendrite( wallet ).forward_text(
    endpoints = graph.endpoints,
    inputs = [text for _ in graph.endpoints]
)
representations = # List[ (1, 9, 512) ... x N ]

Server

import bittensor
import torch
from transformers import BertModel, BertConfig

model = BertModel(BertConfig())

def forward ( pubkey, inputs_x, modality ):
  return model( inputs ).narrow(2, 0, bittensor.__network_dim__)

wallet = bittensor.wallet().create()
axon = bittensor.axon (
    wallet = wallet,
    forward = forward,
).start().subscribe()

...

License

The MIT License (MIT) Copyright © 2021 Yuma Rao

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Acknowledgments

learning-at-home/hivemind

Project details


Release history Release notifications | RSS feed

This version

1.1.8

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bittensor-1.1.8.tar.gz (87.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bittensor-1.1.8-py3-none-any.whl (137.4 kB view details)

Uploaded Python 3

File details

Details for the file bittensor-1.1.8.tar.gz.

File metadata

  • Download URL: bittensor-1.1.8.tar.gz
  • Upload date:
  • Size: 87.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.10

File hashes

Hashes for bittensor-1.1.8.tar.gz
Algorithm Hash digest
SHA256 74600630f0d9ca63dd4f907fc8ca1b2ad9c176b6d0d6d7e78e094ebbdcb52729
MD5 c79439b6f1d2589f263ebd6d1f7f7493
BLAKE2b-256 115ad2f9a7654e3142f4e9b1e1f6ec82d54e42333df6195e974b0c523763c69b

See more details on using hashes here.

File details

Details for the file bittensor-1.1.8-py3-none-any.whl.

File metadata

  • Download URL: bittensor-1.1.8-py3-none-any.whl
  • Upload date:
  • Size: 137.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.10

File hashes

Hashes for bittensor-1.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 4bcf19f433ff53bdc8bb9a55c99ff531217b1627b172840a86f606288862f1e7
MD5 2da4bb301eee66053b2085fe5e0e50a5
BLAKE2b-256 5a88d226e82808f8531427a19f660c812cc13364365b2988a36a9a3de7a0047a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page