summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore1
-rw-r--r--python-argument-esa-model.spec171
-rw-r--r--sources1
3 files changed, 173 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..c944426 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/argument_esa_model-3.11.112.linux-x86_64.tar.gz
diff --git a/python-argument-esa-model.spec b/python-argument-esa-model.spec
new file mode 100644
index 0000000..6bdfa06
--- /dev/null
+++ b/python-argument-esa-model.spec
@@ -0,0 +1,171 @@
+%global _empty_manifest_terminate_build 0
+Name: python-argument-esa-model
+Version: 3.11.112
+Release: 1
+Summary: An ESA implementation in python.
+License: MIT License
+URL: https://git.webis.de/args/args-topic-modeling/tree/master/src/python/esa
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/85/c8/4fc090bc1b235a0b08e8e7c5f61ede22688f374d875f24e75f639f776b2d/argument_esa_model-3.11.112.linux-x86_64.tar.gz
+BuildArch: noarch
+
+
+%description
+# Get the required resources
+<code> scp -r webis@webislab40.medien.uni-weimar.de:/home/weci2587/projects/args-topic-modeling/resources . </code>
+
+# To run the ESA-script with all terms run:
+## For normal ESA:
+
+ ./esa-all-terms.py --similarity cos
+ --matrix-path <path_to_resources>/resources/esa-plain/<debatepedia|strategic-intelligence|wikipedia>.mat
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+## For word2vec-ESA:
+
+ ./esa-all-terms.py --similarity max
+ --matrix-path <path_to_resources>/resources/esa-w2v/<debatepedia|strategic-intelligence|wikipedia>.mat
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+# To run the word2vec-ESA with reduced terms run:
+
+ ./esa-top-n-terms.py -n <number_of_terms>
+ --corpus-path <path_to_resources>/resources/corpora/<debatepedia|strategic-intelligence|wikipedia>.csv
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+The input document must be a csv file with "|" as the separator and must contain the column "document", which is used as the input text for the ESA.
+
+
+
+%package -n python3-argument-esa-model
+Summary: An ESA implementation in python.
+Provides: python-argument-esa-model
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-argument-esa-model
+# Get the required resources
+<code> scp -r webis@webislab40.medien.uni-weimar.de:/home/weci2587/projects/args-topic-modeling/resources . </code>
+
+# To run the ESA-script with all terms run:
+## For normal ESA:
+
+ ./esa-all-terms.py --similarity cos
+ --matrix-path <path_to_resources>/resources/esa-plain/<debatepedia|strategic-intelligence|wikipedia>.mat
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+## For word2vec-ESA:
+
+ ./esa-all-terms.py --similarity max
+ --matrix-path <path_to_resources>/resources/esa-w2v/<debatepedia|strategic-intelligence|wikipedia>.mat
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+# To run the word2vec-ESA with reduced terms run:
+
+ ./esa-top-n-terms.py -n <number_of_terms>
+ --corpus-path <path_to_resources>/resources/corpora/<debatepedia|strategic-intelligence|wikipedia>.csv
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+The input document must be a csv file with "|" as the separator and must contain the column "document", which is used as the input text for the ESA.
+
+
+
+%package help
+Summary: Development documents and examples for argument-esa-model
+Provides: python3-argument-esa-model-doc
+%description help
+# Get the required resources
+<code> scp -r webis@webislab40.medien.uni-weimar.de:/home/weci2587/projects/args-topic-modeling/resources . </code>
+
+# To run the ESA-script with all terms run:
+## For normal ESA:
+
+ ./esa-all-terms.py --similarity cos
+ --matrix-path <path_to_resources>/resources/esa-plain/<debatepedia|strategic-intelligence|wikipedia>.mat
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+## For word2vec-ESA:
+
+ ./esa-all-terms.py --similarity max
+ --matrix-path <path_to_resources>/resources/esa-w2v/<debatepedia|strategic-intelligence|wikipedia>.mat
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+# To run the word2vec-ESA with reduced terms run:
+
+ ./esa-top-n-terms.py -n <number_of_terms>
+ --corpus-path <path_to_resources>/resources/corpora/<debatepedia|strategic-intelligence|wikipedia>.csv
+ --model-path <path_to_resources>/resources/esa-w2v/GoogleNews-vectors-negative300.bin
+ --model-vocab <path_to_resources>/resources/esa-w2v/w2v-vocab.p
+ --input-path <path_to_input_file>
+ --output-path <path_to_output_file>
+
+The input document must be a csv file with "|" as the separator and must contain the column "document", which is used as the input text for the ESA.
+
+
+
+%prep
+%autosetup -n argument-esa-model-3.11.112
+
+%build
+%py3_build
+
+%install
+%py3_install
+install -d -m755 %{buildroot}/%{_pkgdocdir}
+if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
+if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
+if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
+if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
+pushd %{buildroot}
+if [ -d usr/lib ]; then
+ find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/lib64 ]; then
+ find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/bin ]; then
+ find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/sbin ]; then
+ find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+touch doclist.lst
+if [ -d usr/share/man ]; then
+ find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
+fi
+popd
+mv %{buildroot}/filelist.lst .
+mv %{buildroot}/doclist.lst .
+
+%files -n python3-argument-esa-model -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Tue Apr 11 2023 Python_Bot <Python_Bot@openeuler.org> - 3.11.112-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..64cce7f
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+6c1e56c8c1495f3e0a1718c9601843e0 argument_esa_model-3.11.112.linux-x86_64.tar.gz