ragflow-cli-myfbee-test 0.27.2.dev0__tar.gz → 0.27.2.dev2__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.
Files changed (15) hide show
  1. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/PKG-INFO +1 -1
  2. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/parser.py +0 -14
  3. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/pyproject.toml +2 -1
  4. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_cli_myfbee_test.egg-info/PKG-INFO +1 -1
  5. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_client.py +0 -44
  6. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/README.md +0 -0
  7. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/http_client.py +0 -0
  8. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_cli.py +0 -0
  9. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_cli_myfbee_test.egg-info/SOURCES.txt +0 -0
  10. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_cli_myfbee_test.egg-info/dependency_links.txt +0 -0
  11. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_cli_myfbee_test.egg-info/entry_points.txt +0 -0
  12. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_cli_myfbee_test.egg-info/requires.txt +0 -0
  13. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/ragflow_cli_myfbee_test.egg-info/top_level.txt +0 -0
  14. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/setup.cfg +0 -0
  15. {ragflow_cli_myfbee_test-0.27.2.dev0 → ragflow_cli_myfbee_test-0.27.2.dev2}/user.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ragflow-cli-myfbee-test
3
- Version: 0.27.2.dev0
3
+ Version: 0.27.2.dev2
4
4
  Summary: Admin Service's client of [RAGFlow](https://github.com/infiniflow/ragflow). The Admin Service provides user management and system monitoring.
5
5
  Author-email: Lynn <lynn_inf@hotmail.com>
6
6
  License: Apache License, Version 2.0
@@ -97,8 +97,6 @@ sql_command: login_user
97
97
  | search_on_datasets
98
98
  | get_chunk
99
99
  | list_chunks
100
- | insert_dataset_from_file
101
- | insert_metadata_from_file
102
100
  | update_chunk
103
101
  | set_metadata
104
102
  | remove_tags
@@ -223,11 +221,9 @@ TABLE: "TABLE"i
223
221
  CHUNK: "CHUNK"i
224
222
  CHUNKS: "CHUNKS"i
225
223
  GET: "GET"i
226
- INSERT: "INSERT"i
227
224
  PAGE: "PAGE"i
228
225
  KEYWORDS: "KEYWORDS"i
229
226
  AVAILABLE: "AVAILABLE"i
230
- FILE: "FILE"i
231
227
  UPDATE: "UPDATE"i
232
228
  REMOVE: "REMOVE"i
233
229
  TAGS: "TAGS"i
@@ -377,8 +373,6 @@ create_dataset_table: CREATE DATASET TABLE quoted_string VECTOR SIZE NUMBER ";"
377
373
  drop_dataset_table: DROP DATASET TABLE quoted_string ";"
378
374
  create_metadata_table: CREATE METADATA TABLE ";"
379
375
  drop_metadata_table: DROP METADATA TABLE ";"
380
- insert_dataset_from_file: INSERT DATASET FROM FILE quoted_string ";"
381
- insert_metadata_from_file: INSERT METADATA FROM FILE quoted_string ";"
382
376
  generate_nav_for_dataset: GENERATE NAVIGATION OF DATASET quoted_string ";"
383
377
  navigation_search: NAVIGATION SEARCH quoted_string IN DATASET quoted_string MODE quoted_string (TOPK NUMBER)? ";"
384
378
  update_chunk: UPDATE CHUNK quoted_string OF DATASET quoted_string SET quoted_string ";"
@@ -788,14 +782,6 @@ class RAGFlowCLITransformer(Transformer):
788
782
  chunk_id = items[2].children[0].strip("'\"")
789
783
  return {"type": "get_chunk", "chunk_id": chunk_id}
790
784
 
791
- def insert_dataset_from_file(self, items):
792
- file_path = items[4].children[0].strip("'\"")
793
- return {"type": "insert_dataset_from_file", "file_path": file_path}
794
-
795
- def insert_metadata_from_file(self, items):
796
- file_path = items[4].children[0].strip("'\"")
797
- return {"type": "insert_metadata_from_file", "file_path": file_path}
798
-
799
785
  def generate_nav_for_dataset(self, items):
800
786
  dataset_id = items[4].children[0].strip("'\"")
801
787
  return {"type": "generate_nav_for_dataset", "dataset_id": dataset_id}
@@ -1,6 +1,7 @@
1
1
  [project]
2
+ #name = "ragflow-cli"
2
3
  name = "ragflow-cli-myfbee-test"
3
- version = "0.27.2-dev"
4
+ version = "0.27.2.dev2"
4
5
  description = "Admin Service's client of [RAGFlow](https://github.com/infiniflow/ragflow). The Admin Service provides user management and system monitoring. "
5
6
  authors = [{ name = "Lynn", email = "lynn_inf@hotmail.com" }]
6
7
  license = { text = "Apache License, Version 2.0" }
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ragflow-cli-myfbee-test
3
- Version: 0.27.2.dev0
3
+ Version: 0.27.2.dev2
4
4
  Summary: Admin Service's client of [RAGFlow](https://github.com/infiniflow/ragflow). The Admin Service provides user management and system monitoring.
5
5
  Author-email: Lynn <lynn_inf@hotmail.com>
6
6
  License: Apache License, Version 2.0
@@ -1645,46 +1645,6 @@ class RAGFlowClient:
1645
1645
  else:
1646
1646
  print(f"Fail to get chunk, code: {response.status_code}, body: {response.text}")
1647
1647
 
1648
- # Internal
1649
- def insert_dataset_from_file(self, command_dict):
1650
- if self.server_type != "user":
1651
- print("This command is only allowed in USER mode")
1652
- return
1653
-
1654
- file_path = command_dict["file_path"]
1655
- payload = {"file_path": file_path}
1656
- response = self.http_client.request("POST", "/kb/insert_from_file", json_body=payload, use_api_base=False, auth_kind="web")
1657
- if response.status_code == 200:
1658
- res_json = response.json()
1659
- if res_json["code"] == 0:
1660
- print(f"Success to insert dataset from file: {file_path}")
1661
- if res_json.get("data"):
1662
- self._print_key_value(res_json["data"])
1663
- else:
1664
- print(f"Fail to insert dataset from file, code: {res_json['code']}, message: {res_json['message']}")
1665
- else:
1666
- print(f"Fail to insert dataset from file, code: {response.status_code}, body: {response.text}")
1667
-
1668
- # Internal
1669
- def insert_metadata_from_file(self, command_dict):
1670
- if self.server_type != "user":
1671
- print("This command is only allowed in USER mode")
1672
- return
1673
-
1674
- file_path = command_dict["file_path"]
1675
- payload = {"file_path": file_path}
1676
- response = self.http_client.request("POST", "/tenant/insert_metadata_from_file", json_body=payload, use_api_base=False, auth_kind="web")
1677
- if response.status_code == 200:
1678
- res_json = response.json()
1679
- if res_json["code"] == 0:
1680
- print(f"Success to insert metadata from file: {file_path}")
1681
- if res_json.get("data"):
1682
- self._print_key_value(res_json["data"])
1683
- else:
1684
- print(f"Fail to insert metadata from file, code: {res_json['code']}, message: {res_json['message']}")
1685
- else:
1686
- print(f"Fail to insert metadata from file, code: {response.status_code}, body: {response.text}")
1687
-
1688
1648
  def update_chunk(self, command_dict):
1689
1649
  if self.server_type != "user":
1690
1650
  print("This command is only allowed in USER mode")
@@ -2290,10 +2250,6 @@ def run_command(client: RAGFlowClient, command_dict: dict):
2290
2250
  return client.search_on_datasets(command_dict)
2291
2251
  case "get_chunk":
2292
2252
  return client.get_chunk(command_dict)
2293
- case "insert_dataset_from_file":
2294
- return client.insert_dataset_from_file(command_dict)
2295
- case "insert_metadata_from_file":
2296
- return client.insert_metadata_from_file(command_dict)
2297
2253
  case "update_chunk":
2298
2254
  return client.update_chunk(command_dict)
2299
2255
  case "set_metadata":