This repository contains an implementation of the TSSort algorithm proposed in "TSSort – Probabilistic Noise Resistant Sorting" (Hees et al., 2011).
# Expected Input
This module expects a text file with a list of sentences separated by newline and a text file of a list of pairwise comparisons in the form int,int and separated by newline. See the sample data files ```comparisons.txt``` and ```sentences.txt``` in the linked github for an example. The list of pairwise comparisons refers to the sentence index (starting at 0), wherein the first number is the easier sentence and the second number is the harder sentence.
To run the code:
```
python3 -m tssort comparisons.txt sentences.txt [-l or -n]
```
where the ```comparisons.txt``` file is your list of comparisons and the ```sentences.txt``` file is you list of sentences. Note, the ```comparisons.txt``` file must reference the index ordering of sentences in the ```sentences.txt``` file.
The ```-l``` argument will output the ranked list of the sentences, from easiest to hardest.
The ```-n``` argument outputs suggestions for the sentences that should be compared next to ensure the most efficient method of sorting the list.
Raw data
{
"_id": null,
"home_page": null,
"name": "TSSort",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": null,
"keywords": "pairwise, sort, tssort",
"author": "Alexandra Fort, Daniel Swanson, Nicholas Howell",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/76/ce/cd8586ed215008c02c18bda25e3a65de6d9e1a084e25a7962dfadb0aea74/tssort-0.0.3.tar.gz",
"platform": null,
"description": "This repository contains an implementation of the TSSort algorithm proposed in \"TSSort \u2013 Probabilistic Noise Resistant Sorting\" (Hees et al., 2011).\n\n# Expected Input\nThis module expects a text file with a list of sentences separated by newline and a text file of a list of pairwise comparisons in the form int,int and separated by newline. See the sample data files ```comparisons.txt``` and ```sentences.txt``` in the linked github for an example. The list of pairwise comparisons refers to the sentence index (starting at 0), wherein the first number is the easier sentence and the second number is the harder sentence.\n\nTo run the code:\n```\npython3 -m tssort comparisons.txt sentences.txt [-l or -n]\n```\nwhere the ```comparisons.txt``` file is your list of comparisons and the ```sentences.txt``` file is you list of sentences. Note, the ```comparisons.txt``` file must reference the index ordering of sentences in the ```sentences.txt``` file.\n\nThe ```-l``` argument will output the ranked list of the sentences, from easiest to hardest.\n\nThe ```-n``` argument outputs suggestions for the sentences that should be compared next to ensure the most efficient method of sorting the list. \n\n",
"bugtrack_url": null,
"license": null,
"summary": "A library and tool for implementing TSSort in Python, which allows for the sorting of a list using pairwise comparisons while accounting for noisy data.",
"version": "0.0.3",
"project_urls": {
"Homepage": "https://github.com/aconeil/TSSort"
},
"split_keywords": [
"pairwise",
" sort",
" tssort"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "02e29f8991a8caf62323d6321b0e35df8eb4765f48cf6533b244c904ddd7fede",
"md5": "0961277f2f629bd0fb318ff2ad431202",
"sha256": "1a13ca0444e37d3a2450d7ffcbc3335666573fad6dd08ccf50a17270d6276445"
},
"downloads": -1,
"filename": "tssort-0.0.3-py3-none-any.whl",
"has_sig": false,
"md5_digest": "0961277f2f629bd0fb318ff2ad431202",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 5458,
"upload_time": "2025-08-29T19:37:05",
"upload_time_iso_8601": "2025-08-29T19:37:05.579204Z",
"url": "https://files.pythonhosted.org/packages/02/e2/9f8991a8caf62323d6321b0e35df8eb4765f48cf6533b244c904ddd7fede/tssort-0.0.3-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "76cecd8586ed215008c02c18bda25e3a65de6d9e1a084e25a7962dfadb0aea74",
"md5": "7808e0ef2db2ff5fba4ce0658b7b65f1",
"sha256": "1f2232e8e51d53c1f937cbf1977498c1c681772c8f59316bcee0d76c407fa223"
},
"downloads": -1,
"filename": "tssort-0.0.3.tar.gz",
"has_sig": false,
"md5_digest": "7808e0ef2db2ff5fba4ce0658b7b65f1",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 3872,
"upload_time": "2025-08-29T19:37:06",
"upload_time_iso_8601": "2025-08-29T19:37:06.522681Z",
"url": "https://files.pythonhosted.org/packages/76/ce/cd8586ed215008c02c18bda25e3a65de6d9e1a084e25a7962dfadb0aea74/tssort-0.0.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-29 19:37:06",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "aconeil",
"github_project": "TSSort",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [
{
"name": "numpy",
"specs": [
[
">=",
"1.24"
]
]
},
{
"name": "scipy",
"specs": [
[
"==",
"1.15.2"
]
]
}
],
"lcname": "tssort"
}