{"id":15175493,"url":"https://github.com/missuo/cohere2openai","last_synced_at":"2025-10-06T10:31:49.124Z","repository":{"id":234150246,"uuid":"787706625","full_name":"missuo/cohere2openai","owner":"missuo","description":"Convert the Cohere API to OpenAI compatible API.","archived":false,"fork":false,"pushed_at":"2024-04-22T03:37:14.000Z","size":49,"stargazers_count":78,"open_issues_count":3,"forks_count":13,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-24T23:49:29.117Z","etag":null,"topics":["cohere","command-r","command-r-plus"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/missuo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"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}},"created_at":"2024-04-17T02:57:42.000Z","updated_at":"2025-01-23T03:56:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"221ca279-3917-4d7c-bd62-b40ea2d3ea79","html_url":"https://github.com/missuo/cohere2openai","commit_stats":null,"previous_names":["missuo/cohere2openai"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/missuo%2Fcohere2openai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/missuo%2Fcohere2openai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/missuo%2Fcohere2openai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/missuo%2Fcohere2openai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/missuo","download_url":"https://codeload.github.com/missuo/cohere2openai/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235519902,"owners_count":19003201,"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":["cohere","command-r","command-r-plus"],"created_at":"2024-09-27T12:39:18.567Z","updated_at":"2025-10-06T10:31:43.865Z","avatar_url":"https://github.com/missuo.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cohere2OpenAI\nUsed to convert the Cohere API to OpenAI compatible API. **Easily use Cohere with any OpenAI compatible client.**\n\n## Before Using\nYou need to have a Cohere API key, if you don't have one, you can apply for [Trial Key](https://dashboard.cohere.com/api-keys). It is completely free at the moment and will not charge you any fees. You don't even need to bind your credit card.\n\n## Demo (Public Convert API)\nThis is the public API I provide. I cannot guarantee stability, but you can use them for free without any deployment.\n\n```bash\n# Host: c.uid.si\n# Endpoint: /v1/chat/completions\n# Method: POST\n# Headers: Content-Type: application/json, Authorization\ncurl https://c.uid.si/v1/chat/completions \\\n  -H \"Content-Type: application/json\" \\\n  -H \"Authorization: Bearer xxxxxxx\" \\\n  -d '{\n    \"model\": \"command-r-plus\",\n    \"messages\": [\n      {\n        \"role\": \"system\",\n        \"content\": \"翻译为中文!\"\n      },\n      {\n        \"role\": \"user\",\n        \"content\": \"Hello!\"\n      }\n    ],\n    \"stream\": true\n  }'\n```\n\n## Compatibility\nCurrently it is only compatible with the **Command** family of models, if you pass in any other model, the default will be to use **Command R+**. Supports streaming and non-streaming output.\n\n### Models\n```json\n{\n  \"created\": 1692901427,\n  \"id\": \"command-r\",\n  \"object\": \"model\",\n  \"owned_by\": \"system\"\n},\n{\n  \"created\": 1692901427,\n  \"id\": \"command-r-plus\",\n  \"object\": \"model\",\n  \"owned_by\": \"system\"\n},\n{\n  \"created\": 1692901427,\n  \"id\": \"command-light\",\n  \"object\": \"model\",\n  \"owned_by\": \"system\"\n},\n{\n  \"created\": 1692901427,\n  \"id\": \"command-light-nightly\",\n  \"object\": \"model\",\n  \"owned_by\": \"system\"\n},\n{\n  \"created\": 1692901427,\n  \"id\": \"command\",\n  \"object\": \"model\",\n  \"owned_by\": \"system\"\n},\n{\n  \"created\": 1692901427,\n  \"id\": \"command-nightly\",\n  \"object\": \"model\",\n  \"owned_by\": \"system\"\n}\n```\n\n## Request Example\n```bash\ncurl http://127.0.0.1:6600/v1/chat/completions \\\n  -H \"Content-Type: application/json\" \\\n  -H \"Authorization: Bearer xxxxxxx\" \\\n  -d '{\n    \"model\": \"command-r-plus\",\n    \"messages\": [\n      {\n        \"role\": \"system\",\n        \"content\": \"翻译为中文!\"\n      },\n      {\n        \"role\": \"user\",\n        \"content\": \"Hello!\"\n      }\n    ],\n    \"stream\": true\n  }'\n```\n\n\n## Usage\n### Docker\n\n```bash\ndocker run -d --restart always -p 6600:6600 ghcr.io/missuo/cohere2openai:latest\n```\n\n```bash\ndocker run -d --restart always -p 6600:6600 missuo/cohere2openai:latest\n```\n\n### Docker Compose\nIt is recommended that you use docker version **26.0.0** or higher, otherwise you need to specify the version in the `compose.yaml` file.\n```diff\n+version: \"3.9\"\n```\n\n```bash\nmkdir cohere2openai \u0026\u0026 cd cohere2openai\nwget -O compose.yaml https://raw.githubusercontent.com/missuo/cohere2openai/main/compose.yaml\ndocker compose up -d\n```\n\n### Manual\n\nDownload the latest release from the [release page](https://github.com/missuo/cohere2openai/releases).\n\n```bash\nchmod +x cohere2openai\n./cohere2openai\n```\n\n## License\n[GPL 3.0](https://github.com/missuo/cohere2openai/blob/main/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmissuo%2Fcohere2openai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmissuo%2Fcohere2openai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmissuo%2Fcohere2openai/lists"}