{"id":13651531,"url":"https://github.com/joshuadeguzman/stability-sdk-dart","last_synced_at":"2025-04-13T11:30:21.667Z","repository":{"id":65325742,"uuid":"589424315","full_name":"joshuadeguzman/stability-sdk-dart","owner":"joshuadeguzman","description":"An implementation of Stability AI SDK in Dart. Stability AI is a solution studio dedicated to innovating ideas.","archived":false,"fork":false,"pushed_at":"2023-02-03T04:59:05.000Z","size":9417,"stargazers_count":17,"open_issues_count":3,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-04T08:07:53.495Z","etag":null,"topics":["dart","flutter","stability-ai","stable-diffusion"],"latest_commit_sha":null,"homepage":"https://pub.dev/packages/stability_sdk","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/joshuadeguzman.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2023-01-16T04:25:35.000Z","updated_at":"2024-12-01T13:11:01.000Z","dependencies_parsed_at":"2023-02-10T15:45:39.208Z","dependency_job_id":null,"html_url":"https://github.com/joshuadeguzman/stability-sdk-dart","commit_stats":{"total_commits":13,"total_committers":1,"mean_commits":13.0,"dds":0.0,"last_synced_commit":"b735ca927ac4b6d9a4ce670e3bfd844d16d19591"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshuadeguzman%2Fstability-sdk-dart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshuadeguzman%2Fstability-sdk-dart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshuadeguzman%2Fstability-sdk-dart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshuadeguzman%2Fstability-sdk-dart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/joshuadeguzman","download_url":"https://codeload.github.com/joshuadeguzman/stability-sdk-dart/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248705469,"owners_count":21148544,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dart","flutter","stability-ai","stable-diffusion"],"created_at":"2024-08-02T02:00:50.311Z","updated_at":"2025-04-13T11:30:21.646Z","avatar_url":"https://github.com/joshuadeguzman.png","language":"Dart","funding_links":[],"categories":["👑Stable Diffusion"],"sub_categories":["Flutter"],"readme":"# stability_sdk\n\nAn implementation of [Stability AI](https://platform.stability.ai/) SDK in Dart. Stability AI is a solution studio dedicated to innovating ideas.\n\n### Brush AI\n\nA demonstrable use of stability SDK in Flutter and Dart.\n\n![brush-ai demo](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/demo/demo_brush_ai.gif)\n\n*and more sample outputs...*\n\n**Dogs**\n\n\"generate an oil painting canvas of a dog, realistic, painted by Leonardo da Vinci\"\n\n|Output 1|Output 2|Output 3|\n|---|---|---|\n![dog-3](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/dogs/1.png)|![dog-2](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/dogs/2.png)|![dog-3](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/dogs/3.png)|\n\n**Cats**\n\n\"generate an oil painting canvas of a cat, realistic, painted by Leonardo da Vinci\"\n\n|Output 1|Output 2|Output 3|\n|---|---|---|\n![cat-3](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/cats/1.png)|![cat-2](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/cats/2.png)|![cat-3](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/cats/3.png)|\n\n**Cyberpunk**\n\n\"generate a cyberpunk scene, in japan, realistic street scene on the night\"\n\n|Output 1|Output 2|Output 3|\n|---|---|---|\n![cyberpunk-3](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/cyberpunk/1.png)|![cyberpunk-2](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/cyberpunk/2.png)|![cyberpunk-3](https://raw.githubusercontent.com/joshuadeguzman/stability-sdk-dart/main/docs/assets/cyberpunk/3.png)|\n\n## Features\n\n* [x] Text-to-image\n\nUpcoming\n\n* [ ] Image-to-image\n* [ ] Inpainting + Masking\n* [ ] CLIP guidance\n* [ ] Multi-prompting\n\n## Setup\n\n### Prerequisites\n\n* Stability AI requires you to create your own API key to make calls to the API. You can create one [here](https://platform.stability.ai/docs/getting-started/authentication).\n\n* Create a `.env` file and set your Stability AI API key\n\n### Usage\n\nThe example provided is using the SDK directly in a Flutter app. In most cases, you're going to use the SDK in the backend using tools like [Dart Frog](https://pub.dev/packages/dart_frog). This is to secure the API key and to have more control of the incoming requests, e.g. controlling rate limits or blocking sensitive content.\n\n```dart\n// 1. Setup the API client\nfinal client = StabilityApiClient.init(\"\u003cYOUR_API_KEY_HERE\u003e\");\n\n// 2. Create a generation request\nfinal request = RequestBuilder(\"an oil painting of a dog in the canvas, wearing knight armor, realistic painting by Leonardo da Vinci\")\n    .setHeight(512)\n    .setWidth(512)\n    .setEngineType(EngineType.inpainting_v2_0)\n    .setSampleCount(1)\n    .build();\n\n// 3. Subscribe to the response\nclient.generate(request).listen((answer) {\n    image = answer.artifacts?.first.getImage();\n});\n\n```\n## Connect\n\nLet's connect on [@joshuamdeguzman](https://twitter.com/joshuadeguzman).\n\n## License\n\n[BSD 3-Clause](https://github.com/joshuadeguzman/stability_sdk/blob/main/.github/LICENSE.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoshuadeguzman%2Fstability-sdk-dart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjoshuadeguzman%2Fstability-sdk-dart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoshuadeguzman%2Fstability-sdk-dart/lists"}