together-worker


Nametogether-worker JSON
Version 0.1.22 PyPI version JSON
download
home_pagehttps://github.com/together-computer/together-worker
Summary
upload_time2023-08-17 04:29:12
maintainer
docs_urlNone
authortogether
requires_python>=3.7.2,<3.11
licenseMIT
keywords nlp vision speech deep learning transformer pytorch tensorflow bert gpt-2
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # together-worker

## Example

```console
cat examples/echo.py
```

```python
from together_worker.fast_inference import FastInferenceInterface

class Echo(FastInferenceInterface):
    def setup(self, args):
        self.message = " to you too."

    def dispatch_request(self, args, env):
        prompt = args[0]["prompt"]
        return {
            "choices": [ { "text": prompt + self.message } ],
        }
```

### Test with local REST server

```console
pip install --upgrade together-worker
python -m together_worker.serving examples.echo Echo
```

```console
curl -X POST http://127.0.0.1:5001/ -d '{ "prompt": "test123" }'
{"choices": [{"text": "test123 to you too."}]}
```

## Setup dev

```console
make install
```

## Publish to PyPi

GitHub repo > Releases > Draft a new Release > Choose a tag > Create new tag on publish >

Name the tag using the current version from pyproject.toml with a "v" e.g. `v1.0.9`.

> Publish Release

In the repo toolbar select > Actions

- Verify the publish workflow is running and completes successfully



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/together-computer/together-worker",
    "name": "together-worker",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7.2,<3.11",
    "maintainer_email": "",
    "keywords": "NLP,vision,speech,deep,learning,transformer,pytorch,tensorflow,BERT,GPT-2",
    "author": "together",
    "author_email": "together@together.xyz",
    "download_url": "https://files.pythonhosted.org/packages/0d/99/7d7a716b18841915f7ff1849e3b8838e4160d84c328edfe7eb0687eaa4ed/together_worker-0.1.22.tar.gz",
    "platform": null,
    "description": "# together-worker\n\n## Example\n\n```console\ncat examples/echo.py\n```\n\n```python\nfrom together_worker.fast_inference import FastInferenceInterface\n\nclass Echo(FastInferenceInterface):\n    def setup(self, args):\n        self.message = \" to you too.\"\n\n    def dispatch_request(self, args, env):\n        prompt = args[0][\"prompt\"]\n        return {\n            \"choices\": [ { \"text\": prompt + self.message } ],\n        }\n```\n\n### Test with local REST server\n\n```console\npip install --upgrade together-worker\npython -m together_worker.serving examples.echo Echo\n```\n\n```console\ncurl -X POST http://127.0.0.1:5001/ -d '{ \"prompt\": \"test123\" }'\n{\"choices\": [{\"text\": \"test123 to you too.\"}]}\n```\n\n## Setup dev\n\n```console\nmake install\n```\n\n## Publish to PyPi\n\nGitHub repo > Releases > Draft a new Release > Choose a tag > Create new tag on publish >\n\nName the tag using the current version from pyproject.toml with a \"v\" e.g. `v1.0.9`.\n\n> Publish Release\n\nIn the repo toolbar select > Actions\n\n- Verify the publish workflow is running and completes successfully\n\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "",
    "version": "0.1.22",
    "project_urls": {
        "Homepage": "https://github.com/together-computer/together-worker",
        "Repository": "https://github.com/together-computer/together-worker"
    },
    "split_keywords": [
        "nlp",
        "vision",
        "speech",
        "deep",
        "learning",
        "transformer",
        "pytorch",
        "tensorflow",
        "bert",
        "gpt-2"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "feb8fb82a7cbe4c94aad93de205cfc34ca3c107b021af0a9564e41c61725de23",
                "md5": "e4eec3368bd7c0ae3245c0c59dcee8d1",
                "sha256": "f37d058968e90a6f66d283f32706cab21c2e8b904b27da5a49c32202865d2606"
            },
            "downloads": -1,
            "filename": "together_worker-0.1.22-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "e4eec3368bd7c0ae3245c0c59dcee8d1",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7.2,<3.11",
            "size": 10144,
            "upload_time": "2023-08-17T04:29:11",
            "upload_time_iso_8601": "2023-08-17T04:29:11.255503Z",
            "url": "https://files.pythonhosted.org/packages/fe/b8/fb82a7cbe4c94aad93de205cfc34ca3c107b021af0a9564e41c61725de23/together_worker-0.1.22-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0d997d7a716b18841915f7ff1849e3b8838e4160d84c328edfe7eb0687eaa4ed",
                "md5": "cdb3526d618a306c15009447fb203910",
                "sha256": "0bd97bb3a85cb8d358cbad7f89da133afa0b2a3d7a26378560de9572756887e9"
            },
            "downloads": -1,
            "filename": "together_worker-0.1.22.tar.gz",
            "has_sig": false,
            "md5_digest": "cdb3526d618a306c15009447fb203910",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7.2,<3.11",
            "size": 8417,
            "upload_time": "2023-08-17T04:29:12",
            "upload_time_iso_8601": "2023-08-17T04:29:12.371464Z",
            "url": "https://files.pythonhosted.org/packages/0d/99/7d7a716b18841915f7ff1849e3b8838e4160d84c328edfe7eb0687eaa4ed/together_worker-0.1.22.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-08-17 04:29:12",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "together-computer",
    "github_project": "together-worker",
    "github_not_found": true,
    "lcname": "together-worker"
}
        
Elapsed time: 0.10883s