{"id":13534488,"url":"https://github.com/olirice/flupy","last_synced_at":"2025-04-12T19:46:44.380Z","repository":{"id":31401255,"uuid":"116499113","full_name":"olirice/flupy","owner":"olirice","description":"Fluent data pipelines for python and your shell","archived":false,"fork":false,"pushed_at":"2024-09-12T19:09:34.000Z","size":444,"stargazers_count":193,"open_issues_count":5,"forks_count":15,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-04-10T13:29:39.892Z","etag":null,"topics":["collections","data-pipeline","fluent","python"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/olirice.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","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":"2018-01-06T16:46:04.000Z","updated_at":"2025-03-21T08:46:21.000Z","dependencies_parsed_at":"2022-08-07T16:15:59.683Z","dependency_job_id":"17f0d54d-23fe-49b9-aef2-58f8fe12b904","html_url":"https://github.com/olirice/flupy","commit_stats":{"total_commits":193,"total_committers":7,"mean_commits":"27.571428571428573","dds":0.03626943005181349,"last_synced_commit":"b787d605c0ded610cc0292c66a9f92cac3530a4d"},"previous_names":["olirice/chainable"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olirice%2Fflupy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olirice%2Fflupy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olirice%2Fflupy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/olirice%2Fflupy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/olirice","download_url":"https://codeload.github.com/olirice/flupy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248625497,"owners_count":21135513,"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":["collections","data-pipeline","fluent","python"],"created_at":"2024-08-01T07:01:34.250Z","updated_at":"2025-04-12T19:46:44.343Z","avatar_url":"https://github.com/olirice.png","language":"Python","readme":"# flupy\n\n\u003cp\u003e\n\n\u003ca href=\"https://flupy.readthedocs.io/en/latest/?badge=latest\"\u003e\u003cimg src=\"https://readthedocs.org/projects/flupy/badge/?version=latest\" alt=\"Tests\" height=\"18\"\u003e\u003c/a\u003e\n\u003ca href=\"https://codecov.io/gh/olirice/flupy\"\u003e\u003cimg src=\"https://codecov.io/gh/olirice/flupy/branch/master/graph/badge.svg\" height=\"18\"\u003e\u003c/a\u003e\n\u003ca href=\"https://github.com/psf/black\"\u003e\n        \u003cimg src=\"https://img.shields.io/badge/code%20style-black-000000.svg\" alt=\"Codestyle Black\" height=\"18\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp\u003e\n    \u003ca href=\"https://www.python.org/downloads/\"\u003e\u003cimg src=\"https://img.shields.io/badge/python-3.6+-blue.svg\" alt=\"Python version\" height=\"18\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://badge.fury.io/py/flupy\"\u003e\u003cimg src=\"https://badge.fury.io/py/flupy.svg\" alt=\"PyPI version\" height=\"18\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/olirice/flupy/blob/master/LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/pypi/l/markdown-subtemplate.svg\" alt=\"License\" height=\"18\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://pypi.org/project/flupy/\"\u003e\u003cimg src=\"https://img.shields.io/pypi/dm/flupy.svg\" alt=\"Download count\" height=\"18\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n---\n\n**Documentation**: \u003ca href=\"https://flupy.readthedocs.io/en/latest/\" target=\"_blank\"\u003ehttps://flupy.readthedocs.io/en/latest/\u003c/a\u003e\n\n**Source Code**: \u003ca href=\"https://github.com/olirice/flupy\" target=\"_blank\"\u003ehttps://github.com/olirice/flupy\u003c/a\u003e\n\n---\n\n## Overview\nFlupy implements a [fluent interface](https://en.wikipedia.org/wiki/Fluent_interface) for operating on python iterables. All flupy methods return generators and are evaluated lazily. This allows expressions to transform arbitrary size data in extremely limited memory.\n\nYou can think of flupy as a light weight, 0 dependency, pure python alternative to the excellent [Apache Spark](https://spark.apache.org/) project.\n\n## Setup\n\n### Requirements\n\n* Python 3.6+\n\n### Installation\n\nInstall flupy with pip:\n```sh\n$ pip install flupy\n```\n\n### Library\n```python\nfrom itertools import count\nfrom flupy import flu\n\n# Processing an infinite sequence in constant memory\npipeline = (\n    flu(count())\n    .map(lambda x: x**2)\n    .filter(lambda x: x % 517 == 0)\n    .chunk(5)\n    .take(3)\n)\n\nfor item in pipeline:\n  print(item)\n\n# Returns:\n# [0, 267289, 1069156, 2405601, 4276624]\n# [6682225, 9622404, 13097161, 17106496, 21650409]\n# [26728900, 32341969, 38489616, 45171841, 52388644]\n```\n\n### CLI\nThe flupy command line interface brings the same syntax for lazy piplines to your shell. Inputs to the `flu` command are auto-populated into a `Fluent` context named `_`.\n````\n$ flu -h\nusage: flu [-h] [-f FILE] [-i [IMPORT [IMPORT ...]]] command\n\nflupy: a fluent interface for python\n\npositional arguments:\n  command               flupy command to execute on input\n\noptional arguments:\n  -h, --help            show this help message and exit\n  -f FILE, --file FILE  path to input file\n  -i [IMPORT [IMPORT ...]], --import [IMPORT [IMPORT ...]]\n                        modules to import\n                        Syntax: \u003cmodule\u003e:\u003cobject\u003e:\u003calias\u003e\n                        Examples:\n                                'import os' = '-i os'\n                                'import os as op_sys' = '-i os::op_sys'\n                                'from os import environ' = '-i os:environ'\n                                'from os import environ as env' = '-i os:environ:env'\n````\n","funding_links":[],"categories":["Awesome Functional Python","数据管道和流处理","Python","Data Pipelines \u0026 Streaming"],"sub_categories":["Libraries"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Folirice%2Fflupy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Folirice%2Fflupy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Folirice%2Fflupy/lists"}