[CI] Ignore ruff D209, rejoin the docstrings it split, and silence incompatible-rule warnings (#57212)
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com> Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
1085b64425
commit
651a88c09a
@@ -219,8 +219,7 @@ class Hermes2ProToolParser(ToolParser):
|
||||
|
||||
Returns a ``DeltaMessage`` containing either plain content (for
|
||||
text preceding any tool call) or one or more ``DeltaToolCall``
|
||||
entries, or ``None`` if there is nothing new to send yet.
|
||||
"""
|
||||
entries, or ``None`` if there is nothing new to send yet."""
|
||||
try:
|
||||
# Extract any content before tool calls.
|
||||
content = self._extract_content(current_text)
|
||||
|
||||
@@ -114,8 +114,7 @@ class Lfm2ToolParser(ToolParser):
|
||||
"""Drop any orphan <|tool_call_end|> (and the preceding text) from
|
||||
trailing content. LFM2 occasionally echoes the call body after the
|
||||
first end token and caps it with a second end token; everything
|
||||
through the last such orphan is model garbage, not user content.
|
||||
"""
|
||||
through the last such orphan is model garbage, not user content."""
|
||||
last_orphan = raw_after.rfind(TOOL_CALL_END)
|
||||
if last_orphan != -1:
|
||||
return raw_after[last_orphan + len(TOOL_CALL_END) :]
|
||||
|
||||
@@ -426,8 +426,7 @@ def get_json_schema_from_tools(
|
||||
|
||||
class UnexpectedAstError(Exception):
|
||||
"""Raised when the AST structure does not match the expected
|
||||
pythonic tool call format.
|
||||
"""
|
||||
pythonic tool call format."""
|
||||
|
||||
pass
|
||||
|
||||
|
||||
Reference in New Issue
Block a user