-
Notifications
You must be signed in to change notification settings - Fork 233
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into issue-1584/-hide-cost-and-usage-in-playgroun…
…d-and-evaluation-when-these-are-not-specified
- Loading branch information
Showing
12 changed files
with
266 additions
and
198 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import aiodocker | ||
|
||
|
||
async def retrieve_logs(container_id: str) -> str: | ||
""" | ||
Retrieves and returns the last 10 lines of logs (both stdout and stderr) | ||
for a specified Docker container. | ||
Args: | ||
container_id (str): The docker container identifier | ||
Returns: | ||
the last 10 lines of logs | ||
""" | ||
|
||
async with aiodocker.Docker() as client: | ||
container = await client.containers.get(container_id) | ||
logs = await container.log(stdout=True, stderr=True) | ||
outputs = logs[::-1][:10] | ||
return "".join(outputs) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[tool.poetry] | ||
name = "agenta_backend" | ||
version = "0.14.2" | ||
version = "0.14.4" | ||
description = "" | ||
authors = ["Mahmoud Mabrouk <[email protected]>"] | ||
readme = "README.md" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[tool.poetry] | ||
name = "agenta" | ||
version = "0.14.2" | ||
version = "0.14.4" | ||
description = "The SDK for agenta is an open-source LLMOps platform." | ||
readme = "README.md" | ||
authors = ["Mahmoud Mabrouk <[email protected]>"] | ||
|
@@ -34,6 +34,7 @@ cachetools = "^5.3.3" | |
|
||
[tool.poetry.dev-dependencies] | ||
pytest = "^6.2" | ||
setuptools = "^69.5.1" | ||
|
||
[build-system] | ||
requires = ["poetry-core"] | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "agenta", | ||
"version": "0.14.2", | ||
"version": "0.14.4", | ||
"private": true, | ||
"engines": { | ||
"node": ">=18" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters