Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

HHH-19880 Move Hibernate Tools'hibernate-assistant module to Hibernate ORM#11156

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Draft
mbellade wants to merge1 commit intohibernate:main
base:main
Choose a base branch
Loading
frommbellade:language-module

Conversation

@mbellade
Copy link
Member

https://hibernate.atlassian.net/browse/HHH-19880

Opening as draft, TBD:

  • module location (I pickedtooling/assistant for now)
  • naming (washibernate-tools-language)
  • Documentation ?

By submitting this pull request, I confirm that my contribution is made under the terms of theApache 2.0 license
and can be relicensed under the terms of theLGPL v2.1 license in the future at the maintainers' discretion.
For more information on licensing, please checkhere.


Copy link
Member

@yrodiereyrodiere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Thank you! A few comments below.
As long as everything is clearly marked as incubating I think it's all fine, but mostly we'll need the ack from Steve regarding the inclusion/publishing of a new module.

Comment on lines 17 to 21
- Access to data is *constrained to the mapped domain model*. The only tables the LLM will be able to access are the ones that have a corresponding entity class, and only columns listed as fields in your objects can be read. Furthermore, custom filters and SQL restrictions can be applied to further restrict the scope of the data exposed through these tools. You don’t have to worry about creating custom database-level users or permissions only to ensure sensitive information is not exposed to AI services;
- Natively maps results to *Java objects* for direct application consumption, but can also be serialized and passed back to the model to obtain an *informed natural language response based on your existing data*;
- Hibernate’s query language parsing can identify the *type of query* being executed and prevent accidental data modifications when the user only meant to read data;
- *Fail-early* in case generative AI produces incorrect statements. Thanks to Hibernate’s advanced query validation and type-safety features, we don’t need to make a round-trip to the database before noticing a problem, increasing both reliability and overall performance. It’s also easy to understand what the problem with the generated query is thanks to clear error messages, and attempt to solve it either manually or with subsequent prompts;
- With HQL it’s easier to write more *complex queries* involving multiple entities (i.e. tables) thanks to associations, embeddable values and inheritance. LLMs have an easier time generating valid queries that provide useful information to the user when compared to plain SQL, since Hibernate's query language is closer to natural language.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I think it's fine to list features, to say what this think can help you with, and how it does so.

But I wouldn't try to make claims about safety or to compare ease of use with other solutions. That would belong in a blog post IMO.

Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Sure, I didn't know what to add here apart from possible use-cases / advantages of using this module, so that's what I did. If we want to keep this brief, just for reference, we can definitely remove this whole paragraph.

Copy link
Member

@yrodiereyrodiere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I found two incorrect heading levels, but otherwise LGTM. Let's ask Steve on Monday?

mbellade reacted with thumbs up emoji
No implementation is included, but the above provides the building blocks for integration with generative AI services/APIs.

[[assistant-gen-ai]]
==== Generative AI integration considerations
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Incorrect heading level

Suggested change
====Generative AI integration considerations
===Generative AI integration considerations



[[assistant-serialization]]
==== Serialization Components
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Incorrect heading level

Suggested change
====Serialization Components
===Serialization Components

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@yrodiereyrodiereyrodiere left review comments

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@mbellade@yrodiere

[8]ページ先頭

©2009-2025 Movatter.jp