flyteplugins-codegen 2.1.7__py3-none-any.whl → 2.1.8__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.
- flyteplugins/codegen/auto_coder_agent.py +5 -0
- flyteplugins/codegen/execution/agent.py +3 -0
- flyteplugins/codegen/execution/docker.py +3 -0
- {flyteplugins_codegen-2.1.7.dist-info → flyteplugins_codegen-2.1.8.dist-info}/METADATA +2 -1
- {flyteplugins_codegen-2.1.7.dist-info → flyteplugins_codegen-2.1.8.dist-info}/RECORD +7 -7
- {flyteplugins_codegen-2.1.7.dist-info → flyteplugins_codegen-2.1.8.dist-info}/WHEEL +0 -0
- {flyteplugins_codegen-2.1.7.dist-info → flyteplugins_codegen-2.1.8.dist-info}/top_level.txt +0 -0
|
@@ -73,6 +73,7 @@ class AutoCoderAgent:
|
|
|
73
73
|
cache: CacheRequest for sandboxes: "auto", "override", or "disable". Defaults to "auto".
|
|
74
74
|
backend: Execution backend: "litellm" (default) or "claude".
|
|
75
75
|
agent_max_turns: Maximum agent turns when backend="claude". Defaults to 50.
|
|
76
|
+
block_network: Block all outbound network access in sandboxes. Defaults to False.
|
|
76
77
|
|
|
77
78
|
Example::
|
|
78
79
|
|
|
@@ -119,6 +120,7 @@ class AutoCoderAgent:
|
|
|
119
120
|
cache: str = "auto"
|
|
120
121
|
backend: Literal["litellm", "claude"] = "litellm"
|
|
121
122
|
agent_max_turns: int = 50
|
|
123
|
+
block_network: bool = False
|
|
122
124
|
|
|
123
125
|
@syncify
|
|
124
126
|
async def generate(
|
|
@@ -271,6 +273,7 @@ class AutoCoderAgent:
|
|
|
271
273
|
env_vars=self.env_vars,
|
|
272
274
|
secrets=self.secrets,
|
|
273
275
|
cache=self.cache,
|
|
276
|
+
block_network=self.block_network,
|
|
274
277
|
max_turns=self.agent_max_turns,
|
|
275
278
|
)
|
|
276
279
|
|
|
@@ -386,6 +389,7 @@ class _CodeGenSession:
|
|
|
386
389
|
self.env_vars = agent.env_vars
|
|
387
390
|
self.secrets = agent.secrets
|
|
388
391
|
self.cache = agent.cache
|
|
392
|
+
self.block_network = agent.block_network
|
|
389
393
|
self.image_config = agent.image_config
|
|
390
394
|
self.litellm_params = agent.litellm_params
|
|
391
395
|
|
|
@@ -606,6 +610,7 @@ class _CodeGenSession:
|
|
|
606
610
|
env_vars=self.env_vars,
|
|
607
611
|
secrets=self.secrets,
|
|
608
612
|
cache=self.cache,
|
|
613
|
+
block_network=self.block_network,
|
|
609
614
|
_attempt=attempt,
|
|
610
615
|
)
|
|
611
616
|
|
|
@@ -77,6 +77,7 @@ async def code_gen_eval_agent(
|
|
|
77
77
|
env_vars: Optional[dict[str, str]] = None,
|
|
78
78
|
secrets: Optional[list] = None,
|
|
79
79
|
cache: str = "auto",
|
|
80
|
+
block_network: bool = False,
|
|
80
81
|
max_turns: int = 50,
|
|
81
82
|
language: str = "python",
|
|
82
83
|
) -> CodeGenEvalResult:
|
|
@@ -104,6 +105,7 @@ async def code_gen_eval_agent(
|
|
|
104
105
|
env_vars: Optional environment variables to set in the sandbox
|
|
105
106
|
secrets: Optional secrets to make available in the sandbox
|
|
106
107
|
cache: Caching behavior for sandbox execution ("auto", "override", "disable")
|
|
108
|
+
block_network: Block all outbound network access in sandboxes. Defaults to False.
|
|
107
109
|
max_turns: Maximum number of agent turns before stopping (default: 50)
|
|
108
110
|
language: Programming language for code generation (default: "python")
|
|
109
111
|
|
|
@@ -189,6 +191,7 @@ async def code_gen_eval_agent(
|
|
|
189
191
|
env_vars=env_vars,
|
|
190
192
|
secrets=secrets,
|
|
191
193
|
cache=cache,
|
|
194
|
+
block_network=block_network,
|
|
192
195
|
_attempt=_exec_state["test_count"],
|
|
193
196
|
)
|
|
194
197
|
|
|
@@ -140,6 +140,7 @@ async def run_tests(
|
|
|
140
140
|
env_vars: Optional[dict[str, str]] = None,
|
|
141
141
|
secrets: Optional[list] = None,
|
|
142
142
|
cache: str = "auto",
|
|
143
|
+
block_network: bool = False,
|
|
143
144
|
_attempt: int = 1,
|
|
144
145
|
) -> RunResult:
|
|
145
146
|
"""Run pytest tests against code in an isolated container.
|
|
@@ -155,6 +156,7 @@ async def run_tests(
|
|
|
155
156
|
env_vars: Environment variables available inside the container.
|
|
156
157
|
secrets: Flyte secrets to mount.
|
|
157
158
|
cache: Cache behaviour — `"auto"`, `"override"`, or `"disable"`.
|
|
159
|
+
block_network: Block all outbound network access. Defaults to False.
|
|
158
160
|
_attempt: Differentiates repeated calls with the same base name.
|
|
159
161
|
|
|
160
162
|
Returns:
|
|
@@ -180,6 +182,7 @@ async def run_tests(
|
|
|
180
182
|
env_vars=env_vars,
|
|
181
183
|
secrets=secrets,
|
|
182
184
|
cache=cache,
|
|
185
|
+
block_network=block_network,
|
|
183
186
|
)
|
|
184
187
|
|
|
185
188
|
try:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: flyteplugins-codegen
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.8
|
|
4
4
|
Summary: LLM-powered code generation and evaluation plugin for Flyte
|
|
5
5
|
Author-email: Samhita Alla <samhita@union.ai>
|
|
6
6
|
Requires-Python: >=3.10
|
|
@@ -178,6 +178,7 @@ result = await agent.generate.aio(prompt="...")
|
|
|
178
178
|
| `cache` | `str` | `"auto"` | CacheRequest for sandboxes: `"auto"`, `"override"`, or `"disable"` |
|
|
179
179
|
| `backend` | `str` | `"litellm"` | Execution backend: `"litellm"` or `"claude"` |
|
|
180
180
|
| `agent_max_turns` | `int` | `50` | Max turns when `backend="claude"` |
|
|
181
|
+
| `block_network` | `bool` | `False` | Block all outbound network access in sandboxes. Set to `True` to block network access. |
|
|
181
182
|
|
|
182
183
|
**`generate()` parameters (per-call):**
|
|
183
184
|
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
flyteplugins/codegen/__init__.py,sha256=jumoM0Po0Tx1KqatcdNi_Mk1MYCLcccnyjn6d1zurLQ,366
|
|
2
|
-
flyteplugins/codegen/auto_coder_agent.py,sha256
|
|
2
|
+
flyteplugins/codegen/auto_coder_agent.py,sha256=-HkI3nM3T0Ydj8ezDprDI8DLetgQeoixBDGJXnJfmUA,46241
|
|
3
3
|
flyteplugins/codegen/core/__init__.py,sha256=YjAN0PpvkhERFmlkEq78O2q92bmgyGAVttYXeDH_hyc,355
|
|
4
4
|
flyteplugins/codegen/core/types.py,sha256=kxAoKMu9tOTRNPBfiFC-dxMQOmeEawJAVRNKj42_3js,12274
|
|
5
5
|
flyteplugins/codegen/data/__init__.py,sha256=UDkKuvyBEZmsPaTR6yEexcQjLutMRxuV5-pWflGc_sI,670
|
|
6
6
|
flyteplugins/codegen/data/extraction.py,sha256=3jjm4REJYzl3U8FWv1Cys4FOuh2gG1Hv90OpdeiBlgs,10273
|
|
7
7
|
flyteplugins/codegen/data/schema.py,sha256=fAcT0upjXRFIDbLUolFiuPAJHWbVu5VmmBxWEW_-9uc,10300
|
|
8
8
|
flyteplugins/codegen/execution/__init__.py,sha256=3i4bP_xNp8ZgsolRI7ccUtkIW-h-1zCXFrjWfltVu3U,192
|
|
9
|
-
flyteplugins/codegen/execution/agent.py,sha256=
|
|
10
|
-
flyteplugins/codegen/execution/docker.py,sha256=
|
|
9
|
+
flyteplugins/codegen/execution/agent.py,sha256=eCIsQ09YU3OYRci1dZb8lRqxTPr21DHvW3LLPLfIKc4,27334
|
|
10
|
+
flyteplugins/codegen/execution/docker.py,sha256=LSmg9g7MCiD-yGAMuQT0YCh_npma_dellSh0WIvJHak,7294
|
|
11
11
|
flyteplugins/codegen/generation/__init__.py,sha256=GkLiXfJeVQmLlHf4R08qzgUa5wYG97KseGjRtLCFZhU,1065
|
|
12
12
|
flyteplugins/codegen/generation/llm.py,sha256=FPBt1MlW_OjwtEEcnJhE62sYrbSK4tRB3UEk80cWvgQ,44229
|
|
13
13
|
flyteplugins/codegen/generation/prompts.py,sha256=Te9nK9TldLyHM2KB24PhTiWNqoEXJlW9l8nt09FbWa8,5770
|
|
14
|
-
flyteplugins_codegen-2.1.
|
|
15
|
-
flyteplugins_codegen-2.1.
|
|
16
|
-
flyteplugins_codegen-2.1.
|
|
17
|
-
flyteplugins_codegen-2.1.
|
|
14
|
+
flyteplugins_codegen-2.1.8.dist-info/METADATA,sha256=VUaHhiLQdeQxOOj6dK_e6SdWXYsnxN9NnBhYLbNsZTY,19203
|
|
15
|
+
flyteplugins_codegen-2.1.8.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
|
|
16
|
+
flyteplugins_codegen-2.1.8.dist-info/top_level.txt,sha256=cgd779rPu9EsvdtuYgUxNHHgElaQvPn74KhB5XSeMBE,13
|
|
17
|
+
flyteplugins_codegen-2.1.8.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|