Skip to content
This repository has been archived by the owner on Apr 17, 2024. It is now read-only.

Lorg0n/civitai-generation-lib

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

civitai-generation

This is not an interpretation of the available API, but access to the generation of images thanks to the capabilities of the site.

Please use with respect, site resources are limited.

Installing

pip install git+https://github.com/Lorg0n/civitai-generation-lib/

Usage

from civitai import civitai

cookie = "" # insert your cookie here
api = civitai.Civitai(cookie)

lora = api.get_additional_resources("makima")[0]
lora.set_strength(0.7)

resources = [api.get_checkpoints("OrangeMixs")[0], lora]
params = {
        "prompt": "1girl, makima",
        "negativePrompt": "EasyNegative,sketch,duplicate,ugly,huge eyesm, nsfw",
        "cfgScale": 5.5,
        "sampler": "DPM++ 2M Karras",
        "seed": 372223333,
        "steps": 40,
        "clipSkip": 1,
        "quantity": 4,
        "nsfw": False,
        "aspectRatio": "0",
        "baseModel": "SD1"
}
api.create_request(resources, params)
print([e.status for e in api.get_requests()])

Description

The library helps to utilize the site's built-in image generation feature with a variety of customization options.

Cookie

Simply copy the data in the red box and paste this string into the cookie variable

img.png

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages