Skip to content

Commit 7dc5bce

Browse files
committed
Merge branch 'main' into release/v1.5.X
# Conflicts: # version.txt
2 parents 996995d + 0f8aa39 commit 7dc5bce

File tree

13 files changed

+338
-64
lines changed

13 files changed

+338
-64
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: 'bug'
6+
assignees: ''
7+
8+
---
9+
10+
### Describe the bug
11+
12+
A clear and concise description of what the bug is.
13+
14+
### To Reproduce
15+
16+
Code snippet:
17+
18+
```
19+
20+
```
21+
22+
(Please provide a code snippet! This will help expedite us finding and solving the problem.)
23+
24+
Steps to reproduce the behavior:
25+
1. ...
26+
2. ...
27+
28+
### Expected behavior
29+
30+
A clear and concise description of what you expected to happen.
31+
32+
### Actual behavior
33+
34+
Explain the buggy behavior you experience when you go through the steps above. If applicable, add screenshots to help explain your problem.
35+
36+
### Is this a regression?
37+
38+
That is, did this use to work the way you expected in the past?
39+
40+
- [ ] Yes
41+
- [ ] No
42+
43+
### Debug info
44+
45+
- Words'n Fun version:
46+
- Python version: (get it with `$ python --version`)
47+
- OS version:
48+
49+
### Additional context
50+
51+
Add any other context about the problem here.
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
title: ''
5+
labels: 'enhancement'
6+
assignees: ''
7+
8+
9+
---
10+
11+
<!--
12+
Note, you don't have to fill out every section here. They're just here for guidance. That said, nicely detailed feature requests are more likely to get attention sooner
13+
14+
-->
15+
16+
### Problem
17+
18+
Is your feature request related to a problem?
19+
Please describe the problem here. Ex. I'm always frustrated when [...]
20+
21+
### Solution
22+
23+
Describe the solution you'd like, i.e. a clear and concise description of what you want to happen.
24+
Ideally you want to fullfil the following bullet points :
25+
26+
- **MVP:** What's the smallest possible solution that would get 80% of the problem out of the way?
27+
28+
- **Possible additions:** What are other things that could be added to the MVP over time to make it better?
29+
30+
- **Preferred solution:** If you don't like the MVP above, tell us why, and what you'd like done instead.
31+
32+
- **Alternatives solution:** Alternative solutions or features you've considered.
33+
34+
35+
### Additional context
36+
37+
Add any other context or screenshots about the feature request here.

.github/pull_request_template.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
<!--
2+
Before contributing :
3+
4+
⚠️ Any contribution that is more than a few lines of code must be stated on the corresponding issue. If there is no issue for it yet, please create it first.
5+
6+
This ensure that :
7+
8+
1. Two people aren't working on the same thing
9+
2. This is something Words'n Fun's maintainers believe should be implemented/fixed
10+
3. Your time is well spent :)
11+
12+
-->
13+
14+
## ✒️ Context
15+
16+
_Please describe the project or issue background here_
17+
18+
- What kind of change does this PR introduce ?
19+
20+
- [ ] Bugfix
21+
- [ ] Feature
22+
- [ ] Refactoring
23+
- [ ] Other, please describe:
24+
25+
## 🧱 Description of Changes
26+
27+
- _Add bullet points summarizing your changes here_
28+
29+
30+
## 🩺 Testing
31+
32+
- _Add bullet points summarizing your changes here_
33+
34+
- [ ] This change does not need new tests
35+
- [ ] Added/Updated unit tests
36+
37+
## 🔗 References
38+
39+
_Does this depend on other work, documents, or tickets?_
40+
41+
- **Issue**: Closes #XXXX
42+
43+
---
44+
45+
**Contribution License Agreement**
46+
47+
By submitting this pull request you agree that all contributions to this project are made under the GNU AFFERO GENERAL PUBLIC LICENSE.

.github/workflows/wnf_build_tests.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ on:
1111
- 'LICENSE'
1212
- 'Makefile'
1313
pull_request:
14-
types: [opened, reopened, edit]
14+
types: [opened, reopened, edit, synchronize]
1515
branches:
1616
- 'main'
1717
- 'release/v*'
@@ -21,6 +21,8 @@ on:
2121
- '*.md'
2222
- 'LICENSE'
2323
- 'Makefile'
24+
schedule:
25+
- cron: '0 0 * * 0'
2426
workflow_dispatch:
2527

2628
jobs:

CODE_OF_CONDUCT.md

Lines changed: 128 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our
6+
community a harassment-free experience for everyone, regardless of age, body
7+
size, visible or invisible disability, ethnicity, sex characteristics, gender
8+
identity and expression, level of experience, education, socio-economic status,
9+
nationality, personal appearance, race, religion, or sexual identity
10+
and orientation.
11+
12+
We pledge to act and interact in ways that contribute to an open, welcoming,
13+
diverse, inclusive, and healthy community.
14+
15+
## Our Standards
16+
17+
Examples of behavior that contributes to a positive environment for our
18+
community include:
19+
20+
* Demonstrating empathy and kindness toward other people
21+
* Being respectful of differing opinions, viewpoints, and experiences
22+
* Giving and gracefully accepting constructive feedback
23+
* Accepting responsibility and apologizing to those affected by our mistakes,
24+
and learning from the experience
25+
* Focusing on what is best not just for us as individuals, but for the
26+
overall community
27+
28+
Examples of unacceptable behavior include:
29+
30+
* The use of sexualized language or imagery, and sexual attention or
31+
advances of any kind
32+
* Trolling, insulting or derogatory comments, and personal or political attacks
33+
* Public or private harassment
34+
* Publishing others' private information, such as a physical or email
35+
address, without their explicit permission
36+
* Other conduct which could reasonably be considered inappropriate in a
37+
professional setting
38+
39+
## Enforcement Responsibilities
40+
41+
Community leaders are responsible for clarifying and enforcing our standards of
42+
acceptable behavior and will take appropriate and fair corrective action in
43+
response to any behavior that they deem inappropriate, threatening, offensive,
44+
or harmful.
45+
46+
Community leaders have the right and responsibility to remove, edit, or reject
47+
comments, commits, code, wiki edits, issues, and other contributions that are
48+
not aligned to this Code of Conduct, and will communicate reasons for moderation
49+
decisions when appropriate.
50+
51+
## Scope
52+
53+
This Code of Conduct applies within all community spaces, and also applies when
54+
an individual is officially representing the community in public spaces.
55+
Examples of representing our community include using an official e-mail address,
56+
posting via an official social media account, or acting as an appointed
57+
representative at an online or offline event.
58+
59+
## Enforcement
60+
61+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
62+
reported to the community leaders responsible for enforcement at
63+
64+
All complaints will be reviewed and investigated promptly and fairly.
65+
66+
All community leaders are obligated to respect the privacy and security of the
67+
reporter of any incident.
68+
69+
## Enforcement Guidelines
70+
71+
Community leaders will follow these Community Impact Guidelines in determining
72+
the consequences for any action they deem in violation of this Code of Conduct:
73+
74+
### 1. Correction
75+
76+
**Community Impact**: Use of inappropriate language or other behavior deemed
77+
unprofessional or unwelcome in the community.
78+
79+
**Consequence**: A private, written warning from community leaders, providing
80+
clarity around the nature of the violation and an explanation of why the
81+
behavior was inappropriate. A public apology may be requested.
82+
83+
### 2. Warning
84+
85+
**Community Impact**: A violation through a single incident or series
86+
of actions.
87+
88+
**Consequence**: A warning with consequences for continued behavior. No
89+
interaction with the people involved, including unsolicited interaction with
90+
those enforcing the Code of Conduct, for a specified period of time. This
91+
includes avoiding interactions in community spaces as well as external channels
92+
like social media. Violating these terms may lead to a temporary or
93+
permanent ban.
94+
95+
### 3. Temporary Ban
96+
97+
**Community Impact**: A serious violation of community standards, including
98+
sustained inappropriate behavior.
99+
100+
**Consequence**: A temporary ban from any sort of interaction or public
101+
communication with the community for a specified period of time. No public or
102+
private interaction with the people involved, including unsolicited interaction
103+
with those enforcing the Code of Conduct, is allowed during this period.
104+
Violating these terms may lead to a permanent ban.
105+
106+
### 4. Permanent Ban
107+
108+
**Community Impact**: Demonstrating a pattern of violation of community
109+
standards, including sustained inappropriate behavior, harassment of an
110+
individual, or aggression toward or disparagement of classes of individuals.
111+
112+
**Consequence**: A permanent ban from any sort of public interaction within
113+
the community.
114+
115+
## Attribution
116+
117+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118+
version 2.0, available at
119+
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120+
121+
Community Impact Guidelines were inspired by [Mozilla's code of conduct
122+
enforcement ladder](https://github.com/mozilla/diversity).
123+
124+
[homepage]: https://www.contributor-covenant.org
125+
126+
For answers to common questions about this code of conduct, see the FAQ at
127+
https://www.contributor-covenant.org/faq. Translations are available at
128+
https://www.contributor-covenant.org/translations.

README.md

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,18 @@
44
[![License: AGPL v3](https://img.shields.io/badge/License-AGPL%20v3-blue.svg)](https://www.gnu.org/licenses/agpl-3.0)
55
[![Generic badge](https://img.shields.io/badge/python-3.7|3.8-blue.svg)](https://shields.io/)
66

7-
# WORDS N FUN : Semantic analysis module built by agence Data Services
7+
# WORDS N FUN : Semantic analysis module built
8+
9+
The purpose of this project is two folds:
10+
1. To normalize tools and how tos of semantic analysis projects
11+
2. To offer end to end pipelines to speed up the time to market of NLP services
812

913
---
1014

1115
# Licence
1216

1317
This project is distributed under the GNU AFFERO GENERAL PUBLIC LICENSE V3.0. Please check the LICENSE file.
1418

15-
---
16-
17-
## Why ?
18-
19-
The purpose of this project is two folds:
20-
1. To normalize tools and how tos of semantic analysis projects
21-
2. To offer end to end pipelines to speed up the time to market of NLP services
22-
23-
2419
---
2520

2621
## Philosophy of this package

requirements.txt

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,29 @@
11
# Data manipulation
2-
numpy==1.19.5
3-
pandas==1.3.5
2+
numpy==1.21.6; python_version < "3.8"
3+
numpy==1.23.2; python_version >= "3.8"
4+
pandas==1.3.5; python_version < "3.8"
5+
pandas==1.4.4; python_version >= "3.8"
46

57
# NLP
6-
nltk==3.4.5
7-
ftfy==5.8
8+
nltk==3.7
9+
ftfy==6.1.1
810

911
# Others
10-
simplejson==3.17.2
11-
tqdm==4.62.2
12-
requests==2.23.0
12+
tqdm==4.64.1
13+
simplejson==3.17.6
14+
requests==2.28.1
1315

1416
# Optionnals - code quality & cie
15-
flake8==3.7.9
16-
black==19.10b0
17-
isort==4.3.21
17+
flake8==5.0.4
18+
black==22.8.0
19+
isort==5.10.1
1820
nose==1.3.7
1921
nose-exclude==0.5.0
20-
coverage==5.3
22+
coverage==6.4.4
2123

2224
# Has to be installed last / optionnal to use spacy lemmatizer
2325
markupsafe==2.0.1 # BUG FIX -> https://github.com/aws/aws-sam-cli/issues/3661
2426
Cython==0.29.24
2527
spacy==3.3.1
26-
# The following line downloads a spacy model. It can be commented if you don't have an internet access to download it, but lemmatizer features won't work.
28+
# The following line downloads a frnech spacy model. It can be commented if you don't have an internet access to download it, but lemmatizer features won't work.
2729
https://github.com/explosion/spacy-models/releases/download/fr_core_news_sm-3.3.0/fr_core_news_sm-3.3.0-py3-none-any.whl

setup.py

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
# Get package directory
2020
package_directory = os.path.dirname(os.path.abspath(__file__))
2121

22-
# Get package version (env variable or verion file + -local)
22+
# Get package version (env variable or version file + -local)
2323
version_path = os.path.join(package_directory, 'version.txt')
2424
with open(version_path, 'r') as version_file:
2525
version = version_file.read().strip()
@@ -38,22 +38,26 @@
3838
license='AGPL-3.0',
3939
long_description=long_description,
4040
long_description_content_type='text/markdown',
41-
author='Agence Data Services PE Nantes',
41+
author="Agence Data Services PE Nantes",
42+
author_email="[email protected]",
4243
description="Semantic library of the Data Services agency",
4344
url="https://github.com/OSS-Pole-Emploi/words_n_fun",
4445
platforms=['windows', 'linux'],
46+
python_requires='>=3.7',
4547
package_data={
4648
'words_n_fun': ['configs/*.json', 'nltk_data/corpora/stopwords/french']
4749
},
4850
include_package_data=True,
4951
install_requires=[
50-
'pandas==1.3.5',
51-
'numpy==1.19.5',
52-
'nltk>=3.4.5,<3.6',
53-
'tqdm==4.62.2', # https://github.com/tqdm/tqdm/issues/780
54-
'simplejson>=3.17.0,<3.17.3',
55-
'requests>=2.23.0,<2.25.1',
56-
'ftfy>=5.8,<6.0',
52+
'pandas>=1.3,<1.4; python_version < "3.8"',
53+
'pandas>=1.3,<1.5; python_version >= "3.8"',
54+
'numpy>=1.19,<1.22; python_version < "3.8"',
55+
'numpy>=1.19,<1.24; python_version >= "3.8"',
56+
'nltk>=3.4,<3.8',
57+
'ftfy>=5.8,<6.2',
58+
'tqdm>=4.40,<4.65',
59+
'simplejson>=3.17,<3.18',
60+
'requests>=2.23,<2.29',
5761
],
5862
extras_require={
5963
"lemmatizer": ["spacy==3.3.1", "markupsafe==2.0.1", "Cython==0.29.24", "fr-core-news-sm==3.3.0"]

0 commit comments

Comments
 (0)