Skip to content

Commit

Permalink
Merge branch 'main' into opresult-serialization
Browse files Browse the repository at this point in the history
  • Loading branch information
sidnarayanan authored Sep 6, 2024
2 parents cf9102d + bd8f094 commit e0e44b2
Show file tree
Hide file tree
Showing 4 changed files with 220 additions and 269 deletions.
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ repos:
- id: mixed-line-ending
- id: trailing-whitespace
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.6.3
rev: v0.6.4
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
Expand Down Expand Up @@ -62,7 +62,7 @@ repos:
additional_dependencies:
- "validate-pyproject-schema-store[all]>=2024.08.19" # For Ruff renaming RUF025 to C420
- repo: https://github.com/astral-sh/uv-pre-commit
rev: 0.4.4
rev: 0.4.6
hooks:
- id: uv-lock
- repo: https://github.com/pre-commit/mirrors-mypy
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ dependencies = [
]
description = "Agent framework for constructing language model agents and training on constructive tasks."
dynamic = ["version"]
license = {file = "LICENSE"}
name = "ldp"
readme = "README.md"
requires-python = ">=3.11"
Expand Down Expand Up @@ -402,6 +403,7 @@ dev-dependencies = [
"litellm>=1.40.9,<=1.40.12", # Pin lower for get_supported_openai_params not requiring custom LLM, upper for https://github.com/BerriAI/litellm/issues/4032
"mypy>=1.8", # Pin for mutable-override
"pre-commit~=3.4", # Pin to keep recent
"pydantic~=2.9", # Pydantic 2.9 changed JSON schema exports 'allOf', so ensure tests match
"pylint-pydantic",
"pylint>=3.2", # Pin to keep recent
"pytest-asyncio",
Expand Down
14 changes: 6 additions & 8 deletions tests/test_agents.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,13 +454,13 @@ async def test_agent_grad(self, dummy_env: DummyEnv, model_name: str) -> None:
" And despite that there is a multiline argument"
' description.","title":"Y","type":"null"},"union":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"I'
" am a union and the current year is"
' {current_year}.","title":"Union"},"pydantic_model":{"allOf":[{"$ref":"#/$defs/StubState"}],"description":"I'
' {current_year}.","title":"Union"},"pydantic_model":{"$ref":"#/$defs/StubState","description":"I'
" am a Pydantic"
' model."},"basic_dict":{"additionalProperties":{"type":"integer"},"description":"I'
' am a dictionary with primitive values.","title":"Basic'
' Dict","type":"object"},"complex_dict":{"additionalProperties":{"maxItems":2,"minItems":2,"prefixItems":[{"type":"string"},{"type":"integer"}],"type":"array"},"description":"I'
' am a dictionary with complex values.","title":"Complex'
' Dict","type":"object"},"enum":{"allOf":[{"$ref":"#/$defs/StubEnum"}],"description":"I'
' Dict","type":"object"},"enum":{"$ref":"#/$defs/StubEnum","description":"I'
" am an"
' enum."},"defaulted_str":{"default":"default","description":"I'
' have a string default value.","title":"Defaulted'
Expand Down Expand Up @@ -500,16 +500,14 @@ async def test_agent_grad(self, dummy_env: DummyEnv, model_name: str) -> None:
" am null. And despite that there is a multiline argument"
" description.</description><title>Y</title><type>null</type></y><union><anyOf><item><type>integer</type></item><item><type>null</type></item></anyOf><description>I"
" am a union and the current year is"
" {current_year}.</description><title>Union</title></union><pydantic_model><allOf><item><key"
' name="$ref">#/$defs/StubState</key></item></allOf><description>I'
" am a Pydantic"
" {current_year}.</description><title>Union</title></union><pydantic_model><key"
' name="$ref">#/$defs/StubState</key><description>I am a Pydantic'
" model.</description></pydantic_model><basic_dict><additionalProperties><type>integer</type></additionalProperties><description>I"
" am a dictionary with primitive values.</description><title>Basic"
" Dict</title><type>object</type></basic_dict><complex_dict><additionalProperties><maxItems>2</maxItems><minItems>2</minItems><prefixItems><item><type>string</type></item><item><type>integer</type></item></prefixItems><type>array</type></additionalProperties><description>I"
" am a dictionary with complex values.</description><title>Complex"
" Dict</title><type>object</type></complex_dict><enum><allOf><item><key"
' name="$ref">#/$defs/StubEnum</key></item></allOf><description>I'
" am an"
" Dict</title><type>object</type></complex_dict><enum><key"
' name="$ref">#/$defs/StubEnum</key><description>I am an'
" enum.</description></enum><defaulted_str><default>default</default><description>I"
" have a string default value.</description><title>Defaulted"
" Str</title><type>string</type></defaulted_str><defaulted_float><default>1.0</default><description>I"
Expand Down
Loading

0 comments on commit e0e44b2

Please sign in to comment.