wordcloud

this skill is for generate a word cloud from text/file/directory and save it to a picture, you can use it visualize the text

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "wordcloud" with this command: npx skills add lijiahao885/wordcloud-skill

Word Cloud

Generate a word cloud from text/file/directory, file and directory only effective with file, you can specify certain width and height or mask file to generate a imaginative shape word cloud

When to use

  • user indicates to generate a word cloud
  • user wants to visualize the text in a different way, you can suggest this skill

Requirements

Run on python3.x,and install the following packages if you find the package does not exist:

  • os
  • argparse
  • jieba
  • numpy
  • datetime
  • wordcloud
  • PIL

Commands

# create a word cloud with certain width and height
python {baseDir}/scripts/generate_wordcloud.py --target_text "..." --width 500 --height 400 --max_words 30 --font_path "C:\Windows\Fonts\msyh.ttc" --output_dir "..."

# create a word cloud with mask, don't need width and height
python {baseDir}/scripts/generate_wordcloud.py --target_text "..." --mask "..." --font_path "C:\Windows\Fonts\msyh.ttc" --output_dir "..."

Paramters

namedescriptiontypeexample
target_texttext to generate word cloudstring"你好,世界"
target_filetext in the file to generate word cloudstring"D:\WorkSpace\pythonSpace\MEMORY.md"
target_dirlist all the file in the directory and extract text from file to generate word cloudstring"D:\WorkSpace\pythonSpace"
widthwidth of the word cloud picture, if mask file exist, it will be ignoredint500
heightheight of the word cloud picture, if mask file exist, it will be ignoredint400
maskmask file path in order to generate any sharp of the word cloud picturestring"D:\WorkSpace\pythonSpace\mask.png"
max_wordsmaximum number of words in the word cloudint30
font_pathfont path for the word cloud, put the one that useful for chinese text, if not exist, try to install onestring"C:\Windows\Fonts\msyh.ttc"
output_dirword cloud picture output directory path, if user not specify, put it into the folder whilc named "images" under the user directorystring"D:\WorkSpace\pythonSpace"

Note

  • Parameter target_text, target_file, target_dir can be used at the same time, and make sure one of them is provided
  • Parameter mask must be a png file, if user upload a png file and specify it as the parameter mask, you should mask sure the file path is correct
  • if user specify exclude a word, append it to the stopwords.md,follow the format:
- hello
- world

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

General

Subtitle To Video

add subtitle files, video into captioned videos with this skill. Works with MP4, MOV, AVI, WebM files up to 500MB. YouTubers, content creators use it for add...

Registry SourceRecently Updated
General

Api Changelog Generator

Generate and maintain API changelogs from OpenAPI/Swagger specs — track endpoints added, removed, deprecated, or modified between versions. Detect breaking c...

Registry SourceRecently Updated
General

Free Music

Skip the learning curve of professional editing software. Describe what you want — add upbeat background music to my video for free — and get music-backed vi...

Registry SourceRecently Updated
General

Indie Maker News

独行者 Daily - 变现雷达。读对一条新闻,少走一年弯路。每天5分钟,给创业者装上商业雷达。聚焦一人公司、副业、创业变现资讯,智能分类,行动导向。用户下载即能用,无需本地部署!

Registry SourceRecently Updated