auto-coder 0.1.184__py3-none-any.whl → 0.1.187__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.
Potentially problematic release.
This version of auto-coder might be problematic. Click here for more details.
- {auto_coder-0.1.184.dist-info → auto_coder-0.1.187.dist-info}/METADATA +1 -1
- {auto_coder-0.1.184.dist-info → auto_coder-0.1.187.dist-info}/RECORD +11 -11
- autocoder/auto_coder.py +4 -2
- autocoder/auto_coder_rag.py +11 -0
- autocoder/common/__init__.py +2 -0
- autocoder/rag/long_context_rag.py +24 -0
- autocoder/version.py +1 -1
- {auto_coder-0.1.184.dist-info → auto_coder-0.1.187.dist-info}/LICENSE +0 -0
- {auto_coder-0.1.184.dist-info → auto_coder-0.1.187.dist-info}/WHEEL +0 -0
- {auto_coder-0.1.184.dist-info → auto_coder-0.1.187.dist-info}/entry_points.txt +0 -0
- {auto_coder-0.1.184.dist-info → auto_coder-0.1.187.dist-info}/top_level.txt +0 -0
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
autocoder/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
autocoder/auto_coder.py,sha256=
|
|
2
|
+
autocoder/auto_coder.py,sha256=tSNXFMJSrffagFi4egZJp8XZH9trSCwQjOdXKyHVqwo,37106
|
|
3
3
|
autocoder/auto_coder_lang.py,sha256=Rtupq6N3_HT7JRhDKdgCBcwRaiAnyCOR_Gsp4jUomrI,3229
|
|
4
|
-
autocoder/auto_coder_rag.py,sha256=
|
|
4
|
+
autocoder/auto_coder_rag.py,sha256=EsUR48qiW9gxoN0Bc_zELtLLpA7nNKGnAS4-DmTv0R0,16408
|
|
5
5
|
autocoder/auto_coder_server.py,sha256=qRY88mkBnqSGFDcwYE5gwpe2WPhIw1nEH6LdbjCQhQk,20306
|
|
6
6
|
autocoder/chat_auto_coder.py,sha256=1jCx-J83mj_8JnojYSTfPjYide-thbmsFbr12E_kgcQ,81773
|
|
7
7
|
autocoder/chat_auto_coder_lang.py,sha256=QYtu5gWEQmWKVovR_qUZ8plySZarNFX_Onk-1vN9IiA,8524
|
|
8
8
|
autocoder/command_args.py,sha256=ftWw6HnFUZPiQPt1oV-SfpHQe69XN3knaFy1lpROBcU,26854
|
|
9
9
|
autocoder/lang.py,sha256=e-07rYTgimpxS8sm-AxKSmH4kKQX4N05YFHJBg9trVs,12598
|
|
10
|
-
autocoder/version.py,sha256=
|
|
10
|
+
autocoder/version.py,sha256=eFC6_uO8qUnYHjch9ljwwGRsBsamPqNnAO0JPrxjgE8,23
|
|
11
11
|
autocoder/agent/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
12
12
|
autocoder/agent/auto_tool.py,sha256=DBzip-P_T6ZtT2eHexPcusmKYD0h7ufzp7TLwXAY10E,11554
|
|
13
13
|
autocoder/agent/coder.py,sha256=dnITYHqkcOip8zV4lywbkYNH9w7Q3qyYaUArJ4WPrTs,866
|
|
@@ -17,7 +17,7 @@ autocoder/agent/project_reader.py,sha256=-MWRqsr7O4mvU0PIpAhOUBb29htZAvA37pa_GeE
|
|
|
17
17
|
autocoder/chat/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
18
18
|
autocoder/common/JupyterClient.py,sha256=O-wi6pXeAEYhAY24kDa0BINrLYvKS6rKyWe98pDClS0,2816
|
|
19
19
|
autocoder/common/ShellClient.py,sha256=fM1q8t_XMSbLBl2zkCNC2J9xuyKN3eXzGm6hHhqL2WY,2286
|
|
20
|
-
autocoder/common/__init__.py,sha256=
|
|
20
|
+
autocoder/common/__init__.py,sha256=luP0Rl-dFwlZjj56MOs51EHWCIEk6QnrjWN3CGTwFcw,10469
|
|
21
21
|
autocoder/common/anything2images.py,sha256=0ILBbWzY02M-CiWB-vzuomb_J1hVdxRcenAfIrAXq9M,25283
|
|
22
22
|
autocoder/common/audio.py,sha256=Kn9nWKQddWnUrAz0a_ZUgjcu4VUU_IcZBigT7n3N3qc,7439
|
|
23
23
|
autocoder/common/cleaner.py,sha256=NU72i8C6o9m0vXExab7nao5bstBUsfJFcj11cXa9l4U,1089
|
|
@@ -62,7 +62,7 @@ autocoder/rag/api_server.py,sha256=zokIlDJlk7ucRorSLQm80uICO1mecfmn4J2zVqEBskE,6
|
|
|
62
62
|
autocoder/rag/doc_filter.py,sha256=Ha0Yae_G_hF72YzvrO7NoDZcG18K4hRcqGAEqfrIwAs,9330
|
|
63
63
|
autocoder/rag/document_retriever.py,sha256=_jCbCEX0I-5UPWuHocESaWHatQcv1r_DqA0yOfOAiZ0,9092
|
|
64
64
|
autocoder/rag/llm_wrapper.py,sha256=xRbTBpLUH43Ah5jplL8WWWU-kjKfNgEJoUntLGBq5F4,2484
|
|
65
|
-
autocoder/rag/long_context_rag.py,sha256=
|
|
65
|
+
autocoder/rag/long_context_rag.py,sha256=C01LYNk0nDRDeMpBkroWMZcLCcD2JlOvUEOLOndC3XI,22129
|
|
66
66
|
autocoder/rag/rag_config.py,sha256=8LwFcTd8OJWWwi1_WY4IzjqgtT6RyE2j4PjxS5cCTDE,802
|
|
67
67
|
autocoder/rag/rag_entry.py,sha256=V1RJ8RGqM30DNPmzymv64rZjNRGWn6kfc8sRy_LECg0,2451
|
|
68
68
|
autocoder/rag/raw_rag.py,sha256=yS2Ur6kG0IRjhCj2_VonwxjY_xls_E62jO5Gz5j2nqE,2952
|
|
@@ -101,9 +101,9 @@ autocoder/utils/request_event_queue.py,sha256=r3lo5qGsB1dIjzVQ05dnr0z_9Z3zOkBdP1
|
|
|
101
101
|
autocoder/utils/request_queue.py,sha256=nwp6PMtgTCiuwJI24p8OLNZjUiprC-TsefQrhMI-yPE,3889
|
|
102
102
|
autocoder/utils/rest.py,sha256=3tXA8KZG6jKz_tddHNLGx77Icee88WcUeesfNsgPno4,8790
|
|
103
103
|
autocoder/utils/tests.py,sha256=BqphrwyycGAvs-5mhH8pKtMZdObwhFtJ5MC_ZAOiLq8,1340
|
|
104
|
-
auto_coder-0.1.
|
|
105
|
-
auto_coder-0.1.
|
|
106
|
-
auto_coder-0.1.
|
|
107
|
-
auto_coder-0.1.
|
|
108
|
-
auto_coder-0.1.
|
|
109
|
-
auto_coder-0.1.
|
|
104
|
+
auto_coder-0.1.187.dist-info/LICENSE,sha256=HrhfyXIkWY2tGFK11kg7vPCqhgh5DcxleloqdhrpyMY,11558
|
|
105
|
+
auto_coder-0.1.187.dist-info/METADATA,sha256=3VUP6MJh-ZxgNoT7FASzF-VqmFqPmxD75v2DurycKhA,2352
|
|
106
|
+
auto_coder-0.1.187.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
|
|
107
|
+
auto_coder-0.1.187.dist-info/entry_points.txt,sha256=0nzHtHH4pNcM7xq4EBA2toS28Qelrvcbrr59GqD_0Ak,350
|
|
108
|
+
auto_coder-0.1.187.dist-info/top_level.txt,sha256=Jqc0_uJSw2GwoFQAa9iJxYns-2mWla-9ok_Y3Gcznjk,10
|
|
109
|
+
auto_coder-0.1.187.dist-info/RECORD,,
|
autocoder/auto_coder.py
CHANGED
|
@@ -754,12 +754,14 @@ def main(input_args: Optional[List[str]] = None):
|
|
|
754
754
|
{% endif %}
|
|
755
755
|
|
|
756
756
|
{% if pre_conversations %}
|
|
757
|
-
|
|
757
|
+
下面是我们之间的历史对话,假设我是A,你是B。
|
|
758
758
|
{% for conv in pre_conversations %}
|
|
759
|
-
|
|
759
|
+
{{ "A" if conv.role == "user" else "B" }}: {{ conv.content }}
|
|
760
760
|
{% endfor %}
|
|
761
761
|
{% endif %}
|
|
762
762
|
|
|
763
|
+
|
|
764
|
+
参考上面的文件以及对话,回答用户的问题。
|
|
763
765
|
用户的问题: {{ last_conversation.content }}
|
|
764
766
|
"""
|
|
765
767
|
|
autocoder/auto_coder_rag.py
CHANGED
|
@@ -256,6 +256,11 @@ def main(input_args: Optional[List[str]] = None):
|
|
|
256
256
|
action="store_true",
|
|
257
257
|
help="Enable deep thought in inference mode",
|
|
258
258
|
)
|
|
259
|
+
serve_parser.add_argument(
|
|
260
|
+
"--inference_slow_without_deep_thought",
|
|
261
|
+
action="store_true",
|
|
262
|
+
help="Enable slow inference without deep thought",
|
|
263
|
+
)
|
|
259
264
|
|
|
260
265
|
serve_parser.add_argument(
|
|
261
266
|
"--enable_hybrid_index",
|
|
@@ -269,6 +274,12 @@ def main(input_args: Optional[List[str]] = None):
|
|
|
269
274
|
help="The maximum number of tokens in the output. This is only used when enable_hybrid_index is true.",
|
|
270
275
|
)
|
|
271
276
|
|
|
277
|
+
serve_parser.add_argument(
|
|
278
|
+
"--without_contexts",
|
|
279
|
+
action="store_true",
|
|
280
|
+
help="Whether to return responses without contexts. only works when pro plugin is installed",
|
|
281
|
+
)
|
|
282
|
+
|
|
272
283
|
# Tools command
|
|
273
284
|
tools_parser = subparsers.add_parser("tools", help="Various tools")
|
|
274
285
|
tools_subparsers = tools_parser.add_subparsers(dest="tool", help="Available tools")
|
autocoder/common/__init__.py
CHANGED
|
@@ -316,6 +316,8 @@ class AutoCoderArgs(pydantic.BaseModel):
|
|
|
316
316
|
|
|
317
317
|
disable_inference_enhance: Optional[bool] = False
|
|
318
318
|
inference_deep_thought: Optional[bool] = False
|
|
319
|
+
inference_slow_without_deep_thought: Optional[bool] = False
|
|
320
|
+
without_contexts: Optional[bool] = False
|
|
319
321
|
|
|
320
322
|
class Config:
|
|
321
323
|
protected_namespaces = ()
|
|
@@ -343,6 +343,30 @@ class LongContextRAG:
|
|
|
343
343
|
)
|
|
344
344
|
return (chunk[0] for chunk in chunks), context
|
|
345
345
|
|
|
346
|
+
if self.args.without_contexts and LLMComputeEngine is not None:
|
|
347
|
+
llm_compute_engine = LLMComputeEngine(
|
|
348
|
+
llm=self.llm,
|
|
349
|
+
inference_enhance=not self.args.disable_inference_enhance,
|
|
350
|
+
inference_deep_thought=self.args.inference_deep_thought,
|
|
351
|
+
inference_slow_without_deep_thought=self.args.inference_slow_without_deep_thought
|
|
352
|
+
)
|
|
353
|
+
conversations = conversations[:-1]
|
|
354
|
+
new_conversations = llm_compute_engine.process_conversation(
|
|
355
|
+
conversations, query, []
|
|
356
|
+
)
|
|
357
|
+
|
|
358
|
+
return (
|
|
359
|
+
llm_compute_engine.stream_chat_oai(
|
|
360
|
+
conversations=new_conversations,
|
|
361
|
+
model=model,
|
|
362
|
+
role_mapping=role_mapping,
|
|
363
|
+
llm_config=llm_config,
|
|
364
|
+
delta_mode=True,
|
|
365
|
+
),
|
|
366
|
+
context,
|
|
367
|
+
)
|
|
368
|
+
|
|
369
|
+
|
|
346
370
|
only_contexts = False
|
|
347
371
|
try:
|
|
348
372
|
v = json.loads(query)
|
autocoder/version.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "0.1.
|
|
1
|
+
__version__ = "0.1.187"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|