Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 25f97f9

Browse filesBrowse files
authored
Fix typos and misspellings (#486)
Detected typos using typos-cli (https://crates.io/crates/typos-cli). It detected "occured" in a string constant "handoff_occured" too, but I didn't change the part this time because it could be a minor breaking change. Full outputs: ``` % typos . error: `Supresses` should be `Suppresses` --> ./src/agents/function_schema.py:134:7 | 134 | # Supresses warnings about missing annotations for params | ^^^^^^^^^ | error: `typ` should be `typo`, `type` --> ./src/agents/strict_schema.py:51:5 | 51 | typ = json_schema.get("type") | ^^^ | error: `typ` should be `typo`, `type` --> ./src/agents/strict_schema.py:52:8 | 52 | if typ == "object" and "additionalProperties" not in json_schema: | ^^^ | error: `typ` should be `typo`, `type` --> ./src/agents/strict_schema.py:55:9 | 55 | typ == "object" | ^^^ | error: `occured` should be `occurred` --> ./src/agents/stream_events.py:34:18 | 34 | "handoff_occured", | ^^^^^^^ | error: `occured` should be `occurred` --> ./src/agents/_run_impl.py:723:69 | 723 | event = RunItemStreamEvent(item=item, name="handoff_occured") | ^^^^^^^ | error: `desitnation` should be `destination` --> ./src/agents/tracing/span_data.py:171:25 | 171 | Includes source and desitnation agents. | ^^^^^^^^^^^ | error: `exmaples` should be `examples` --> ./docs/scripts/translate_docs.py:71:145 | 71 | "* The term 'examples' must be code examples when the page mentions the code examples in the repo, it can be translated as either 'code exmaples' or 'sample code'.", | ^^^^^^^^ | error: `structed` should be `structured` --> ./tests/test_agent_hooks.py:227:16 | 227 | async def test_structed_output_non_streamed_agent_hooks(): | ^^^^^^^^ | error: `structed` should be `structured` --> ./tests/test_agent_hooks.py:298:16 | 298 | async def test_structed_output_streamed_agent_hooks(): | ^^^^^^^^ | ```
1 parent e04d87c commit 25f97f9
Copy full SHA for 25f97f9

File tree

Expand file treeCollapse file tree

4 files changed

+5
-5
lines changed
Filter options
Expand file treeCollapse file tree

4 files changed

+5
-5
lines changed

‎docs/scripts/translate_docs.py

Copy file name to clipboardExpand all lines: docs/scripts/translate_docs.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
}
6969
eng_to_non_eng_instructions = {
7070
"common": [
71-
"* The term 'examples' must be code examples when the page mentions the code examples in the repo, it can be translated as either 'code exmaples' or 'sample code'.",
71+
"* The term 'examples' must be code examples when the page mentions the code examples in the repo, it can be translated as either 'code examples' or 'sample code'.",
7272
"* The term 'primitives' can be translated as basic components.",
7373
"* When the terms 'instructions' and 'tools' are mentioned as API parameter names, they must be kept as is.",
7474
"* The terms 'temperature', 'top_p', 'max_tokens', 'presence_penalty', 'frequency_penalty' as parameter names must be kept as is.",

‎src/agents/function_schema.py

Copy file name to clipboardExpand all lines: src/agents/function_schema.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ def _detect_docstring_style(doc: str) -> DocstringStyle:
131131

132132
@contextlib.contextmanager
133133
def _suppress_griffe_logging():
134-
# Supresses warnings about missing annotations for params
134+
# Suppresses warnings about missing annotations for params
135135
logger = logging.getLogger("griffe")
136136
previous_level = logger.getEffectiveLevel()
137137
logger.setLevel(logging.ERROR)

‎src/agents/tracing/span_data.py

Copy file name to clipboardExpand all lines: src/agents/tracing/span_data.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ def export(self) -> dict[str, Any]:
168168
class HandoffSpanData(SpanData):
169169
"""
170170
Represents a Handoff Span in the trace.
171-
Includes source and desitnation agents.
171+
Includes source and destination agents.
172172
"""
173173

174174
__slots__ = ("from_agent", "to_agent")

‎tests/test_agent_hooks.py

Copy file name to clipboardExpand all lines: tests/test_agent_hooks.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ class Foo(TypedDict):
224224

225225

226226
@pytest.mark.asyncio
227-
async def test_structed_output_non_streamed_agent_hooks():
227+
async def test_structured_output_non_streamed_agent_hooks():
228228
hooks = AgentHooksForTests()
229229
model = FakeModel()
230230
agent_1 = Agent(name="test_1", model=model)
@@ -295,7 +295,7 @@ async def test_structed_output_non_streamed_agent_hooks():
295295

296296

297297
@pytest.mark.asyncio
298-
async def test_structed_output_streamed_agent_hooks():
298+
async def test_structured_output_streamed_agent_hooks():
299299
hooks = AgentHooksForTests()
300300
model = FakeModel()
301301
agent_1 = Agent(name="test_1", model=model)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.