{"id":28773182,"url":"https://github.com/biboudis/sml-streams","last_synced_at":"2026-02-08T16:31:55.239Z","repository":{"id":20794487,"uuid":"24079704","full_name":"biboudis/sml-streams","owner":"biboudis","description":"Streaming library for bulk memory operations with Standard ML in MLton","archived":false,"fork":false,"pushed_at":"2015-03-16T19:44:31.000Z","size":332,"stargazers_count":28,"open_issues_count":0,"forks_count":2,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-07-29T10:00:26.653Z","etag":null,"topics":["mlton","sml","sml-streams"],"latest_commit_sha":null,"homepage":"","language":"Standard ML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/biboudis.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-09-16T00:46:58.000Z","updated_at":"2024-10-27T01:14:24.000Z","dependencies_parsed_at":"2022-09-16T21:21:47.292Z","dependency_job_id":null,"html_url":"https://github.com/biboudis/sml-streams","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/biboudis/sml-streams","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/biboudis%2Fsml-streams","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/biboudis%2Fsml-streams/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/biboudis%2Fsml-streams/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/biboudis%2Fsml-streams/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/biboudis","download_url":"https://codeload.github.com/biboudis/sml-streams/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/biboudis%2Fsml-streams/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29236898,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-08T14:18:14.570Z","status":"ssl_error","status_checked_at":"2026-02-08T14:18:14.071Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["mlton","sml","sml-streams"],"created_at":"2025-06-17T14:07:16.092Z","updated_at":"2026-02-08T16:31:55.215Z","avatar_url":"https://github.com/biboudis.png","language":"Standard ML","funding_links":[],"categories":[],"sub_categories":[],"readme":"sml-streams\n===========\n\nThe vision: Bulk memory operations with Standard ML in MLton. The pattern is based on pipelines that are composed via continuations, where a source is wrapped as a push-based stream, transformations are applied via lazy operations and eager combinators force the effects on the backing, in-memory collection of items:\n```\nsource - lazy - lazy - lazy - eager\n```\n\n### Test\nTo experiment with the library install MLton and ```make``` the project:\n```shell\n\u003e sudo yum install mlton\n\u003e make bench\n\u003e cd build \n\u003e ./bench-streams\n```\n\n### Example \n```sml\n(* using F#-like pipe operators *)\nArray.tabulate (10, fn i =\u003e i)\n    |\u003e Stream.ofArray\n    |\u003e Stream.map(fn x =\u003e x * x)\n    |\u003e Stream.take 6\n    |\u003e Stream.sum\n```\n\n### Benchmarks\n```shell\n# Outer=1000000, Inner=10\nStreams cart time: 0.098 sec/op\nBaseline cart time: 0.048 sec/op\n\n# Outer=5000000, Inner=50\nStreams cart time: 1.857 sec/op\nBaseline cart time: 1.195 sec/op\n\n# Outer=10000000, Inner=100\nStreams cart time: 7.151 sec/op\nBaseline cart time: 4.723 sec/op\n```\n### References\n\n* Inspired by our work on [Clash of the Lambdas](http://biboudis.github.io/clashofthelambdas/)\n* [Nessos/Streams](https://github.com/nessos/Streams) in F#\n* [Lightweight Streams](https://github.com/biboudis/lightweight-streams) in Java (reimplemented with lambdas only)\n* [MLton](http://mlton.org/)\n* Found out that similar pattern appears in [MLton/Iterator combinators](http://mlton.org/ForLoops), [iter.sml](https://github.com/MLton/mltonlib/blob/master/com/ssh/extended-basis/unstable/detail/control/iter.sml) / [iter.sig](https://github.com/MLton/mltonlib/blob/master/com/ssh/extended-basis/unstable/public/control/iter.sig)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbiboudis%2Fsml-streams","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbiboudis%2Fsml-streams","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbiboudis%2Fsml-streams/lists"}