This project aims to mitigate bias in AI-generated images by refining user prompts through a series of questions intended to clarify and specify the desired output. It utilizes OpenAI's API to generate images and refine prompts based on user feedback.
- Prompt Refinement: Dynamically generates questions based on an initial prompt to help specify and clarify the user's intention, mitigating potential biases in the generated image.
- Image Generation: Generates images from refined prompts using OpenAI's DALL-E model.
- Iterative Refinement: Allows users to iteratively refine their prompts based on specific questions, further reducing bias in the final image generation.
- Navigate to the
image-text-generator-backenddirectory. - Install dependencies with
npm install. - Create a
.envfile with your OpenAI API key:
OPENAI_API_KEY=your_api_key_here
- Start the server with
npm start. The server will run onhttp://localhost:3001.
- Navigate to the
image-text-generatordirectory. - Install dependencies with
npm install. - Start the React app with
npm start. It will openhttp://localhost:3000in your browser.
- Enter an initial prompt related to the image you want to generate.
- Answer the generated questions to refine your prompt and reduce potential bias.
- Click "Generate" to create an image based on your refined prompt.
- (Optional) Iterate on the generated image by refining further or generating variations.
Contributions are welcome! Please open an issue or submit a pull request with your proposed changes or improvements.