-
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat:Enhance LangSmith library with improvements to ChartsClient and API handling #26
Conversation
WalkthroughThe recent changes introduce a series of enhancements across the LangSmith library, primarily focusing on the Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant ChartsClient
participant API
participant ResponseHandler
Client->>ChartsClient: ReadSectionsApiV1ChartsSectionGetAsync(limit, offset, titleContains)
ChartsClient->>API: GET /api/v1/charts/section?limit&offset&titleContains
API-->>ChartsClient: Response with sections
ChartsClient->>ResponseHandler: Process response
ResponseHandler-->>Client: Return list of sections
sequenceDiagram
participant Client
participant ExamplesClient
participant API
participant ResponseHandler
Client->>ExamplesClient: CreateExampleApiV1ExamplesPostAsync(inputs, datasetId)
ExamplesClient->>API: POST /api/v1/examples
API-->>ExamplesClient: Response with created example
ExamplesClient->>ResponseHandler: Process response
ResponseHandler-->>Client: Return created example
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (9)
- src/libs/LangSmith/Generated/LangSmith.ChartsClient.ReadSectionsApiV1ChartsSectionGet.g.cs (1 hunks)
- src/libs/LangSmith/Generated/LangSmith.ExamplesClient.CreateExampleApiV1ExamplesPost.g.cs (1 hunks)
- src/libs/LangSmith/Generated/LangSmith.Models.Example.g.cs (2 hunks)
- src/libs/LangSmith/Generated/LangSmith.Models.ExampleBulkCreate.g.cs (3 hunks)
- src/libs/LangSmith/Generated/LangSmith.Models.ExampleCreate.g.cs (3 hunks)
- src/libs/LangSmith/Generated/LangSmith.Models.ExampleWithRuns.g.cs (2 hunks)
- src/libs/LangSmith/Generated/LangSmith.Models.ExampleWithRunsCH.g.cs (2 hunks)
- src/libs/LangSmith/Generated/LangSmith.Models.PublicExampleWithRuns.g.cs (2 hunks)
- src/libs/LangSmith/openapi.yaml (16 hunks)
Files skipped from review due to trivial changes (2)
- src/libs/LangSmith/Generated/LangSmith.Models.ExampleWithRunsCH.g.cs
- src/libs/LangSmith/Generated/LangSmith.Models.PublicExampleWithRuns.g.cs
Additional comments not posted (27)
src/libs/LangSmith/Generated/LangSmith.Models.Example.g.cs (1)
41-46
: Reintroduction ofInputs
Property Approved.The
Inputs
property has been correctly reintroduced with necessary JSON serialization attributes, ensuring its proper integration into the data model.src/libs/LangSmith/Generated/LangSmith.Models.ExampleCreate.g.cs (4)
44-46
: Enhanced Flexibility forInputs
Property.The change to use
AnyOf
for theInputs
property allows for more versatile input handling, which is a beneficial enhancement.
48-53
: Introduction ofSplit
Property with Default Value.The new
Split
property is correctly defined with a default value of"base"
, enhancing the class's configurability.
63-66
: Addition ofUseSourceRunIo
Property.The
UseSourceRunIo
property is a valuable addition, providing control over source run input/output operations.
68-72
: Repositioning ofCreatedAt
Property.The repositioning of
CreatedAt
maintains the class's structure without affecting its functionality.src/libs/LangSmith/Generated/LangSmith.Models.ExampleWithRuns.g.cs (1)
41-46
: Reintroduction ofInputs
Property Approved.The
Inputs
property has been correctly reintroduced with necessary JSON serialization attributes, ensuring its proper integration into the data model.src/libs/LangSmith/Generated/LangSmith.Models.ExampleBulkCreate.g.cs (3)
44-46
: Verify serialization and deserialization impact.The
Inputs
property type has been changed to an optional type with a different converter. Ensure that this change does not adversely affect the serialization and deserialization processes.
62-66
: Addition ofUseSourceRunIo
property is approved.The new property
UseSourceRunIo
with a default value offalse
is a useful addition for configuration.
68-73
: Verify the context change forCreatedAt
.The
CreatedAt
property remains but with a changed context. Verify that this aligns with the intended functionality and does not introduce issues.src/libs/LangSmith/Generated/LangSmith.ChartsClient.ReadSectionsApiV1ChartsSectionGet.g.cs (1)
41-104
: Verify HTTP request construction and response handling.Ensure that the HTTP request is correctly constructed with the provided parameters and that the response is properly handled, including error handling and content processing.
src/libs/LangSmith/Generated/LangSmith.ExamplesClient.CreateExampleApiV1ExamplesPost.g.cs (1)
106-139
: Verify parameter changes and documentation.Ensure that the changes to parameter types and the addition of the
useSourceRunIo
parameter are correctly integrated and documented in the method signature and comments.src/libs/LangSmith/openapi.yaml (16)
Line range hint
7661-7734
: LGTM! New endpoints for sections are well-defined.The introduction of the
GET
andPOST
endpoints for/api/v1/charts/section
enhances clarity and functionality for handling sections.
7740-7762
: LGTM! Endpoint for reading charts is well-structured.The
POST
endpoint for/api/v1/charts
is now focused on reading charts, with updated schemas that align with the new API structure.
7770-7792
: LGTM! Endpoint for creating charts is clearly defined.The
POST
endpoint for/api/v1/charts/create
is now focused on creating charts, with well-defined request and response schemas.
Line range hint
11073-11081
: LGTM! Requiringinputs
improves data consistency.Adding
inputs
to the required fields in theExample
schema ensures consistency and aligns with the schema's intended use.
Line range hint
11098-11104
: LGTM! Defininginputs
as an object adds flexibility.The definition of
inputs
as an object in theExample
schema provides flexibility in handling various input structures.
Line range hint
11135-11143
: LGTM! Includinginputs
ensures consistency in bulk operations.Adding
inputs
to theExampleBulkCreate
schema ensures consistency across bulk operations.
11145-11150
: LGTM! Flexibility ininputs
definition is beneficial.Defining
inputs
withanyOf
in theExampleBulkCreate
schema allows for optional inputs, enhancing flexibility.
11165-11174
: LGTM! New properties enhance schema functionality.The introduction of
use_source_run_io
and the optionalcreated_at
field in theExampleBulkCreate
schema enhance its functionality and prevent multiple versions.
11202-11207
: LGTM! Flexibility ininputs
definition is beneficial.Defining
inputs
withanyOf
in theExampleCreate
schema allows for optional inputs, enhancing flexibility.
11216-11229
: LGTM! New properties enhance schema functionality.The introduction of
use_source_run_io
and the optionalcreated_at
field in theExampleCreate
schema enhance its functionality.
11329-11337
: LGTM! Requiringinputs
improves data consistency.Adding
inputs
to the required fields in theExampleWithRuns
schema ensures consistency and aligns with the schema's intended use.
Line range hint
11355-11361
: LGTM! Defininginputs
as an object adds flexibility.The definition of
inputs
as an object in theExampleWithRuns
schema provides flexibility in handling various input structures.
11385-11393
: LGTM! Requiringinputs
improves data consistency.Adding
inputs
to the required fields in theExampleWithRunsCH
schema ensures consistency and aligns with the schema's intended use.
Line range hint
11411-11417
: LGTM! Defininginputs
as an object adds flexibility.The definition of
inputs
as an object in theExampleWithRunsCH
schema provides flexibility in handling various input structures.
13698-13706
: LGTM! Requiringinputs
improves data consistency.Adding
inputs
to the required fields in thePublicExampleWithRuns
schema ensures consistency and aligns with the schema's intended use.
Line range hint
13724-13730
: LGTM! Defininginputs
as an object adds flexibility.The definition of
inputs
as an object in thePublicExampleWithRuns
schema provides flexibility in handling various input structures.
Summary by CodeRabbit
New Features
Improvements
Bug Fixes