reme-ai 0.1.2__py3-none-any.whl → 0.1.4__py3-none-any.whl

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,13 +1,13 @@
1
- reme_ai/__init__.py,sha256=OdYTFucC-LX33nnaShPPTUZIi4wA6qGLUKIzifKTllk,139
1
+ reme_ai/__init__.py,sha256=4I3Q01LVJIHiSz1mgQko-2xpIt-FSaMB0DNHgyOG6vk,139
2
2
  reme_ai/app.py,sha256=h73ttERKpId5O80wKiAvDmYKjnGqbMAq-vc1aHkcXAU,314
3
3
  reme_ai/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
4
  reme_ai/config/config_parser.py,sha256=gk9bsMNnAlLLjChdalHWHgpOazyvZh5bItTUZcIGqbU,189
5
- reme_ai/config/default.yaml,sha256=g9t4Obs_jCdLkqEYUhsguhuiQXtN4_j0DpJhnY7PWMw,5300
5
+ reme_ai/config/default.yaml,sha256=pWlIH4o6BrNqF0fz6oyansftAn926mz_QPiQ2A817Rg,5593
6
6
  reme_ai/constants/__init__.py,sha256=HdNweT3fTmdsCfoyTVKpBIPF9EELepLVNCrpKpJymY4,128
7
- reme_ai/constants/common_constants.py,sha256=9xj995uCL-upn3qys1Manl6N4dQnOctuSqjqMTebers,1083
8
- reme_ai/constants/language_constants.py,sha256=7RehdVTVVt4QpeXobeRn7nuuUv6j4APsGlDe55VHovs,4764
7
+ reme_ai/constants/common_constants.py,sha256=0JuJS8y--bdQ9Knx2f8f0bnNaWTBFLLMYYp2xhathjc,1038
8
+ reme_ai/constants/language_constants.py,sha256=bCNJJ8by5aNIaClDT6q2WqF7Xia6pXdHSMEK8DKLtfA,4754
9
9
  reme_ai/enumeration/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
10
- reme_ai/enumeration/language_constants.py,sha256=7RehdVTVVt4QpeXobeRn7nuuUv6j4APsGlDe55VHovs,4764
10
+ reme_ai/enumeration/language_enum.py,sha256=zaWc0L1Etb4r3QcfNvVrkX6hwYNAHUms962PlUKLtas,261
11
11
  reme_ai/react/__init__.py,sha256=-EEF7Moo56-R6O2CoWMbkXz12l8tsbpMht5vSUdRnbU,43
12
12
  reme_ai/react/simple_react_op.py,sha256=kJWR7ZC2E_SxuqFIinULcaSnZis2AXEWW2PYROYS5G4,645
13
13
  reme_ai/retrieve/__init__.py,sha256=K3qulFpRGZU_UsyYjIouR1F2CXwDBf9NkGiqYmIU2hQ,42
@@ -48,7 +48,7 @@ reme_ai/summary/personal/long_contra_repeat_op.py,sha256=WGoWPl4rJDpOsw00RHf3Isc
48
48
  reme_ai/summary/personal/long_contra_repeat_prompt.yaml,sha256=6q3Y4xZx3liZwXLcJsOgeCIQZzAE2PwqVNQCFMNAWsI,7516
49
49
  reme_ai/summary/personal/update_insight_op.py,sha256=_OY6s9rXBpHxdy_kB8gh2howoIyLkNRuYf9SNO176xA,10994
50
50
  reme_ai/summary/personal/update_insight_prompt.yaml,sha256=02EPEC5vQGTEYOfHeq29GUEhlWxdLAcMnaj6jOgeI8c,10295
51
- reme_ai/summary/task/__init__.py,sha256=Giqlc9LIZr89uPCwhvUYPkHE0o8lBnZ-4DLAzrpBrEQ,583
51
+ reme_ai/summary/task/__init__.py,sha256=GApTaFsmX7q-NbGtk5cTfx23cf-X-DBt-RORy0UMcvI,528
52
52
  reme_ai/summary/task/comparative_extraction_op.py,sha256=o3Zb-hsIaEioSP7TtLcXGCEXxktzY6GqgY2qhnzUsz0,10655
53
53
  reme_ai/summary/task/comparative_extraction_prompt.yaml,sha256=EgsveH1fHcXle5sHDqyxZ_KxTfTUn2IGbkZ0KjZRl1I,3331
54
54
  reme_ai/summary/task/failure_extraction_op.py,sha256=_BNoe-Am9GxyBXW49JQjZnPSEJ1wPKCanAot2hANE-Y,3042
@@ -56,19 +56,17 @@ reme_ai/summary/task/failure_extraction_prompt.yaml,sha256=kWz55BRxtEd_CjoaKWliC
56
56
  reme_ai/summary/task/memory_deduplication_op.py,sha256=_HRxafjH_JbsgGIIPxanb-yxHjsGOOnXSJlzubOdYGE,6838
57
57
  reme_ai/summary/task/memory_validation_op.py,sha256=fZBIN9_n4UjYzw_E4copmIwctgFfxUwqtFiaspTdDFY,4362
58
58
  reme_ai/summary/task/memory_validation_prompt.yaml,sha256=CwqT76ktjnkCXcZFEe0XtvJPkhZTpt32_N--A0gH3k0,1230
59
- reme_ai/summary/task/pdf_preprocess_op_wrapper.py,sha256=RcS-qkjJpOPeFQTcqyX2h2aH1QURVs8silD60eF0NlE,1841
60
59
  reme_ai/summary/task/simple_comparative_summary_op.py,sha256=8_4W6Apjt19LJWp0kuvyHi7La1rAduJ5-oiCsnr0YoU,3436
61
60
  reme_ai/summary/task/simple_comparative_summary_prompt.yaml,sha256=FGGj-jE8SvgEDEJAiq33ptB_-pI2qmBulsLDQyy8_bM,1140
62
61
  reme_ai/summary/task/simple_summary_op.py,sha256=O070MuSZlsJQKj1jYkIqsi5RES_kORp9o7mnwbFkTM8,2975
63
62
  reme_ai/summary/task/simple_summary_prompt.yaml,sha256=o0JbPBtGqKJ6_GIDhI_wGdBOSOy74bpaehLAKqtBYco,943
64
63
  reme_ai/summary/task/success_extraction_op.py,sha256=H-WxIadbAFg7FueC31VoxY-Ydc99F4TXfdT-3RGWRSw,3037
65
64
  reme_ai/summary/task/success_extraction_prompt.yaml,sha256=rr_5sm9j2r_Ea5JgBBPG-yCnFMmCdTi391rqWovqraw,1527
66
- reme_ai/summary/task/trajectory_preprocess_op.py,sha256=fUYNZLTv6hfzDpYVgHZtayLuWAYJKmk9aKyLZn5PMBM,2886
65
+ reme_ai/summary/task/trajectory_preprocess_op.py,sha256=OXrH36Y_vKWCIfhHAQ8VCpwH9f8iYfx6aIkH63kw1vM,1710
67
66
  reme_ai/summary/task/trajectory_segmentation_op.py,sha256=QpYsvG5UAKcetDpWTZHqmU-9PcXXcB8nid1r_kUd6sU,4626
68
67
  reme_ai/summary/task/trajectory_segmentation_prompt.yaml,sha256=8E5nDQn9x7DHC6P1dsF3l_bd8UITla9AyfmSLoyFLpM,1193
69
68
  reme_ai/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
70
- reme_ai/utils/datetime_handler.py,sha256=ul3igS4tKIqzLykhHBcum4bapjTqd4hhIdi6CPOWQZk,14453
71
- reme_ai/utils/miner_u_pdf_processor.py,sha256=wYcKmNxFNwOMmDyO790G3uqBsFtZgHy65VZE2pM9A10,28956
69
+ reme_ai/utils/datetime_handler.py,sha256=mTf-c7Ko7crrTzh1hU5v-A7Hbg_8gQRCeN2c-aoP3Tw,14451
72
70
  reme_ai/utils/op_utils.py,sha256=tYsAl5LcQKe0I7YyEe8VXjrjJGVZ7Q_oD28qorJsCB0,4175
73
71
  reme_ai/vector_store/__init__.py,sha256=1Yh14F5UZirKHxM7cgWiATpoZUqWGo147KlJK_wD03Q,327
74
72
  reme_ai/vector_store/delete_memory_op.py,sha256=0suPyTSbJ_y04J_FhbgKMNXAUf1Wq_4sAobtVmxUKX0,905
@@ -77,9 +75,9 @@ reme_ai/vector_store/update_memory_freq_op.py,sha256=LTkIp9oEieFt-zmlJ_QxH2dBaOr
77
75
  reme_ai/vector_store/update_memory_utility_op.py,sha256=d49os4sG_pd7bXwlGSCGytlbcguU5ZFgAmJrxHDJapA,1013
78
76
  reme_ai/vector_store/update_vector_store_op.py,sha256=nSw_i0bOfhzLbM200tyqygiETPqKQe4ZT3IguSwKYh0,1297
79
77
  reme_ai/vector_store/vector_store_action_op.py,sha256=wiWNHAG6XtrEUCXt76B2KZvNS_i0P8BF53hLrZR0IbQ,2231
80
- reme_ai-0.1.2.dist-info/licenses/LICENSE,sha256=zFTWearO11HAlvEgtmY1XBBtk5TSj5P23zU5c_bNfb4,11343
81
- reme_ai-0.1.2.dist-info/METADATA,sha256=hRtuLBPu-NxBlIzkCuDwOGSHW8yl1T2bTcoUOFuTmbc,13381
82
- reme_ai-0.1.2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
83
- reme_ai-0.1.2.dist-info/entry_points.txt,sha256=6SP3ncXOMyKotdT4LHWPeaXo3-Sv-1qmK7OhVw76Xhw,42
84
- reme_ai-0.1.2.dist-info/top_level.txt,sha256=3ca2UBk97aSfPmGdg8LlVqyeLikb5qEnBEbfGgtzao0,8
85
- reme_ai-0.1.2.dist-info/RECORD,,
78
+ reme_ai-0.1.4.dist-info/licenses/LICENSE,sha256=zFTWearO11HAlvEgtmY1XBBtk5TSj5P23zU5c_bNfb4,11343
79
+ reme_ai-0.1.4.dist-info/METADATA,sha256=JkvAqnZEk2_a3F5rxmlscVyE-1rBavkgfVve4Woyvyc,27087
80
+ reme_ai-0.1.4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
81
+ reme_ai-0.1.4.dist-info/entry_points.txt,sha256=6SP3ncXOMyKotdT4LHWPeaXo3-Sv-1qmK7OhVw76Xhw,42
82
+ reme_ai-0.1.4.dist-info/top_level.txt,sha256=3ca2UBk97aSfPmGdg8LlVqyeLikb5qEnBEbfGgtzao0,8
83
+ reme_ai-0.1.4.dist-info/RECORD,,
@@ -1,215 +0,0 @@
1
- from memoryscope.enumeration.language_enum import LanguageEnum
2
-
3
- # This dictionary maps languages to lists of words related to datetime expressions.
4
- # It aids in recognizing and processing datetime mentions in text, enhancing the system's ability to understand
5
- # temporal context across different languages.
6
- DATATIME_WORD_LIST = {
7
- LanguageEnum.CN: [
8
- "天",
9
- "周",
10
- "月",
11
- "年",
12
- "星期",
13
- "点",
14
- "分钟",
15
- "小时",
16
- "秒",
17
- "上午",
18
- "下午",
19
- "早上",
20
- "早晨",
21
- "晚上",
22
- "中午",
23
- "日",
24
- "夜",
25
- "清晨",
26
- "傍晚",
27
- "凌晨",
28
- "岁",
29
- ],
30
- LanguageEnum.EN: [
31
- # Units of Time
32
- "year", "yr",
33
- "month", "mo",
34
- "week", "wk",
35
- "day", "d",
36
- "hour", "hr",
37
- "minute", "min",
38
- "second", "sec",
39
-
40
- # Days of the Week
41
- "Monday", "Mon",
42
- "Tuesday", "Tue", "Tues",
43
- "Wednesday", "Wed",
44
- "Thursday", "Thu", "Thur", "Thurs",
45
- "Friday", "Fri",
46
- "Saturday", "Sat",
47
- "Sunday", "Sun",
48
-
49
- # Months of the Year
50
- "January", "Jan",
51
- "February", "Feb",
52
- "March", "Mar",
53
- "April", "Apr",
54
- "May", "May",
55
- "June", "Jun",
56
- "July", "Jul",
57
- "August", "Aug",
58
- "September", "Sep", "Sept",
59
- "October", "Oct",
60
- "November", "Nov",
61
- "December", "Dec",
62
-
63
- # Relative Time References
64
- "Today",
65
- "Tomorrow", "Tmrw",
66
- "Yesterday", "Yday",
67
- "Now",
68
- "Morning", "AM", "a.m.",
69
- "Afternoon", "PM", "p.m.",
70
- "Evening",
71
- "Night",
72
- "Midnight",
73
- "Noon",
74
-
75
- # Seasonal References
76
- "Spring",
77
- "Summer",
78
- "Autumn", "Fall",
79
- "Winter",
80
-
81
- # General Time References
82
- "Century", "cent.",
83
- "Decade",
84
- "Millennium",
85
- "Quarter", "Q1", "Q2", "Q3", "Q4",
86
- "Semester",
87
- "Fortnight",
88
- "Weekend"
89
- ]
90
- }
91
-
92
- # A mapping of weekdays for each supported language, facilitating calendar-related operations and understanding
93
- # within the application.
94
- WEEKDAYS = {
95
- LanguageEnum.CN: [
96
- "周一",
97
- "周二",
98
- "周三",
99
- "周四",
100
- "周五",
101
- "周六",
102
- "周日"
103
- ],
104
- LanguageEnum.EN: [
105
- "Monday",
106
- "Tuesday",
107
- "Wednesday",
108
- "Thursday",
109
- "Friday",
110
- "Saturday",
111
- "Sunday",
112
- ]
113
- }
114
-
115
- MONTH_DICT = {
116
- LanguageEnum.CN: [
117
- "1月",
118
- "2月",
119
- "3月",
120
- "4月",
121
- "5月",
122
- "6月",
123
- "7月",
124
- "8月",
125
- "9月",
126
- "10月",
127
- "11月",
128
- "12月",
129
- ],
130
- LanguageEnum.EN: [
131
- "January",
132
- "February",
133
- "March",
134
- "April",
135
- "May",
136
- "June",
137
- "July",
138
- "August",
139
- "September",
140
- "October",
141
- "November",
142
- "December",
143
- ]
144
- }
145
-
146
- # Constants for the word 'none' in different languages
147
- NONE_WORD = {
148
- LanguageEnum.CN: "无",
149
- LanguageEnum.EN: "none"
150
- }
151
-
152
- # Constants for the word 'repeated' in different languages
153
- REPEATED_WORD = {
154
- LanguageEnum.CN: "重复",
155
- LanguageEnum.EN: "repeated"
156
- }
157
-
158
- # Constants for the word 'contradictory' in different languages
159
- CONTRADICTORY_WORD = {
160
- LanguageEnum.CN: "矛盾",
161
- LanguageEnum.EN: "contradiction"
162
- }
163
-
164
- # Constants for the phrase 'included' in different languages
165
- CONTAINED_WORD = {
166
- LanguageEnum.CN: "被包含",
167
- LanguageEnum.EN: "contained"
168
- }
169
-
170
- # Constants for the symbol ':' in different languages' representations
171
- COLON_WORD = {
172
- LanguageEnum.CN: ":",
173
- LanguageEnum.EN: ":"
174
- }
175
-
176
- # Constants for the symbol ',' in different languages' representations
177
- COMMA_WORD = {
178
- LanguageEnum.CN: ",",
179
- LanguageEnum.EN: ","
180
- }
181
-
182
- # Default human name placeholders for different languages
183
- DEFAULT_HUMAN_NAME = {
184
- LanguageEnum.CN: "用户",
185
- LanguageEnum.EN: "user"
186
- }
187
-
188
- # Mapping of datetime terms from natural language to standardized keys for each supported language
189
- DATATIME_KEY_MAP = {
190
- LanguageEnum.CN: {
191
- "年": "year",
192
- "月": "month",
193
- "日": "day",
194
- "周": "week",
195
- "星期几": "weekday",
196
- },
197
- LanguageEnum.EN: {
198
- "Year": "year",
199
- "Month": "month",
200
- "Day": "day",
201
- "Week": "week",
202
- "Weekday": "weekday",
203
- }
204
- }
205
-
206
- # Phrase for indicating inferred time in different languages
207
- TIME_INFER_WORD = {
208
- LanguageEnum.CN: "推断时间",
209
- LanguageEnum.EN: "Inference time"
210
- }
211
-
212
- USER_NAME_EXPRESSION = {
213
- LanguageEnum.CN: "用户姓名是{name}。",
214
- LanguageEnum.EN: "User's name is {name}."
215
- }
@@ -1,50 +0,0 @@
1
- from flowllm import C, BaseOp
2
- from loguru import logger
3
-
4
- from reme_ai.utils.miner_u_pdf_processor import MinerUPDFProcessor, chunk_pdf_content
5
-
6
-
7
- @C.register_op()
8
- class PDFPreprocessOp(BaseOp):
9
- file_path: str = __file__
10
-
11
- def execute(self):
12
- """Process PDF files using MinerU and chunk content"""
13
- pdf_path = self.context.get("pdf_path")
14
- output_dir = self.context.get("output_dir")
15
-
16
- if not pdf_path:
17
- logger.error("No PDF path provided in context")
18
- return
19
-
20
- # Process PDF
21
- processor = MinerUPDFProcessor(log_level="INFO")
22
-
23
- try:
24
- content_list, markdown_content = processor.process_pdf(
25
- pdf_path=pdf_path,
26
- output_dir=output_dir,
27
- method=self.op_params.get("method", "auto"),
28
- lang=self.op_params.get("lang"),
29
- backend=self.op_params.get("backend", "pipeline")
30
- )
31
-
32
- # Create chunks if requested
33
- chunks = []
34
- if self.op_params.get("create_chunks", True):
35
- max_length = self.op_params.get("max_chunk_length", 4000)
36
- chunks = chunk_pdf_content(content_list, max_length=max_length)
37
-
38
- # Store results in context
39
- self.context.pdf_content_list = content_list
40
- self.context.pdf_markdown_content = markdown_content
41
- self.context.pdf_chunks = chunks
42
-
43
- logger.info(f"PDF processing completed: {len(content_list)} content blocks, "
44
- f"{len(chunks)} chunks, {len(markdown_content)} characters of markdown")
45
-
46
- except Exception as e:
47
- logger.error(f"PDF processing failed: {e}")
48
- self.context.pdf_content_list = []
49
- self.context.pdf_markdown_content = ""
50
- self.context.pdf_chunks = []