feat(agent): Release agent SDK (#1396)

This commit is contained in:
Fangyin Cheng
2024-04-10 22:44:53 +08:00
committed by GitHub
parent 37e7c0151b
commit df80bc2079
152 changed files with 5680 additions and 6114 deletions

View File

@@ -1,13 +1,10 @@
"""Utilities for the json_fixes package."""
import json
import logging
import os.path
import re
from dataclasses import asdict, dataclass, is_dataclass
from dataclasses import asdict, is_dataclass
from datetime import date, datetime
from jsonschema import Draft7Validator
logger = logging.getLogger(__name__)
LLM_DEFAULT_RESPONSE_FORMAT = "llm_response_format_1"

View File

@@ -1,4 +1,5 @@
import re
from typing import Dict
def is_all_chinese(text):
@@ -34,7 +35,7 @@ def is_scientific_notation(string):
return False
def extract_content(long_string, s1, s2, is_include: bool = False):
def extract_content(long_string, s1, s2, is_include: bool = False) -> Dict[int, str]:
# extract text
match_map = {}
start_index = long_string.find(s1)