Skip to content

CharacterCraft is a web application that uses OpenAI to generate unique and detailed characters. Built using Flask and Python, it allows for character storage and viewing.

Notifications You must be signed in to change notification settings

SaberSwordBoy/CharacterGenerator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CharacterCraft

CharacterCraft is a web application that allows users to generate unique and detailed characters for their stories, role-playing games, or any other creative project. Using OpenAI's API, CharacterCraft generates a wide range of character attributes such as gender, age, occupation, physical appearance, and more.

Features

  • Character generation: Users can generate a character by filling out a simple form with the desired attributes. If left blank, the attributes will be generated by OpenAI's API.
  • Character storage: Each generated character is given a unique ID and stored on the server, allowing users to access and view characters at any time.
  • Character viewing: Users can view generated characters in detail, including all attributes and a detailed description.

Technology

CharacterCraft is built using the Flask web framework for Python. It uses OpenAI's API for character generation and SQLite for character storage. The front-end is built with HTML, CSS, and JavaScript.

Future Developments

  • Character editing: Users will be able to edit their generated characters.
  • Character sharing: Users will be able to share their generated characters with other users.
  • Character searching: Users will be able to search for specific generated characters.

CharacterCraft is a powerful tool for any creative project and is constantly being updated and improved to better serve its users. Whether you're an author, game master, or just looking for inspiration, CharacterCraft is the perfect tool for generating unique and detailed characters.

Setting up CharacterCraft

This guide will walk you through the process of setting up the CharacterCraft web application on your server.

Prerequisites

  • A server running Linux (Ubuntu 18.04 LTS recommended)
  • Python 3.6 or higher
  • pip3
  • Git
  • An OpenAI API key (https://openai.com/api)

Installing Flask

Make sure that your server has Python 3.6 or higher installed by running python3 -V.

If not already installed, install pip3 by running sudo apt-get install python3-pip.

Use pip3 to install Flask by running pip3 install flask.

Verify that Flask was installed correctly by running python3 -c "import flask; print(flask.version)". This should print the version of Flask that was installed.

Setting up the Application

Clone the CharacterCraft repository to your server by running git clone https://github.com/saberswordboy/charactergenerator.

Navigate to the root directory of the repository.

Create a virtual environment by running python3 -m venv venv. This will create a new directory called "venv" in the root directory of the repository.

Activate the virtual environment by running source venv/bin/activate.

Install the required packages by running pip3 install -r packages.txt.

Create a new file named .env and add the following line to it: API_KEY="YOUR API KEY HERE"

Run flask run to start the server

Your CharacterCraft web application should now be running and accessible at the server's IP address on port 80. You may need to check permissions if this does not work, as port 80 requires root permissions.

This document partly created using AI

About

CharacterCraft is a web application that uses OpenAI to generate unique and detailed characters. Built using Flask and Python, it allows for character storage and viewing.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages