[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"tool-David-patrick-chuks--Riona-AI-Agent":3,"similar-David-patrick-chuks--Riona-AI-Agent":106},{"id":4,"github_repo":5,"name":6,"description_en":7,"description_zh":8,"ai_summary_zh":8,"readme_en":9,"readme_zh":10,"quickstart_zh":11,"use_case_zh":12,"hero_image_url":13,"owner_login":14,"owner_name":15,"owner_avatar_url":16,"owner_bio":17,"owner_company":18,"owner_location":19,"owner_email":18,"owner_twitter":20,"owner_website":21,"owner_url":22,"languages":23,"stars":40,"forks":41,"last_commit_at":42,"license":43,"difficulty_score":44,"env_os":45,"env_gpu":46,"env_ram":46,"env_deps":47,"category_tags":51,"github_topics":18,"view_count":53,"oss_zip_url":18,"oss_zip_packed_at":18,"status":54,"created_at":55,"updated_at":56,"faqs":57,"releases":105},1236,"David-patrick-chuks\u002FRiona-AI-Agent","Riona-AI-Agent","Riona Ai Agent 🌸 is built using Node.js and TypeScript 🛠️, designed for seamless job execution 📸. It's lightweight, efficient, and still evolving 🚧—exciting new features coming soon! 🌟","Riona AI Agent 是一款开源社交自动化工具，基于Node.js和TypeScript开发，专注于Instagram和X\u002FTwitter平台的智能运营。它能自动执行发帖、点赞、评论、消息互动等任务，结合Gemini AI生成自然流畅的评论和标题，并支持从YouTube、文档、网站等多源训练AI行为。内置多账号管理、MongoDB状态存储和智能冷却机制，有效降低账号被限风险。适合社交媒体运营者、营销团队及有一定技术基础的用户，帮助提升运营效率的同时保障账号安全。项目持续迭代中，未来将扩展X\u002FTwitter全功能支持及更多自动化场景。","\n# Riona AI Agent\n\n[Website](https:\u002F\u002Fwww.agentriona.xyz) | [Roadmap](ROADMAP.md) | [Twitter](https:\u002F\u002Ftwitter.com\u002Fdavid_patrick01) | [Contact](mailto:davidchuksdev@gmail.com)\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDavid-patrick-chuks_Riona-AI-Agent_readme_1718f640720e.png\" alt=\"Riona AI Agent banner\" width=\"100%\" \u002F>\n\u003C\u002Fp>\n\nRiona AI Agent is an AI-powered social automation platform for Instagram and X\u002FTwitter. It combines browser automation, AI-generated content, account workflows, scheduling, engagement actions, and training inputs so you can run a social media operator from one codebase.\n\n## Overview\n\nRiona is built to automate social activity while keeping control surfaces explicit. The project includes:\n\n- Instagram automation for login, posting, liking, commenting, messaging, and follower scraping\n- X\u002FTwitter support in progress for publishing and engagement workflows\n- AI content generation using Gemini for captions and comments\n- Training inputs from YouTube, audio, files, and websites\n- API endpoints, health checks, dashboards, cooldowns, summaries, and logging\n- A separate reCAPTCHA ML subproject under `riona-recaptcha-model\u002F`\n\n## Quick Links\n\n- Live website: `https:\u002F\u002Fwww.agentriona.xyz`\n- Token ticker: `$RIONA`\n- Contract address: `smuCA77z3nkWKH7CUP7FVVDi5AnDoQY5pXEqksmpump`\n- Project roadmap: `ROADMAP.md`\n\nIf you'd like to support the project, see the private donations file maintained locally.\n\n## Training Inputs\n\nBefore running automation, you can shape the agent with:\n\n- YouTube video URLs\n- Audio files\n- Portfolio or website links\n- Documents and text files including PDF, DOC, DOCX, and TXT\n\n## Feature Summary\n\n- Instagram automation with cookies, relogin handling, posting, scheduling, and interactions\n- AI-generated captions and comments with schema-guided responses\n- Multi-account and profile-based operation support\n- MongoDB-backed state, summaries, and rate-limiting controls\n- Simple dashboard for runtime health and latest activity\n- Logging, environment validation, and utility scripts for operations\n\n## Planned Expansion\n\n- Complete X\u002FTwitter workflow coverage\n- GitHub automation\n- Additional analytics, reporting, and compliance controls\n\n## Installation\n\n1. **Clone the repository**:\n\n   ```sh\n   git clone https:\u002F\u002Fgithub.com\u002Fdavid-patrick-chuks\u002Friona-ai-agent.git\n   cd riona-ai-agent\n   ```\n\n2. **Install dependencies**:\n\n   ```sh\n   npm install\n   ```\n\n3. **Set up environment variables**:\n   Rename the `.env.example` file to `.env` in the root directory and add your Instagram credentials. Refer to the `.env.example` file for the required variables.\n   ```dotenv # Instagram credentials\n   IGusername=your_instagram_username\n   IGpassword=your_instagram_password \n   \n   Xusername= #Twitter username\n   Xpassword= #Twitter password\n\n   MONGODB_URI= #MongoDB URI\n   MONGODB_REQUIRED=false\n   \n   # Gemini API keys (set only the ones you use)\n   GEMINI_API_KEY=your_primary_gemini_api_key\n   GEMINI_API_KEY_1=your_gemini_api_key_1\n   GEMINI_API_KEY_2=your_gemini_api_key_2\n   \n   # Optional: locale-specific ad\u002Fsponsored markers (comma-separated)\n   IG_AD_MARKERS=sponsored,paid partnership,paid partnership with\n   IG_AD_BUTTON_MARKERS=learn more,shop now,sign up,install now,get offer,subscribe,book now\n\n   # Optional: run Instagram agent loop automatically\n   IG_AGENT_ENABLED=false\n   IG_AGENT_INTERVAL_MS=30000\n   \n   # Optional: daily limit for IG actions (likes\u002Fcomments). 0 = unlimited\n   IG_DAILY_MAX_ACTIONS=0\n   \n   # Optional: logging backend (\"winston\" or \"console\")\n   LOGGER=console\n   ```\n\n## MongoDB Setup (Using Docker)\n\n1. **Install Docker**:\n   If you don't have Docker installed, download and install it from the [official website](https:\u002F\u002Fwww.docker.com\u002Fproducts\u002Fdocker-desktop\u002F)\n2. **Run MongoDB using Docker Container**:\n\n    **Option 1:**\n      ```sh\n      docker run -d -p 27017:27017 --name instagram-ai-mongodb mongodb\u002Fmongodb-community-server:latest\n      ```\n    **Option 2:**\n      ```sh\n      docker run -d -p 27017:27017 --name instagram-ai-mongodb -v mongodb_data:\u002Fdata\u002Fdb mongodb\u002Fmongodb-community-server:latest\n      ```   \n      (Option 2: use this if you want to have like a permanent storage in you so your data won't be lost or remove if you stop or remove your Docker container)\n3. **Modify the MONGODB_URI in the .env file**:\n   ```dotenv\n   MONGODB_URI=mongodb:\u002F\u002Flocalhost:27017\u002Finstagram-ai-agent\n   ```\n4. **Verify the connection**:\n   Open a new terminal and run the following command:\n   ```sh\n   docker ps\n   ```\n   You should see the MongoDB container running.\n\n   Docker Commands (Additional Info):\n   - To stop the MongoDB container:\n     ```sh\n     docker stop instagram-ai-mongodb\n     ```\n   - To start the MongoDB container:\n       ```sh\n       docker start instagram-ai-mongodb\n       ```\n   - To remove the MongoDB container:\n      ```sh\n      docker rm instagram-ai-mongodb\n      ```\n   - To remove the MongoDB container and its data:\n      ```sh\n      docker rm -v instagram-ai-mongodb\n      ```\n\n## Usage\n\n1. **Run the agent**:\n   ```sh\n   npm start\n   ```\n   Note: The specific platform (Instagram, Twitter) and actions performed by the agent are typically configured through environment variables in the `.env` file, or by selections made if the application prompts for choices at runtime.\n\n2. **Log in and trigger interactions via API**:\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Flogin \\\n     -H \"Content-Type: application\u002Fjson\" \\\n     -d '{\"username\":\"YOUR_IG_USERNAME\",\"password\":\"YOUR_IG_PASSWORD\"}'\n   ```\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Finteract \\\n     -H \"Content-Type: application\u002Fjson\" \\\n     --cookie \"token=YOUR_JWT_TOKEN\"\n   ```\n\n3. **Optional: auto-run the Instagram agent loop**\n   Set `IG_AGENT_ENABLED=true` in `.env` to run the interaction loop continuously.\n\n4. **Post a photo (by URL)**\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Fpost-photo \\\\\n     -H \"Content-Type: application\u002Fjson\" \\\\\n     --cookie \"token=YOUR_JWT_TOKEN\" \\\\\n     -d '{\"imageUrl\":\"https:\u002F\u002Fexample.com\u002Fphoto.jpg\",\"caption\":\"Hello IG!\"}'\n   ```\n\n5. **Post a photo (file upload)**\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Fpost-photo-file \\\\\n     -H \"Content-Type: multipart\u002Fform-data\" \\\\\n     --cookie \"token=YOUR_JWT_TOKEN\" \\\\\n     -F \"image=@\u002Fpath\u002Fto\u002Fphoto.jpg\" \\\\\n     -F \"caption=Hello IG!\"\n   ```\n\n6. **Schedule a photo post**\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Fschedule-post \\\\\n     -H \"Content-Type: application\u002Fjson\" \\\\\n     --cookie \"token=YOUR_JWT_TOKEN\" \\\\\n     -d '{\"imageUrl\":\"https:\u002F\u002Fexample.com\u002Fphoto.jpg\",\"caption\":\"Scheduled post\",\"cronTime\":\"0 9 * * *\"}'\n   ```\n\n## Dashboard\n\nOpen `http:\u002F\u002Flocalhost:3000\u002Fdashboard` for live status and the last IG run summary.\n\n## Development\n\n- Run tests: `npm test`\n- Lint: `npm run lint`\n- Format: `npm run format`\n- Env check: `npm run check:env`\n- Setup check: `npm run setup`\n\n## Guides\n\n- `Guides\u002FInstagram-Bot.md`\n- `Guides\u002FOperations.md`\n- `Guides\u002FAPI.md`\n- `Guides\u002FEnv.md`\n- `Guides\u002FTesting.md`\n- `Guides\u002FCI.md`\n- `Guides\u002FFAQ.md`\n- `Guides\u002FLogging.md`\n- `Guides\u002FScripts.md`\n- `Guides\u002FTraining.md`\n\n## reCAPTCHA Model\n\nThis repo now includes the reCAPTCHA model under `riona-recaptcha-model\u002F` and is run via root scripts:\n\n- `npm run recaptcha:dev`\n- `npm run recaptcha:train`\n- `npm run recaptcha:collect`\n- `npm run recaptcha:build`\n- `npm run recaptcha:serve`\n\n## IG Run Profiles\n\nSet `IG_RUN_PROFILE` to tune behavior:\n- `safe`: slower, fewer actions\n- `standard`: balanced (default)\n- `aggressive`: faster, higher limits\n\nOverrides:\n- `IG_DAILY_MAX_ACTIONS`\n- `IG_MAX_POSTS_PER_RUN`\n- `IG_ACTION_DELAY_MIN_MS`\n- `IG_ACTION_DELAY_MAX_MS`\n- `IG_AGENT_INTERVAL_MS`\n\n## Cooldown Mode\n\nIf IG triggers a challenge or login error, the agent will enter cooldown and skip interactions.\nConfigure via:\n- `IG_COOLDOWN_MINUTES`\n\nManual trigger:\n```\nPOST \u002Fapi\u002Fcooldown { \"minutes\": 60 }\n```\n\n## Comment Filters\n\nUse allow\u002Fdeny lists and a simple sentiment gate:\n- `IG_COMMENT_ALLOWLIST`\n- `IG_COMMENT_DENYLIST`\n- `IG_COMMENT_SENTIMENT` = `any | positive | neutral`\n\n## Multi-Account Support\n\nCreate `src\u002Fconfig\u002Faccounts.json` (not committed) based on `src\u002Fconfig\u002Faccounts.example.json`.\nThen pass `account` in `\u002Fapi\u002Flogin` to select which account to use.\n\n## Project Policies\n\n- `CONTRIBUTING.md`\n- `CODE_OF_CONDUCT.md`\n- `SECURITY.md`\n- `LICENSE`\n\n## Project Structure\n\n- **src\u002Fclient**: Contains the main logic for interacting with social media platforms like Instagram.\n- **src\u002Fconfig**: Configuration files, including the logger setup.\n- **src\u002Futils**: Utility functions for handling errors, cookies, data saving, etc.\n- **src\u002FAgent**: Contains the AI agent logic and training scripts.\n- **src\u002FAgent\u002Ftraining**: Training scripts for the AI agent.\n- **src\u002FAgent\u002Fschema**: Schema definitions for AI-generated content and database models.\n- **src\u002Ftest**: Contains test data and scripts, such as example tweets.\n\n## Logging\n\nThe project uses a custom logger to log information, warnings, and errors. Logs are saved in the [logs](http:\u002F\u002F_vscodecontentref_\u002F3) directory.\n\n## Error Handling\n\nProcess-level error handlers are set up to catch unhandled promise rejections, uncaught exceptions, and process warnings. Errors are logged using the custom logger.\n\n## Contributing\n\nContributions are welcome! Please fork the repository and submit a pull request with your changes.\n\n## License\n\nThis project is licensed under the MIT License. See the LICENSE file for details.\n\n## Stargazers\nThank you to all our supporters!\n\n[![Star History Chart](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDavid-patrick-chuks_Riona-AI-Agent_readme_6fcf2de4d416.png)](https:\u002F\u002Fwww.star-history.com\u002F#David-patrick-chuks\u002FRiona-AI-Agent&Date)\n\n## \n\n\u003Cp align=\"center\">\nBuilt with ❤️ by David Patrick \n\u003C\u002Fp>\n\n## Community & Contact\n\n- GitHub Discussions: use the Discussions tab for Q&A\n- Issues: bug reports and feature requests\n- Twitter: @david_patrick01\n- Email: davidchuksdev@gmail.com\n\nReal-time chat is not set up yet. If you want a Discord server, open a discussion and we can spin it up based on interest.\n","# Riona AI 代理\n\n[网站](https:\u002F\u002Fwww.agentriona.xyz) | [路线图](ROADMAP.md) | [Twitter](https:\u002F\u002Ftwitter.com\u002Fdavid_patrick01) | [联系](mailto:davidchuksdev@gmail.com)\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDavid-patrick-chuks_Riona-AI-Agent_readme_1718f640720e.png\" alt=\"Riona AI 代理横幅\" width=\"100%\" \u002F>\n\u003C\u002Fp>\n\nRiona AI 代理是一个基于人工智能的社交自动化平台，适用于Instagram和X\u002FTwitter。它结合了浏览器自动化、AI生成内容、账号工作流、日程安排、互动操作以及训练输入，让您只需一个代码库即可运行社交媒体运营。\n\n## 概览\n\nRiona旨在实现社交活动的自动化，同时保持控制界面的清晰可见。该项目包括：\n\n- Instagram自动化功能，支持登录、发帖、点赞、评论、消息发送及粉丝抓取\n- X\u002FTwitter支持正在开发中，涵盖发布与互动工作流\n- 使用Gemini生成AI内容，用于标题和评论\n- 来自YouTube、音频、文件和网站的训练输入\n- API端点、健康检查、仪表板、冷却时间、摘要和日志记录\n- 位于`riona-recaptcha-model\u002F`下的独立reCAPTCHA ML子项目\n\n## 快速链接\n\n- 实时网站：`https:\u002F\u002Fwww.agentriona.xyz`\n- 代币简称：`$RIONA`\n- 合约地址：`smuCA77z3nkWKH7CUP7FVVDi5AnDoQY5pXEqksmpump`\n- 项目路线图：`ROADMAP.md`\n\n如果您想支持该项目，请查看本地维护的私人捐赠文件。\n\n## 训练输入\n\n在运行自动化之前，您可以通过以下方式塑造代理：\n\n- YouTube视频URL\n- 音频文件\n- 投资组合或网站链接\n- 包括PDF、DOC、DOCX和TXT在内的文档和文本文件\n\n## 功能概要\n\n- 带有Cookie的Instagram自动化，支持重新登录、发帖、日程安排和互动\n- 使用模式引导回复的AI生成标题和评论\n- 支持多账号和基于个人资料的操作\n- 基于MongoDB的状态、摘要和速率限制控制\n- 简单的仪表板，用于显示运行时健康状况和最新活动\n- 日志记录、环境验证和实用脚本，方便运维\n\n## 计划扩展\n\n- 完整覆盖X\u002FTwitter工作流\n- GitHub自动化\n- 更多分析、报告和合规性控制\n\n## 安装\n\n1. **克隆仓库**：\n\n   ```sh\n   git clone https:\u002F\u002Fgithub.com\u002Fdavid-patrick-chuks\u002Friona-ai-agent.git\n   cd riona-ai-agent\n   ```\n\n2. **安装依赖**：\n\n   ```sh\n   npm install\n   ```\n\n3. **设置环境变量**：\n   将根目录中的`.env.example`文件重命名为`.env`，并添加您的Instagram凭据。请参考`.env.example`文件获取所需变量。\n   ```dotenv # Instagram凭据\n   IGusername=您的Instagram用户名\n   IGpassword=您的Instagram密码\n   \n   Xusername= #Twitter用户名\n   Xpassword= #Twitter密码\n\n   MONGODB_URI= #MongoDB URI\n   MONGODB_REQUIRED=false\n   \n   # Gemini API密钥（仅设置您使用的密钥）\n   GEMINI_API_KEY=您的主要Gemini API密钥\n   GEMINI_API_KEY_1=您的Gemini API密钥1\n   GEMINI_API_KEY_2=您的Gemini API密钥2\n   \n   # 可选：特定语言的广告\u002F赞助标记（用逗号分隔）\n   IG_AD_MARKERS=赞助,付费合作,付费合作与\n   IG_AD_BUTTON_MARKERS=了解更多,立即购买,注册,立即安装,获取优惠,订阅,立即预订\n\n   # 可选：自动运行Instagram代理循环\n   IG_AGENT_ENABLED=false\n   IG_AGENT_INTERVAL_MS=30000\n   \n   # 可选：IG行动每日最大次数（点赞\u002F评论）。0表示无限制\n   IG_DAILY_MAX_ACTIONS=0\n   \n   # 可选：日志后端（“winston”或“console”）\n   LOGGER=console\n   ```\n\n## MongoDB设置（使用Docker）\n\n1. **安装Docker**：\n   如果您尚未安装Docker，请从[官方网站](https:\u002F\u002Fwww.docker.com\u002Fproducts\u002Fdocker-desktop\u002F)下载并安装。\n2. **使用Docker容器运行MongoDB**：\n\n    **选项1：**\n      ```sh\n      docker run -d -p 27017:27017 --name instagram-ai-mongodb mongodb\u002Fmongodb-community-server:latest\n      ```\n    **选项2：**\n      ```sh\n      docker run -d -p 27017:27017 --name instagram-ai-mongodb -v mongodb_data:\u002Fdata\u002Fdb mongodb\u002Fmongodb-community-server:latest\n      ```   \n      （选项2：如果您希望数据永久存储，避免停止或删除Docker容器时数据丢失或被清除，请使用此选项）\n3. **修改.env文件中的MONGODB_URI**：\n   ```dotenv\n   MONGODB_URI=mongodb:\u002F\u002Flocalhost:27017\u002Finstagram-ai-agent\n   ```\n4. **验证连接**：\n   打开一个新的终端，运行以下命令：\n   ```sh\n   docker ps\n   ```\n   您应该能看到MongoDB容器正在运行。\n\n   Docker命令（附加信息）：\n   - 停止MongoDB容器：\n     ```sh\n     docker stop instagram-ai-mongodb\n     ```\n   - 启动MongoDB容器：\n       ```sh\n       docker start instagram-ai-mongodb\n       ```\n   - 删除MongoDB容器：\n      ```sh\n      docker rm instagram-ai-mongodb\n      ```\n   - 删除MongoDB容器及其数据：\n      ```sh\n      docker rm -v instagram-ai-mongodb\n      ```\n\n## 使用方法\n\n1. **运行代理**：\n   ```sh\n   npm start\n   ```\n   注意：代理的具体平台（Instagram、Twitter）和执行的操作通常通过`.env`文件中的环境变量配置，或者在应用运行时提示选择。\n\n2. **登录并通过API触发互动**：\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Flogin \\\n     -H \"Content-Type: application\u002Fjson\" \\\n     -d '{\"username\":\"YOUR_IG_USERNAME\",\"password\":\"YOUR_IG_PASSWORD\"}'\n   ```\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Finteract \\\n     -H \"Content-Type: application\u002Fjson\" \\\n     --cookie \"token=YOUR_JWT_TOKEN\"\n   ```\n\n3. **可选：自动运行Instagram代理循环**\n   在`.env`中将`IG_AGENT_ENABLED=true`设置为启用，以持续运行互动循环。\n\n4. **发布照片（通过URL）**：\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Fpost-photo \\\\\n     -H \"Content-Type: application\u002Fjson\" \\\\\n     --cookie \"token=YOUR_JWT_TOKEN\" \\\\\n     -d '{\"imageUrl\":\"https:\u002F\u002Fexample.com\u002Fphoto.jpg\",\"caption\":\"Hello IG!\"}'\n   ```\n\n5. **发布照片（文件上传）**：\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Fpost-photo-file \\\\\n     -H \"Content-Type: multipart\u002Fform-data\" \\\\\n     --cookie \"token=YOUR_JWT_TOKEN\" \\\\\n     -F \"image=@\u002Fpath\u002Fto\u002Fphoto.jpg\" \\\\\n     -F \"caption=Hello IG!\"\n   ```\n\n6. **安排照片发布时间**：\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Fschedule-post \\\\\n     -H \"Content-Type: application\u002Fjson\" \\\\\n     --cookie \"token=YOUR_JWT_TOKEN\" \\\\\n     -d '{\"imageUrl\":\"https:\u002F\u002Fexample.com\u002Fphoto.jpg\",\"caption\":\"Scheduled post\",\"cronTime\":\"0 9 * * *\"}'\n   ```\n\n## 仪表板\n\n打开`http:\u002F\u002Flocalhost:3000\u002Fdashboard`以查看实时状态和最近的IG运行摘要。\n\n## 开发\n\n- 运行测试：`npm test`\n- 格式化：`npm run format`\n- 环境检查：`npm run check:env`\n- 设置检查：`npm run setup`\n\n## 指南\n\n- `Guides\u002FInstagram-Bot.md`\n- `Guides\u002FOperations.md`\n- `Guides\u002FAPI.md`\n- `Guides\u002FEnv.md`\n- `Guides\u002FTesting.md`\n- `Guides\u002FCI.md`\n- `Guides\u002FFAQ.md`\n- `Guides\u002FLogging.md`\n- `Guides\u002FScripts.md`\n- `Guides\u002FTraining.md`\n\n## reCAPTCHA 模型\n\n此仓库现已在 `riona-recaptcha-model\u002F` 下包含 reCAPTCHA 模型，并通过根脚本运行：\n\n- `npm run recaptcha:dev`\n- `npm run recaptcha:train`\n- `npm run recaptcha:collect`\n- `npm run recaptcha:build`\n- `npm run recaptcha:serve`\n\n## IG 运行配置文件\n\n设置 `IG_RUN_PROFILE` 以调整行为：\n- `safe`：较慢，动作较少\n- `standard`：平衡（默认）\n- `aggressive`：较快，限制更高\n\n覆盖项：\n- `IG_DAILY_MAX_ACTIONS`\n- `IG_MAX_POSTS_PER_RUN`\n- `IG_ACTION_DELAY_MIN_MS`\n- `IG_ACTION_DELAY_MAX_MS`\n- `IG_AGENT_INTERVAL_MS`\n\n## 冷却模式\n\n如果 IG 触发挑战或登录错误，代理将进入冷却状态并跳过交互。\n可通过以下方式配置：\n- `IG_COOLDOWN_MINUTES`\n\n手动触发：\n```\nPOST \u002Fapi\u002Fcooldown { \"minutes\": 60 }\n```\n\n## 评论过滤器\n\n使用允许\u002F拒绝列表和简单的情感门控：\n- `IG_COMMENT_ALLOWLIST`\n- `IG_COMMENT_DENYLIST`\n- `IG_COMMENT_SENTIMENT` = `any | positive | neutral`\n\n## 多账号支持\n\n根据 `src\u002Fconfig\u002Faccounts.example.json` 创建 `src\u002Fconfig\u002Faccounts.json`（未提交）。\n然后在 `\u002Fapi\u002Flogin` 中传递 `account` 以选择要使用的账号。\n\n## 项目政策\n\n- `CONTRIBUTING.md`\n- `CODE_OF_CONDUCT.md`\n- `SECURITY.md`\n- `LICENSE`\n\n## 项目结构\n\n- **src\u002Fclient**：包含与 Instagram 等社交媒体平台交互的主要逻辑。\n- **src\u002Fconfig**：配置文件，包括日志记录器的设置。\n- **src\u002Futils**：用于处理错误、Cookie、数据保存等的实用函数。\n- **src\u002FAgent**：包含 AI 代理逻辑和训练脚本。\n- **src\u002FAgent\u002Ftraining**：AI 代理的训练脚本。\n- **src\u002FAgent\u002Fschema**：AI 生成内容和数据库模型的模式定义。\n- **src\u002Ftest**：包含测试数据和脚本，例如示例推文。\n\n## 日志记录\n\n该项目使用自定义日志记录器记录信息、警告和错误。日志保存在 [logs](http:\u002F\u002F_vscodecontentref_\u002F3) 目录中。\n\n## 错误处理\n\n已设置进程级错误处理器，以捕获未处理的 Promise 拒绝、未捕获的异常和进程警告。错误会通过自定义日志记录器进行记录。\n\n## 贡献\n\n欢迎贡献！请 fork 仓库并提交包含您更改的拉取请求。\n\n## 许可证\n\n本项目采用 MIT 许可证。详情请参阅 LICENSE 文件。\n\n## 星标用户\n感谢所有支持我们的朋友！\n\n[![Star History Chart](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDavid-patrick-chuks_Riona-AI-Agent_readme_6fcf2de4d416.png)](https:\u002F\u002Fwww.star-history.com\u002F#David-patrick-chuks\u002FRiona-AI-Agent&Date)\n\n## \n\n\u003Cp align=\"center\">\n由 David Patrick 用 ❤️ 构建\n\u003C\u002Fp>\n\n## 社区与联系\n\n- GitHub 讨论：使用“讨论”选项卡进行问答\n- 问题：报告 bug 和提出功能需求\n- Twitter：@david_patrick01\n- 邮箱：davidchuksdev@gmail.com\n\n实时聊天功能尚未启用。如果您希望创建 Discord 服务器，请发起讨论，我们将根据兴趣搭建。","# Riona AI Agent 中文快速上手指南\n\n## 环境准备\n\n- **系统要求**：Windows \u002F macOS \u002F Linux（推荐 Linux 环境）\n- **前置依赖**：\n  - Node.js v18+（推荐使用 [nvm](https:\u002F\u002Fgithub.com\u002Fnvm-sh\u002Fnvm) 管理版本）\n  - npm（随 Node.js 安装）\n  - Docker（用于 MongoDB，推荐使用国内镜像加速）\n\n> ✅ 推荐使用阿里云 Docker 镜像加速：  \n> 编辑 `\u002Fetc\u002Fdocker\u002Fdaemon.json`（Linux\u002FmacOS）或 Docker Desktop 设置中添加：\n> ```json\n> {\n>   \"registry-mirrors\": [\"https:\u002F\u002Fregistry.docker-cn.com\"]\n> }\n> ```\n> 重启 Docker 服务生效。\n\n## 安装步骤\n\n1. **克隆仓库**：\n   ```sh\n   git clone https:\u002F\u002Fgithub.com\u002Fdavid-patrick-chuks\u002Friona-ai-agent.git\n   cd riona-ai-agent\n   ```\n\n2. **安装依赖**：\n   ```sh\n   npm install\n   ```\n\n3. **配置环境变量**：\n   复制示例配置并填写你的信息：\n   ```sh\n   cp .env.example .env\n   ```\n   编辑 `.env` 文件，至少填写以下字段：\n   ```dotenv\n   IGusername=你的Instagram用户名\n   IGpassword=你的Instagram密码\n   MONGODB_URI=mongodb:\u002F\u002Flocalhost:27017\u002Finstagram-ai-agent\n   GEMINI_API_KEY=你的Gemini API密钥\n   ```\n\n4. **启动 MongoDB（推荐 Docker）**：\n   ```sh\n   docker run -d -p 27017:27017 --name instagram-ai-mongodb -v mongodb_data:\u002Fdata\u002Fdb mongodb\u002Fmongodb-community-server:latest\n   ```\n\n## 基本使用\n\n1. **启动代理服务**：\n   ```sh\n   npm start\n   ```\n\n2. **登录 Instagram 账号（API 方式）**：\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Flogin \\\n     -H \"Content-Type: application\u002Fjson\" \\\n     -d '{\"username\":\"你的Instagram用户名\",\"password\":\"你的Instagram密码\"}'\n   ```\n\n3. **发布一张图片（示例）**：\n   ```sh\n   curl -X POST http:\u002F\u002Flocalhost:3000\u002Fapi\u002Fpost-photo \\\n     -H \"Content-Type: application\u002Fjson\" \\\n     --cookie \"token=上一步返回的JWT令牌\" \\\n     -d '{\"imageUrl\":\"https:\u002F\u002Fexample.com\u002Fphoto.jpg\",\"caption\":\"Hello from Riona!\"}'\n   ```\n\n4. **访问控制面板**（查看运行状态）：\n   打开浏览器访问：`http:\u002F\u002Flocalhost:3000\u002Fdashboard`\n\n> 💡 默认启用 Instagram 自动化，如需开启自动循环互动，请在 `.env` 中设置：  \n> `IG_AGENT_ENABLED=true`","一位独立社交媒体运营者正在为一家小型手工艺品品牌管理 Instagram 和 Twitter 账号，每天需手动发布内容、回复评论、点赞互动，并跟踪粉丝增长。由于人手有限，她每天花费 3 小时以上处理社交任务，导致内容更新不稳定，互动率持续低迷。\n\n### 没有 Riona-AI-Agent 时\n- 每天需手动登录多个账号，重复操作耗时且易出错，常因忘记发布而错过最佳互动时段\n- 内容文案依赖灵感，难以持续产出高质量、风格统一的文案，粉丝反馈“内容同质化”\n- 无法有效追踪互动数据，不知道哪些评论值得回复、哪些粉丝值得跟进，精力浪费在低价值互动上\n- 面对突发热点或节日活动时，无法快速生成适配内容，错失流量机会\n- 多设备登录易触发平台风控，账号曾因频繁操作被临时封禁\n\n### 使用 Riona-AI-Agent 后\n- 自动化登录与定时发布功能让内容按计划精准推送，即使深夜也能准时更新，粉丝活跃度提升 40%\n- 借助 Gemini AI 分析品牌历史内容与用户评论，自动生成符合品牌调性的文案与回复，风格更统一、更具人情味\n- 通过 MongoDB 记录互动行为，自动识别高价值粉丝并优先回复，运营效率翻倍，转化率明显上升\n- 只需输入一段 YouTube 视频或产品文档，Riona 就能生成相关帖子与话题标签，热点响应速度从 6 小时缩短至 15 分钟\n- 内置冷却机制与操作限制避免触发平台风控，账号再未被封，长期运营更稳定\n\nRiona-AI-Agent 让一个人也能像一支专业团队一样，持续、智能、安全地运营社交账号，真正把时间还给创意与业务。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDavid-patrick-chuks_Riona-AI-Agent_1718f640.png","David-patrick-chuks","David Patrick","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002FDavid-patrick-chuks_f7795e49.png"," Developer & problem solver.👾 || Building Ai Agent for FUN",null,"Nigeria","david_patrick01","https:\u002F\u002Fdavid.tsx.app\u002F","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks",[24,28,32,36],{"name":25,"color":26,"percentage":27},"HTML","#e34c26",79,{"name":29,"color":30,"percentage":31},"TypeScript","#3178c6",19.6,{"name":33,"color":34,"percentage":35},"JavaScript","#f1e05a",1.2,{"name":37,"color":38,"percentage":39},"CSS","#663399",0.2,4197,817,"2026-04-04T08:15:37","MIT",3,"Linux, macOS, Windows","未说明",{"notes":48,"python":46,"dependencies":49},"项目基于 Node.js，需安装 npm 和 Docker 以运行 MongoDB；AI 内容生成依赖 Gemini API，需配置 API 密钥；首次运行需设置环境变量并可能下载模型文件（如 reCAPTCHA 模型）；建议使用 Docker 管理数据库以确保数据持久化。",[50],"npm",[52],"Agent",2,"ready","2026-03-27T02:49:30.150509","2026-04-06T07:05:56.687341",[58,63,68,73,78,83,88,92,97,101],{"id":59,"question_zh":60,"answer_zh":61,"source_url":62},8815,"是否需要本地安装 MongoDB？如何配置 MONGODB_URI？","需要手动安装 MongoDB 并配置 MONGODB_URI。在 .env 文件中填写 MongoDB 连接字符串，例如：MONGODB_URI=mongodb:\u002F\u002Flocalhost:27017\u002Friona。确保 MongoDB 服务已启动，并在项目根目录下创建 cookies\u002FInstagramcookies.json 文件以避免 Cookie 错误。","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks\u002FRiona-AI-Agent\u002Fissues\u002F8",{"id":64,"question_zh":65,"answer_zh":66,"source_url":67},8816,"如何解决 'cookies\u002FInstagramcookies.json' 文件不存在的错误？","在项目根目录下手动创建文件夹 cookies，并在其中创建空文件 Instagramcookies.json。例如在 Windows 上运行：mkdir cookies && type nul > cookies\\Instagramcookies.json；在 Linux\u002FmacOS 上运行：mkdir -p cookies && touch cookies\u002FInstagramcookies.json。","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks\u002FRiona-AI-Agent\u002Fissues\u002F33",{"id":69,"question_zh":70,"answer_zh":71,"source_url":72},8817,"如何解决 GEMINI_API_KEY_1 使用耗尽的问题？","前往 Google Cloud Console 创建多个 Gemini API 密钥，并将它们全部添加到 .env 文件中，格式为：GEMINI_API_KEY_1=xxx、GEMINI_API_KEY_2=yyy、GEMINI_API_KEY_3=zzz。系统会自动轮换使用，避免单个密钥超限。","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks\u002FRiona-AI-Agent\u002Fissues\u002F54",{"id":74,"question_zh":75,"answer_zh":76,"source_url":77},8818,"项目中缺少 .env.example 文件怎么办？","虽然 README 中未提供 .env.example，但该文件可能被隐藏。在项目根目录中检查是否存在 .env.example 文件（Mac\u002FLinux 下使用 ls -a 查看）。若不存在，可手动创建 .env 文件并添加必要变量如 MONGODB_URI 和 GEMINI_API_KEY_1。","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks\u002FRiona-AI-Agent\u002Fissues\u002F1",{"id":79,"question_zh":80,"answer_zh":81,"source_url":82},8819,"评论功能报错 'Protocol error (Input.insertText): Invalid parameters' 如何修复？","该错误通常由 Puppeteer 版本不兼容或输入文本包含非法字符导致。请更新项目到最新版本（git pull），并确保评论文本中不包含特殊符号或表情。若问题依旧，尝试在 .env 中设置 COMMENT_DELAY=3000 延迟评论以避免速率限制。","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks\u002FRiona-AI-Agent\u002Fissues\u002F10",{"id":84,"question_zh":85,"answer_zh":86,"source_url":87},8820,"启动后程序显示运行但无任何操作，如何排查？","请检查：1）.env 文件是否完整配置了 MONGODB_URI 和 API 密钥；2）cookies\u002FInstagramcookies.json 文件是否存在；3）MongoDB 服务是否正在运行；4）终端是否有登录失败或 Cookie 加载失败的错误日志。若均正常，尝试重启服务并查看是否出现 'Login verified with cookies' 日志。","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks\u002FRiona-AI-Agent\u002Fissues\u002F73",{"id":89,"question_zh":90,"answer_zh":91,"source_url":67},8821,"如何解决 'Failed to execute 'querySelector' on 'Document': ... is not a valid selector' 错误？","这是 Instagram 页面结构更新导致的 CSS 选择器失效。请拉取项目最新代码（git pull），维护者已修复选择器逻辑。若仍报错，可临时修改 node_modules\u002Fpuppeteer-core\u002Flib\u002Fcjs\u002Fpuppeteer\u002Fcommon\u002FQueryHandler.js 中的 selector 为更通用的 'article div[role=\"button\"]'，并重新编译（tsc）。",{"id":93,"question_zh":94,"answer_zh":95,"source_url":96},8822,"该工具是否支持非英语语言？","支持非英语语言，但需确保 .env 中的 PROMPT_TEMPLATE 使用目标语言编写。例如，将评论模板改为西班牙语或阿拉伯语。用户反馈在西班牙语和阿拉伯语环境下可正常工作，但需避免使用特殊 Unicode 字符引发输入错误。","https:\u002F\u002Fgithub.com\u002FDavid-patrick-chuks\u002FRiona-AI-Agent\u002Fissues\u002F3",{"id":98,"question_zh":99,"answer_zh":100,"source_url":96},8823,"是否支持多账号同时运行且无需打开浏览器？","支持多账号并发运行，但必须通过 Cookie 登录（无需打开浏览器）。将每个账号的 cookies\u002FInstagramcookies.json 文件分别命名（如 Instagramcookies_account1.json），并在启动脚本中指定对应配置。确保每个账号使用独立的 API 密钥和代理 IP 以避免封禁。",{"id":102,"question_zh":103,"answer_zh":104,"source_url":72},8824,"为什么使用 API 密钥后 Instagram 账号被封？","频繁自动点赞和评论可能触发 Instagram 反垃圾机制。建议：1）在 .env 中设置 COMMENT_DELAY=5000 和 LIKE_DELAY=8000 增加延迟；2）每个账号使用独立 IP 和浏览器指纹；3）避免在短时间内操作超过 50 个帖子；4）不要使用公共 API 密钥，应申请个人专属密钥。",[],[107,117,126,134,147,155],{"id":108,"name":109,"github_repo":110,"description_zh":111,"stars":112,"difficulty_score":44,"last_commit_at":113,"category_tags":114,"status":54},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,"2026-04-05T11:01:52",[115,116,52],"开发框架","图像",{"id":118,"name":119,"github_repo":120,"description_zh":121,"stars":122,"difficulty_score":53,"last_commit_at":123,"category_tags":124,"status":54},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 真正成长为懂上",138956,"2026-04-05T11:33:21",[115,52,125],"语言模型",{"id":127,"name":128,"github_repo":129,"description_zh":130,"stars":131,"difficulty_score":53,"last_commit_at":132,"category_tags":133,"status":54},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",[115,116,52],{"id":135,"name":136,"github_repo":137,"description_zh":138,"stars":139,"difficulty_score":53,"last_commit_at":140,"category_tags":141,"status":54},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",[116,142,143,144,52,145,125,115,146],"数据工具","视频","插件","其他","音频",{"id":148,"name":149,"github_repo":150,"description_zh":151,"stars":152,"difficulty_score":44,"last_commit_at":153,"category_tags":154,"status":54},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",[52,116,115,125,145],{"id":156,"name":157,"github_repo":158,"description_zh":159,"stars":160,"difficulty_score":44,"last_commit_at":161,"category_tags":162,"status":54},2181,"OpenHands","OpenHands\u002FOpenHands","OpenHands 是一个专注于 AI 驱动开发的开源平台，旨在让智能体（Agent）像人类开发者一样理解、编写和调试代码。它解决了传统编程中重复性劳动多、环境配置复杂以及人机协作效率低等痛点，通过自动化流程显著提升开发速度。\n\n无论是希望提升编码效率的软件工程师、探索智能体技术的研究人员，还是需要快速原型验证的技术团队，都能从中受益。OpenHands 提供了灵活多样的使用方式：既可以通过命令行（CLI）或本地图形界面在个人电脑上轻松上手，体验类似 Devin 的流畅交互；也能利用其强大的 Python SDK 自定义智能体逻辑，甚至在云端大规模部署上千个智能体并行工作。\n\n其核心技术亮点在于模块化的软件智能体 SDK，这不仅构成了平台的引擎，还支持高度可组合的开发模式。此外，OpenHands 在 SWE-bench 基准测试中取得了 77.6% 的优异成绩，证明了其解决真实世界软件工程问题的能力。平台还具备完善的企业级功能，支持与 Slack、Jira 等工具集成，并提供细粒度的权限管理，适合从个人开发者到大型企业的各类用户场景。",70612,"2026-04-05T11:12:22",[125,52,115,144]]