Skip to content

Commit 2ac5002

Browse files
feat(api): api update
1 parent f1cea4d commit 2ac5002

File tree

4 files changed

+6
-24
lines changed

4 files changed

+6
-24
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
timeout-minutes: 10
2020
name: lint
2121
runs-on: ${{ github.repository == 'stainless-sdks/asktable-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
22-
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
22+
if: (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata')
2323
steps:
2424
- uses: actions/checkout@v6
2525

@@ -38,7 +38,7 @@ jobs:
3838
run: ./scripts/lint
3939

4040
build:
41-
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
41+
if: (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata')
4242
timeout-minutes: 10
4343
name: build
4444
permissions:

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 101
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/datamini%2Fasktable-19546db54db4d5fe31d84567ab15607ca8640a790512d8e018fa515775e76cce.yml
3-
openapi_spec_hash: bd19efe5301965c58bb6a40c0dd98067
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/datamini%2Fasktable-3d14223aff5b36054429657d79df4f842b934d05a970de387b4e34fbbe6bbbe3.yml
3+
openapi_spec_hash: f5e2bb7eafad08b801936a4bfc7abf4f
44
config_hash: acdf4142177ed1932c2d82372693f811

src/asktable/types/answer_response.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
from .._models import BaseModel
88

9-
__all__ = ["AnswerResponse", "Answer", "AnswerAttachment", "Request", "Timing"]
9+
__all__ = ["AnswerResponse", "Answer", "AnswerAttachment", "Request"]
1010

1111

1212
class AnswerAttachment(BaseModel):
@@ -45,14 +45,6 @@ class Request(BaseModel):
4545
"""是否同时将数据,作为 json 格式的附件一起返回"""
4646

4747

48-
class Timing(BaseModel):
49-
accessor_duration: Optional[float] = None
50-
51-
llm_duration: Optional[float] = None
52-
53-
total_duration: Optional[float] = None
54-
55-
5648
class AnswerResponse(BaseModel):
5749
id: str
5850

@@ -72,6 +64,4 @@ class AnswerResponse(BaseModel):
7264

7365
err_msg: Optional[str] = None
7466

75-
timing: Optional[Timing] = None
76-
7767
trace_id: Optional[str] = None

src/asktable/types/query_response.py

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
from .._models import BaseModel
77

8-
__all__ = ["QueryResponse", "Query", "Request", "Timing"]
8+
__all__ = ["QueryResponse", "Query", "Request"]
99

1010

1111
class Query(BaseModel):
@@ -39,12 +39,6 @@ class Request(BaseModel):
3939
"""在扮演这个角色时需要传递的变量值,用 Key-Value 形式传递"""
4040

4141

42-
class Timing(BaseModel):
43-
llm_duration: Optional[float] = None
44-
45-
total_duration: Optional[float] = None
46-
47-
4842
class QueryResponse(BaseModel):
4943
id: str
5044

@@ -64,6 +58,4 @@ class QueryResponse(BaseModel):
6458

6559
err_msg: Optional[str] = None
6660

67-
timing: Optional[Timing] = None
68-
6961
trace_id: Optional[str] = None

0 commit comments

Comments
 (0)