patchllm 0.1.0__py3-none-any.whl → 0.1.1__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.
- patchllm/__init__.py +1 -0
- patchllm/main.py +10 -5
- {patchllm-0.1.0.dist-info → patchllm-0.1.1.dist-info}/METADATA +5 -1
- patchllm-0.1.1.dist-info/RECORD +12 -0
- patchllm-0.1.1.dist-info/entry_points.txt +2 -0
- patchllm-0.1.0.dist-info/RECORD +0 -12
- patchllm-0.1.0.dist-info/entry_points.txt +0 -2
- {patchllm-0.1.0.dist-info → patchllm-0.1.1.dist-info}/WHEEL +0 -0
- {patchllm-0.1.0.dist-info → patchllm-0.1.1.dist-info}/licenses/LICENSE +0 -0
- {patchllm-0.1.0.dist-info → patchllm-0.1.1.dist-info}/top_level.txt +0 -0
patchllm/__init__.py
CHANGED
@@ -0,0 +1 @@
|
|
1
|
+
from .main import Assistant
|
patchllm/main.py
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
import sys
|
2
2
|
|
3
|
-
from context import build_context
|
4
|
-
from parser import paste_response
|
5
|
-
from utils import load_from_py_file
|
3
|
+
from .context import build_context
|
4
|
+
from .parser import paste_response
|
5
|
+
from .utils import load_from_py_file
|
6
6
|
import textwrap
|
7
7
|
import argparse
|
8
8
|
import litellm
|
@@ -18,16 +18,21 @@ class Assistant:
|
|
18
18
|
def __init__(
|
19
19
|
self,
|
20
20
|
model_name="gemini/gemini-2.5-flash",
|
21
|
+
configs: dict = None,
|
21
22
|
configs_file = "./configs.py",
|
22
23
|
):
|
23
24
|
"""
|
24
25
|
Initializes the Assistant.
|
25
26
|
Args:
|
26
27
|
model_name (str): The alias for the generative model to use (must be a litellm supported model string).
|
28
|
+
configs (Dict[str]): A dictionary of configurations to use for building the code context.
|
27
29
|
configs_file (str): The path to the configurations file.
|
28
30
|
"""
|
29
31
|
self.model_name = model_name
|
30
|
-
|
32
|
+
if configs:
|
33
|
+
self.configs = configs
|
34
|
+
else:
|
35
|
+
self.configs = load_from_py_file(configs_file, "configs")
|
31
36
|
system_prompt = textwrap.dedent("""
|
32
37
|
You are an expert pair programmer. Your purpose is to help users by modifying files based on their instructions.
|
33
38
|
|
@@ -192,7 +197,7 @@ def main():
|
|
192
197
|
|
193
198
|
# Handle voice input
|
194
199
|
if args.voice not in ["False", "false"]:
|
195
|
-
from listener import listen, speak
|
200
|
+
from .listener import listen, speak
|
196
201
|
|
197
202
|
speak("Say your task instruction.")
|
198
203
|
task = listen()
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: patchllm
|
3
|
-
Version: 0.1.
|
3
|
+
Version: 0.1.1
|
4
4
|
Summary: Lightweight tool to manage contexts and update code with LLMs
|
5
5
|
Author: nassimberrada
|
6
6
|
License: MIT License
|
@@ -28,6 +28,10 @@ Requires-Python: >=3.8
|
|
28
28
|
Description-Content-Type: text/markdown
|
29
29
|
License-File: LICENSE
|
30
30
|
Requires-Dist: litellm
|
31
|
+
Requires-Dist: python-dotenv
|
32
|
+
Provides-Extra: voice
|
33
|
+
Requires-Dist: SpeechRecognition; extra == "voice"
|
34
|
+
Requires-Dist: pyttsx3; extra == "voice"
|
31
35
|
Dynamic: license-file
|
32
36
|
|
33
37
|
<p align="center">
|
@@ -0,0 +1,12 @@
|
|
1
|
+
patchllm/__init__.py,sha256=rtpA9Og8Jm6IVwPB2r0xA57nririqM09DuvaIV6JipQ,27
|
2
|
+
patchllm/context.py,sha256=zUrXf5l3cdxAbmxB7IjbShTAWA_ZEMBz8OGlaB-cofE,6450
|
3
|
+
patchllm/listener.py,sha256=EdcceJCLEoSftX1dVSWxtwBsLaII2lcZ0VnllHwCGWI,845
|
4
|
+
patchllm/main.py,sha256=ed7CNEt8UlOw2GmE-LVLMyVZddTBKR1R0U3YBrRg6UM,8782
|
5
|
+
patchllm/parser.py,sha256=4wipa6deoE2gUIhYrvUZcbKTIr5j6lw5Z6bOItUH6YI,2629
|
6
|
+
patchllm/utils.py,sha256=hz28hd017gRGT632VQAYLPdX0KAS1GLvZzeUDCKbLc0,647
|
7
|
+
patchllm-0.1.1.dist-info/licenses/LICENSE,sha256=vZxgIRNxffjkTV2NWLemgYjDRu0hSMTyFXCZ1zEWbUc,1077
|
8
|
+
patchllm-0.1.1.dist-info/METADATA,sha256=q-jcWSBhahwklDhaDyydRGFxX25co-tY3wyWhNAiuRI,3547
|
9
|
+
patchllm-0.1.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
10
|
+
patchllm-0.1.1.dist-info/entry_points.txt,sha256=xm-W7FKOQd3o9RgK_4krVnO2sC8phpYxDCobf0htLiU,48
|
11
|
+
patchllm-0.1.1.dist-info/top_level.txt,sha256=SLIZj9EhBXbSnYrbnV8EjL-OfNz-hXRwABCPCjE5Fas,9
|
12
|
+
patchllm-0.1.1.dist-info/RECORD,,
|
patchllm-0.1.0.dist-info/RECORD
DELETED
@@ -1,12 +0,0 @@
|
|
1
|
-
patchllm/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
-
patchllm/context.py,sha256=zUrXf5l3cdxAbmxB7IjbShTAWA_ZEMBz8OGlaB-cofE,6450
|
3
|
-
patchllm/listener.py,sha256=EdcceJCLEoSftX1dVSWxtwBsLaII2lcZ0VnllHwCGWI,845
|
4
|
-
patchllm/main.py,sha256=-11bAS-bx2SfGx14KCCZhuwrfh_FDcQ80cwUfYrszY8,8569
|
5
|
-
patchllm/parser.py,sha256=4wipa6deoE2gUIhYrvUZcbKTIr5j6lw5Z6bOItUH6YI,2629
|
6
|
-
patchllm/utils.py,sha256=hz28hd017gRGT632VQAYLPdX0KAS1GLvZzeUDCKbLc0,647
|
7
|
-
patchllm-0.1.0.dist-info/licenses/LICENSE,sha256=vZxgIRNxffjkTV2NWLemgYjDRu0hSMTyFXCZ1zEWbUc,1077
|
8
|
-
patchllm-0.1.0.dist-info/METADATA,sha256=BtSvIfjwiWqvv-1d_GPBf1n7ao9R2YY3m8Qd_Rr4c6A,3404
|
9
|
-
patchllm-0.1.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
10
|
-
patchllm-0.1.0.dist-info/entry_points.txt,sha256=_jqCdL7snk6RZfqiSzP_XttWYAPNw_UdnAEqYS-rrd8,48
|
11
|
-
patchllm-0.1.0.dist-info/top_level.txt,sha256=SLIZj9EhBXbSnYrbnV8EjL-OfNz-hXRwABCPCjE5Fas,9
|
12
|
-
patchllm-0.1.0.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|