{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"Self-hosting quickstart","description":"Generate and edit images and video with Bria's Fibo models through a REST API, Python and TypeScript SDKs, MCP server and agent skills. Licensed training data, controllable output, provenance on every result.","siteUrl":"https://docs.bria.ai","image":"/assets/bria-social-card.5f3c59395e7b5efa776984c64ef9cb0956b1d651f45b7ebf9502122a66054f35.db81178d.png","llmstxt":{"hide":false,"title":"Bria API documentation","description":"Bria's developer platform: controllable, commercially safe visual generative AI (images and video) as a REST API, Python and TypeScript SDKs, MCP server and agent skills.","details":{"path":"_llmstxt-details.md"},"sections":[{"title":"Getting started","description":"First call, authentication, async jobs and webhooks, rate limits, inputs.","includeFiles":["index.md","whats-new/fibo-2.md","getting-started/quickstart.md","getting-started/authentication.md","getting-started/async-requests.md","status.yaml","getting-started/rate-limits-and-errors.md","getting-started/working-with-images.md","getting-started/asset-retention.md"]},{"title":"Integrate","description":"Python SDK, TypeScript SDK, MCP server, agent skills, and machine-readable docs for agents.","includeFiles":["integration-methods/python-sdk.md","integration-methods/typescript-sdk.md","MCP-authentication.md","integration-methods/bria-skill.md","integration-methods/for-ai-agents.md"]},{"title":"Concepts","description":"Platform map, VGL and the Fibo models, safety, best practices.","includeFiles":["products-overview.md","VGL.md","safety.md","best-practices-overview.md","image-generation-best-practices.md","image-editing-best-practices.md","product-shots-best-practices.md"]},{"title":"Image Generation","description":"Generate images from text, reference images or structured (VGL) prompts with Fibo 2.","includeFiles":["image-generation-overview.md","image-generation.yaml"]},{"title":"Image Editing","description":"Instruction-based editing plus specialized endpoints for backgrounds, erasing, fill, expansion, upscaling and style.","includeFiles":["image-editing-overview.md","image-editing.yaml"]},{"title":"Product Shot Editing","description":"Cutouts, packshots, shadows, lifestyle scenes, product integration, holding, virtual try-on, automotive.","includeFiles":["product-shot-overview.md","product-shot-editing.yaml"]},{"title":"Video Editing","description":"Background removal (REST or real-time streaming), erasing, upscaling and masks for video; local video upload.","includeFiles":["video-editing-overview.md","local-video-upload-service.md","streaming-rmbg.md","video-editing.yaml"]},{"title":"Ads","description":"Finished ads as input. Ad Delayer turns one into editable layers (the guide holds the layer document contract); Ad Resize produces it at other sizes with the layout redone.","includeFiles":["ads-overview.md","ads.yaml"]},{"title":"Trust and provenance","description":"Public verification of Bria provenance, and attribution of outputs to licensed training data.","includeFiles":["trust-and-provenance-overview.md","visual-verification-overview.md","visual-verification.yaml","enterprise/attribution.md","bria-attribution-service.yaml"]},{"title":"Self-hosting","description":"Run licensed Bria models on your own GPUs. Buy a per-model license, install with Bria Studio or the Python library, run, and handle license errors.","includeFiles":["self-hosted/quickstart.md","self-hosted/overview.md","self-hosted/best-practices.md","self-hosted/fibo-2.md","self-hosted/rmbg-2.md"]},{"title":"Enterprise","description":"Run Bria in your own cloud or on-premises.","includeFiles":["enterprise/deployment-options.md"]}],"excludeFiles":["_llmstxt-details.md","README.md"]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"self-hosting-quickstart","__idx":0},"children":["Self-hosting quickstart"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["One command installs a licensed model on your GPU and runs it:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"npx @bria-ai/studio\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Studio signs you in through your browser, installs the model you pick into a virtual environment at ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["~/.bria/venvs/<model>"]},", downloads its weights, and runs a first generation."]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info","name":"Before you run it"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["You need ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://nodejs.org"},"children":["Node.js"]},", an NVIDIA GPU, and a model license. No license yet? See ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://platform.bria.ai/licensing/pricing"},"children":["pricing"]}," and ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/self-hosted/overview"},"children":["Self-hosted models"]},"."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"use-the-model","__idx":1},"children":["Use the model"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The model's package stays installed in that virtual environment. Activate it and call the model from your own code:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"source ~/.bria/venvs/rmbg-2.0/bin/activate\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"python","header":{"controls":{"copy":{}}},"source":"from remove_bg import RemoveBG, RemoveBGConfig, RemoveBGInput\n\npipe = RemoveBG(config=RemoveBGConfig(api_token=\"<your-bria-api-token>\"))\npipe.setup()  # reuses the weights Studio already downloaded\npipe.execute([RemoveBGInput(image=\"input.jpg\")])[0].image.save(\"cutout.png\")\n","lang":"python"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"next-steps","__idx":2},"children":["Next steps"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Full options, and installing without Studio — each model's guide: ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/self-hosted/fibo-2"},"children":["Fibo 2"]},", ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/self-hosted/rmbg-2"},"children":["RMBG 2.0"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Running in production? ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/self-hosted/best-practices"},"children":["Self-hosting best practices"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["How licensing, API keys and usage work: ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/self-hosted/overview"},"children":["Self-hosted models"]}]}]}]},"headings":[{"value":"Self-hosting quickstart","id":"self-hosting-quickstart","depth":1},{"value":"Use the model","id":"use-the-model","depth":2},{"value":"Next steps","id":"next-steps","depth":2}],"frontmatter":{"title":"Self-hosting quickstart","description":"Run a licensed Bria model on your own GPU with one command, then use it from your own code.","seo":{"title":"Self-hosting quickstart"}},"lastModified":"2026-10-20T15:06:45.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/self-hosted/quickstart","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}