Skip to content

This command line tool uses AI to generate ascii art from a text prompt.

License

Notifications You must be signed in to change notification settings

sweetkane/artscii

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🖼️ artscii

This command line tool uses AI to generate ascii art from a text prompt.
Screenshot 2024-03-13 at 5 06 36 PM

Overview

Artscii is a simple command line tool that:

  1. Makes a call to OpenAI's image generation API
  2. Converts the image to ascii using ascii-image-converter
  3. Outputs the ascii art to the command line

Installation

Homebrew

To install artscii with Homebrew, run:

brew install sweetkane/tap/artscii

tap repo

Usage

Note: To use artscii, the OPENAI_API_KEY environment variable must be set.

The most basic usage is to simply invoke the tool and supply a prompt. It will look like this:

artscii "a scene in the swiss alps"

Options

You can specify many options to customize the way your image is converted to ascii. Add any number of these options after the prompt. These options are actually passed directly to the ascii-image-converter program, a third party dependency of artscii with many options for customizing the output.

To output an image with color, you can run:

artscii "a scene in the swiss alps" --color

To use braille characters AND color, you can run:

artscii "a scene in the swiss alps" --braille --color

A full list of options can be found here

Caching

You can cache the OpenAI API response json, which contains a link to the raw image, by adding the -c flag before the prompt. It will look like this:

artscii -c "a scene in the swiss alps"

The cache will be created as artscii.cache.json in your working directory. The program will append to the cache if one already exists.

Gallery

Screenshot 2024-03-18 at 12 49 35 PM Screenshot 2024-03-18 at 12 15 48 PM Screenshot 2024-03-18 at 12 22 39 PM Screenshot 2024-03-18 at 12 23 53 PM Screenshot 2024-03-26 at 4 19 49 PM

Packages Used

https://github.com/TheZoraiz/ascii-image-converter

License

This project is licensed under the Apache License, Version 2.0. See the LICENSE file for details.

License

About

This command line tool uses AI to generate ascii art from a text prompt.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages