text-summarizer-aweebtaku 1.2.3__py3-none-any.whl → 1.2.5__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +1,3 @@
1
1
  from .summarizer import TextSummarizer
2
2
 
3
- __version__ = "1.2.3"
3
+ __version__ = "1.2.5"
text_summarizer/cli.py CHANGED
@@ -2,14 +2,22 @@ import argparse
2
2
  from .summarizer import TextSummarizer
3
3
 
4
4
  def main():
5
- parser = argparse.ArgumentParser(description="Text Summarization Tool")
6
- parser.add_argument("--glove-path", default="glove.6B.100d.txt/glove.6B.100d.txt",
7
- help="Path to GloVe embeddings file")
8
- parser.add_argument("--num-sentences", type=int, default=5,
9
- help="Number of sentences in summary")
10
- parser.add_argument("--csv-file", help="Path to CSV file with articles")
11
- parser.add_argument("--article-id", type=int, help="Article ID to summarize (if CSV provided)")
12
- parser.add_argument("--gui", action="store_true", help="Launch graphical user interface")
5
+ parser = argparse.ArgumentParser(
6
+ description="Text Summarization Tool",
7
+ epilog="""
8
+ Examples:
9
+ text-summarizer-aweebtaku --csv-file data.csv --article-id 1
10
+ text-summarizer-aweebtaku --gui
11
+
12
+ Desktop Shortcuts (Windows):
13
+ text-summarizer-shortcuts # Create desktop shortcuts
14
+ text-summarizer-gui # Launch graphical interface
15
+
16
+ Upgrade:
17
+ pip install --upgrade text-summarizer-aweebtaku
18
+ """,
19
+ formatter_class=argparse.RawDescriptionHelpFormatter
20
+ )
13
21
 
14
22
  args = parser.parse_args()
15
23
 
@@ -0,0 +1,64 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ Create desktop shortcuts for Text Summarizer on Windows.
4
+ Run this after installing the text-summarizer-aweebtaku package.
5
+ """
6
+
7
+ import os
8
+ import sys
9
+ import platform
10
+
11
+ def create_shortcuts():
12
+ """Create desktop shortcuts for Text Summarizer GUI and CLI."""
13
+
14
+ if platform.system() != "Windows":
15
+ print("This script is designed for Windows only.")
16
+ print("On other platforms, use the console scripts:")
17
+ print(" text-summarizer-gui # Launch GUI")
18
+ print(" text-summarizer-aweebtaku --help # CLI help")
19
+ return
20
+
21
+ try:
22
+ import winshell
23
+ from win32com.client import Dispatch
24
+ except ImportError:
25
+ print("Required modules not found. Installing...")
26
+ os.system(f"{sys.executable} -m pip install pywin32 winshell")
27
+ try:
28
+ import winshell
29
+ from win32com.client import Dispatch
30
+ except ImportError:
31
+ print("Failed to install required modules.")
32
+ print("Please install manually: pip install pywin32 winshell")
33
+ return
34
+
35
+ desktop = winshell.desktop()
36
+
37
+ # Create GUI shortcut
38
+ gui_shortcut_path = os.path.join(desktop, "Text Summarizer GUI.lnk")
39
+ shell = Dispatch('WScript.Shell')
40
+ shortcut = shell.CreateShortCut(gui_shortcut_path)
41
+ shortcut.Targetpath = sys.executable
42
+ shortcut.Arguments = '-c "import text_summarizer.ui; text_summarizer.ui.main()"'
43
+ shortcut.WorkingDirectory = os.path.expanduser("~")
44
+ shortcut.IconLocation = sys.executable + ",0"
45
+ shortcut.Description = "Text Summarizer GUI - Extractive text summarization tool"
46
+ shortcut.save()
47
+
48
+ # Create CLI shortcut
49
+ cli_shortcut_path = os.path.join(desktop, "Text Summarizer CLI.lnk")
50
+ shortcut = shell.CreateShortCut(cli_shortcut_path)
51
+ shortcut.Targetpath = "cmd.exe"
52
+ shortcut.Arguments = '/k text-summarizer-aweebtaku --help'
53
+ shortcut.WorkingDirectory = os.path.expanduser("~")
54
+ shortcut.IconLocation = "cmd.exe,0"
55
+ shortcut.Description = "Text Summarizer CLI - Command line interface"
56
+ shortcut.save()
57
+
58
+ print("Desktop shortcuts created successfully!")
59
+ print(f"GUI Shortcut: {gui_shortcut_path}")
60
+ print(f"CLI Shortcut: {cli_shortcut_path}")
61
+ print("\nYou can now double-click these shortcuts to launch the application.")
62
+
63
+ if __name__ == "__main__":
64
+ create_shortcuts()
@@ -0,0 +1 @@
1
+ # Data package for text_summarizer
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: text-summarizer-aweebtaku
3
- Version: 1.2.3
3
+ Version: 1.2.5
4
4
  Summary: A text summarization tool using GloVe embeddings and PageRank algorithm
5
5
  Home-page: https://github.com/AWeebTaku/Summarizer
6
6
  Author: Aditya Chaurasiya
@@ -74,6 +74,29 @@ cd Summarizer
74
74
  pip install -e .
75
75
  ```
76
76
 
77
+ ### Upgrade Package
78
+
79
+ To upgrade to the latest version with new features:
80
+ ```bash
81
+ pip install --upgrade text-summarizer-aweebtaku
82
+ ```
83
+
84
+ ### Create Desktop Shortcuts (Windows)
85
+
86
+ After installation, create desktop shortcuts for easy access:
87
+
88
+ **Option 1: Automatic (Recommended)**
89
+ ```bash
90
+ text-summarizer-shortcuts
91
+ ```
92
+ This will create desktop shortcuts for both GUI and CLI versions.
93
+
94
+ **Option 2: Manual**
95
+ Run the included batch file:
96
+ ```cmd
97
+ create_shortcuts.bat
98
+ ```
99
+
77
100
  ### Download GloVe Embeddings
78
101
 
79
102
  **No manual download required!** The package will automatically download GloVe embeddings (100d, ~400MB) on first use and cache them in your home directory (`~/.text_summarizer/`).
@@ -85,6 +108,24 @@ summarizer = TextSummarizer(glove_path='path/to/your/glove.6B.100d.txt')
85
108
 
86
109
  ## Usage
87
110
 
111
+ ### Console Scripts
112
+
113
+ After installation, you can use these commands from anywhere:
114
+
115
+ ```bash
116
+ # Upgrade to the latest version
117
+ pip install --upgrade text-summarizer-aweebtaku
118
+
119
+ # Launch the graphical user interface
120
+ text-summarizer-gui
121
+
122
+ # Use the command line interface
123
+ text-summarizer-aweebtaku --help
124
+
125
+ # Create desktop shortcuts (Windows only)
126
+ text-summarizer-shortcuts
127
+ ```
128
+
88
129
  ### Command Line Interface
89
130
 
90
131
  ```bash
@@ -0,0 +1,13 @@
1
+ text_summarizer/__init__.py,sha256=uSFM4J2uZ_aM2N5JYmrlBvkWQ0S4es8DCJeC3YHvIg4,63
2
+ text_summarizer/cli.py,sha256=zMP4amFDj5F-GCOcQSRN924HrCHcrKrcqmTiwfSTCr8,3656
3
+ text_summarizer/create_shortcuts.py,sha256=1fwZkHG-2vim0HkIkb15BHEh-Xe2NbXcoidUtLvn1Tg,2436
4
+ text_summarizer/summarizer.py,sha256=80RamR76QFtOAZGdVGqy-Bi5xQb3WBbQ2pSYSnOnT5c,12733
5
+ text_summarizer/ui.py,sha256=Ky40zcr-_0zh5I7Kh4Bc8hKrEBdOALe5G4i3ukDJWts,16638
6
+ text_summarizer/data/__init__.py,sha256=keVAOKSXlHFknU6dXsWGV_4Vx8RKEyUdY76PK05_4Ug,34
7
+ text_summarizer/data/tennis.csv,sha256=oEPZr4Dy6cmCDtdQ2QYJyJpERzQseuNJ53JP2XyIfBk,12943
8
+ text_summarizer_aweebtaku-1.2.5.dist-info/licenses/LICENSE,sha256=UdJHHpU6zYlYRsiLua2qeQwtJk2-UR17jXRV-MfxoVk,1093
9
+ text_summarizer_aweebtaku-1.2.5.dist-info/METADATA,sha256=2klEtxOTxHNYm0trBQqysb1Srqov-Xt74mE7D4hiZWQ,6007
10
+ text_summarizer_aweebtaku-1.2.5.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
11
+ text_summarizer_aweebtaku-1.2.5.dist-info/entry_points.txt,sha256=jOt-WcgMjgjfoD1cvbYoPExPiyIbLn49Gh-A5OEgugw,195
12
+ text_summarizer_aweebtaku-1.2.5.dist-info/top_level.txt,sha256=2s-4Uyii86k2iEeiIi0JghAXW47cEQ8qM_ONYPs9Gh8,16
13
+ text_summarizer_aweebtaku-1.2.5.dist-info/RECORD,,
@@ -1,3 +1,4 @@
1
1
  [console_scripts]
2
2
  text-summarizer-aweebtaku = text_summarizer.cli:main
3
3
  text-summarizer-gui = text_summarizer.ui:main
4
+ text-summarizer-shortcuts = text_summarizer.create_shortcuts:create_shortcuts
@@ -1,11 +0,0 @@
1
- text_summarizer/__init__.py,sha256=XS4OxcZIvDnFpnjsLeZ6qwB0sUd8cajpY_DBWU6FCjw,63
2
- text_summarizer/cli.py,sha256=rWbSpT1gJ8kVcsTQ-ov6AZkfy5uUz2taAXeSnDEy0Zw,3773
3
- text_summarizer/summarizer.py,sha256=80RamR76QFtOAZGdVGqy-Bi5xQb3WBbQ2pSYSnOnT5c,12733
4
- text_summarizer/ui.py,sha256=Ky40zcr-_0zh5I7Kh4Bc8hKrEBdOALe5G4i3ukDJWts,16638
5
- text_summarizer/data/tennis.csv,sha256=oEPZr4Dy6cmCDtdQ2QYJyJpERzQseuNJ53JP2XyIfBk,12943
6
- text_summarizer_aweebtaku-1.2.3.dist-info/licenses/LICENSE,sha256=UdJHHpU6zYlYRsiLua2qeQwtJk2-UR17jXRV-MfxoVk,1093
7
- text_summarizer_aweebtaku-1.2.3.dist-info/METADATA,sha256=3JZMgdymeRJlZ2ROb0uYwzrmFQyHMqlLCG-nMpdyn98,5131
8
- text_summarizer_aweebtaku-1.2.3.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
9
- text_summarizer_aweebtaku-1.2.3.dist-info/entry_points.txt,sha256=a8n647pYmETd5RzGoOBcfYtIxxNFNu7P5zctmhpldNY,117
10
- text_summarizer_aweebtaku-1.2.3.dist-info/top_level.txt,sha256=2s-4Uyii86k2iEeiIi0JghAXW47cEQ8qM_ONYPs9Gh8,16
11
- text_summarizer_aweebtaku-1.2.3.dist-info/RECORD,,