Skip to content

knap-ai/chisel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

13 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Chisel - Compose AI for vision applications.

The documentation are a great place to start building with Chisel.

Getting Started

Install with pip:

pip install chisel-ai

Operations

Chisel supports several AI model-powered operations:

  1. TxtToImg
  2. ImgToImg
  3. ImgEdit
  4. SuperResolution

These operations make it very easy to start building AI vision pipelines:

from chisel.ops import ImgToImg, TxtToImg, SuperResolution
from chisel.ops.provider import Provider

txt2img = TxtToImg(provider=Provider.STABILITY_AI)
img2img = ImgToImg(provider=Provider.OPENAI)
super_res = SuperResolution(provider=Provider.STABILITY_AI)

prompt = "watercolor painting of a park in the fall"

img = txt2img(prompt)
refined_img = img2img(img)
upscaled_img = super_res(refined_img)

Initial Setup

API Keys

Chisel looks for API keys in these environment variables

  • OpenAI - CHISEL_API_KEY_OPEN_AI
  • StabilityAI - CHISEL_API_KEY_STABILITY_AI
  • Stable Diffusion - CHISEL_API_KEY_STABLE_DIFFUSION

OpenAI Setup

  • Create an OpenAI API key
  • Set Chisel's environment variable
    • ZSH - echo 'export CHISEL_API_KEY_OPEN_AI=1234ABCD' >> ~/.zshenv
    • BASH - echo 'export CHISEL_API_KEY_OPEN_AI_=12345ABCD' >> ~/.bash_profile

StabilityAI Setup

  • Create a StabilityAI API Key
  • Set Chisel's environment variable
    • ZSH - echo 'export CHISEL_API_KEY_STABILITY_AI=1234ABCD' >> ~/.zshenv
    • BASH - echo 'export CHISEL_API_KEY_STABILITY_AI=12345ABCD' >> ~/.bash_profile

Stable Diffusion Setup

  • Create a Stable Diffusion API key
  • Set Chisel's environment variable
    • ZSH - echo 'export CHISEL_API_KEY_STABLE_DIFFUSION=1234ABCD' >> ~/.zshenv
    • BASH - echo 'export CHISEL_API_KEY_STABLE_DIFFUSION=12345ABCD' >> ~/.bash_profile

About

πŸ’Ž Compose AI for images; build next-gen applications, easily. πŸ’Ž

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages