[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-EvanZhouDev--open-genmoji":3,"tool-EvanZhouDev--open-genmoji":64},[4,17,27,35,43,56],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":16},3808,"stable-diffusion-webui","AUTOMATIC1111\u002Fstable-diffusion-webui","stable-diffusion-webui 是一个基于 Gradio 构建的网页版操作界面，旨在让用户能够轻松地在本地运行和使用强大的 Stable Diffusion 图像生成模型。它解决了原始模型依赖命令行、操作门槛高且功能分散的痛点，将复杂的 AI 绘图流程整合进一个直观易用的图形化平台。\n\n无论是希望快速上手的普通创作者、需要精细控制画面细节的设计师，还是想要深入探索模型潜力的开发者与研究人员，都能从中获益。其核心亮点在于极高的功能丰富度：不仅支持文生图、图生图、局部重绘（Inpainting）和外绘（Outpainting）等基础模式，还独创了注意力机制调整、提示词矩阵、负向提示词以及“高清修复”等高级功能。此外，它内置了 GFPGAN 和 CodeFormer 等人脸修复工具，支持多种神经网络放大算法，并允许用户通过插件系统无限扩展能力。即使是显存有限的设备，stable-diffusion-webui 也提供了相应的优化选项，让高质量的 AI 艺术创作变得触手可及。",162132,3,"2026-04-05T11:01:52",[13,14,15],"开发框架","图像","Agent","ready",{"id":18,"name":19,"github_repo":20,"description_zh":21,"stars":22,"difficulty_score":23,"last_commit_at":24,"category_tags":25,"status":16},1381,"everything-claude-code","affaan-m\u002Feverything-claude-code","everything-claude-code 是一套专为 AI 编程助手（如 Claude Code、Codex、Cursor 等）打造的高性能优化系统。它不仅仅是一组配置文件，而是一个经过长期实战打磨的完整框架，旨在解决 AI 代理在实际开发中面临的效率低下、记忆丢失、安全隐患及缺乏持续学习能力等核心痛点。\n\n通过引入技能模块化、直觉增强、记忆持久化机制以及内置的安全扫描功能，everything-claude-code 能显著提升 AI 在复杂任务中的表现，帮助开发者构建更稳定、更智能的生产级 AI 代理。其独特的“研究优先”开发理念和针对 Token 消耗的优化策略，使得模型响应更快、成本更低，同时有效防御潜在的攻击向量。\n\n这套工具特别适合软件开发者、AI 研究人员以及希望深度定制 AI 工作流的技术团队使用。无论您是在构建大型代码库，还是需要 AI 协助进行安全审计与自动化测试，everything-claude-code 都能提供强大的底层支持。作为一个曾荣获 Anthropic 黑客大奖的开源项目，它融合了多语言支持与丰富的实战钩子（hooks），让 AI 真正成长为懂上",140436,2,"2026-04-05T23:32:43",[13,15,26],"语言模型",{"id":28,"name":29,"github_repo":30,"description_zh":31,"stars":32,"difficulty_score":23,"last_commit_at":33,"category_tags":34,"status":16},2271,"ComfyUI","Comfy-Org\u002FComfyUI","ComfyUI 是一款功能强大且高度模块化的视觉 AI 引擎，专为设计和执行复杂的 Stable Diffusion 图像生成流程而打造。它摒弃了传统的代码编写模式，采用直观的节点式流程图界面，让用户通过连接不同的功能模块即可构建个性化的生成管线。\n\n这一设计巧妙解决了高级 AI 绘图工作流配置复杂、灵活性不足的痛点。用户无需具备编程背景，也能自由组合模型、调整参数并实时预览效果，轻松实现从基础文生图到多步骤高清修复等各类复杂任务。ComfyUI 拥有极佳的兼容性，不仅支持 Windows、macOS 和 Linux 全平台，还广泛适配 NVIDIA、AMD、Intel 及苹果 Silicon 等多种硬件架构，并率先支持 SDXL、Flux、SD3 等前沿模型。\n\n无论是希望深入探索算法潜力的研究人员和开发者，还是追求极致创作自由度的设计师与资深 AI 绘画爱好者，ComfyUI 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",107662,"2026-04-03T11:11:01",[13,14,15],{"id":36,"name":37,"github_repo":38,"description_zh":39,"stars":40,"difficulty_score":23,"last_commit_at":41,"category_tags":42,"status":16},3704,"NextChat","ChatGPTNextWeb\u002FNextChat","NextChat 是一款轻量且极速的 AI 助手，旨在为用户提供流畅、跨平台的大模型交互体验。它完美解决了用户在多设备间切换时难以保持对话连续性，以及面对众多 AI 模型不知如何统一管理的痛点。无论是日常办公、学习辅助还是创意激发，NextChat 都能让用户随时随地通过网页、iOS、Android、Windows、MacOS 或 Linux 端无缝接入智能服务。\n\n这款工具非常适合普通用户、学生、职场人士以及需要私有化部署的企业团队使用。对于开发者而言，它也提供了便捷的自托管方案，支持一键部署到 Vercel 或 Zeabur 等平台。\n\nNextChat 的核心亮点在于其广泛的模型兼容性，原生支持 Claude、DeepSeek、GPT-4 及 Gemini Pro 等主流大模型，让用户在一个界面即可自由切换不同 AI 能力。此外，它还率先支持 MCP（Model Context Protocol）协议，增强了上下文处理能力。针对企业用户，NextChat 提供专业版解决方案，具备品牌定制、细粒度权限控制、内部知识库整合及安全审计等功能，满足公司对数据隐私和个性化管理的高标准要求。",87618,"2026-04-05T07:20:52",[13,26],{"id":44,"name":45,"github_repo":46,"description_zh":47,"stars":48,"difficulty_score":23,"last_commit_at":49,"category_tags":50,"status":16},2268,"ML-For-Beginners","microsoft\u002FML-For-Beginners","ML-For-Beginners 是由微软推出的一套系统化机器学习入门课程，旨在帮助零基础用户轻松掌握经典机器学习知识。这套课程将学习路径规划为 12 周，包含 26 节精炼课程和 52 道配套测验，内容涵盖从基础概念到实际应用的完整流程，有效解决了初学者面对庞大知识体系时无从下手、缺乏结构化指导的痛点。\n\n无论是希望转型的开发者、需要补充算法背景的研究人员，还是对人工智能充满好奇的普通爱好者，都能从中受益。课程不仅提供了清晰的理论讲解，还强调动手实践，让用户在循序渐进中建立扎实的技能基础。其独特的亮点在于强大的多语言支持，通过自动化机制提供了包括简体中文在内的 50 多种语言版本，极大地降低了全球不同背景用户的学习门槛。此外，项目采用开源协作模式，社区活跃且内容持续更新，确保学习者能获取前沿且准确的技术资讯。如果你正寻找一条清晰、友好且专业的机器学习入门之路，ML-For-Beginners 将是理想的起点。",84991,"2026-04-05T10:45:23",[14,51,52,53,15,54,26,13,55],"数据工具","视频","插件","其他","音频",{"id":57,"name":58,"github_repo":59,"description_zh":60,"stars":61,"difficulty_score":10,"last_commit_at":62,"category_tags":63,"status":16},3128,"ragflow","infiniflow\u002Fragflow","RAGFlow 是一款领先的开源检索增强生成（RAG）引擎，旨在为大语言模型构建更精准、可靠的上下文层。它巧妙地将前沿的 RAG 技术与智能体（Agent）能力相结合，不仅支持从各类文档中高效提取知识，还能让模型基于这些知识进行逻辑推理和任务执行。\n\n在大模型应用中，幻觉问题和知识滞后是常见痛点。RAGFlow 通过深度解析复杂文档结构（如表格、图表及混合排版），显著提升了信息检索的准确度，从而有效减少模型“胡编乱造”的现象，确保回答既有据可依又具备时效性。其内置的智能体机制更进一步，使系统不仅能回答问题，还能自主规划步骤解决复杂问题。\n\n这款工具特别适合开发者、企业技术团队以及 AI 研究人员使用。无论是希望快速搭建私有知识库问答系统，还是致力于探索大模型在垂直领域落地的创新者，都能从中受益。RAGFlow 提供了可视化的工作流编排界面和灵活的 API 接口，既降低了非算法背景用户的上手门槛，也满足了专业开发者对系统深度定制的需求。作为基于 Apache 2.0 协议开源的项目，它正成为连接通用大模型与行业专有知识之间的重要桥梁。",77062,"2026-04-04T04:44:48",[15,14,13,26,54],{"id":65,"github_repo":66,"name":67,"description_en":68,"description_zh":69,"ai_summary_zh":70,"readme_en":71,"readme_zh":72,"quickstart_zh":73,"use_case_zh":74,"hero_image_url":75,"owner_login":76,"owner_name":77,"owner_avatar_url":78,"owner_bio":79,"owner_company":80,"owner_location":81,"owner_email":82,"owner_twitter":83,"owner_website":80,"owner_url":84,"languages":85,"stars":90,"forks":91,"last_commit_at":92,"license":80,"difficulty_score":10,"env_os":93,"env_gpu":94,"env_ram":95,"env_deps":96,"category_tags":104,"github_topics":105,"view_count":23,"oss_zip_url":80,"oss_zip_packed_at":80,"status":16,"created_at":109,"updated_at":110,"faqs":111,"releases":112},3895,"EvanZhouDev\u002Fopen-genmoji","open-genmoji","Generative Emoji for the rest of us.","open-genmoji 是一个旨在让所有人都能体验生成式表情符号（Genmoji）的开源项目。它成功复现了苹果设备专属的 Genmoji 功能，但打破了硬件限制，让非苹果用户也能自由创建个性化表情。无论是长着翅膀的飞猪、穿西装的骏马，还是太空泰迪熊，只需输入简单的文字描述，open-genmoji 就能生成风格统一、创意丰富的表情图像。\n\n该项目主要解决了生成式表情符号技术被封闭生态垄断的问题，通过开放的技术方案，让创意表达不再受限于特定品牌或设备。其核心由一系列在 HuggingFace 上公开的 LoRA 模型文件组成，基于强大的 flux-dev 架构，并配合 Qwen 2.5 大模型进行提示词优化，确保生成效果既精准又生动。\n\nopen-genmoji 非常适合开发者、AI 研究人员以及希望探索自定义表情设计的设计师使用。对于普通用户而言，只要具备基础的 AI 绘图操作知识，也能轻松上手，将自己的奇思妙想转化为独特的数字表情。作为一个完全开源的项目，它不仅提供了高质量的表情生成能力，更为社区理解和研究苹果 Genmoji 背后的技术原理提供了宝贵的参考实例，推动了生成式 AI","open-genmoji 是一个旨在让所有人都能体验生成式表情符号（Genmoji）的开源项目。它成功复现了苹果设备专属的 Genmoji 功能，但打破了硬件限制，让非苹果用户也能自由创建个性化表情。无论是长着翅膀的飞猪、穿西装的骏马，还是太空泰迪熊，只需输入简单的文字描述，open-genmoji 就能生成风格统一、创意丰富的表情图像。\n\n该项目主要解决了生成式表情符号技术被封闭生态垄断的问题，通过开放的技术方案，让创意表达不再受限于特定品牌或设备。其核心由一系列在 HuggingFace 上公开的 LoRA 模型文件组成，基于强大的 flux-dev 架构，并配合 Qwen 2.5 大模型进行提示词优化，确保生成效果既精准又生动。\n\nopen-genmoji 非常适合开发者、AI 研究人员以及希望探索自定义表情设计的设计师使用。对于普通用户而言，只要具备基础的 AI 绘图操作知识，也能轻松上手，将自己的奇思妙想转化为独特的数字表情。作为一个完全开源的项目，它不仅提供了高质量的表情生成能力，更为社区理解和研究苹果 Genmoji 背后的技术原理提供了宝贵的参考实例，推动了生成式 AI 在大众层面的普及与应用。","\u003Cpicture>\n  \u003Csource media=\"(prefers-color-scheme: dark)\" srcset=\".\u002Fassets\u002Fbanner@dark.png\">\n  \u003Csource media=\"(prefers-color-scheme: light)\" srcset=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_b9457c447ad7.png\">\n  \u003Cimg alt=\"Open Genmoji Banner\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_b9457c447ad7.png\">\n\u003C\u002Fpicture>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji\">HuggingFace\u003C\u002Fa> | \u003Ca href=\"#quickstart\">Quickstart\u003C\u002Fa> | \u003Ca href=\"#tutorial\">Tutorial\u003C\u002Fa> | \u003Ca href=\"https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=vOVDyRIS09k\">Making Open Genmoji (Video)\u003C\u002Fa>\n\u003C\u002Fp>\n\n## What is Open Genmoji?\n\n> See how Open Genmoji was created—and learn about how Apple Genmoji works under-the-hood, on [YouTube](https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=vOVDyRIS09k).\n\nOpen Genmoji attempts to recreate Apple's Genmoji feature, but with open technology! Open Genmoji works anywhere—Not just Apple devices.\n\nHere's a sneak peek of what Open Genmoji is capable of:\n| ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_95ec4eeab1a5.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_ecbbe77ae94e.png) |![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_51e37ff8df21.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_13a7bfe20be2.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_35a065abb728.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_076ab2e13f26.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_5be5f379b0a1.png) |\n| --------------------------------------------------------- | ---------------------------------------------------- | ------------------------------------------------------- | -------------------------------------------------------- | ----------------------------------------------------- | ---------------------------------------------------- |---------------------------------------------------- |\n\n\u003Cdetails>\n\u003Csummary>Prompts, Apple Genmoji Comparison, and More Information\u003C\u002Fsummary>\n\nAll shown emojis were created with the `flux-dev` Open Genmoji LoRA and Prompt Assist. The exact same prompt was given to both Open Genmoji and Apple. Prompt Assist was run with Qwen 2.5 32B Instruct.\n\nBackground of emojis removed with Figma AI.\n\nThe 7 samples were selected to demonstrate the ability of Open Genmoji across Animal, Object, and Person emojis.\n\n| Prompt                                                                  | Open Genmoji                                              | Apple                                              |\n| ----------------------------------------------------------------------- | --------------------------------------------------------- | -------------------------------------------------- |\n| `flying pig white wings` (Animal Emoji)                                 | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_95ec4eeab1a5.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_9d721f8f83ef.png) |\n| `handsome horse in black suit and tie with flowing mane` (Animal Emoji) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_ecbbe77ae94e.png)      | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_1a6f9f790669.png)      |\n| `teddy bear in space suit` (Animal Emoji)                               | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_51e37ff8df21.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_24c2ea4c2603.png) |\n| `rainbow popsicle` (Object Emoji)                                       | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_13a7bfe20be2.png)   | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_e8d4a09f78ad.png)   |\n| `fireplace` (Object Emoji)                                              | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_35a065abb728.png)  | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_dcf77130f500.png)  |\n| `robber with money bag` (Person Emoji)                                  | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_076ab2e13f26.png)     | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_770f5ec22c23.png)     |\n| `hiker` (Person Emoji)                                                  | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_5be5f379b0a1.png)      | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_10a1231bc08d.png)      |\n\n\u003C\u002Fdetails>\n\n\u003Cbr>\n\nAt its core, Open Genmoji is simply a collection of LoRA files (available on [HuggingFace](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji)), each finetuned based on thousands of Apple emojis, that teaches an image generation model to create emojis. Anywhere you can add a LoRA onto an image generation model, you can use Open Genmoji.\n\nOpen Genmoji also comes with a special metaprompts, known as [Open Genmoji Prompt Assist](#prompt-assist) to help you create the perfect prompt to make any emoji you want. Some Open Genmoji LoRAs may have their own metaprompts.\n\nThe best part? You can also [use your creation in iOS 18+ as a real emoji](#postprocessing)—Even if your phone doesn't support Apple Intelligence.\n\nIf you're experienced with Image Models, go to [Quickstart](#quickstart). Otherwise, check out the [Tutorial](#tutorial) for a full explanation.\n\nBe sure to read the [Important Things to Know](#important-things-to-know) and [Tips for Prompting](#tips-for-prompting)!\n\n## Table of Contents\n\n- [Important Things to Know](#important-things-to-know)\n- [Downloading the Model](#downloading-the-model)\n- [Quickstart](#quickstart)\n- [Tips for Prompting](#tips-for-prompting)\n- [Prompt Assist](#prompt-assist)\n- [Tutorial](#tutorial)\n  - [Running Open Genmoji with `mflux`](#running-open-genmoji-with-mflux)\n  - [Running Open Genmoji with Prompt Assist](#running-open-genmoji-with-prompt-assist)\n  - [LM Studio Prompt Assist and `mflux` Workflow](#lm-studio-prompt-assist-and-mflux-workflow)\n- [Postprocessing](#postprocessing)\n- [Contributing](#contributing)\n\n## Important Things to Know\n\n> **Please read this before continuing with the repository!**\n\nTL;DR: Use **Python 3.11** and **use HuggingFace** to download weights\n\n1. This project **works best with Python 3.11**. If you have a Python Version Manager, simply instally Python 3.11, and use the `python3.11` command in place of all commands that say `python3`, and also ensure to create your `.venv` with `python3.11`\n2. The various LoRA weights for this project are **hosted on HuggingFace** at [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji). Check [Downloading the Finetune](#downloading-the-finetune) below for more info.\n\n## Downloading the Finetune\n\nVarious Open Genmoji LoRAs are available on HuggingFace at [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji). However, there's a script included in this repository that makes downloading these LoRAs simple.\n\nFirst, clone into this repo:\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FEvanZhouDev\u002Fopen-genmoji.git\n```\n\nNext, we need to install the `huggingface_hub` library. It is recommended you first create a `venv`.\n\n```bash\n# Create a venv, optional\npython3 -m venv .venv\nsource .venv\u002Fbin\u002Factivate\n\n# Install huggingface_hub\npip install -U huggingface_hub\n```\n\nNow, all you have to do is run the `download.py` script available in the root directory:\n\n```bash\npython3 download.py\n```\n\nYou are now able to pick which LoRA you want to install. Each LoRA has a brief description, and the model it works with. For example, let's choose the `flux-dev` LoRA.\n\nGive it a few seconds, and check that `lora\u002Fflux-dev.safetensors` is installed. It should be a 209MB file. You're all good to go! Choose the LoRA you want for whatever you're doing.\n\n## Quickstart\n\n> If you're looking for detailed steps to run the model, check out the [Tutorial](#tutorial)\n\nIf you know what you're doing, here's a quickstart guide:\n\n- Use **Python 3.11** to ensure everything works\n- Get a LoRA from HuggingFace at [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji). Check out [Downloading the Finetune](#downloading-the-finetune) above for more info. There are various available.\n- Metaprompts for Open Genmoji are available in the `metaprompt` folder, so you can create the perfect prompt. [Learn more here.](#prompt-assist) I highly recommend using it!\n- Run the correct image model with the LoRA you downloaded (i.e. Flux.1 Dev). Check out [Postprocessing](#postprocessing) to learn how to use your creation as a real emoji in iOS 18\n\n## Tips for Prompting\n\nThe trigger word for the LoRA (what the image model needs to \"hear\" to start generating emojis) is \"emoji\". If you do not include this in your prompt, there is a high chance it won't generate an actual emoji.\n\nFurthermore, in order to develop a good prompt, I **highly recommend using Prompt Assist**.\n\n## Prompt Assist\n\nOpen Genmoji Prompt Assist is a way to use a metaprompt with Open Genmoji, to help you generate the perfect prompt for the Open Genmoji finetuned models. Note that each finetuned model may have its own metaprompt. See `lora\u002Finfo.json` to see which metaprompt each model uses. Then, find that metaprompt in the `metaprompt` folder.\n\n> However, if you're generating Apple Emojis, `metaprompt\u002Fopen-genmoji.md` should work fine.\n\nHere's an example of what Prompt Assist does:\n\n| Input        | Output                                                                                                                                      |\n| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------- |\n| `flying pig` | `emoji of flying pink pig. enlarged head in cartoon style. cute. white wings. head is turned towards viewer. 3D lighting. no cast shadows.` |\n\n> This was generated with `metaprompt\u002Fopen-genmoji.md`\n\nNow, you can focus on imagining the perfect emoji, while Prompt Assist helps you phrase it in a way that image models can understand.\n\nThe metaprompts can be used in any LLM, such as ChatGPT, to generate a prompt for Open Genmoji.\n\nCheck out [LM Studio Prompt Assist and `mflux` Workflow](#lm-studio-prompt-assist-and-mflux-workflow) for my full workflow of using LM Studio and `mflux` together to run Open Genmoji on Mac. This workflow automatically picks the metaprompt for the correct LLM, so you don't need to worry about checking the `info.json`.\n\n## Tutorial\n\n> This tutorial is **specifically for MacOS**. However, Open Genmoji is completely adaptable for other operating systems. You will just need another tool to run Flux.1 Dev, with a LoRA.\n\nIf you're new to Image Generation or locally running models, this is the place for you. This guide will lead you through all the steps necessary to run Open Genmoji, and also use the Open Genmoji Prompt Assist metaprompt.\n\nBefore you start, ensure you are using Python 3.11. The easiest way to do this is by installing Python 3.11 with your method of choice, then replacing the CLI command `python3`\u002F`python` with `python3.11`. Ensure you also create your `venv` with Python 3.11.\n\nFirst, let's get started by simply running the model.\n\n### Prerequisites\n\nBefore everything, we need to set up Hugging Face. If you already have a Hugging Face token, logged in to the CLI, and agreed to Flux.1 Dev terms and conditions, skip to [Running Open Genmoji with `mflux`](#running-open-genmoji-with-mflux)\n\n**Setting Up Hugging Face**:\n\n1. Go to [Hugging Face](https:\u002F\u002Fhuggingface.co) and make an account. Verify your email.\n2. Go to [Hugging Face Token Settings](https:\u002F\u002Fhuggingface.co\u002Fsettings\u002Ftokens) and create a token. Ensure you either have Token Type of **Read** at the top, or check **Read access to contents of all public gated repos you can access** in token type Fine-grained.\n3. Install the [Hugging Face CLI](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Fhuggingface_hub\u002Fen\u002Fguides\u002Fcli) with your method of choice (Homebrew, pip, etc.)\n4. Run `huggingface-cli login` and use your token to login\n5. Finally, go to [Flux.1 Dev Hugging Face Page](https:\u002F\u002Fhuggingface.co\u002Fblack-forest-labs\u002FFLUX.1-dev). Read and agree to the terms at the top to use the Gated model.\n\nYou're all done! When you run `mflux` below for the first time, it'll automatically download Flux.1 Dev.\n\n### Running Open Genmoji with `mflux`\n\nThe image model we'll be using in this guide is Flux.1 Dev. Open Genmoji takes the form of a LoRA, which is just a file that can teach the image model how to do something specific. In this case, create emojis!\n\nFirst, clone this repository:\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FEvanZhouDev\u002Fopen-genmoji.git\n```\n\nNext, we need to install some dependencies. It's recommended we create a `venv`:\n\n```bash\n# Create a venv, optional\npython3 -m venv .venv\nsource .venv\u002Fbin\u002Factivate\n\n# Install huggingface_hub and mflux\npip install -U huggingface_hub mflux\n```\n\nHere's what those dependencies are:\n\n- `huggingface_hub`: This will help us download the weights that we need to run Open Genmoji\n- `mflux`: This is a port of Flux (to run our image generation model), specifically for Mac.\n\nNow, let's actually install the LoRA. There are various available on HuggingFace at [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji), for different uses, but there's a quick installation script you can run in this directory:\n\n```bash\npython3 .\u002Fdownload.py\n```\n\nNow, you can pick which LoRA you want. For this tutorial, let's install the one named `flux-dev`. Use arrow keys to navigate to it, and press enter to select.\n\nAfter it's done installing, verify that `lora\u002Fflux-dev.safetensors` is downloaded. That'll be the LoRA that you'll be using.\n\nNow, you're all good to go. Run the following command and you'll be able to create your first emoji. Play around with the prompt, and see what you can make. (If you're struggling with a good result, check out [Prompt Assist](#running-open-genmoji-with-prompt-assist))\n\n```bash\nmflux-generate \\\n    --model dev \\\n    --prompt \"your prompt\" \\\n    --steps 20 \\\n    --seed 2 \\\n    --quantize 8 \\\n    --guidance 5.0 \\\n    --width 160 \\\n    --height 160 \\\n    --lora-paths \".\u002Flora\u002Fflux-dev.safetensors\"\n```\n\n### Running Open Genmoji with Prompt Assist\n\nIt's pretty difficult to get a good prompt to make a Apple-like emoji. Thus, we'll use a metaprompt... a prompt for an LLM, to make a prompt for Open Genmoji. Here's an example:\n\n| Input        | Output                                                                                                                                      |\n| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------- |\n| `flying pig` | `emoji of flying pink pig. enlarged head in cartoon style. cute. white wings. head is turned towards viewer. 3D lighting. no cast shadows.` |\n\nThe output prompt is now much better, and the generated emoji will be of much better quality.\n\nYou can run the metaprompt in any place an LLM is available, including ChatGPT! Each LoRA has its own metaprompt. However in our case, we'll simply be using `metaprompt\u002Fopen-genmoji.md`, for the `flux-dev` LoRA. Now, give the prompt to the LLM, and after it, include your user prompt. Something like this:\n\n```\n{METAPROMPT HERE}\n\nUSER PROMPT: {your input}\n```\n\nThen, take the LLM output and feed that to `mflux`. Observe how the output is much better!\n\nNow that you have a image output, head on to [Postprocessing](#postprocessing) to start using your creation as an actual emoji on your iPhone, or learn a bit more below about how to chain Prompt Assist and `mflux` together.\n\n### LM Studio Prompt Assist and `mflux` Workflow\n\n> If you haven't already, go to [Downloading the Finetune](#downloading-the-finetune) to download the LoRA\n\nIt's a bit tedious to feed your own prompt to an LLM, then feed the LLM output to `mflux`. So I made a quick Python workflow to chain these things together.\n\nIt's a bit of a specific\u002Fpersonal setup, but I decided to push it in case anyone wants to use it too.\n\nFirst, you will need to install [LM Studio](https:\u002F\u002Flmstudio.ai\u002F). Download your favorite local model, and start the Development mode. It should be running on port `1234` (default).\n\nNow, install these two dependencies (in addition to `mflux`):\n\n```bash\npip install mflux pillow requests\n```\n\nNow, given that LM Studio is correctly set up, you should be able to directly run:\n\n```bash\npython3 genmoji.py \"[your prompt]\"\n```\n\n> Note that this will automatically use the `flux-dev` LoRA (and will error should it [not be installed](#downloading-the-finetune)). See [Advanced Usage](#advanced-usage) below to see how to use a different LoRA.\n\nAnd it'll first generate a prompt with LM Studio, and feed that into `mflux`. The output should be saved by default in `output\u002Fgenmoji-001.png` (Number will increase automatically).\n\n> **Note**: Before it saves, it'll also do the Postprocessing step of resizing it to 5x the size with anti-aliasing (160x160 → 800x800). Learn more in [Postprocessing](#postprocessing)\n\nNow, let's take a look at [Postprocessing](#postprocessing) to start using your creation as an actual emoji in iOS, or see [Advanced Usage](#advanced-usage) to learn how to use a different LoRA with this workflow.\n\n#### Advanced Usage\n\n##### Using different LoRA's\n\nThis workflow also enables automatic metaprompt selection when using a different LoRA.\n\nAll you have to do is call it with an extra argument with flag `--lora` or `-l`, as such:\n\n```bash\npython3 genmoji.py \"[your prompt]\" --lora [lora name] \n```\n\nFor example, let's use [@caspersimon](https:\u002F\u002Fgithub.com\u002Fcaspersimon)'s `diverse-emoji` LoRA. First, you'll need to ensure it's [downloaded with the download script](#downloading-the-finetune). Now, run this command:\n\n```bash\npython3 genmoji.py \"[your prompt]\" -l diverse-emoji\n```\n\nThis will automatically fetch the correct metaprompt, use it, and generate an emoji with the `diverse-emoji` LoRA.\n\n##### Bypassing Prompt Assistant\n\nTo directly generate without first using Prompt Assistant, add the `--direct` or `-d` flag to your command\n\n\n```bash\npython3 genmoji.py \"emoji of a squirrel\" -d\n```\n\n##### Generating at custom resolution\n\nThe default resolution is 160x160. To change it, use the `--height` or `-ih` flags to change image height, and `--width` or `-iw` to change image width.\n\nFor example, to generate an emoji of a dog wearing sunglasses at 320x320 pixels, run:\n\n```bash\npython3 genmoji.py \"dog wearing sunglasses\" -ih 320 -iw 320\n```\n\n##### Changing upscale factor\n\nBy default, images are scaled up to 5 times their original resolution. To change it, use the `--upscale` or `-u` flags.\n\nFor example, to upscale to 2x the original resolution, use:\n\n```bash\npython3 genmoji.py \"emoji of a squirrel\" -u 2\n```\n\n## Postprocessing\n\nNow that you have a single output image, our first step is to resize to 800x800, with anti-aliasing, so that iOS's Sticker\u002FEmoji system recognizes it. If you've used the all-in-one LM Studio\u002F`mflux` workflow, this step is already done.\n\nIf you don't have it installed, first install `pillow` to do the following procedure:\n\n```bash\npip install pillow\n```\n\nAll you have to do is simply run `python3 resize.py path\u002Fto\u002Fyour\u002Fimage.png`. This should generate a new image conveniently with \"resized\" in the name.\n\nNow, all you have to do is send this image over to your phone. Now, follow these simple steps to use it as a Sticker (iOS 17+) or Emoji (iOS 18+):\n\n1. Open the image on your phone in Photos\n2. Long press and hold on the emoji in your picture (**don't move your finger**), and release after ~2s\n3. Press the **Add Sticker** button\n\nNow, if you're on iOS 17+, you should be able to apply this sticker by dragging it onto a message.\n\nIf you're on iOS 18+, in your emoji menu, you can simply tap your sticker to use it inline just like an emoji.\n\nIf you want to delete the Sticker, long press and hold (**don't move your finger**) on the Sticker in the Sticker gallery and release after ~2s. Press **Delete**.\n\n## Contributing\n\nOpen Genmoji is open to more LoRAs for:\n\n- New models\n- New\u002FDifferent sets of emojis\n- More training for existing emoji sets\n\nCheck out `finetuning\u002FREADME.md` for more information about finetuning, and check out `lora\u002FREADME.md` for the current available LoRAs, as well as more information about how to contribute.\n","\u003Cpicture>\n  \u003Csource media=\"(prefers-color-scheme: dark)\" srcset=\".\u002Fassets\u002Fbanner@dark.png\">\n  \u003Csource media=\"(prefers-color-scheme: light)\" srcset=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_b9457c447ad7.png\">\n  \u003Cimg alt=\"Open Genmoji 横幅\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_b9457c447ad7.png\">\n\u003C\u002Fpicture>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji\">HuggingFace\u003C\u002Fa> | \u003Ca href=\"#quickstart\">快速入门\u003C\u002Fa> | \u003Ca href=\"#tutorial\">教程\u003C\u002Fa> | \u003Ca href=\"https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=vOVDyRIS09k\">制作 Open Genmoji（视频）\u003C\u002Fa>\n\u003C\u002Fp>\n\n## 什么是 Open Genmoji？\n\n> 请观看 [YouTube](https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=vOVDyRIS09k)，了解 Open Genmoji 的创作过程，并深入探究 Apple Genmoji 的底层工作原理。\n\nOpen Genmoji 致力于使用开源技术重现 Apple 的 Genmoji 功能！它不仅能在 Apple 设备上运行，还能在任何平台上使用。\n\n以下是 Open Genmoji 的一些示例：\n| ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_95ec4eeab1a5.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_ecbbe77ae94e.png) |![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_51e37ff8df21.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_13a7bfe20be2.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_35a065abb728.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_076ab2e13f26.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_5be5f379b0a1.png) |\n| --------------------------------------------------------- | ---------------------------------------------------- | ------------------------------------------------------- | -------------------------------------------------------- | ----------------------------------------------------- | ---------------------------------------------------- |---------------------------------------------------- |\n\n\u003Cdetails>\n\u003Csummary>提示词、与 Apple Genmoji 的对比及更多信息\u003C\u002Fsummary>\n\n所有展示的表情符号均由 `flux-dev` Open Genmoji LoRA 和 Prompt Assist 生成。我们对 Open Genmoji 和 Apple 使用了完全相同的提示词，Prompt Assist 则基于 Qwen 2.5 32B Instruct 模型运行。\n\n表情符号的背景通过 Figma AI 工具去除。\n\n这 7 个样本分别展示了 Open Genmoji 在动物、物品和人物表情符号方面的表现。\n\n| 提示词                                                                  | Open Genmoji                                              | Apple                                              |\n| ----------------------------------------------------------------------- | --------------------------------------------------------- | -------------------------------------------------- |\n| `flying pig white wings`（动物表情符号）                                 | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_95ec4eeab1a5.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_9d721f8f83ef.png) |\n| `handsome horse in black suit and tie with flowing mane`（动物表情符号） | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_ecbbe77ae94e.png)      | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_1a6f9f790669.png)      |\n| `teddy bear in space suit`（动物表情符号）                               | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_51e37ff8df21.png) | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_24c2ea4c2603.png) |\n| `rainbow popsicle`（物品表情符号）                                       | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_13a7bfe20be2.png)   | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_e8d4a09f78ad.png)   |\n| `fireplace`（物品表情符号）                                              | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_35a065abb728.png)  | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_dcf77130f500.png)  |\n| `robber with money bag`（人物表情符号）                                  | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_076ab2e13f26.png)     | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_770f5ec22c23.png)     |\n| `hiker`（人物表情符号）                                                  | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_5be5f379b0a1.png)      | ![](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_readme_10a1231bc08d.png)      |\n\n\u003C\u002Fdetails>\n\n\u003Cbr>\n\n本质上，Open Genmoji 只是一组 LoRA 文件（可在 [HuggingFace](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji) 上获取），每一份都基于数千个 Apple 表情符号进行微调，从而教会图像生成模型如何创建表情符号。只要能够在图像生成模型中加载 LoRA，就可以使用 Open Genmoji。\n\n此外，Open Genmoji 还配备了特殊的元提示词工具——[Open Genmoji Prompt Assist](#prompt-assist)，帮助你构建完美的提示词，以生成任意想要的表情符号。部分 Open Genmoji LoRA 也可能自带专属的元提示词。\n\n最棒的是，你甚至可以将自己生成的内容在 iOS 18 及更高版本中作为真正的表情符号使用——即使你的手机不支持 Apple Intelligence！\n\n如果你熟悉图像生成模型，请直接跳转至 [快速入门](#quickstart)。否则，建议先阅读 [教程](#tutorial)，以获得更全面的说明。\n\n别忘了查看 [重要须知](#important-things-to-know) 和 [提示词编写技巧](#tips-for-prompting)！\n\n## 目录\n\n- [重要须知](#important-things-to-know)\n- [下载模型](#downloading-the-model)\n- [快速入门](#quickstart)\n- [提示词编写技巧](#tips-for-prompting)\n- [Prompt Assist](#prompt-assist)\n- [教程](#tutorial)\n  - [使用 `mflux` 运行 Open Genmoji](#running-open-genmoji-with-mflux)\n  - [使用 Prompt Assist 运行 Open Genmoji](#running-open-genmoji-with-prompt-assist)\n  - [LM Studio Prompt Assist 与 `mflux` 工作流程](#lm-studio-prompt-assist-and-mflux-workflow)\n- [后处理](#postprocessing)\n- [贡献代码](#contributing)\n\n## 重要须知\n\n> **请在继续操作本仓库之前仔细阅读！**\n\n简而言之：请使用 Python 3.11，并通过 HuggingFace 下载权重。\n\n1. 本项目 **最适合使用 Python 3.11**。如果你有 Python 版本管理工具，只需安装 Python 3.11，并将所有命令中的 `python3` 替换为 `python3.11`，同时确保使用 `python3.11` 创建虚拟环境。\n2. 本项目的各类 LoRA 权重均托管在 HuggingFace 上，地址为 [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji)。更多详情请参阅下方的 [下载微调模型](#downloading-the-finetune)。\n\n## 下载微调模型\n\nOpen Genmoji 的多种 LoRA 文件已在 HuggingFace 的 [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji) 页面上发布。不过，本仓库内附带了一个脚本，可简化这些 LoRA 文件的下载流程。\n\n首先，克隆本仓库：\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FEvanZhouDev\u002Fopen-genmoji.git\n```\n\n接下来，我们需要安装 `huggingface_hub` 库。建议先创建一个虚拟环境。\n\n```bash\n# 创建虚拟环境（可选）\npython3 -m venv .venv\nsource .venv\u002Fbin\u002Factivate\n\n# 安装 huggingface_hub\npip install -U huggingface_hub\n```\n\n现在，你只需运行根目录下的 `download.py` 脚本即可：\n\n```bash\npython3 download.py\n```\n\n接下来，你可以选择要安装的 LoRA。每个 LoRA 都附有简短描述以及它所适用的模型。例如，我们选择 `flux-dev` LoRA。\n\n等待几秒钟后，请确认 `lora\u002Fflux-dev.safetensors` 已成功安装。该文件大小应为 209MB。一切就绪！根据你的需求选择合适的 LoRA 即可。\n\n## 快速入门\n\n> 如果你想了解详细的运行步骤，请参阅【教程】部分。\n\n如果你已经熟悉相关操作，以下是快速入门指南：\n\n- 使用 **Python 3.11** 以确保一切正常运行。\n- 从 HuggingFace 的 [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji) 获取 LoRA。更多信息请参阅上方的【下载微调模型】部分。目前有多种 LoRA 可供选择。\n- Open Genmoji 的元提示位于 `metaprompt` 文件夹中，可以帮助你构建完美的提示词。[点击此处了解更多。](#prompt-assist) 强烈推荐使用！\n- 使用你下载的 LoRA（例如 Flux.1 Dev）运行相应的图像模型。请参阅【后处理】部分，了解如何将生成的作品用作 iOS 18 中的真实表情符号。\n\n## 提示词编写技巧\n\nLoRA 的触发词（即图像模型需要“听到”才能开始生成表情符号的关键字）是“emoji”。如果你的提示词中未包含此关键词，则很可能无法生成真正的表情符号。\n\n此外，为了编写出优质的提示词，我**强烈建议使用 Prompt Assist**。\n\n## Prompt Assist\n\nOpen Genmoji Prompt Assist 是一种结合元提示与 Open Genmoji 使用的方式，旨在帮助你为 Open Genmoji 微调模型生成最理想的提示词。请注意，每种微调模型可能对应不同的元提示。你可以在 `lora\u002Finfo.json` 文件中查看各模型使用的元提示，然后在 `metaprompt` 文件夹中找到对应的元提示。\n\n> 不过，如果你要生成 Apple 表情符号，直接使用 `metaprompt\u002Fopen-genmoji.md` 即可。\n\n以下是 Prompt Assist 的示例：\n\n| 输入        | 输出                                                                                                                                      |\n| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------- |\n| `flying pig` | `一只飞翔的粉色猪的表情符号。卡通风格，头部放大。可爱。白色翅膀。头部朝向观看者。3D 光照效果。无投影阴影。` |\n\n> 此结果由 `metaprompt\u002Fopen-genmoji.md` 生成。\n\n现在，你可以专注于构思完美的表情符号，而 Prompt Assist 则会帮你将其转化为图像模型能够理解的提示语。\n\n这些元提示也可以用于任何大型语言模型（如 ChatGPT），以生成适用于 Open Genmoji 的提示词。\n\n请参阅【LM Studio Prompt Assist 和 `mflux` 工作流】部分，了解我在 Mac 上同时使用 LM Studio 和 `mflux` 运行 Open Genmoji 的完整流程。该工作流会自动为正确的 LLM 选择元提示，因此你无需再检查 `info.json` 文件。\n\n## 教程\n\n> 本教程**专为 macOS 设计**。不过，Open Genmoji 完全可以适配其他操作系统。你只需要另外的工具来运行带有 LoRA 的 Flux.1 Dev 模型即可。\n\n如果你是图像生成或本地运行模型的新手，那么本指南非常适合你。我们将一步步引导你完成 Open Genmoji 的运行，并教你如何使用 Open Genmoji Prompt Assist 元提示。\n\n在开始之前，请确保使用 Python 3.11。最简单的方法是通过你喜欢的方式安装 Python 3.11，然后将命令行中的 `python3` 或 `python` 替换为 `python3.11`。同时，请务必使用 Python 3.11 创建虚拟环境。\n\n首先，让我们从运行模型开始。\n\n### 前置条件\n\n在开始之前，我们需要先设置 HuggingFace。如果你已经拥有 HuggingFace 令牌、登录了 CLI，并同意了 Flux.1 Dev 的使用条款，请直接跳转至【使用 `mflux` 运行 Open Genmoji】部分。\n\n**设置 HuggingFace**：\n\n1. 访问 [HuggingFace](https:\u002F\u002Fhuggingface.co)，注册并验证邮箱。\n2. 进入 [HuggingFace 令牌设置](https:\u002F\u002Fhuggingface.co\u002Fsettings\u002Ftokens)，创建一个令牌。确保令牌类型为 **读取**，或者在细粒度令牌类型中勾选 **对所有可访问的公共 gated 仓库内容的读取权限**。\n3. 使用你喜欢的方式（Homebrew、pip 等）安装 [HuggingFace CLI](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Fhuggingface_hub\u002Fen\u002Fguides\u002Fcli)。\n4. 运行 `huggingface-cli login`，并使用你的令牌登录。\n5. 最后，前往 [Flux.1 Dev 的 HuggingFace 页面](https:\u002F\u002Fhuggingface.co\u002Fblack-forest-labs\u002FFLUX.1-dev)。阅读并同意页面顶部的条款，以使用该 gated 模型。\n\n大功告成！当你首次运行下方的 `mflux` 时，它会自动下载 Flux.1 Dev 模型。\n\n### 使用 `mflux` 运行 Open Genmoji\n\n本指南中我们将使用的图像模型是 Flux.1 Dev。Open Genmoji 以 LoRA 的形式存在，它只是一个文件，能够教会图像模型执行特定任务——在本例中就是生成表情符号！\n\n首先，克隆本仓库：\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FEvanZhouDev\u002Fopen-genmoji.git\n```\n\n接下来，我们需要安装一些依赖项。建议创建一个虚拟环境：\n\n```bash\n# 创建虚拟环境（可选）\npython3 -m venv .venv\nsource .venv\u002Fbin\u002Factivate\n\n# 安装 huggingface_hub 和 mflux\npip install -U huggingface_hub mflux\n```\n\n这些依赖项的作用如下：\n\n- `huggingface_hub`：用于下载运行 Open Genmoji 所需的权重。\n- `mflux`：这是 Flux 的移植版本，专门用于 Mac 平台的图像生成。\n\n现在，我们来安装 LoRA。HuggingFace 上的 [EvanZhouDev\u002Fopen-genmoji](https:\u002F\u002Fhuggingface.co\u002FEvanZhouDev\u002Fopen-genmoji) 提供了多种 LoRA，适用于不同场景。你可以在当前目录下运行一个快捷安装脚本：\n\n```bash\npython3 .\u002Fdownload.py\n```\n\n现在，你可以选择想要安装的 LoRA。在本教程中，我们安装名为 `flux-dev` 的 LoRA。使用方向键导航到它，然后按 Enter 键进行选择。\n\n安装完成后，请确认 `lora\u002Fflux-dev.safetensors` 已下载。这正是你将要使用的 LoRA。\n\n至此，准备工作已完成。运行以下命令即可生成你的第一个表情符号。尝试调整提示词，看看能创造出什么有趣的内容。（如果始终得不到理想效果，不妨参考【Prompt Assist】部分）\n\n```bash\nmflux-generate \\\n    --model dev \\\n    --prompt \"你的提示词\" \\\n    --steps 20 \\\n    --seed 2 \\\n    --quantize 8 \\\n    --guidance 5.0 \\\n    --width 160 \\\n    --height 160 \\\n    --lora-paths \".\u002Flora\u002Fflux-dev.safetensors\"\n```\n\n### 使用提示助手运行 Open Genmoji\n\n要编写一个能生成类似 Apple 风格表情符号的良好提示，通常相当困难。因此，我们将使用元提示——即用于大语言模型的提示——来为 Open Genmoji 生成提示。以下是一个示例：\n\n| 输入        | 输出                                                                                                                                      |\n| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------- |\n| `flying pig` | `一只飞翔的粉色小猪的表情符号。卡通风格，头部放大。可爱。白色翅膀。头部朝向观看者。3D 光照效果。无投影阴影。` |\n\n现在生成的提示要好得多，由此生成的表情符号质量也会更高。\n你可以将元提示输入到任何可用的大语言模型中，包括 ChatGPT！每个 LoRA 都有自己的元提示。但在我们的例子中，我们将直接使用 `flux-dev` LoRA 对应的 `metaprompt\u002Fopen-genmoji.md` 文件。接下来，将该元提示提供给大语言模型，然后在其后加上你的用户提示，格式如下：\n\n```\n{METAPROMPT HERE}\n\nUSER PROMPT: {your input}\n```\n\n随后，将大语言模型的输出传递给 `mflux`。你会发现，最终生成的结果要好得多！\n\n现在你已经得到了一张图像输出，可以前往 [后处理](#postprocessing) 部分，开始将你的作品用作 iPhone 上的真实表情符号；或者在下方了解更多关于如何将提示助手与 `mflux` 链接起来的信息。\n\n### LM Studio 提示助手与 `mflux` 工作流\n\n> 如果你尚未完成，请先前往 [下载微调模型](#downloading-the-finetune) 下载 LoRA 模型。\n\n手动将自定义提示输入大语言模型，再将模型的输出传递给 `mflux`，这个过程略显繁琐。为此，我编写了一个简单的 Python 工作流来自动串联这些步骤。\n虽然这套设置较为特定且个人化，但我还是决定将其公开，以供有兴趣的人使用。\n\n首先，你需要安装 [LM Studio](https:\u002F\u002Flmstudio.ai\u002F)。下载你喜欢的本地模型，并启动开发模式。默认情况下，它会运行在端口 `1234` 上。\n\n接着，除了 `mflux` 之外，还需安装以下两个依赖库：\n\n```bash\npip install mflux pillow requests\n```\n\n确保 LM Studio 设置正确后，你就可以直接运行以下命令：\n\n```bash\npython3 genmoji.py \"[your prompt]\"\n```\n\n> 注意，此脚本会自动使用 `flux-dev` LoRA（如果未安装该 LoRA，则会报错）。如需使用其他 LoRA，请参阅下方的 [高级用法](#advanced-usage)。\n\n运行后，脚本会先通过 LM Studio 生成提示，再将该提示输入 `mflux` 进行处理。最终生成的图像默认保存为 `output\u002Fgenmoji-001.png`（文件名中的数字会自动递增）。\n> **注意**：在保存之前，脚本还会执行后处理步骤，将图像按 5 倍比例放大并进行抗锯齿处理（160×160 → 800×800）。更多详情请参阅 [后处理](#postprocessing) 部分。\n\n接下来，让我们查看 [后处理](#postprocessing) 部分，了解如何将你的作品作为 iOS 系统中的真实表情符号使用；或者参阅 [高级用法](#advanced-usage) 部分，学习如何在此工作流中使用不同的 LoRA。\n\n#### 高级用法\n\n##### 使用不同 LoRA\n\n该工作流还支持在使用不同 LoRA 时自动选择对应的元提示。\n你只需在命令中添加额外的 `--lora` 或 `-l` 参数即可，例如：\n\n```bash\npython3 genmoji.py \"[your prompt]\" --lora [lora name] \n```\n\n以 [@caspersimon](https:\u002F\u002Fgithub.com\u002Fcaspersimon) 的 `diverse-emoji` LoRA 为例。首先，你需要确保已通过下载脚本将其下载到位（详见 [下载微调模型](#downloading-the-finetune)）。然后运行以下命令：\n\n```bash\npython3 genmoji.py \"[your prompt]\" -l diverse-emoji\n```\n\n这样，脚本会自动获取正确的元提示，应用该提示，并使用 `diverse-emoji` LoRA 生成表情符号。\n\n##### 跳过提示助手\n\n若希望直接生成而无需先使用提示助手，可在命令中添加 `--direct` 或 `-d` 标志。\n\n```bash\npython3 genmoji.py \"一只松鼠的表情符号\" -d\n```\n\n##### 自定义分辨率生成\n\n默认分辨率为 160×160。如需更改，可使用 `--height` 或 `-ih` 参数调整图像高度，以及 `--width` 或 `-iw` 参数调整图像宽度。\n例如，要生成一只戴着太阳镜的狗的表情符号，分辨率为 320×320 像素，可运行：\n\n```bash\npython3 genmoji.py \"戴太阳镜的狗\" -ih 320 -iw 320\n```\n\n##### 更改放大倍数\n\n默认情况下，图像会被放大至原始分辨率的 5 倍。如需更改，可使用 `--upscale` 或 `-u` 参数。\n例如，若希望将图像放大至原尺寸的 2 倍，可运行：\n\n```bash\npython3 genmoji.py \"一只松鼠的表情符号\" -u 2\n```\n\n## 后处理\n\n现在你已经获得了一张输出图像，第一步是将其调整为 800×800 像素，并进行抗锯齿处理，以便 iOS 的贴纸\u002F表情符号系统能够识别它。如果你使用的是 LM Studio 和 `mflux` 的一体化工作流，这一步已经自动完成。\n若尚未安装相关工具，首先需要安装 `pillow` 库来执行后续操作：\n\n```bash\npip install pillow\n```\n\n之后，只需运行 `python3 resize.py path\u002Fto\u002Fyour\u002Fimage.png` 即可。该脚本会生成一张新图像，文件名中会包含“resized”字样。\n接下来，只需将这张图像发送到你的手机上。按照以下简单步骤，即可将其用作贴纸（iOS 17 及以上版本）或表情符号（iOS 18 及以上版本）：\n\n1. 在手机相册中打开该图像。\n2. 长按图片中的表情符号（**不要移动手指**），持续约 2 秒后松开。\n3. 点击 **添加贴纸** 按钮。\n\n如果你使用的是 iOS 17 或更高版本，可以直接将该贴纸拖拽到消息中应用。\n如果你使用的是 iOS 18 或更高版本，在表情符号菜单中，只需轻点你的贴纸，即可像普通表情符号一样直接插入文本中。\n若想删除该贴纸，同样长按贴纸（**不要移动手指**），持续约 2 秒后松开，然后点击 **删除** 即可。\n\n## 贡献\n\nOpen Genmoji 欢迎更多 LoRA 的加入，用于：\n- 新模型\n- 新的或不同的表情符号集\n- 对现有表情符号集的进一步训练\n\n有关微调的更多信息，请参阅 `finetuning\u002FREADME.md`；有关当前可用的 LoRA 以及如何贡献的详细信息，请参阅 `lora\u002FREADME.md`。","# Open Genmoji 快速上手指南\n\nOpen Genmoji 是一个开源项目，旨在复现 Apple 的 Genmoji 功能。它通过 LoRA 微调技术，让图像生成模型（如 Flux.1 Dev）能够创建自定义表情符号。本项目不依赖 Apple 设备，生成的图片经过简单处理后即可在 iOS 18+ 中作为真实表情使用。\n\n## 环境准备\n\n*   **操作系统**：本指南以 macOS 为例（Linux\u002FWindows 用户需自行配置对应的图像生成推理工具）。\n*   **Python 版本**：**必须使用 Python 3.11**。其他版本可能导致兼容性问题。\n    *   建议使用 `pyenv` 或系统包管理器安装 Python 3.11。\n    *   后续所有命令中的 `python3` 请替换为 `python3.11`。\n*   **Hugging Face 账号**：\n    1. 注册并验证邮箱。\n    2. 创建 Access Token（权限需包含 **Read** 或勾选 **Read access to contents of all public gated repos**）。\n    3. 访问 [Flux.1 Dev 页面](https:\u002F\u002Fhuggingface.co\u002Fblack-forest-labs\u002FFLUX.1-dev) 阅读并同意使用条款（Gated Model）。\n*   **硬件要求**：运行 Flux.1 Dev 模型建议具备较高显存的 GPU（Mac M 系列芯片或 NVIDIA 显卡）。\n\n## 安装步骤\n\n### 1. 克隆项目与配置虚拟环境\n\n```bash\n# 克隆仓库\ngit clone https:\u002F\u002Fgithub.com\u002FEvanZhouDev\u002Fopen-genmoji.git\ncd open-genmoji\n\n# 创建并激活虚拟环境 (务必使用 python3.11)\npython3.11 -m venv .venv\nsource .venv\u002Fbin\u002Factivate\n\n# 安装 Hugging Face CLI 工具\npip install -U huggingface_hub\n```\n\n### 2. 登录 Hugging Face\n\n```bash\nhuggingface-cli login\n# 按提示输入之前创建的 Token\n```\n\n### 3. 下载模型权重 (LoRA)\n\n项目提供脚本自动下载所需的 LoRA 文件。\n\n```bash\npython3.11 download.py\n```\n\n*   运行后根据提示选择模型，推荐选择 `flux-dev` LoRA。\n*   下载完成后，确认 `lora\u002Fflux-dev.safetensors` 文件已存在（约 209MB）。\n\n### 4. 安装推理工具 (mflux)\n\n本教程使用 `mflux` 在本地运行 Flux.1 Dev 模型。确保已安装该工具（若未安装，通常可通过 pip 或项目推荐方式安装）：\n\n```bash\n# 示例安装命令，具体视 mflux 发布渠道而定\npip install mflux\n```\n*(注：首次运行 mflux 时会自动下载 Flux.1 Dev 主模型，请保持网络通畅)*\n\n## 基本使用\n\nOpen Genmoji 的核心在于使用特定的触发词 **\"emoji\"** 并结合优化后的提示词。\n\n### 方法一：直接使用提示词 (快速测试)\n\n在使用支持 LoRA 的图像生成工具（如 mflux, ComfyUI, WebUI）时，加载下载的 LoRA 文件，并使用以下格式的 Prompt：\n\n**Prompt 模板：**\n```text\nemoji of [你的描述]. enlarged head in cartoon style. cute. 3D lighting. no cast shadows.\n```\n\n**示例：**\n```text\nemoji of flying pig with white wings. enlarged head in cartoon style. cute. 3D lighting. no cast shadows.\n```\n*注意：必须包含触发词 `emoji`，否则模型可能无法生成表情风格。*\n\n### 方法二：使用 Prompt Assist 优化提示词 (推荐)\n\n为了获得最佳效果，建议使用项目提供的元提示词（Metaprompt）让大语言模型（如 ChatGPT, Qwen, LM Studio）帮你优化描述。\n\n1.  找到 `metaprompt\u002Fopen-genmoji.md` 文件内容。\n2.  将其发送给任意 LLM，并附上你的简单想法（例如：\"flying pig\"）。\n3.  LLM 将输出优化的详细 Prompt（例如：`emoji of flying pink pig. enlarged head in cartoon style. cute. white wings...`）。\n4.  将输出的完整句子放入图像生成模型中运行。\n\n### 后续处理 (Postprocessing)\n\n生成的图片包含背景。若要在 iOS 18+ 中作为系统表情使用：\n1.  使用工具（如 Figma AI, Photoshop, 或在线去背工具）移除图片背景，保存为透明 PNG。\n2.  通过快捷指令或特定工具将其导入 iOS 表情键盘。","某跨平台社交应用的产品团队正计划上线“用户自定义表情”功能，希望让用户能通过文字描述生成独一无二的个性化 Emoji，以增强社区互动趣味性。\n\n### 没有 open-genmoji 时\n- **设备生态受限**：团队只能依赖苹果设备的 Genmoji 功能，导致安卓和 Web 端用户无法体验该特性，造成严重的用户体验割裂。\n- **开发成本高昂**：若自行训练生成模型，需要昂贵的算力资源和漫长的数据清洗周期，初创团队难以承担。\n- **创意实现僵化**：现有静态贴图库无法覆盖用户千奇百怪的脑洞（如“穿西装的飞马”或“太空泰迪熊”），只能提供有限的预设选项。\n- **迭代响应缓慢**：每当需要新增特定风格的表情时，都必须等待设计师手动绘制，无法实时响应用户的即时创作需求。\n\n### 使用 open-genmoji 后\n- **全平台无缝覆盖**：利用 open-genmoji 的开源 LoRA 模型，团队成功在安卓、iOS 及网页端统一部署了生成能力，所有用户均可平等使用。\n- **快速低成本落地**：直接复用 HuggingFace 上成熟的 `flux-dev` LoRA 文件，无需从零训练，几天内即可完成功能集成与上线。\n- **无限创意支持**：用户输入任意自然语言提示词（如“拿着钱袋的劫匪”），open-genmoji 即可实时生成高质量、风格统一的动态表情，完美还原用户想象。\n- **实时交互体验**：结合后端部署，实现了“输入即生成”的流畅交互，用户不再需要等待人工审核或制作，极大提升了创作热情。\n\nopen-genmoji 打破了专有硬件的壁垒，让每个开发者都能以极低的成本为用户赋予“所想即所得”的创意表达权。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FEvanZhouDev_open-genmoji_95ec4eea.png","EvanZhouDev","Evan Zhou","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002FEvanZhouDev_d48816df.png","Designer, Developer, Content Creator",null,"echo \"$PWD\"","evanzhoudev@gmail.com","evanzhoudev","https:\u002F\u002Fgithub.com\u002FEvanZhouDev",[86],{"name":87,"color":88,"percentage":89},"Python","#3572A5",100,640,47,"2026-04-01T21:13:54","macOS, Linux, Windows","未说明（教程主要针对 macOS，但指出项目可适配其他系统，需自行准备能运行 Flux.1 Dev + LoRA 的工具）","未说明",{"notes":97,"python":98,"dependencies":99},"1. 强烈建议使用 Python 3.11 版本，否则可能无法正常运行。\n2. 核心组件为 LoRA 文件，需配合支持 LoRA 的图像生成模型（如 Flux.1 Dev）使用。\n3. 首次运行前需配置 Hugging Face Token 并同意 Flux.1 Dev 的使用条款以下载权重。\n4. 提供了 'Prompt Assist' 功能，建议结合 LLM（如 Qwen 2.5 或 LM Studio）优化提示词以获得最佳效果。\n5. 生成的图片可通过后处理在 iOS 18+ 中作为真实表情符号使用。","3.11",[100,101,102,103],"huggingface_hub","mflux","Flux.1 Dev (模型)","Open Genmoji LoRA",[15,13,14],[106,107,108],"ai","emoji","genmoji","2026-03-27T02:49:30.150509","2026-04-06T08:40:44.646129",[],[]]