{"id":40216358,"url":"https://github.com/maximtrp/tmplot","last_synced_at":"2026-01-19T21:37:09.938Z","repository":{"id":57475982,"uuid":"370406553","full_name":"maximtrp/tmplot","owner":"maximtrp","description":"Visualization of Topic Modeling Results","archived":false,"fork":false,"pushed_at":"2025-09-13T11:13:29.000Z","size":18244,"stargazers_count":22,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-13T13:37:55.370Z","etag":null,"topics":["data-science","data-visualization","machine-learning","plotting","python","topic-modeling","visualization"],"latest_commit_sha":null,"homepage":"https://tmplot.readthedocs.org","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/maximtrp.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2021-05-24T15:50:46.000Z","updated_at":"2025-09-13T11:13:00.000Z","dependencies_parsed_at":"2023-01-27T18:46:47.534Z","dependency_job_id":"1d46b037-47f0-4144-89c6-0fd2833f7928","html_url":"https://github.com/maximtrp/tmplot","commit_stats":{"total_commits":58,"total_committers":1,"mean_commits":58.0,"dds":0.0,"last_synced_commit":"970a9762b03a0148072535861b05682916602e17"},"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/maximtrp/tmplot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maximtrp%2Ftmplot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maximtrp%2Ftmplot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maximtrp%2Ftmplot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maximtrp%2Ftmplot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/maximtrp","download_url":"https://codeload.github.com/maximtrp/tmplot/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maximtrp%2Ftmplot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28585595,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-19T20:45:59.482Z","status":"ssl_error","status_checked_at":"2026-01-19T20:45:41.500Z","response_time":67,"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":["data-science","data-visualization","machine-learning","plotting","python","topic-modeling","visualization"],"created_at":"2026-01-19T21:37:09.754Z","updated_at":"2026-01-19T21:37:09.933Z","avatar_url":"https://github.com/maximtrp.png","language":"Python","funding_links":["https://www.buymeacoffee.com/maximtrp"],"categories":[],"sub_categories":[],"readme":"# tmplot\n\n[![Codacy coverage](https://img.shields.io/codacy/coverage/5939b1cf99bc4f9d91de11c0d3ff9e50)](https://app.codacy.com/gh/maximtrp/tmplot/coverage)\n[![Codacy grade](https://img.shields.io/codacy/grade/5939b1cf99bc4f9d91de11c0d3ff9e50)](https://app.codacy.com/gh/maximtrp/tmplot)\n[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/maximtrp/tmplot/python-package.yml?label=tests)](https://github.com/maximtrp/tmplot/actions/workflows/python-package.yml)\n[![Documentation Status](https://readthedocs.org/projects/tmplot/badge/?version=latest)](https://tmplot.readthedocs.io/en/latest/?badge=latest)\n[![Downloads](https://static.pepy.tech/badge/tmplot)](https://pepy.tech/project/tmplot)\n[![PyPI](https://img.shields.io/pypi/v/tmplot)](https://pypi.org/project/tmplot)\n[![Issues](https://img.shields.io/github/issues/maximtrp/tmplot.svg)](https://github.com/maximtrp/tmplot/issues)\n\n**tmplot** is a comprehensive Python package for **topic modeling analysis and visualization**. Built for data scientists and researchers, it provides powerful interactive reports and advanced analytics that extend beyond traditional LDAvis/pyLDAvis capabilities.\n\n**Analyze** • **Visualize** • **Compare** multiple topic models with ease\n\n![Plots](https://raw.githubusercontent.com/maximtrp/tmplot/main/images/topics_terms_plots.png)\n\n## Key Features\n\n### Interactive Visualization\n\n- **Topic scatter plots** with customizable coordinates and sizing\n- **Term probability charts** with relevance weighting\n- **Document analysis** showing top documents per topic\n- **Interactive reports** with real-time parameter adjustment\n\n### Advanced Analytics\n\n- **Topic stability analysis** across multiple model runs\n- **Model comparison** with sophisticated distance metrics\n- **Saliency calculations** for term importance\n- **Entropy metrics** for model optimization\n\n### Model Support\n\n- **[tomotopy](https://bab2min.github.io/tomotopy/)**: `LDAModel`, `LLDAModel`, `CTModel`, `DMRModel`, `HDPModel`, `PTModel`, `SLDAModel`, `GDMRModel`\n- **[gensim](https://radimrehurek.com/gensim/)**: `LdaModel`, `LdaMulticore`\n- **[bitermplus](https://github.com/maximtrp/bitermplus)**: `BTM`\n\n### Distance Metrics\n\n- Kullback-Leibler (symmetric \u0026 non-symmetric)\n- Jensen-Shannon divergence\n- Jeffrey's divergence\n- Hellinger \u0026 Bhattacharyya distances\n- Total variation distance\n- Jaccard index\n\n### Dimensionality Reduction\n\nt-SNE, SpectralEmbedding, MDS, LocallyLinearEmbedding, Isomap\n\n## Donate\n\nIf you find this package useful, please consider donating any amount of money. This will help me spend more time on supporting open-source software.\n\n\u003ca href=\"https://www.buymeacoffee.com/maximtrp\" target=\"_blank\"\u003e\u003cimg src=\"https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png\" alt=\"Buy Me A Coffee\" style=\"height: 60px !important;width: 217px !important;\" \u003e\u003c/a\u003e\n\n## Quick Start\n\n### Installation\n\n```bash\n# From PyPI (recommended)\npip install tmplot\n\n# Development version\npip install git+https://github.com/maximtrp/tmplot.git\n```\n\n### Basic Usage\n\n```python\nimport tmplot as tmp\n\n# Load your topic model and documents\nmodel = your_fitted_model  # tomotopy, gensim, or bitermplus\ndocs = your_documents\n\n# Create interactive report\ntmp.report(model, docs=docs)\n\n# Or create individual visualizations\ncoords = tmp.prepare_coords(model)\ntmp.plot_scatter_topics(coords, size_col='size')\n```\n\n## Advanced Examples\n\n### Get Stable Topics\n\n```python\nimport tmplot as tmp\n\n# Find stable topics across multiple models\nmodels = [model1, model2, model3, model4]\nclosest_topics, distances = tmp.get_closest_topics(models)\nstable_topics, stable_distances = tmp.get_stable_topics(closest_topics, distances)\n```\n\n### Analyze Model\n\n```python\n# Calculate entropy for model selection\nentropy_score = tmp.entropy(phi_matrix)\n\n# Analyze topic stability\nsaliency = tmp.get_salient_terms(phi, theta)\n```\n\n### Visualize\n\n```python\n# Create topic distance matrix with different metrics\ntopic_dists = tmp.get_topics_dist(phi, method='jensen-shannon')\n\n# Generate coordinates with custom algorithm\ncoords = tmp.get_topics_scatter(topic_dists, theta, method='tsne')\ntmp.plot_scatter_topics(coords, topic=3)  # Highlight topic 3\n```\n\n## Documentation \u0026 Examples\n\n- [Complete Tutorial](https://tmplot.readthedocs.io/en/latest/tutorial.html) - Step-by-step guide\n- [API Reference](https://tmplot.readthedocs.io/) - Full documentation\n- [Example Notebooks](https://github.com/maximtrp/tmplot/tree/main/examples) - Jupyter examples\n\n## Requirements\n\n**Core dependencies:** `numpy`, `scipy`, `scikit-learn`, `pandas`, `altair`, `ipywidgets`\n\n**Optional models:** `tomotopy`, `gensim`, `bitermplus`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaximtrp%2Ftmplot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmaximtrp%2Ftmplot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaximtrp%2Ftmplot/lists"}