Documentation that ships.
Start with a task
Publish your first repositoryAuthenticate, create a versioned repository, and push a model card.Make an inference requestSend an OpenAI-compatible request through a configured Provider.Explore a datasetPreview rows, media, splits, and SQL results in Dataset Viewer and Data Studio.Connect an AI agentUse MEGA MCP, plugins, and portable Skills from your coding assistant.
Hub
MEGA DocumentationMEGA combines a model artifact runtime with a collaborative Hub. Use the same platform to publish models, datasets, and Spaces; automate repositories; run…QuickstartPublish and retrieve your first versioned repository on MEGA Hub. This path uses a small model card so you can verify authentication, repository creation,…Hugging Face CompatibilityMEGA supports core Hugging Face Hub workflows for models, datasets, Spaces, and Storage Buckets. Existing hf, huggingfacehub, Transformers, Diffusers, and…IntegrationsMEGA offers several public ways to work with Hub resources. Choose the smallest interface that fits the job; this keeps credentials and permissions easy to…Hub RepositoriesMEGA Hub repositories provide one revisioned storage model for model, dataset, space, and mcp content. Every file mutation creates an immutable commit, while…Repository SettingsRepository settings control the name, description, tags, license, visibility, and community features for one model, dataset, or Space repository. Open the…Repository CardsThe root README.md is the long-form card for a model, dataset, or Space. It explains what the repository contains and how to use it, while repository metadata…Repository LicensesDeclare a license before publishing a model, dataset, or Space whose contents others may use. A license tells readers the terms for code, weights, data, and…Gated RepositoriesGated access lets an author share a public model, dataset, or Space repository only after an individual user accepts the repository terms and, when selected,…Large FilesUse MEGA's resumable upload and download commands for large model weights, dataset archives, and Space assets. The client selects the appropriate transfer…Storage LimitsRepository and Bucket limits protect shared service capacity. The applicable limit depends on the owner, plan, repository type, and requested operation. The…Local CacheMEGA clients cache downloaded revisions locally to avoid fetching immutable files again. A cache is an optimization, not a source of truth: use an explicit…Continuous IntegrationUse a scoped MEGA token in CI to validate, publish, or download a pinned release. Keep the token in your CI secret store and grant only the scopes the…Discussions and Pull RequestsDiscussions and pull requests provide one collaboration surface for model, dataset, and Space repositories. They share numbering, Markdown messages,…NotificationsThe MEGA inbox keeps repository and community activity in one place. Open Notifications to review unread items and follow their links back to the relevant…WebhooksMEGA webhooks deliver signed JSON events to a public HTTPS receiver. Routes can cover repositories owned by the current account or one explicit repository.Repository Next StepsAfter creating a repository, make it useful to others:NotebooksNotebooks can be stored, reviewed, and versioned as ordinary repository files. MEGA renders .ipynb files as a safe static preview: Markdown, code, and plain…Model RepositoriesModel repositories keep weights, configuration, tokenizer assets, documentation, and release history under one versioned owner/name identity. They use the…Model CardsA model card is the root README.md of a model repository. It gives readers the context needed to decide whether a release is appropriate for their use. MEGA…Uploading ModelsPublish model files, configuration, tokenizer assets, and the model card in one revision. A complete release lets a reader download and load the same artifact…Downloading ModelsDownload a complete model revision or the specific files your application needs. Use a tag or commit ID for reproducible automation.Model LibrariesMEGA repositories are library-neutral: a repository can store files consumed by Megatensors, transformers, Diffusers, or another compatible client. The…Model EvaluationsModel repositories can publish structured benchmark results from HF-compatible .evalresults/.yaml files. The model page reads files merged into main as…Model Release ChecklistUse this checklist before announcing a model release:Model FAQUse public for unrestricted distribution, gated for a public listing with individual access terms, and private when the repository itself must not be…Model HardwareModel repositories can document the hardware and software assumptions used for training, evaluation, conversion, and inference. Put this information in the…Model TasksUse concise, stable task tags to help readers find a model. A task tag is a discovery signal, not proof that a release is compatible with a particular runtime…Model WidgetsA model page shows an inline chat widget when the live Inference Provider catalog contains a healthy chat-completions route for the same owner/model ID.…GGUF ModelsMEGA can store GGUF files in a model repository, but a file extension alone does not declare a complete runtime contract. Document the producer, quantized…Signing and TrustMEGA treats downloaded artifacts as untrusted until both integrity and provenance checks pass.Dataset RepositoriesDataset repositories provide revisioned storage for training data, evaluation sets, annotations, schemas, and the documentation needed to use them…Datasets OverviewDataset repositories provide versioned files, a dataset card, discovery metadata, and controlled access. Use a dataset repository for material that needs a…Dataset CardsA dataset card is the root README.md of a dataset repository. It explains what the data contains, how it was collected or derived, how to load it, and where…Uploading DatasetsCreate a dataset repository, organize its files by split or release, and publish the card with the data.Downloading DatasetsDownload a complete snapshot or selected files from a dataset repository. Pin the revision used by an experiment.Streaming DatasetsMEGA serves repository files through revision-aware download URLs. For a dataset that is too large to materialize locally, design the reader to process files…Dataset File OrganizationOrganize a dataset so a reader can identify files, splits, and schema without guessing. A simple release layout is:Ingesting DatasetsIngest data into a dataset repository only after checking its license, provenance, and privacy obligations. Preserve source metadata and document the…Dataset LibrariesMEGA dataset repositories are format-neutral. A dataset card should identify the library or reader expected to load the files, the supported formats, and a…Dataset ViewingDataset Viewer is the browser preview in a dataset repository's Data Studio tab. It lets readers inspect indexed dataset configurations and splits without…Dataset SQL ConsoleDataset SQL Console lets you run a read-only SQL query against the selected configuration and split in a dataset's Data Studio tab. It is intended for quick…Data StudioData Studio is the dataset workspace available from the Data Studio tab of every dataset repository. It brings together Dataset Viewer, SQL Console, and the…Image, Audio, and Video DatasetsMedia datasets need more context than a file list. State media format, sampling or frame rate where relevant, annotations, split rules, consent or rights…SpacesMEGA Spaces turn a space repository into a deployed web application. Source, revisions, visibility, discussions, and organization ownership stay in the Hub;…Spaces Configuration ReferenceConfigure a Space in the YAML frontmatter at the top of its root README.md. The card is still rendered as documentation; the recognized Space fields select…Spaces DependenciesCommit every dependency declaration needed to build a Space. A Docker Space uses its Dockerfile; a Python-oriented Space should keep its dependency files next…Space SettingsSpace settings control runtime hardware, sleep behavior, variables, secrets, and lifecycle actions. Open the Space page or use the CLI:Space HardwareMEGA Spaces run on the hardware flavors currently returned by the Space API and CLI. Query before choosing a flavor:ZeroGPU SpacesMEGA does not currently offer ZeroGPU. Hugging Face ZeroGPU requires a function-scoped GPU lease for Gradio requests; MEGA's connected GPU capacity is an…Space Dev ModeDev Mode gives an eligible Space a development-oriented workflow while you iterate on its source. It is available to PRO personal Spaces and Team or…Space StorageSpace source is stored in its repository revision. The application filesystem outside /data is temporary and may be replaced on each build or restart.Spaces API EndpointsUse the Space API to inspect, control, and observe a Space from another application. The OpenAPI Explorer is the source of truth for current schemas and…Gradio SpacesSet sdk: gradio in a Space card when the repository contains a Gradio application. Keep the entry-point file and dependency declaration in the same revision,…Streamlit SpacesSet sdk: streamlit in the Space card and commit the Streamlit entry point and dependencies with the application source.Static SpacesSet sdk: static for a Space that serves a static HTML, CSS, and JavaScript application from its repository. Keep the published entry files in the same…Docker SpacesSet sdk: docker, declare the public application port, and commit a Dockerfile with the Space source.Jupyter Notebook SpacesA Jupyter Notebook Space is a private managed JupyterLab workspace. Set the repository card metadata to sdk: jupyter and enable persistent Space storage. MEGA…Embed a SpacePublic Spaces can opt in to iframe embedding. Add embed: true to the Space card and deploy the revision:Space Custom DomainsPublic Spaces support self-service custom domains through the Space API:Spaces and MCPMEGA has two separate MCP surfaces:Spaces as Agent ToolsA Space can be a useful human-facing demo for an agent workflow, but MEGA does not automatically treat every Space as an agent tool. Use the MCP Server for…Authentication in SpacesEnable built-in identity sign-in by setting megaoauth: true in the Space card. The Space receives a public OAuth client configuration automatically; no client…Storage BucketsStorage Buckets are mutable file stores for checkpoints, training artifacts, media, exports, and Job inputs. A Bucket has an owner/name identity, but it is…Bucket Access PatternsUse mega://buckets/OWNER/NAME/PATH with MEGA-native clients and hf://buckets/OWNER/NAME/PATH with configured Hugging Face-compatible clients. Buckets also…Bucket S3 GatewayStorage Buckets provide an S3-compatible, path-style gateway for applications that already use S3 clients and SDKs. The gateway works only with Storage…Bucket IntegrationsBuckets integrate with MEGA CLI, the Python client, and compatible huggingfacehub workflows. They are suitable for mutable artifacts that do not need…Bucket SecurityUse private Buckets for artifacts that are not ready for public distribution. Visibility controls reads; ownership, organization role, resource group, and…Subscriptions and PlansMEGA subscriptions unlock plan features for either an individual or an organization. They are separate from prepaid compute credit, which pays for metered…PRO PlanPRO is the subscription for an individual MEGA account. It adds personal features and capacity; it does not apply to organizations you belong to.Team and Enterprise PlansTeam and Enterprise are subscriptions for MEGA organizations. They unlock organization capabilities; they do not change an individual member's personal plan.BillingBilling has two separate parts:JobsMEGA Jobs runs a public Docker image and command in a MEGA-managed environment. The interface is intentionally Docker-like: dispatch with run, discover active…Jobs OverviewMEGA Jobs runs a public container image and command for a bounded duration. Use Jobs for batch tasks, scripts, scheduled work, and reproducible command…Jobs QuickstartInstall the CLI, sign in, inspect available hardware, and run a small command:Job ConfigurationConfigure a Job with a public image, command, timeout, non-secret environment variables, secret names, labels, and optional organization namespace.Manage JobsUse the Job ID returned by mega jobs run to inspect, stream, cancel, or wait for a Job.Schedule JobsCreate a recurring Job when a command should run on a defined schedule. Verify the first run manually before relying on a schedule for a production workflow.Job Webhook AutomationUse Webhooks to notify an external HTTPS service about repository events that should trigger a Job workflow. Verify the signed payload before acting on it,…SandboxesMEGA Sandboxes provide supported interactive execution sessions for workflows that need to run commands, inspect state, or collect bounded metrics. They are…Job ExamplesRun a small command first, then add explicit inputs, labels, and timeout:Serving ModelsJobs are for bounded container execution and do not expose a long-lived public service endpoint. Use Spaces for an interactive application or Inference…Jobs ReferenceThe Jobs guide documents the public CLI, runtime states, pricing rules, and endpoint groups. The live OpenAPI Explorer is authoritative for request schemas,…Search and DiscoveryMEGA offers global search, type-specific catalogs, social follows, and a personalized home feed. Discovery uses public repository metadata; private resources…CollectionsCollections are ordered, shareable lists of MEGA models, datasets, Spaces, papers, other collections, and Storage Buckets. Use collections to publish a…Paper PagesPaper Pages connect an arXiv publication to verified MEGA authors and public model, dataset, or Space releases. They provide a stable research-identity record…Community ModerationRepository discussions, papers, and community content can be reported when they violate applicable policy or create a safety concern. Use the reporting…OrganizationsAn organization is a shared owner namespace for repositories, Jobs, Spaces, billing, and security policy. People always sign in with personal accounts;…Audit LogsEligible organizations can review an audit log of important membership, repository, access-policy, and administration changes. Open Organization Settings →…Organization Storage RegionsOrganization Storage Regions let Team and Enterprise administrators choose the default location for new model, dataset, and Space repositories. The chosen…Organization Single Sign-OnTeam and Enterprise organizations can configure single sign-on (SSO) in Organization Settings → Security. SSO centralizes sign-in requirements for members…SCIM ProvisioningEnterprise organizations can use SCIM to provision and deprovision members from an identity provider. Configure SCIM only after SSO has a verified recovery…Service AccountsEnterprise service accounts are organization-owned identities for automation that must outlive an individual member. Use one service account and one scoped…OAuth ApplicationsOrganization administrators can register OAuth applications for integrations that need a user-approved MEGA authorization flow. Manage applications from…AuthenticationMEGA uses the same authentication boundary across the CLI, Python SDK, and Web API. Interactive users normally use the browser device flow; automation should…Access TokensAccess tokens authenticate CLI, SDK, and API automation. Create them in Settings → Access Tokens, give each token a descriptive name, and select only the…PasskeysPasskeys provide phishing-resistant browser sign-in with a fingerprint, face, device PIN, or password-manager confirmation. MEGA stores the credential's…Two-Factor AuthenticationEnable time-based one-time password (TOTP) multi-factor authentication from Settings → Security. MFA adds a second proof at sign-in and protects an account…Account SecurityMEGA protects browser sessions, API tokens, Git credentials, organization access, and destructive operations as separate security boundaries. Use the controls…Trusted PublishersUse a short-lived workload identity where your CI platform and MEGA integration support it, instead of putting a long-lived personal token in every workflow.…Resource GroupsResource groups add repository-specific access controls for an organization. Use them when an organization-wide role would grant more access than a project…Organization Network SecurityOrganization Network Security is an Enterprise control for limiting access to organization resources from trusted networks. Administrators can define approved…Publisher AnalyticsPublisher Analytics is a Team and Enterprise organization feature for reviewing how the organization's models, datasets, and Spaces are being published and…Organization CardsAn organization card is the public, long-form introduction on an organization profile. It gives a publisher room to explain its work, link to important…Content PreferencesContent Preferences let an account control selected discovery and recommendation behavior. Open Settings → Content Preferences to review available options and…Delete Your AccountOpen Settings → Account to request account deletion. Review the affected personal repositories, memberships, tokens, keys, subscriptions, and compute credit…Hub APIThe canonical Hub API is the language-neutral interface for repositories, accounts, organizations, community workflows, compute, billing, and platform…Python SDKThe Python SDK is the application entry point for automating MEGA Hub from Python. It talks to the same Hub API used by the web application and CLI; it does…Rate LimitsMEGA applies rate limits to public traffic and authenticated automation. Limits protect shared Hub, Git, and compute capacity; authentication and…MCP ServerThe official MEGA MCP server gives AI clients typed, bounded access to Hub resources through the focused HF-style Version 1 contract.MCP MarketplaceThe MCP Marketplace lets MEGA users publish a public MCP repository backed by a separate managed private runtime and earn Mega Coins when other users make…Service status and supportThis page helps Hub users diagnose an unavailable page, API call, Git operation, Space, or Job. It covers user-visible service status and support only.
Megatensors
Tensor RuntimeThis page documents the local tensor runtime. For Hub repositories, Jobs, authentication, and webhooks, use the Hub Python SDK.MEGA CLI ReferenceThe mega CLI is the shortest path for interactive Hub work and shell automation. Its command layout follows the same domain boundaries as the Web API and…Conversionmega convert reads a Hugging Face model directory and writes MEGA shards plus a model.mega.index.json manifest.Hub Python SDKMegaHubClient is the typed Python client for MEGA Hub service operations. It is separate from the local Tensor Runtime API, which opens and loads .mega…Artifact FormatMEGA files are intentionally not safetensors files. The format is optimized for explicit metadata, aligned payloads, and backend-specific loading paths.Model and TokenizerMEGA stores enough model and tokenizer metadata to make an artifact usable without keeping the original Hugging Face directory beside it.BackendsMEGA separates the public Python API from backend-specific I/O. The same artifact can be opened through different backends depending on the host.KV Cache SidecarsKV cache data is stored outside the model artifact in .megakv sidecars. This keeps model releases immutable while allowing deployments to reuse…ExamplesExample scripts live under megatensors/examples in the MEGA source tree. They are not installed with the Python wheel, so run this page from a source checkout…
Inference Providers
Inference ProvidersMEGA Inference Providers is a routed, OpenAI-compatible inference service at inference.tensorplay.cn. Use one MEGA token to call models across supported…Your First Inference Provider CallThis guide takes you from a live model mapping to a successful routed request. MEGA runs the model on a healthy registered Provider; you do not deploy an…Model CatalogThe Inference Provider catalog lists model and Provider routes that are healthy, validated, and available for new requests. Use it instead of assuming that…Routing and Provider SelectionMEGA selects an eligible Provider route for each request from the public model ID, task, account preferences, billing mode, price, and current availability.…Pricing and BillingInference Provider prices are published per live model route in USD per one million input and output tokens. MEGA Routed Inference charges the selected…Custom Provider KeysA custom Provider key lets MEGA authenticate and route a request while the selected Provider bills your external account directly. Keys are supported only for…Organization BillingOrganization billing lets an eligible workspace own inference routing preferences, shared custom keys, usage, compute credit, and a monthly hard limit. It is…Chat CompletionsChat Completions sends an ordered message history to a live Provider and returns the OpenAI-compatible choices response. Use it for applications already built…Responses APIThe Responses API exposes the OpenAI-compatible /v1/responses contract for text generation, instructions, tools, structured output, and event-based streaming.…EmbeddingsThe Embeddings endpoint converts one string or a batch of strings into OpenAI-compatible numeric vectors. MEGA routes only to mappings validated for the…Function CallingFunction Calling lets a model request an action from your application. MEGA returns the requested tool call; your application validates it, decides whether it…Structured OutputStructured Output asks a model to return data that conforms to a declared shape, such as a JSON object for an extraction or classification workflow. It is…Clients and SDKsMEGA's public Router is OpenAI-compatible, so applications call it through an OpenAI SDK or raw HTTP with a MEGA token. The model page's Use this model dialog…Router API ReferenceMEGA provides an OpenAI-compatible inference API at https://inference.tensorplay.cn and a Hub REST API at https://mega.tensorplay.cn/api.Security and PrivacyUse a MEGA access token to authenticate inference requests. MEGA checks the token, your account or organization permissions, and the selected billing owner…TroubleshootingStart with the response status and Inference-Id, then separate authentication, catalog, billing, routing, and Provider failures. Do not include prompt or…
Xet
XetXet provides the large-artifact storage experience for MEGA Hub repositories. Use it through the standard repository, Git, and MEGA CLI workflows when you…Xet Storage OverviewXet makes large files practical in versioned MEGA model, dataset, and Space repositories. It works with the existing repository revision model: commits,…Use Xet StorageUse Xet through MEGA's ordinary repository tools. For most workflows, select a repository, keep the source tree stable while it transfers, and use a commit or…Git LFS CompatibilityMEGA supports Git LFS-compatible repository workflows so existing projects can continue using standard Git tools while moving large artifacts through MEGA.…DeduplicationXet can reuse data that has already been transferred when large repository artifacts are repeated or incrementally updated. This reduces unnecessary data…Xet SecurityXet-backed artifacts use the same repository visibility, ownership, organization policy, and token permissions as other MEGA repository files. Large-file…Xet TroubleshootingFor a large-artifact problem, first identify the repository, revision, client, and operation that failed. Keep the error message and the time of the attempt,…
AI Native
AI NativeUse MEGA from Codex with the MEGA Codex plugin or with standalone MEGA Agent Skills. The plugin connects Codex to MEGA workflows and includes focused Skills…Install the MEGA Codex PluginInstall the MEGA plugin from its Codex marketplace, then restart Codex so it can load the plugin and its bundled Skills.Plugins in TensorPlayChatTensorPlayChat can install packages that follow the Codex plugin protocol. A plugin is a package, not a product-specific integration: its manifest declares…Use the MEGA Codex PluginThe MEGA Codex plugin combines MCP access for bounded online operations with workflow Skills that guide Codex through MEGA tasks. Describe the outcome you…MCP Workflows in CodexThe MEGA plugin lets Codex use MEGA MCP for focused, online Hub workflows. MCP is a good fit for discovering resources, reading metadata, inspecting a small…Authorize MEGA in CodexThe MEGA Codex plugin asks you to sign in and approve access when it first needs your MEGA account. Authorization connects Codex to the account you choose; it…MEGA Agent SkillsMEGA Agent Skills are portable workflow instructions for Codex and other supported coding agents. Install one Skill when you want focused guidance, or install…MEGA Skills CatalogThe MEGA Skills catalog contains one general router and focused workflow guidance for common Hub tasks.AI Native TroubleshootingStart by identifying whether the problem is installation, authorization, the selected MEGA resource, or the workflow surface.

