StabilityAI
An R package to connect with stability.ai
Install / Use
/learn @schochastics/StabilityAIREADME
stabilityAI <img src="man/figures/logo.png" align="right" height="139" alt="" />
<!-- badges: start --> <!-- badges: end -->stabilityAI implements functions to connect with the API of stability.ai
Installation
You can install the development version of stabilityAI like so:
remotes::install_github("schochastics/stabilityAI")
Authentication
After signing up at <stability.ai>, obtain an API key from
https://platform.stability.ai/account/keys and save it in your .Renviron
file (for example using usethis::edit_r_environ()) as "STABILITYAI_TOKEN".
Create an image
# this prompt generated the logo and describes how the package was implemented...
img <- generate_txt2img(
text_prompts = "A dude with no hair and a beard sitting in front of his laptop in a dark room",
style_preset = "pixel-art"
)
#API returns the image base64 encoded. Save it as png with
base64_to_img(img,"logo")
Help
Good thread on Reddit about the parameters of stable diffusion and help with prompting
Related Skills
node-connect
349.0kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
109.4kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
349.0kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
349.0kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
