Skip to content

pokedim13/wombo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hi there, I'm

I am a module for using wombo dream ai (neural network of image generation)

There are some changes in the new version of dream, We did not record the last version, so you will have to rewrite your previous code. We apologize for the sincere inconvenience

Mini Documentation
Synchro version
Import
Basic import
from wombo import Dream # sync
dream = Dream(out_msg: str,  max_requests_per_token: int = 30)
# out_msg: Message for response errors from the server
            
Get styles
dream.get_styles() -> StyleModel
# return pydantic model
            
Check task
dream.check_task(self, task_id: str, only_bool: bool = False) -> Union[CheckTask, bool]
# only_bool: If this flag is set, false or True will be returned, depending on the completeness of the task
            
Create task
dream.create_task(self, text: str, style: Union[Style, int] = Style.BASESTYLE) -> CreateTask
# style: Style identifier, yes, too fashionable class, it's on style
            
Generate
dream.generate(text: str, style: Style = Style.BASESTYLE, timeout: int = 60, check_for: int = 3, gif: bool = False)  -> Union[io.BytesIO, CheckTask]
# style: Style identifier, yes, too fashionable class, it's on style
# timeout: The number of seconds after which the task will stop being checked and will throw Timeout error
# check_for: Race in how many seconds to do the check
# gif: Flag, create a gif or not
            
GIF
dream.gif(self, url_list: list) -> io.BytesIO
# url_list: List[str] list of links to images (CheckTask.photo_url_list)
            
Asynchronous version
Import
Basic import
from wombo import AsyncDream # sync
dream = AsyncDream(out_msg: str,  max_requests_per_token: int = 30)
# out_msg: Message for response errors from the server
            
Get styles
await dream.get_styles() -> StyleModel
# return pydantic model
            
Check task
await dream.check_task(self, task_id: str, only_bool: bool = False) -> Union[CheckTask, bool]
# only_bool: If this flag is set, false or True will be returned, depending on the completeness of the task
            
Create task
await dream.create_task(self, text: str, style: Union[Style, int] = Style.BASESTYLE) -> CreateTask
# style: Style identifier, yes, too fashionable class, it's on style
            
Generate
await dream.generate(text: str, style: Style = Style.BASESTYLE, timeout: int = 60, check_for: int = 3, gif: bool = False)  -> Union[io.BytesIO, CheckTask]
# style: Style identifier, yes, too fashionable class, it's on style
# timeout: The number of seconds after which the task will stop being checked and will throw Timeout error
# check_for: Race in how many seconds to do the check
# gif: Flag, create a gif or not
            
GIF
await dream.gif(self, url_list: list, thread: bool = True) -> io.BytesIO
# url_list: List[str] list of links to images (CheckTask.photo_url_list)
# thread: Run the task to create a gif in another thread, so as not to block the program
            
Style
    Style().get_awaible_styles: Getting available styles
    Style.BASESTYLE: Basic style
    Style().{name_style}: Specifying a style, works only after initialization, does not update styles automatically
    

Creditless

Requirements

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages