Skip to content

Commit 7f96e83

Browse files
feat: Rename company 👽
1 parent 4baa177 commit 7f96e83

11 files changed

Lines changed: 72 additions & 46 deletions

File tree

RELEASES.md

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,50 @@
1-
<img src="https://raw.githubusercontent.com/neural7/five-factor-e/main/doc/neural7.png" align="right" width="80" height="70"/>
1+
<img src="https://raw.githubusercontent.com/rewire5-io/five-factor-e/main/doc/rewire5-io.png" align="right" width="80" height="70"/>
22

33
### Releases 🎈
44

5-
Release **[1.8.0](https://github.com/neural7/five-factor-e/releases/tag/v1.8.0)**:
5+
Release **[1.9.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.9.0)**:
66

77
* Leaving the json format more Pythonic;
88
* Revised README files.
99

10-
Release **[1.7.0](https://github.com/neural7/five-factor-e/releases/tag/v1.7.0)**:
10+
Release **[1.8.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.8.0)**:
11+
12+
* Leaving the json format more Pythonic;
13+
* Revised README files.
14+
15+
Release **[1.7.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.7.0)**:
1116

1217
* Leaving the age range between 10 to 110 years;
1318
* Revised README files.
1419

15-
Release **[1.6.0](https://github.com/neural7/five-factor-e/releases/tag/v1.6.0)**:
20+
Release **[1.6.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.6.0)**:
1621

1722
* Added to the return with the big-five averages: (low, average, high);
1823
* Refactoring of the reverse scored questions code;
1924
* Added to the quiz program, the verification of the translation of the questions (120 or 300);
2025
* Added new topics to PyPI setup.
2126

22-
Release **[1.5.0](https://github.com/neural7/five-factor-e/releases/tag/v1.5.0)**:
27+
Release **[1.5.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.5.0)**:
2328

2429
* Added support for original IPIP version with 300 items;
2530
* Refactoring of the program for testing the questions (quiz);
2631
* Added support for simulate question with reversed score;
2732
* Revised README files.
2833

29-
Release **[1.4.0](https://github.com/neural7/five-factor-e/releases/tag/v1.4.0)**:
34+
Release **[1.4.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.4.0)**:
3035

3136
* Adding language support Portuguese Brazil (pt-br) and Spain (es-es).
3237

33-
Release **[1.3.0](https://github.com/neural7/five-factor-e/releases/tag/v1.3.0)**::
38+
Release **[1.3.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.3.0)**::
3439

3540
* Fix of the normalization calculation of norms;
3641
* Fix of answers that have inversion, different weights.
3742

38-
Release **[1.2.0](https://github.com/neural7/five-factor-e/releases/tag/v1.2.0)**:
43+
Release **[1.2.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.2.0)**:
3944

4045
* Adding inventory tests (quiz).
4146

42-
Release **[1.1.0](https://github.com/neural7/five-factor-e/releases/tag/v1.1.0)**:
47+
Release **[1.1.0](https://github.com/rewire5-io/five-factor-e/releases/tag/v1.1.0)**:
4348

4449
* Initial version of IPIP-NEO;
4550
* Adding license information.

data/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
<img src="https://raw.githubusercontent.com/neural7/five-factor-e/main/doc/neural7.png" align="right" width="80" height="70"/>
1+
<img src="https://raw.githubusercontent.com/rewire5-io/five-factor-e/main/doc/rewire5.png" align="right" width="80" height="70"/>
22

33
### About data 📊
44

55
The data directory contains the artifacts used for the [IPIP-NEO](https://ipip.ori.org/) used by this library, in the short version with **120** items and the long version with **300** items.
66

7-
If you are thinking of using this library in your project, you should follow the standard question and answer files proposed in examples [120](https://github.com/neural7/five-factor-e/blob/main/data/IPIP-NEO/120/answers.json) and [300](https://github.com/neural7/five-factor-e/blob/main/data/IPIP-NEO/300/answers.json).
7+
If you are thinking of using this library in your project, you should follow the standard question and answer files proposed in examples [120](https://github.com/rewire5-io/five-factor-e/blob/main/data/IPIP-NEO/120/answers.json) and [300](https://github.com/rewire5-io/five-factor-e/blob/main/data/IPIP-NEO/300/answers.json).
88

9-
The translations of the questions are in the [translation](https://github.com/neural7/five-factor-e/tree/main/data/IPIP-NEO/120/translation) folder, as the translations happen, we will attach them to this directory. If you want to send a translation that is not in the repository, feel free to contribute with us following the [json file pattern](https://github.com/neural7/five-factor-e/blob/main/data/IPIP-NEO/120/translation/questions-en-us.json).
9+
The translations of the questions are in the [translation](https://github.com/rewire5-io/five-factor-e/tree/main/data/IPIP-NEO/120/translation) folder, as the translations happen, we will attach them to this directory. If you want to send a translation that is not in the repository, feel free to contribute with us following the [json file pattern](https://github.com/rewire5-io/five-factor-e/blob/main/data/IPIP-NEO/120/translation/questions-en-us.json).
1010

1111
### Experiments with reverse scoring questions ⚡
1212

13-
If you want to test and experiment with questions with the reverse order, you need to use the [example json file](https://github.com/neural7/five-factor-e/blob/main/data/IPIP-NEO/120/test/answers-1.json). Answers that have the key (reverse_scored = *1*) will have the reverse score ie: The value selected was *5*, it will be turned into *1*. You can read more about it here:
13+
If you want to test and experiment with questions with the reverse order, you need to use the [example json file](https://github.com/rewire5-io/five-factor-e/blob/main/data/IPIP-NEO/120/test/answers-1.json). Answers that have the key (reverse_scored = *1*) will have the reverse score ie: The value selected was *5*, it will be turned into *1*. You can read more about it here:
1414

1515
* [https://ipip.ori.org/newScoringInstructions.htm](https://ipip.ori.org/newScoringInstructions.htm)
1616
* [https://ipip.ori.org/newMultipleconstructs.htm](https://ipip.ori.org/newMultipleconstructs.htm)
@@ -50,6 +50,6 @@ from ipipneo import IpipNeo
5050
IpipNeo(question=120, test=True).compute(sex="M", age=40, answers=answers120, compare=True)
5151
```
5252

53-
If you have any questions, please send us an email to: (**e at neural.io**) or create an issue reporting the question of the problem in the repository of this project (https://github.com/neural7/five-factor-e/issues).
53+
If you have any questions, please send us an email to: (**e at neural.io**) or create an issue reporting the question of the problem in the repository of this project (https://github.com/rewire5-io/five-factor-e/issues).
5454

5555
Thanks!

ipipneo/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
"""Import of the classes to be used."""
22

33
__name__ = "five-factor-e"
4-
__version__ = "1.8.0"
4+
__version__ = "1.9.0"
55

66
from ipipneo.ipipneo import IpipNeo

ipipneo/facet.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
"""Creation and scoring of the facets that make up the Big-Five."""
22

33
__author__ = "Ederson Corbari"
4-
__email__ = "e@neural7.io"
5-
__copyright__ = "Copyright Neural7 2022, Big 5 Personality Traits"
4+
__email__ = "e@rewire5.io"
5+
__copyright__ = "Copyright ReWire5 2022-2023, Big 5 Personality Traits"
66
__credits__ = ["John A. Johnson", "Dhiru Kholia"]
77
__license__ = "MIT"
8-
__version__ = "1.8.0"
8+
__version__ = "1.9.0"
99
__status__ = "production"
1010

1111
from enum import IntEnum

ipipneo/ipipneo.py

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
"""It does the calculations to generate the IPIP-NEO results based on the questions and answers."""
22

33
__author__ = "Ederson Corbari"
4-
__email__ = "e@neural7.io"
5-
__copyright__ = "Copyright Neural7 2022, Big 5 Personality Traits"
4+
__email__ = "e@rewire5.io"
5+
__copyright__ = "Copyright ReWire5 2022-2023, Big 5 Personality Traits"
66
__credits__ = ["John A. Johnson", "Dhiru Kholia"]
77
__license__ = "MIT"
8-
__version__ = "1.8.0"
8+
__version__ = "1.9.0"
99
__status__ = "production"
1010

1111
import copy
@@ -19,6 +19,7 @@
1919
organize_list_json,
2020
raise_if_age_is_invalid,
2121
raise_if_sex_is_invalid,
22+
add_dict_footer,
2223
)
2324

2425

@@ -58,7 +59,9 @@ def evaluator(self, sex: str, age: int, score: list) -> dict:
5859
normc = Norm.calc(domain=self.domain(score=score), norm=norm)
5960
assert isinstance(normc, dict), "normc must be a dict"
6061

61-
distrib = self.distrib(size=len(score), b5=self.b5create(score=score), norm=norm)
62+
distrib = self.distrib(
63+
size=len(score), b5=self.b5create(score=score), norm=norm
64+
)
6265
assert isinstance(distrib, dict), "distrib must be a dict"
6366

6467
normalize = Norm.normalize(normc=normc, percent=Norm.percent(normc=normc))
@@ -79,10 +82,9 @@ def evaluator(self, sex: str, age: int, score: list) -> dict:
7982
return {
8083
"id": str(uuid.uuid4()),
8184
"theory": "Big 5 Personality Traits",
82-
"model": "IPIP-NEO",
85+
"model": "IPIP-NEO" if self._nquestion == 120 else "IPIP",
8386
"question": self._nquestion,
8487
"test": self._test,
85-
"version": __version__,
8688
"person": {
8789
"sex": sex,
8890
"age": age,
@@ -96,6 +98,7 @@ def evaluator(self, sex: str, age: int, score: list) -> dict:
9698
]
9799
},
98100
},
101+
**add_dict_footer(),
99102
}
100103

101104
def compute(self, sex: str, age: int, answers: dict, compare: bool = False) -> dict:
@@ -120,7 +123,9 @@ def compute(self, sex: str, age: int, answers: dict, compare: bool = False) -> d
120123
reversed = ReverseScoredCustom(answers=answers)
121124
else:
122125
reversed = (
123-
ReverseScored120(answers=answers) if self._nquestion == 120 else ReverseScored300(answers=answers)
126+
ReverseScored120(answers=answers)
127+
if self._nquestion == 120
128+
else ReverseScored300(answers=answers)
124129
)
125130
assert isinstance(reversed, dict), "reversed must be a dict"
126131

ipipneo/model.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
"""Auxiliary constants that are used in the library."""
22

33
__author__ = "Ederson Corbari"
4-
__email__ = "e@neural7.io"
5-
__copyright__ = "Copyright Neural7 2022, Big 5 Personality Traits"
4+
__email__ = "e@rewire5.io"
5+
__copyright__ = "Copyright ReWire5 2022-2023, Big 5 Personality Traits"
66
__credits__ = ["John A. Johnson", "Dhiru Kholia"]
77
__license__ = "MIT"
8-
__version__ = "1.8.0"
8+
__version__ = "1.9.0"
99
__status__ = "production"
1010

1111
from enum import Enum, IntEnum

ipipneo/norm.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
"""The standard with the rules of IPIP-NEO norms."""
22

33
__author__ = "Ederson Corbari"
4-
__email__ = "e@neural7.io"
5-
__copyright__ = "Copyright Neural7 2022, Big 5 Personality Traits"
4+
__email__ = "e@rewire5.io"
5+
__copyright__ = "Copyright ReWire5 2022-2023, Big 5 Personality Traits"
66
__credits__ = ["John A. Johnson", "Dhiru Kholia"]
77
__license__ = "MIT"
8-
__version__ = "1.8.0"
8+
__version__ = "1.9.0"
99
__status__ = "production"
1010

1111
from enum import IntEnum

ipipneo/quiz.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
"""We use this for testing."""
22

33
__author__ = "Ederson Corbari"
4-
__email__ = "e@neural7.io"
5-
__copyright__ = "Copyright Neural7 2022, Big 5 Personality Traits"
4+
__email__ = "e@rewire5.io"
5+
__copyright__ = "Copyright ReWire5 2022-2023, Big 5 Personality Traits"
66
__credits__ = ["John A. Johnson", "Dhiru Kholia"]
77
__license__ = "MIT"
8-
__version__ = "1.8.0"
8+
__version__ = "1.9.0"
99
__status__ = "production"
1010

1111
import json

ipipneo/reverse.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
"""Reverses scores for certain questions from the IPIP-120, IPIP-300 and Custom Items."""
22

33
__author__ = "Ederson Corbari"
4-
__email__ = "e@neural7.io"
5-
__copyright__ = "Copyright Neural7 2022, Big 5 Personality Traits"
4+
__email__ = "e@rewire5.io"
5+
__copyright__ = "Copyright ReWire5 2022-2023, Big 5 Personality Traits"
66
__credits__ = ["John A. Johnson", "Dhiru Kholia"]
77
__license__ = "MIT"
8-
__version__ = "1.8.0"
8+
__version__ = "1.9.0"
99
__status__ = "production"
1010

1111
from ipipneo.utility import reverse_scored

ipipneo/utility.py

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
"""Contains utility functions used in the library."""
22

33
__author__ = "Ederson Corbari"
4-
__email__ = "e@neural7.io"
5-
__copyright__ = "Copyright Neural7 2022, Big 5 Personality Traits"
4+
__email__ = "e@rewire5.io"
5+
__copyright__ = "Copyright ReWire5 2022-2023, Big 5 Personality Traits"
66
__credits__ = ["John A. Johnson", "Dhiru Kholia"]
77
__license__ = "MIT"
8-
__version__ = "1.8.0"
8+
__version__ = "1.9.0"
99
__status__ = "production"
1010

11+
from datetime import datetime
1112
from enum import Enum
1213

1314
from ipipneo.model import (
@@ -48,7 +49,9 @@ def raise_if_age_is_invalid(age: int) -> bool or AssertionError or BaseException
4849

4950
min, max = (10, 110)
5051
if not (min <= age <= max):
51-
raise AssertionError("The age (%r) must be between %r and %r!" % (age, min, max))
52+
raise AssertionError(
53+
"The age (%r) must be between %r and %r!" % (age, min, max)
54+
)
5255

5356
return True
5457

@@ -71,7 +74,9 @@ def answers_is_valid(answers: list) -> bool or AssertionError or BaseException:
7174
if 1 in [1 if x > 5 else 0 for x in answers]:
7275
raise BaseException("You cannot have answers with a number greater than 5!")
7376

74-
assert len(answers) == 120 or len(answers) == 300, "The (answers) field should be of size 120 or 300!"
77+
assert (
78+
len(answers) == 120 or len(answers) == 300
79+
), "The (answers) field should be of size 120 or 300!"
7580

7681
return True
7782

@@ -96,7 +101,9 @@ def organize_list_json(answers: dict) -> list or AssertionError or BaseException
96101

97102
return [
98103
x["id_select"]
99-
for x in sorted([x for x in answers.get("answers", [])], key=lambda x: x["id_question"])
104+
for x in sorted(
105+
[x for x in answers.get("answers", [])], key=lambda x: x["id_question"]
106+
)
100107
if x["id_select"] >= 1
101108
]
102109

@@ -206,3 +213,11 @@ def create_big5_dict(label: str, big5: float, x: list, y: list) -> dict:
206213
},
207214
],
208215
}
216+
217+
218+
def add_dict_footer() -> dict:
219+
return {
220+
"library": "five-factor-e",
221+
"version": __version__,
222+
"date": datetime.now().strftime("%Y-%m-%d %H:%M:%S"),
223+
}

0 commit comments

Comments
 (0)