{"id":13465977,"url":"https://github.com/MartialBE/one-hub","last_synced_at":"2025-03-25T21:30:58.230Z","repository":{"id":194960637,"uuid":"689214770","full_name":"MartialBE/one-hub","owner":"MartialBE","description":"OpenAI 接口管理 \u0026 分发系统，改自songquanpeng/one-api。支持更多模型，加入统计页面，完善非openai模型的函数调用。","archived":false,"fork":false,"pushed_at":"2024-10-29T10:58:01.000Z","size":3972,"stargazers_count":1123,"open_issues_count":39,"forks_count":229,"subscribers_count":14,"default_branch":"main","last_synced_at":"2024-10-29T12:47:34.811Z","etag":null,"topics":["chatgpt","openai","openai-api"],"latest_commit_sha":null,"homepage":"https://one-hub.xiao5.info/","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"songquanpeng/one-api","license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MartialBE.png","metadata":{"files":{"readme":"README.en.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"custom":["https://github.com/MartialBE/one-hub/wiki/Coffee"]}},"created_at":"2023-09-09T05:40:25.000Z","updated_at":"2024-10-29T10:58:05.000Z","dependencies_parsed_at":"2024-07-14T17:41:41.566Z","dependency_job_id":"8d659fa8-f214-455e-a609-fd5861895445","html_url":"https://github.com/MartialBE/one-hub","commit_stats":null,"previous_names":["martialbe/one-api","martialbe/one-hub"],"tags_count":61,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MartialBE%2Fone-hub","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MartialBE%2Fone-hub/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MartialBE%2Fone-hub/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MartialBE%2Fone-hub/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MartialBE","download_url":"https://codeload.github.com/MartialBE/one-hub/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245547072,"owners_count":20633284,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chatgpt","openai","openai-api"],"created_at":"2024-07-31T15:00:37.574Z","updated_at":"2025-03-25T21:30:58.202Z","avatar_url":"https://github.com/MartialBE.png","language":"Go","funding_links":["https://github.com/MartialBE/one-hub/wiki/Coffee"],"categories":["Go","A01_文本生成_文本对话"],"sub_categories":["大语言对话模型及数据"],"readme":"\u003cp align=\"right\"\u003e\n   \u003cstrong\u003eEnglish\u003c/strong\u003e | \u003ca href=\"./README.md\"\u003e中文\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n   \u003cpicture\u003e\n   \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://github.com/MartialBE/one-hub/assets/42402987/c4125d1a-5577-446d-ba15-2a71c52140c1\"\u003e\n   \u003cimg height=\"90\" src=\"https://raw.githubusercontent.com/MartialBE/one-api/main/web/src/assets/images/logo.svg\"\u003e\n   \u003c/picture\u003e\n\u003c/p\u003e\n\n\u003cdiv align=\"center\"\u003e\n\n# One Hub\n\n_This project is based on [one-api](https://github.com/songquanpeng/one-api) and has been developed for the second time._\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://raw.githubusercontent.com/MartialBE/one-api/main/LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/license/MartialBE/one-api?color=brightgreen\" alt=\"license\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/MartialBE/one-hub/releases/latest\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/v/release/MartialBE/one-api?color=brightgreen\u0026include_prereleases\" alt=\"release\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/users/MartialBE/packages/container/package/one-api\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/docker-ghcr.io-blue\" alt=\"docker\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://hub.docker.com/r/martialbe/one-api\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/docker-dockerHub-blue\" alt=\"docker\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://goreportcard.com/report/github.com/MartialBE/one-api\"\u003e\n    \u003cimg src=\"https://goreportcard.com/badge/github.com/MartialBE/one-api\" alt=\"GoReportCard\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n**Please do not mix with the original version, because the new functions, the database is not compatible with the original version**\n\n**For the sake of simplicity, after this project, except for updating the model list built into the program when adding a new supplier, the model list built into the program will not be updated under normal circumstances.**\n\nIf you find that a new model is missing, please update the newly added model in `Backend-Model Price-Update Price`\n\n[Demo Site](https://one-api-martialbe.vercel.app/)\n\n\u003c/div\u003e\n\n## Functional Changes\n\n- Brand new UI interface\n- Added user dashboard\n- Added administrator data analysis and statistics interface\n- Refactored the intermediary `supplier` module\n- Support for using `Azure Speech` to simulate `TTS` function\n- Channels can be configured with separate http/socks5 proxies\n- Support for dynamically returning user model lists\n- Support for custom speed testing models\n- Logs now include request duration\n- Support and optimize function calls for non-OpenAI models (supported models can be used directly in Lobe-Chat)\n- Support for custom completion rates\n- Support for full pagination and sorting\n- Support for `Telegram bot`\n- Support for models charged per use\n- Support for model wildcards\n- Support for starting the program using a configuration file\n- Support model price update\n- Support automatic acquisition of supplier models\n- Support chat only. If there is an incoming `function call` parameter after opening, the channel will be skipped.\n- Support payment\n- Support configuring user group RPM\n- Support `Prometheus` monitoring\n\n## Documentation\n\nPlease refer to the [documentation](https://github.com/MartialBE/one-hub/wiki).\n\n## Current Supported Providers\n\n| Provider                                                              | Chat                             | Embeddings | Audio  | Images   | Other                                                            |\n| --------------------------------------------------------------------- | -------------------------------- | ---------- | ------ | -------- | ---------------------------------------------------------------- |\n| [OpenAI](https://platform.openai.com/docs/api-reference/introduction) | ✅                               | ✅         | ✅     | ✅       | -                                                                |\n| [Azure OpenAI](https://oai.azure.com/)                                | ✅                               | ✅         | ✅     | ✅       | -                                                                |\n| [Azure Speech](https://portal.azure.com/)                             | -                                | -          | ⚠️ tts | -        | -                                                                |\n| [Anthropic](https://www.anthropic.com/)                               | ✅                               | -          | -      | -        | -                                                                |\n| [Gemini](https://aistudio.google.com/)                                | ✅                               | -          | -      | -        | -                                                                |\n| [百度文心](https://console.bce.baidu.com/qianfan/overview)            | ✅                               | ✅         | -      | -        | -                                                                |\n| [通义千问](https://dashscope.console.aliyun.com/overview)             | ✅                               | ✅         | -      | -        | -                                                                |\n| [讯飞星火](https://console.xfyun.cn/)                                 | ✅                               | -          | -      | -        | -                                                                |\n| [智谱](https://open.bigmodel.cn/overview)                             | ✅                               | ✅         | -      | ⚠️ image | -                                                                |\n| [腾讯混元](https://cloud.tencent.com/product/hunyuan)                 | ✅                               | -          | -      | -        | -                                                                |\n| [百川](https://platform.baichuan-ai.com/console/apikey)               | ✅                               | ✅         | -      | -        | -                                                                |\n| [MiniMax](https://www.minimaxi.com/user-center/basic-information)     | ✅                               | ✅         | -      | -        | -                                                                |\n| [Deepseek](https://platform.deepseek.com/usage)                       | ✅                               | -          | -      | -        | -                                                                |\n| [Moonshot](https://moonshot.ai/)                                      | ✅                               | -          | -      | -        | -                                                                |\n| [Mistral](https://mistral.ai/)                                        | ✅                               | ✅         | -      | -        | -                                                                |\n| [Groq](https://console.groq.com/keys)                                 | ✅                               | -          | -      | -        | -                                                                |\n| [Amazon Bedrock](https://console.aws.amazon.com/bedrock/home)         | ⚠️ Only support Anthropic models | -          | -      | -        | -                                                                |\n| [零一万物](https://platform.lingyiwanwu.com/details)                  | ✅                               | -          | -      | -        | -                                                                |\n| [Cloudflare AI](https://ai.cloudflare.com/)                           | ✅                               | -          | ⚠️ stt | ⚠️ image | -                                                                |\n| [Midjourney](https://www.midjourney.com/)                             | -                                | -          | -      | -        | [midjourney-proxy](https://github.com/novicezk/midjourney-proxy) |\n| [Cohere](https://cohere.com/)                                         | ✅                               | -          | -      | -        | -                                                                |\n| [Stability AI](https://platform.stability.ai/account/credits)         | -                                | -          | -      | ⚠️ image | -                                                                |\n| [Coze](https://www.coze.com/open/docs/chat?_lang=zh)                  | ✅                               | -          | -      | -        | -                                                                |\n| [Ollama](https://github.com/ollama/ollama)                            | ✅                               | ✅         | -      | -        | -                                                                |\n| [Suno](https://suno.com/)                                             | -                                | -          | -      | -        | [Suno-API](https://github.com/Suno-API/Suno-API)                 |\n\n## Acknowledgements\n\n- This program utilizes the following open-source projects:\n  - [one-api](https://github.com/songquanpeng/one-api) serves as the foundation of this project.\n  - [Berry Free React Admin Template](https://github.com/codedthemes/berry-free-react-admin-template) provides the frontend interface for this project.\n  - [minimal-ui-kit](https://github.com/minimal-ui-kit/material-kit-react), some styles from this project were used.\n  - [new api](https://github.com/Calcium-Ion/new-api), the code for the Midjourney/Suno module is sourced from here.\n\nSpecial thanks to the authors and contributors of the above projects.\n\n## Others\n\n\u003ca href=\"https://next.ossinsight.io/widgets/official/analyze-repo-stars-history?repo_id=689214770\" target=\"_blank\" style=\"display: block\" align=\"center\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://next.ossinsight.io/widgets/official/analyze-repo-stars-history/thumbnail.png?repo_id=689214770\u0026image_size=auto\u0026color_scheme=dark\" width=\"721\" height=\"auto\"\u003e\n    \u003cimg alt=\"Star History of MartialBE/one-api\" src=\"https://next.ossinsight.io/widgets/official/analyze-repo-stars-history/thumbnail.png?repo_id=689214770\u0026image_size=auto\u0026color_scheme=light\" width=\"721\" height=\"auto\"\u003e\n  \u003c/picture\u003e\n\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMartialBE%2Fone-hub","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FMartialBE%2Fone-hub","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMartialBE%2Fone-hub/lists"}