|
42 | 42 | - [ ] Do not use os.path.join(); |
43 | 43 | always use pythainlp.tools.safe_path_join() instead, |
44 | 44 | to prevent path traversal vulnerabilities (CWE-22). |
45 | | -- [ ] Naming conventions: Follows PEP 8. |
| 45 | +- [ ] Naming conventions: Follows PEP 8. |
46 | 46 | Align new modules, classes, public APIs, and environment |
47 | | - variables with NLTK conventions as the primary standard. |
| 47 | + variables with NLTK conventions as the primary standard, |
| 48 | + provided they suit the component's behavior. |
48 | 49 | If NLTK offers no clear precedent, defer to established NLP |
49 | 50 | frameworks in the following order of preference: |
50 | | - spaCy, CoreNLP/Stanza, LangPipe, and Hugging Face, |
51 | | - Ensure the chosen name accurately reflects the nature and |
52 | | - behavior of the component. |
| 51 | + spaCy, CoreNLP/Stanza, LangPipe, and Hugging Face. |
| 52 | +- [ ] Noun number consistency: Maintain strict intentionality |
| 53 | + regarding singular vs. plural forms. Use singular names for |
| 54 | + classes representing a single entity and reserve plural |
| 55 | + names only for collections, utility modules, or clear aggregates. |
53 | 56 |
|
54 | 57 | ## Project contribution guidelines |
55 | 58 |
|
|
0 commit comments