dynamic-learning-model 3.3.3__tar.gz → 3.3.5__tar.gz

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,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dynamic-learning-model
3
- Version: 3.3.3
3
+ Version: 3.3.5
4
4
  Summary: A Dynamic Learning Model for processing NLP queries using hybrid AI and reasoning.
5
5
  Home-page: https://github.com/VigneshT24/Dynamic_Learning_Model
6
6
  Author: Vignesh Thondikulam
@@ -54,7 +54,7 @@ Whether you're building a student support bot, a domain-specific assistant, or a
54
54
  **REQUIRED PARAMETERS**:
55
55
  * The constructor requires passing in two parameters:
56
56
  - Bot Mode:
57
- - 'learn' = Enables training using the memory model. The bot can be updated with new information,
57
+ - 'learn' = Enables training using the memory model. The bot can be updated with new information
58
58
  - 'apply' = The bot automatically switches between its "compute" and "memory" model depending on the query asked
59
59
  - Empty SQL Database for training the bot with queries and for the memory model
60
60
  * The ask() method also requires passing in two parameters:
@@ -66,10 +66,9 @@ Whether you're building a student support bot, a domain-specific assistant, or a
66
66
  ```bash
67
67
  pip install dynamic-learning-model
68
68
  ```
69
- * ***Python 3.12 or higher is required to use this bot in your program***
69
+ * ***Python 3.12.0 is required to use this bot in your program.***
70
70
 
71
71
  ('learn' mode [training queries])
72
- * You can find the training password in the ```__trainingPwd``` variable defined within the DLM.py file
73
72
  ```python
74
73
  from dlm import DLM
75
74
 
@@ -22,7 +22,7 @@ Whether you're building a student support bot, a domain-specific assistant, or a
22
22
  **REQUIRED PARAMETERS**:
23
23
  * The constructor requires passing in two parameters:
24
24
  - Bot Mode:
25
- - 'learn' = Enables training using the memory model. The bot can be updated with new information,
25
+ - 'learn' = Enables training using the memory model. The bot can be updated with new information
26
26
  - 'apply' = The bot automatically switches between its "compute" and "memory" model depending on the query asked
27
27
  - Empty SQL Database for training the bot with queries and for the memory model
28
28
  * The ask() method also requires passing in two parameters:
@@ -34,10 +34,9 @@ Whether you're building a student support bot, a domain-specific assistant, or a
34
34
  ```bash
35
35
  pip install dynamic-learning-model
36
36
  ```
37
- * ***Python 3.12 or higher is required to use this bot in your program***
37
+ * ***Python 3.12.0 is required to use this bot in your program.***
38
38
 
39
39
  ('learn' mode [training queries])
40
- * You can find the training password in the ```__trainingPwd``` variable defined within the DLM.py file
41
40
  ```python
42
41
  from dlm import DLM
43
42
 
@@ -20,7 +20,6 @@ class DLM:
20
20
  __category = None # categorizes each question for efficient retrieval and basic NLG in SQL DB
21
21
  __nlp = None # Spacy NLP analysis
22
22
  __tone = None # sentimental tone of user query
23
- __trainingPwd = "371507" # password to enter training mode
24
23
  __mode = None # either "learn" or "apply"
25
24
  __unsure_while_thinking = False # if uncertain while thinking, then it will let the user know that
26
25
  __nlp_similarity_value = None # saves the similarity value by doing SpaCy calculation (for debugging)
@@ -394,40 +393,32 @@ class DLM:
394
393
  'learn' for training mode (to train the bot with queries).
395
394
  'apply' for trained model to choose "compute" or "memory" mode.
396
395
  Behavior:
397
- - If mode is 'learn', prompts for a password and displays mandatory training instructions.
398
- - If mode is 'apply', enters without prompting password and allows model to answer queries.
396
+ - If mode is 'learn', displays mandatory training instructions that must be understood.
397
+ - If mode is 'apply', allows model to answer queries using trained data and compute model.
399
398
  """
400
399
  if mode.lower() == "learn":
401
- password = input("Enter the password to enter Learn Mode: ")
402
- while password != self.__trainingPwd:
403
- password = input("Password is incorrect, try again or type 'stop' to enter in apply mode instead: ")
404
- if password.lower() == "stop":
405
- self.__mode = "apply"
406
- print("\n")
407
- break
408
- if password == self.__trainingPwd:
409
- # trainers must understand these rules as DLM can generate bad responses if these instructions are neglected
410
- print(
411
- f"\n\n{'\033[31m'}MAKE SURE TO UNDERSTAND THE FOLLOWING ANSWER FORMAT EXPECTED FOR EACH CATEGORY FOR THE BOT TO LEARN ACCURATELY:{'\033[0m'}\n")
412
- print("*'yesno': Make sure to start your answer responses with \"yes\" or \"no\" ONLY")
413
- print(
414
- "*'process': Each answer must have three steps for your responses, separated by \";\" (semicolon)")
415
- print(
416
- "*'definition': Make sure to not mention the WORD/PHRASE to be defined & always start your response here with \"the\" only")
417
- print("*'deadline': Only include the deadline date, as an example, \"March 31st 2025\"")
418
- print("*'location': Mention the location only, nothing else. For example, \"The FAFSA.Gov website\"")
419
- print("*'generic': Format doesn't matter for this, give your answer in any comprehensive format")
420
- print(
421
- "*'eligibility': Make sure to ONLY start the response with a pronoun like \"you\", \"they\", \"he\", \"she\", etc\n\n")
422
-
423
- confirmation = input(
424
- "Make sure to understand and note these instructions somewhere as the generated responses would get corrupt otherwise.\nType 'Y' if you understood: ")
425
- while confirmation.lower() != "y": # trainers must understand the instructions above
426
- confirmation = input("You cannot proceed to train without understanding the instructions aforementioned. Type 'Y' to continue: ")
427
- self.__mode = "learn"
428
- print("\n")
429
- self.__loading_animation("Logging in as Trainer", 0.6)
430
- print("\n")
400
+ # trainers must understand these rules as DLM can generate bad responses if these instructions are neglected
401
+ print(
402
+ f"\n\n{'\033[31m'}MAKE SURE TO UNDERSTAND THE FOLLOWING ANSWER FORMAT EXPECTED FOR EACH CATEGORY FOR THE BOT TO LEARN ACCURATELY:{'\033[0m'}\n")
403
+ print("*'yesno': Make sure to start your answer responses with \"yes\" or \"no\" ONLY")
404
+ print(
405
+ "*'process': Each answer must have three steps for your responses, separated by \";\" (semicolon)")
406
+ print(
407
+ "*'definition': Make sure to not mention the WORD/PHRASE to be defined & always start your response here with \"the\" only")
408
+ print("*'deadline': Only include the deadline date, as an example, \"March 31st 2025\"")
409
+ print("*'location': Mention the location only, nothing else. For example, \"The FAFSA.Gov website\"")
410
+ print("*'generic': Format doesn't matter for this, give your answer in any comprehensive format")
411
+ print(
412
+ "*'eligibility': Make sure to ONLY start the response with a pronoun like \"you\", \"they\", \"he\", \"she\", etc\n\n")
413
+
414
+ confirmation = input(
415
+ "Make sure to understand and note these instructions somewhere as the generated responses would get corrupt otherwise.\nType 'Y' if you understood: ")
416
+ while confirmation.lower() != "y": # trainers must understand the instructions above
417
+ confirmation = input("You cannot proceed to train without understanding the instructions aforementioned. Type 'Y' to continue: ")
418
+ self.__mode = "learn"
419
+ print("\n")
420
+ self.__loading_animation("Logging in as Trainer", 0.6)
421
+ print("\n")
431
422
  else:
432
423
  self.__mode = "apply"
433
424
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dynamic-learning-model
3
- Version: 3.3.3
3
+ Version: 3.3.5
4
4
  Summary: A Dynamic Learning Model for processing NLP queries using hybrid AI and reasoning.
5
5
  Home-page: https://github.com/VigneshT24/Dynamic_Learning_Model
6
6
  Author: Vignesh Thondikulam
@@ -54,7 +54,7 @@ Whether you're building a student support bot, a domain-specific assistant, or a
54
54
  **REQUIRED PARAMETERS**:
55
55
  * The constructor requires passing in two parameters:
56
56
  - Bot Mode:
57
- - 'learn' = Enables training using the memory model. The bot can be updated with new information,
57
+ - 'learn' = Enables training using the memory model. The bot can be updated with new information
58
58
  - 'apply' = The bot automatically switches between its "compute" and "memory" model depending on the query asked
59
59
  - Empty SQL Database for training the bot with queries and for the memory model
60
60
  * The ask() method also requires passing in two parameters:
@@ -66,10 +66,9 @@ Whether you're building a student support bot, a domain-specific assistant, or a
66
66
  ```bash
67
67
  pip install dynamic-learning-model
68
68
  ```
69
- * ***Python 3.12 or higher is required to use this bot in your program***
69
+ * ***Python 3.12.0 is required to use this bot in your program.***
70
70
 
71
71
  ('learn' mode [training queries])
72
- * You can find the training password in the ```__trainingPwd``` variable defined within the DLM.py file
73
72
  ```python
74
73
  from dlm import DLM
75
74
 
@@ -5,7 +5,7 @@ with open('README.md', 'r', encoding='utf-8') as f:
5
5
 
6
6
  setup(
7
7
  name='dynamic-learning-model',
8
- version='3.3.3',
8
+ version='3.3.5',
9
9
  author='Vignesh Thondikulam',
10
10
  author_email='vignesh.tho2006@gmail.com',
11
11
  description='A Dynamic Learning Model for processing NLP queries using hybrid AI and reasoning.',