-
Notifications
You must be signed in to change notification settings - Fork 699
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
[FEATURE] UX: handle tool misconfiguration better #983
Labels
Comments
langchain4j
changed the title
[FEATURE] UX: handle tool configuration better
[FEATURE] UX: handle tool misconfiguration better
Apr 19, 2024
If we try to create an object when we have a Class as a parameter. Do we have to handle the following case too ?
|
@anunnakian after a second thought, I am not sure it is a good idea to introduce another reflexion usage, I would rather just throw an exception if the provided object is a |
Got it! could you assign this issue to me, I'll make a PR at the end of the day |
langchain4j
added a commit
that referenced
this issue
May 17, 2024
## Issue #983 ## Change When we configure a tool by using a `Class` instance, we get an exception because only object instances are allowed. ## General checklist <!-- Please double-check the following points and mark them like this: [X] --> - [ ] There are no breaking changes - [ ] I have added unit and integration tests for my change - [ ] I have manually run all the unit and integration tests in the module I have added/changed, and they are all green - [ ] I have manually run all the unit and integration tests in the [core](https://github.com/langchain4j/langchain4j/tree/main/langchain4j-core) and [main](https://github.com/langchain4j/langchain4j/tree/main/langchain4j) modules, and they are all green <!-- Before adding documentation and example(s) (below), please wait until the PR is reviewed and approved. --> - [ ] I have added/updated the [documentation](https://github.com/langchain4j/langchain4j/tree/main/docs/docs) - [ ] I have added an example in the [examples repo](https://github.com/langchain4j/langchain4j-examples) (only for "big" features) ## Checklist for adding new model integration <!-- Please double-check the following points and mark them like this: [X] --> - [ ] I have added my new module in the [BOM](https://github.com/langchain4j/langchain4j/blob/main/langchain4j-bom/pom.xml) ## Checklist for adding new embedding store integration <!-- Please double-check the following points and mark them like this: [X] --> - [ ] I have added a `{NameOfIntegration}EmbeddingStoreIT` that extends from either `EmbeddingStoreIT` or `EmbeddingStoreWithFilteringIT` - [ ] I have added my new module in the [BOM](https://github.com/langchain4j/langchain4j/blob/main/langchain4j-bom/pom.xml) ## Checklist for changing existing embedding store integration <!-- Please double-check the following points and mark them like this: [X] --> - [ ] I have manually verified that the `{NameOfIntegration}EmbeddingStore` works correctly with the data persisted using the latest released version of LangChain4j --------- Co-authored-by: LangChain4j <langchain4j@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In the following case, when tools is a class, not an object, we should do a better job handling this situation.
Exception should be thrown if (one of) the provided object(s) is a
Class
.The text was updated successfully, but these errors were encountered: